Split out service management from the installation type.

This commit is contained in:
sparrowhawk 2020-08-14 13:46:05 +02:00 committed by Timothée Floure
parent ef748cf8e2
commit 647833580d
No known key found for this signature in database
GPG key ID: 4502C902C00A1E12
2 changed files with 3 additions and 3 deletions

View file

@ -18,5 +18,4 @@ EOF
cat << EOF
cd /var/wiki || exit 1
npm install
service start wikijs
EOF

View file

@ -48,11 +48,12 @@ fi
db_pass="$(cat "${__object:?}/parameter/database-password")"
__package nodejs
__package nghttp2-dev # Required for some reason, else a symbol is missing
__package npm
__directory /var/wiki/
# These things are Alpine-dependant.
__file /etc/init.d/wikijs --source "${__files:?}/files/wikijs-openrc"
require='__file/etc/init.d/wikijs' __start_on_boot wikijs
__package nghttp2-dev # Required for some reason, else a symbol is missing
mkdir -p "${__object:?}/files"
"${__type:?}/files/config.yml.sh" "$db_pass" > "${__object:?}/files/config.yml"