2018-09-13 13:34:27 +02:00
|
|
|
IMAGE mifosx
|
2019-02-26 20:24:02 +01:00
|
|
|
LAYER shared/alpine3.9
|
|
|
|
LAYER shared/alpine3.9-java8
|
2019-03-01 12:22:17 +01:00
|
|
|
LAYER shared/alpine3.9-tomcat8.5
|
2018-09-13 13:34:27 +02:00
|
|
|
LAYER mifosx/mifosx
|
|
|
|
|
|
|
|
RUN EOF
|
|
|
|
# Install full-featured wget to work around sourceforge bugs
|
|
|
|
apk --no-cache add wget
|
|
|
|
|
|
|
|
# Download Mifos X
|
2018-12-10 09:31:18 +01:00
|
|
|
wget https://sourceforge.net/projects/mifos/files/Mifos%20X/mifosplatform-18.03.01.RELEASE.zip/download -O /tmp/mifosx.zip
|
2018-09-13 13:34:27 +02:00
|
|
|
mkdir /srv/tomcat/webapps/fineract-provider
|
|
|
|
unzip /tmp/mifosx.zip -d /tmp
|
|
|
|
unzip /tmp/fineractplatform-18.03.01.RELEASE/fineract-provider.war -d /srv/tomcat/webapps/fineract-provider
|
|
|
|
mv /tmp/fineractplatform-18.03.01.RELEASE/apps/community-app /srv/tomcat/webapps/ROOT
|
|
|
|
mv /tmp/fineractplatform-18.03.01.RELEASE/database/mifospltaform-tenants-first-time-install.sql /tmp/mifospltaform-tenants-first-time-install.sql
|
|
|
|
|
|
|
|
# Download Java library dependencies
|
2019-03-01 12:22:17 +01:00
|
|
|
wget http://central.maven.org/maven2/org/drizzle/jdbc/drizzle-jdbc/1.4/drizzle-jdbc-1.4.jar -O /srv/tomcat/lib/drizzle-jdbc-1.4.jar
|
2018-09-13 13:34:27 +02:00
|
|
|
|
|
|
|
# Create OS user
|
|
|
|
addgroup -S -g 8012 mifosx
|
|
|
|
adduser -S -u 8012 -h /srv/tomcat -s /bin/false -g mifosx -G mifosx mifosx
|
|
|
|
chown -R mifosx:mifosx /srv/tomcat/conf /srv/tomcat/logs /srv/tomcat/temp /srv/tomcat/webapps /srv/tomcat/work
|
2019-03-01 12:22:17 +01:00
|
|
|
|
2018-09-13 13:34:27 +02:00
|
|
|
# Cleanup
|
|
|
|
apk --no-cache del wget
|
|
|
|
rm -rf /tmp/fineractplatform-18.03.01.RELEASE /tmp/mifosx.zip
|
2018-12-10 09:31:18 +01:00
|
|
|
EOF
|
|
|
|
|
|
|
|
# s6 required for single service due to hanging threads
|
|
|
|
COPY lxc
|
2018-09-13 13:34:27 +02:00
|
|
|
|
2018-12-10 09:31:18 +01:00
|
|
|
RUN EOF
|
2018-09-13 13:34:27 +02:00
|
|
|
# Update Czech translation of community-app
|
|
|
|
wget 'https://translatewiki.net/wiki/Special:ExportTranslations?group=out-mifos&language=cs&format=export-to-file' -O /srv/tomcat/webapps/ROOT/global-translations/locale-cs.json
|
|
|
|
cd /srv/tomcat/webapps/ROOT/scripts/
|
|
|
|
patch -p0 </tmp/locale-cs.patch
|
|
|
|
rm /tmp/locale-cs.patch
|
|
|
|
EOF
|
|
|
|
|
2018-09-14 18:13:11 +02:00
|
|
|
MOUNT FILE /srv/mifosx/conf/server.xml srv/tomcat/conf/server.xml
|
|
|
|
MOUNT FILE /srv/mifosx/conf/context.xml srv/tomcat/webapps/fineract-provider/META-INF/context.xml
|
2018-09-13 14:58:03 +02:00
|
|
|
|
2018-09-21 11:04:12 +02:00
|
|
|
CMD s6-svscan /etc/services.d
|