Disassembler
ce325cf3d0
- Bump basic OS to Alpine 3.9 - Restructure repo and add layer versioning - Use JSON for all metadata - Merge abuild branch (but without abuild)
20 lines
624 B
Bash
Executable File
20 lines
624 B
Bash
Executable File
#!/bin/sh
|
|
set -ev
|
|
|
|
cd $(realpath $(dirname "${0}"))/install
|
|
|
|
# Configure OpenMapKit
|
|
export OPENMAPKIT_ADMIN_USER="admin"
|
|
export OPENMAPKIT_ADMIN_PWD=$(head -c 12 /dev/urandom | base64)
|
|
mkdir -p /srv/openmapkit/conf /srv/openmapkit/data
|
|
chown -R 8007:8007 /srv/openmapkit/data
|
|
cp -rp /var/lib/lxc/openmapkit/openmapkit/srv/openmapkit/data/. /srv/openmapkit/data
|
|
envsubst <srv/openmapkit/conf/settings.js >/srv/openmapkit/conf/settings.js
|
|
|
|
# Install service
|
|
cp etc/init.d/openmapkit /etc/init.d/openmapkit
|
|
rc-update -u
|
|
|
|
# Register application
|
|
vmmgr register-app openmapkit "${OPENMAPKIT_ADMIN_USER}" "${OPENMAPKIT_ADMIN_PWD}"
|