docker improvement: ATUIN_DB_PASSWORD_FILE
It would be nice if somehow the containerized sync server could read the DB password from a file, thus enabling e.g. docker swarm's secret facility, which presents secrets to containers as files. Now I'm forced to override the entrypoint, and insert a shell command to read the pwd file and construct the DB URI, and then execute the atuin server.
I realize that this is tricky exactly because a URI needs to be constructed, but there might be some solution. Maybe ATUIN_DB_URI_FILE, and store the whole thing in the secret?
Would like to configure atuin pgsql connection with password from file like this: (this snipped is for kubernetes, but file based secrets is also well supported in docker)
env:
ATUIN_DB_HOST:
valueFrom:
secretKeyRef:
name: pgsql-secret
key: host
ATUIN_DB_PORT:
valueFrom:
secretKeyRef:
name: pgsql-secret
key: port
ATUIN_DB_NAME:
valueFrom:
secretKeyRef:
name: pgsql-secret
key: dbname
ATUIN_DB_USERNAME:
valueFrom:
secretKeyRef:
name: pgsql-secret
key: user
ATUIN_DB_PASSWORD_FILE: /var/run/secrets/pgpassword
instead of using the URI.