Skip to content

Commit

Permalink
update dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
crysg committed Dec 13, 2024
1 parent de4463b commit 95eb795
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
14 changes: 14 additions & 0 deletions 000-default.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<VirtualHost *:8080>

ServerAdmin webmaster@localhost
DocumentRoot /var/www/html/public/

<Directory /var/www/html>
AllowOverride All
Require all granted
</Directory>

ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined

</VirtualHost>
5 changes: 5 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,15 @@ RUN sed -ri -e 's!/var/www/!${APACHE_DOCUMENT_ROOT}!g' /etc/apache2/apache2.conf
# Install composer
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer

EXPOSE 8080
# Copy the application code
COPY . /var/www/html

# Set the working directory
WORKDIR /var/www/html

COPY docker/000-default.conf /etc/apache2/sites-available/000-default.conf

# Install project dependencies
RUN composer install

Expand All @@ -54,6 +57,8 @@ RUN curl -sL https://deb.nodesource.com/setup_${NODE_VERSION}.x | bash - && apt
# Set permissions
RUN chown -R www-data:www-data /var/www/html/storage /var/www/html/bootstrap/cache

RUN echo "Listen 8080" >> /etc/apache2/ports.conf

# Install node
RUN npm install

Expand Down

0 comments on commit 95eb795

Please sign in to comment.