Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/higebu/iap-token
A CLI tool to generate Google Cloud Identity-Aware Proxy token
https://github.com/higebu/iap-token
Last synced: about 1 month ago
JSON representation
A CLI tool to generate Google Cloud Identity-Aware Proxy token
- Host: GitHub
- URL: https://github.com/higebu/iap-token
- Owner: higebu
- License: mit
- Created: 2022-05-18T00:40:42.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2022-09-28T11:06:41.000Z (over 2 years ago)
- Last Synced: 2024-10-04T19:44:27.094Z (4 months ago)
- Language: Go
- Homepage:
- Size: 23.4 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# iap-token
Generate Google Cloud Identity-Aware Proxy token with [Impersonate Service Account](https://cloud.google.com/iam/docs/impersonating-service-accounts)
# Install
```shell
go install github.com/higebu/iap-token@latest
```# Usage
```shell
export CLOUDSDK_AUTH_IMPERSONATE_SERVICE_ACCOUNT=user-sa-name@project-id.iam.gserviceaccount.com
export IAP_CLIENT_ID=xxxxx.apps.googleusercontent.com
curl -H "Authorization: Bearer $(iap-token)" https://example.com
# curl -H "Proxy-Authorization: Bearer $(iap-token)" https://example.com
```