Most of this is just gpt slop
This commit is contained in:
parent
9213ca6df6
commit
57afb8862d
12 changed files with 600 additions and 0 deletions
34
docker/Dockerfile
Normal file
34
docker/Dockerfile
Normal file
|
@ -0,0 +1,34 @@
|
|||
FROM registry.gitlab.com/dxcker/apache-php:latest
|
||||
|
||||
# Switch over to root user
|
||||
USER root
|
||||
|
||||
RUN apt update \
|
||||
&& apt -y install unzip git curl \
|
||||
&& apt -y install php-xml php-mbstring php-curl php-pdo php-mysql \
|
||||
&& apt autoclean
|
||||
|
||||
# Enable mod_rewrite and mod_headers. Should be upstream but hey.
|
||||
RUN a2enmod rewrite headers
|
||||
|
||||
# Reconfigure apache for this project
|
||||
RUN echo "DocumentRoot /var/www/public" >> /etc/apache2/apache2.conf
|
||||
RUN sed -i 's/\/var\/www\/html/\/var\/www\/public/g' /etc/apache2/apache2.conf
|
||||
|
||||
# Install Composer
|
||||
COPY --from=composer:latest /usr/bin/composer /usr/bin/composer
|
||||
|
||||
# Copy over entrypoint
|
||||
COPY docker/entrypoint.sh /entrypoint.sh
|
||||
RUN chmod +x /entrypoint.sh
|
||||
|
||||
# Copy over files
|
||||
WORKDIR /var/www/
|
||||
|
||||
RUN mkdir -p data/files data && chown -R app:app data
|
||||
COPY src/ .
|
||||
RUN chown -R app:app /var/www/
|
||||
|
||||
USER app
|
||||
|
||||
ENTRYPOINT ["/entrypoint.sh"]
|
Loading…
Add table
Add a link
Reference in a new issue