Running nginx with ssl certificate on build env


I’m trying to run an nginx docker inside the build env, but my nginx configuration is requiring a ssl certificate path.

On my production server i’m attach a volume to the docker image with the relevant certificate keys.

but on circleci when i build and run the docker nginx doesnt start because of obviously missing certificates.

Any suggestions ?

One way would be to build a custom nginx based image which has keys built in (some test keys).
Other would be to generate keys non-interactively in process of the build and run nginx from the base container in background.

1 Like

I think i will generate a test certificate on the build ENV.

1 Like