Added apache images, restructured
This commit is contained in:
parent
334288e104
commit
188167f6b1
18
apache-alpine/Dockerfile
Normal file
18
apache-alpine/Dockerfile
Normal file
|
@ -0,0 +1,18 @@
|
|||
FROM webdevops/php-apache:alpine
|
||||
MAINTAINER Belman Kraul <bkraul@belmankraul.com>
|
||||
|
||||
ENV \
|
||||
WEB_DOCUMENT_ROOT="/app/public"
|
||||
|
||||
RUN git clone https://github.com/kevinpapst/kimai2.git /app && \
|
||||
sed "s/prod/dev/g" /app/.env.dist > /app/.env && \
|
||||
chown -R ${APPLICATION_UID}:${APPLICATION_GID} /app && \
|
||||
su -c '/usr/local/bin/composer install --working-dir=/app --optimize-autoloader' -l application && \
|
||||
su -c '/usr/local/bin/composer require zendframework/zend-ldap --working-dir=/app' -l application && \
|
||||
rm /app/.env && \
|
||||
touch /app/.env && \
|
||||
chown ${APPLICATION_UID}:${APPLICATION_GID} /app/.env
|
||||
|
||||
COPY ./50-kimai-init.sh /opt/docker/provision/entrypoint.d/50-kimai-init.sh
|
||||
|
||||
WORKDIR /app
|
6
apache-alpine/build
Normal file
6
apache-alpine/build
Normal file
|
@ -0,0 +1,6 @@
|
|||
#!/bin/sh
|
||||
|
||||
docker pull webdevops/php-apache:alpine
|
||||
docker build $1\
|
||||
-t bkraul/kimai2:apache-alpine \
|
||||
.
|
15
apache-ubuntu-18.04/50-kimai-init.sh
Normal file
15
apache-ubuntu-18.04/50-kimai-init.sh
Normal file
|
@ -0,0 +1,15 @@
|
|||
#!/bin
|
||||
|
||||
echo Refreshing .env file...
|
||||
echo APP_ENV=${APP_ENV} > /app/.env
|
||||
echo DATABASE_URL=${DATABASE_URL} >> /app/.env
|
||||
echo MAILER_FROM=${MAILER_FROM} >> /app/.env
|
||||
echo MAILER_URL=${MAILER_URL} >> /app/.env
|
||||
chown ${APPLICATION_UID}:${APPLICATION_GID} /app/.env
|
||||
|
||||
su -c "/app/bin/console cache:clear --env=${APP_ENV} || true" -l application
|
||||
su -c "cd /app && composer install --optimize-autoloader || true" -l application
|
||||
su -c "/app/bin/console doctrine:schema:create || true" -l application
|
||||
su -c "/app/bin/console doctrine:migrations:version --add --all -n || true" -l application
|
||||
su -c "/app/bin/console cache:warmup --env=${APP_ENV} || true" -l application
|
||||
su -c "/app/bin/console kimai:create-user ${APP_ADMIN_USER} ${APP_ADMIN_EMAIL} ROLE_SUPER_ADMIN ${APP_ADMIN_PASS} --env=${APP_ENV} -vvv || true" -l application
|
18
apache-ubuntu-18.04/Dockerfile
Normal file
18
apache-ubuntu-18.04/Dockerfile
Normal file
|
@ -0,0 +1,18 @@
|
|||
FROM webdevops/php-apache:ubuntu-18.04
|
||||
MAINTAINER Belman Kraul <bkraul@belmankraul.com>
|
||||
|
||||
ENV \
|
||||
WEB_DOCUMENT_ROOT="/app/public"
|
||||
|
||||
RUN git clone https://github.com/kevinpapst/kimai2.git /app && \
|
||||
sed "s/prod/dev/g" /app/.env.dist > /app/.env && \
|
||||
chown -R ${APPLICATION_UID}:${APPLICATION_GID} /app && \
|
||||
su -c '/usr/local/bin/composer install --working-dir=/app --optimize-autoloader' -l application && \
|
||||
su -c '/usr/local/bin/composer require zendframework/zend-ldap --working-dir=/app' -l application && \
|
||||
rm /app/.env && \
|
||||
touch /app/.env && \
|
||||
chown ${APPLICATION_UID}:${APPLICATION_GID} /app/.env
|
||||
|
||||
COPY ./50-kimai-init.sh /opt/docker/provision/entrypoint.d/50-kimai-init.sh
|
||||
|
||||
WORKDIR /app
|
6
apache-ubuntu-18.04/build
Normal file
6
apache-ubuntu-18.04/build
Normal file
|
@ -0,0 +1,6 @@
|
|||
#!/bin/sh
|
||||
|
||||
docker pull webdevops/php-apache:ubuntu-18.04
|
||||
docker build $1\
|
||||
-t bkraul/kimai2:apache-ubuntu-18.04 \
|
||||
.
|
|
@ -2,13 +2,13 @@ FROM webdevops/php-nginx:alpine
|
|||
MAINTAINER Belman Kraul <bkraul@belmankraul.com>
|
||||
|
||||
ENV \
|
||||
WEB_DOCUMENT_ROOT="/app/public"
|
||||
WEB_DOCUMENT_ROOT="/app/public"
|
||||
|
||||
RUN git clone https://github.com/kevinpapst/kimai2.git /app && \
|
||||
sed "s/prod/dev/g" /app/.env.dist > /app/.env && \
|
||||
chown -R ${APPLICATION_UID}:${APPLICATION_GID} /app && \
|
||||
su -c '/usr/local/bin/composer install --working-dir=/app --optimize-autoloader' -l application && \
|
||||
su -c '/usr/local/bin/composer require zendframework/zend-ldap --working-dir=/app' -l application && \
|
||||
su -c '/usr/local/bin/composer require zendframework/zend-ldap --working-dir=/app' -l application && \
|
||||
rm /app/.env && \
|
||||
touch /app/.env && \
|
||||
chown ${APPLICATION_UID}:${APPLICATION_GID} /app/.env
|
||||
|
|
15
nginx-ubuntu-18.04/50-kimai-init.sh
Normal file
15
nginx-ubuntu-18.04/50-kimai-init.sh
Normal file
|
@ -0,0 +1,15 @@
|
|||
#!/bin
|
||||
|
||||
echo Refreshing .env file...
|
||||
echo APP_ENV=${APP_ENV} > /app/.env
|
||||
echo DATABASE_URL=${DATABASE_URL} >> /app/.env
|
||||
echo MAILER_FROM=${MAILER_FROM} >> /app/.env
|
||||
echo MAILER_URL=${MAILER_URL} >> /app/.env
|
||||
chown ${APPLICATION_UID}:${APPLICATION_GID} /app/.env
|
||||
|
||||
su -c "/app/bin/console cache:clear --env=${APP_ENV} || true" -l application
|
||||
su -c "cd /app && composer install --optimize-autoloader || true" -l application
|
||||
su -c "/app/bin/console doctrine:schema:create || true" -l application
|
||||
su -c "/app/bin/console doctrine:migrations:version --add --all -n || true" -l application
|
||||
su -c "/app/bin/console cache:warmup --env=${APP_ENV} || true" -l application
|
||||
su -c "/app/bin/console kimai:create-user ${APP_ADMIN_USER} ${APP_ADMIN_EMAIL} ROLE_SUPER_ADMIN ${APP_ADMIN_PASS} --env=${APP_ENV} -vvv || true" -l application
|
|
@ -2,13 +2,13 @@ FROM webdevops/php-nginx:ubuntu-18.04
|
|||
MAINTAINER Belman Kraul <bkraul@belmankraul.com>
|
||||
|
||||
ENV \
|
||||
WEB_DOCUMENT_ROOT="/app/public"
|
||||
WEB_DOCUMENT_ROOT="/app/public"
|
||||
|
||||
RUN git clone https://github.com/kevinpapst/kimai2.git /app && \
|
||||
sed "s/prod/dev/g" /app/.env.dist > /app/.env && \
|
||||
chown -R ${APPLICATION_UID}:${APPLICATION_GID} /app && \
|
||||
su -c '/usr/local/bin/composer install --working-dir=/app --optimize-autoloader' -l application && \
|
||||
su -c '/usr/local/bin/composer require zendframework/zend-ldap --working-dir=/app' -l application && \
|
||||
su -c '/usr/local/bin/composer require zendframework/zend-ldap --working-dir=/app' -l application && \
|
||||
rm /app/.env && \
|
||||
touch /app/.env && \
|
||||
chown ${APPLICATION_UID}:${APPLICATION_GID} /app/.env
|
|
@ -2,6 +2,6 @@
|
|||
|
||||
docker pull webdevops/php-nginx:ubuntu-18.04
|
||||
docker build $1\
|
||||
-t bkraul/kimai2:nginx-ubuntu \
|
||||
-t bkraul/kimai2:nginx-ubuntu-18.04 \
|
||||
.
|
||||
|
Loading…
Reference in New Issue
Block a user