Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implements config file env map #1

Closed
babarot opened this issue Nov 21, 2017 · 1 comment
Closed

Implements config file env map #1

babarot opened this issue Nov 21, 2017 · 1 comment

Comments

@babarot
Copy link
Owner

babarot commented Nov 21, 2017

{
  "maps": [
    {
      "url": "https://iap-protected.app1.com",
      "env": {
        "GOOGLE_APPLICATION_CREDENTIALS": "/path/to/google-cred-app1.json",
        "IAP_CLIENT_ID": "342624545358-asdfd8fas9df8sd7ga0sdguadfpvqp69.apps.googleusercontent.com",
        "IAP_CURL_BIN": "httpstat"
      }
    },
    {
      "url": "https://iap-protected.app2.com",
      "env": {
        "GOOGLE_APPLICATION_CREDENTIALS": "/path/to/google-cred-app2.json",
        "IAP_CLIENT_ID": "342624545358-asdfd8fas9df8sd7ga0sdguadfpvqp69.apps.googleusercontent.com"
      }
    },
    {
      "url": "https://iap-protected.app3.com",
      "env": {
        "GOOGLE_APPLICATION_CREDENTIALS": "/path/to/google-cred-app3.json",
        "IAP_CLIENT_ID": "342624545358-asdfd8fas9df8sd7ga0sdguadfpvqp69.apps.googleusercontent.com"
      }
    }
  ]
}

Prepare a JSON file like above that maps the URL given to the argument and the necessary credentials for that connection so that you can connect automatically:

$ iap_curl https://iap-protected.app3.com
@babarot babarot changed the title Implements credentials config map Implements config file env map Nov 21, 2017
babarot added a commit that referenced this issue Nov 21, 2017
@babarot
Copy link
Owner Author

babarot commented Nov 21, 2017

Implemented --list-urls options. Thanks to that, you can run the following commands:

$ iap_curl $(iap_curl --list-urls | peco)

babarot added a commit that referenced this issue Nov 21, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant