Reputation: 174
I was able to deploy the site locally after adding the putenv
in my wp-config.php file. However when I run gcloud app deploy
, I get the error in the domain.
According to https://wordpress.org/plugins/gcs/#installation I have placed my json file in Dropbox, see screenshot below. Where should the right place be?
Screenshot showing putenv
in wp-config.php
See the error I get after deploying Dosbranding
Upvotes: 0
Views: 6732
Reputation: 2034
i have a similiar problem with php 7.2. php can't read enviroment vars, this must be declared into the etc/apache2/envars add this lines to this file, solved my problem
export GOOGLE_APPLICATION_CREDENTIALS=/var/www/html/myjson.json
export FIREBASE_CREDENTIALS=/var/www/html/myjson.json
Upvotes: 2
Reputation: 116
It says
Upload the json key file to the hosting server. Don’t put it in a public serving area.
that means you have to deploy it with your project.
Your dropbox folder is local to your computer hence it is visible when you run local dev instance.
You probably should place the json in the same location as your wp-config.php and than set the env to:
putenv('GOOGLE_APPLICATION_CREDENTIALS=dosbrandingke-f191a195723d.json');
Upvotes: 0