Score:0

bitnami/nginx - stop generating RSA key pair

pt flag

Please is there a way to stop bitnami/nginx to generate RSA key pair on start (since I am not using SSL in nginx.conf)?

It takes 25-30 seconds to start the app :(

Thanks

nginx 20:56:32.30
nginx 20:56:32.50 Welcome to the Bitnami nginx container
nginx 20:56:32.80 Subscribe to project updates by watching https://github.com/bitnami/containers
nginx 20:56:33.00 Submit issues and feature requests at https://github.com/bitnami/containers/issues
nginx 20:56:33.20
nginx 20:56:33.39 INFO ==> ** Starting NGINX setup **
nginx 20:56:34.70 INFO ==> Validating settings in NGINX_* env vars
nginx 20:56:35.30 WARN ==> The NGINX configuration file '/opt/bitnami/nginx/conf/nginx.conf' is not writable by current user. Configurations based on environment variables will not be applied.
Generating RSA private key, 4096 bit long modulus (2 primes)
.....................++++
.....................................................++++
e is 65537 (0x010001)
Signature ok
subject=CN = example.com
Getting Private key
nginx 20:57:00.90 INFO ==> No custom scripts in /docker-entrypoint-initdb.d
nginx 20:57:01.40 INFO ==> Initializing NGINX
realpath: /bitnami/nginx/conf/vhosts: No such file or directory
nginx 20:57:03.70 INFO ==> ** NGINX setup finished! **
Score:0
hu flag

Based on their README you can just store these certificates persistently:

docker run --name nginx \
  -v /path/to/my_server_block.conf:/opt/bitnami/nginx/conf/server_blocks/my_server_block.conf:ro \
  -v /path/to/nginx-persistence/certs:/certs \
  bitnami/nginx:latest

Try it out. I've found this here.

Score:0
pt flag

there must exist (even empty) file /certs/server.crt even if you do not have SSL configured in your nginx.conf...

section from image starting scrpit

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.