waku-org / nwaku-compose

Deployment docker-compose files to deploy an nwaku node
13 stars 22 forks source link

feat: add support for .env #27

Closed vpavlin closed 10 months ago

vpavlin commented 11 months ago

This PR adds support for .env for registration and running docker-compose

It also removes the PG port exposure (let me know if I should submit it as a separate PR)

It also tweaks the shell scripts a bit, but there should be no change in behaviour

vpavlin commented 11 months ago

In that case let's do this instead of the 3 exports as currently recommended approach is

  1. more complex (3 commands instead of 1 + file edit)
  2. insecure (pasting your secrets in shell is a terrible practice)
  3. not easily reproducible (if you close the terminal and open it again and run docker compose up again, the variables are gone)

Using .env is a "standard", exporting secrets in env vars is promoting bad practices:)

I am happy to remove the exports and leave just the .env - WDYT @alrevuelta ?

vpavlin commented 11 months ago

@alrevuelta updated the README

alrevuelta commented 10 months ago

@vpavlin Already approved, can we merge this?