mirror of
https://github.com/wallabag/docker.git
synced 2026-02-27 12:17:37 +01:00
Add docker secret support
This commit is contained in:
@ -44,6 +44,8 @@ Default login is `wallabag:wallabag`.
|
||||
- `-e POPULATE_DATABASE=...`(defaults to "True". Does the DB has to be populated or is it an existing one)
|
||||
- `-e SYMFONY__ENV__SERVER_NAME=...` (defaults to "Your wallabag instance". Specifies a user-friendly name for the 2FA issuer)
|
||||
|
||||
To set any of these environment variables from a file (for instance a Docker Secret), append `__FILE` to the name of the environment variable.
|
||||
|
||||
## SQLite
|
||||
|
||||
The easiest way to start wallabag is to use the SQLite backend. You can spin that up with
|
||||
|
||||
@ -1,5 +1,14 @@
|
||||
#!/bin/sh
|
||||
|
||||
FILE_ENV_VARS="$(env | grep '__FILE=')"
|
||||
for env_var in $FILE_ENV_VARS; do
|
||||
var_name="$(echo $env_var | grep -o '.*__FILE=' | sed 's/__FILE=//g')"
|
||||
file_path="$(echo $env_var | grep -o '__FILE=.*' | sed 's/__FILE=//g')"
|
||||
file_content="$(cat $file_path)"
|
||||
new_var="$(echo $var_name=$file_content)"
|
||||
export $(echo $new_var | xargs)
|
||||
done
|
||||
|
||||
provisioner () {
|
||||
echo "Starting provisioner..."
|
||||
if ! out=`ansible-playbook -i /etc/ansible/hosts /etc/ansible/entrypoint.yml -c local "$@"`;then
|
||||
|
||||
Reference in New Issue
Block a user