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

Gcloud failing - file referenced in environment variable needs volume mapping #3

Open
Haulien opened this issue Apr 5, 2019 · 0 comments

Comments

@Haulien
Copy link

Haulien commented Apr 5, 2019

So I've been updating my server from 8.3 and have run into an issue regarding Traefik.

With the 8.5 rewrite to make Traefik more modular (nice work!) it has broken providers that reference files in their environment variables. For example, Google Cloud's GCE_SERVICE_ACCOUNT_FILE environment variable, which gets mapped to a volume in v8.4 for later usage.

The fix for this is to go the old way, add the file referenced in the env variable as a volume. I hardcoded it in my fork, however obviously this isn't ideal....


Traefik also started erroring when using GCE_SERVICE_ACCOUNT_FILE,:

cannot get ACME client googlecloud: unable to get Google Cloud client: google: could not find default credentials

however changing the environment variable to GOOGLE_APPLICATION_CREDENTIALS as per Google's documentation, which is now also supported by go-acme/lego (and as such Traefik) it started to work with no issues (after the above hardcoding in my fork, without it it said the file referenced in the env was not found...)

I'd recommend switching GCE_SERVICE_ACCOUNT_FILE to GOOGLE_APPLICATION_CREDENTIALS however it could pose issues with those using gcloud currently... though for those using gcloud currently it's unlikely Traefik is working for them anyway using the newer versions...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant