Exposing Environment Variables to subsequent processes

Hey everyone,

I’m trying to create a deploy pipeline for my project. All code is available here:

Everything works fine in the .circleci/config.yml file. The issue is within the deploy/run.sh script that I run in the same process.

I’m very unfamiliar with bash and need help understanding how I may get PG_USERNAME, PG_PASS, CIRCLE_SHA (which are defined in my circle env variable settings) to be accessible within the docker-compose.deploy.yml file.

My assumption was that by simply running run.sh in the same process as the circle job all would be well and good. But it does not seem to be working.

You can define just a variable key in your YAML file, and Docker Compose will pass it through from the host OS to the guest container. See here.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.