Initial add

This commit is contained in:
bkraul 2019-07-08 11:20:18 -05:00
commit 334288e104
6 changed files with 80 additions and 0 deletions

View 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
nginx-alpine/Dockerfile Normal file
View File

@ -0,0 +1,18 @@
FROM webdevops/php-nginx: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

7
nginx-alpine/build Normal file
View File

@ -0,0 +1,7 @@
#!/bin/sh
docker pull webdevops/php-nginx:alpine
docker build $1\
-t bkraul/kimai2:nginx-alpine \
.

View 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
nginx-ubuntu/Dockerfile Normal file
View File

@ -0,0 +1,18 @@
FROM webdevops/php-nginx: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

7
nginx-ubuntu/build Normal file
View File

@ -0,0 +1,7 @@
#!/bin/sh
docker pull webdevops/php-nginx:ubuntu-18.04
docker build $1\
-t bkraul/kimai2:nginx-ubuntu \
.