mirror of
https://github.com/bitnami/containers.git
synced 2026-03-15 14:58:17 +08:00
adds app-entrypoint.sh to initialize ruby module at launch
This commit is contained in:
19
bitnami/ruby/rootfs/app-entrypoint.sh
Executable file
19
bitnami/ruby/rootfs/app-entrypoint.sh
Executable file
@@ -0,0 +1,19 @@
|
||||
#!/bin/bash -e
|
||||
|
||||
function initialize {
|
||||
# Package can be "installed" or "unpacked"
|
||||
status=`nami inspect $1`
|
||||
if [[ "$status" == *'"lifecycle": "unpacked"'* ]]; then
|
||||
inputs=""
|
||||
if [[ -f /$1-inputs.json ]]; then
|
||||
inputs=--inputs-file=/$1-inputs.json
|
||||
fi
|
||||
nami initialize $1 $inputs
|
||||
fi
|
||||
}
|
||||
|
||||
for module in ruby; do
|
||||
initialize $module
|
||||
done
|
||||
|
||||
exec /entrypoint.sh "$@"
|
||||
Reference in New Issue
Block a user