89 lines
3.1 KiB
Bash
Executable File
89 lines
3.1 KiB
Bash
Executable File
#!/bin/sh
|
|
set -e
|
|
|
|
SOURCE_DIR=$(realpath $(dirname "${0}"))
|
|
|
|
# Install build and packaging scripts
|
|
ln -s ${SOURCE_DIR}/zz-extra/fix-apk /usr/bin/fix-apk
|
|
ln -s ${SOURCE_DIR}/zz-extra/lxc-build /usr/bin/lxc-build
|
|
ln -s ${SOURCE_DIR}/zz-extra/lxc-pack /usr/bin/lxc-pack
|
|
|
|
# Build basic Alpine LXC image
|
|
mkdir -p /var/lib/lxc/shared/alpine
|
|
wget https://github.com/gliderlabs/docker-alpine/raw/2bfe6510ee31d86cfeb2f37587f4cf866f28ffbc/versions/library-3.8/x86_64/rootfs.tar.xz -O - | tar xJf - -C /var/lib/lxc/shared/alpine
|
|
chmod 755 /var/lib/lxc/shared/alpine
|
|
lxc-build ${SOURCE_DIR}/basic-runtimes/alpine.lxcfile
|
|
|
|
# Build shared overlays
|
|
lxc-build ${SOURCE_DIR}/basic-runtimes/java.lxcfile
|
|
lxc-build ${SOURCE_DIR}/basic-runtimes/libxml.lxcfile
|
|
lxc-build ${SOURCE_DIR}/basic-runtimes/php.lxcfile
|
|
lxc-build ${SOURCE_DIR}/basic-runtimes/python2.lxcfile
|
|
lxc-build ${SOURCE_DIR}/basic-runtimes/python3.lxcfile
|
|
lxc-build ${SOURCE_DIR}/basic-runtimes/nodejs.lxcfile
|
|
lxc-build ${SOURCE_DIR}/basic-runtimes/ruby.lxcfile
|
|
lxc-build ${SOURCE_DIR}/basic-runtimes/tomcat.lxcfile
|
|
|
|
# Build applications
|
|
lxc-build ${SOURCE_DIR}/activemq
|
|
lxc-build ${SOURCE_DIR}/ckan
|
|
lxc-build ${SOURCE_DIR}/ckan-datapusher
|
|
lxc-build ${SOURCE_DIR}/crisiscleanup
|
|
lxc-build ${SOURCE_DIR}/cts
|
|
lxc-build ${SOURCE_DIR}/frontlinesms
|
|
lxc-build ${SOURCE_DIR}/gnuhealth
|
|
lxc-build ${SOURCE_DIR}/kanboard
|
|
lxc-build ${SOURCE_DIR}/mariadb
|
|
lxc-build ${SOURCE_DIR}/mifosx
|
|
lxc-build ${SOURCE_DIR}/motech
|
|
lxc-build ${SOURCE_DIR}/opendatakit
|
|
lxc-build ${SOURCE_DIR}/opendatakit-build
|
|
lxc-build ${SOURCE_DIR}/openmapkit
|
|
lxc-build ${SOURCE_DIR}/pandora
|
|
lxc-build ${SOURCE_DIR}/postgres
|
|
lxc-build ${SOURCE_DIR}/rabbitmq
|
|
lxc-build ${SOURCE_DIR}/redis
|
|
lxc-build ${SOURCE_DIR}/sahana
|
|
lxc-build ${SOURCE_DIR}/sahana-demo
|
|
lxc-build ${SOURCE_DIR}/sambro
|
|
lxc-build ${SOURCE_DIR}/seeddms
|
|
lxc-build ${SOURCE_DIR}/sigmah
|
|
lxc-build ${SOURCE_DIR}/solr
|
|
lxc-build ${SOURCE_DIR}/ushahidi
|
|
|
|
# Create packages
|
|
lxc-pack ${SOURCE_DIR}/basic-runtimes/java.pkg
|
|
lxc-pack ${SOURCE_DIR}/basic-runtimes/libxml.pkg
|
|
lxc-pack ${SOURCE_DIR}/basic-runtimes/php.pkg
|
|
lxc-pack ${SOURCE_DIR}/basic-runtimes/python2.pkg
|
|
lxc-pack ${SOURCE_DIR}/basic-runtimes/python3.pkg
|
|
lxc-pack ${SOURCE_DIR}/basic-runtimes/nodejs.pkg
|
|
lxc-pack ${SOURCE_DIR}/basic-runtimes/ruby.pkg
|
|
lxc-pack ${SOURCE_DIR}/basic-runtimes/tomcat.pkg
|
|
|
|
lxc-pack ${SOURCE_DIR}/activemq
|
|
lxc-pack ${SOURCE_DIR}/ckan
|
|
lxc-pack ${SOURCE_DIR}/ckan-datapusher
|
|
lxc-pack ${SOURCE_DIR}/crisiscleanup
|
|
lxc-pack ${SOURCE_DIR}/cts
|
|
lxc-pack ${SOURCE_DIR}/frontlinesms
|
|
lxc-pack ${SOURCE_DIR}/gnuhealth
|
|
lxc-pack ${SOURCE_DIR}/kanboard
|
|
lxc-pack ${SOURCE_DIR}/mariadb
|
|
lxc-pack ${SOURCE_DIR}/mifosx
|
|
lxc-pack ${SOURCE_DIR}/motech
|
|
lxc-pack ${SOURCE_DIR}/opendatakit
|
|
lxc-pack ${SOURCE_DIR}/opendatakit-build
|
|
lxc-pack ${SOURCE_DIR}/openmapkit
|
|
lxc-pack ${SOURCE_DIR}/pandora
|
|
lxc-pack ${SOURCE_DIR}/postgres
|
|
lxc-pack ${SOURCE_DIR}/rabbitmq
|
|
lxc-pack ${SOURCE_DIR}/redis
|
|
lxc-pack ${SOURCE_DIR}/sahana
|
|
lxc-pack ${SOURCE_DIR}/sahana-demo
|
|
lxc-pack ${SOURCE_DIR}/sambro
|
|
lxc-pack ${SOURCE_DIR}/seeddms
|
|
lxc-pack ${SOURCE_DIR}/sigmah
|
|
lxc-pack ${SOURCE_DIR}/solr
|
|
lxc-pack ${SOURCE_DIR}/ushahidi
|