mirror of
https://github.com/wallabag/docker.git
synced 2026-02-27 20:27:40 +01:00
Add docker secret support
This commit is contained in:
@ -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