Description
When authorizing the Shopify app on production i get a 'Your Shopify app has been successfully authorized' notification.
All settings are working in development (with a second Shopify 'local' app) trough ngrok tunnel.
But in the debugbar there is an error '
craft\shopify\services\Api::getAccessToken | Couldn't save the Shopify Access Token in the .env file. No .env file exists at /srv/app/xxx/htdocs/.env'
This seems to be an issue with Fortrabbit, where the website is hosted and .env vars are stored separately and not in an .env file in the root.
Result is that the webhooks option is not shown after authentication. On reload of the succes page i get an 'Error authorizing app. Invalid OAuth callback.'
EDIT: fixed by creating an empty .env file in the root of production. After authentication copy the generated SHOPIFY_API_ACCESS_TOKEN to the env vars section. Now working!
Additional info
- Craft version: 5.19.17
- PHP version: 8.4
- Plugins & versions: Shopify 7.0.1