10
Dockerfile
10
Dockerfile
@ -15,7 +15,11 @@ RUN sed -ri -e 's!/var/www/html!${APACHE_DOCUMENT_ROOT}!g' /etc/apache2/sites-av
|
|||||||
RUN sed -ri -e 's!/var/www/!${APACHE_DOCUMENT_ROOT}!g' /etc/apache2/apache2.conf /etc/apache2/conf-available/*.conf
|
RUN sed -ri -e 's!/var/www/!${APACHE_DOCUMENT_ROOT}!g' /etc/apache2/apache2.conf /etc/apache2/conf-available/*.conf
|
||||||
|
|
||||||
|
|
||||||
COPY . /var/www/html
|
COPY --chown=www-data:www-data . /var/www/html
|
||||||
|
|
||||||
|
WORKDIR /var/www/html
|
||||||
|
# Install Composer
|
||||||
|
COPY --from=composer:latest /usr/bin/composer /usr/bin/composer
|
||||||
|
|
||||||
RUN apt-get update && apt-get install -y \
|
RUN apt-get update && apt-get install -y \
|
||||||
curl \
|
curl \
|
||||||
@ -28,5 +32,9 @@ RUN apt-get update && apt-get install -y \
|
|||||||
RUN docker-php-ext-install mbstring exif pcntl bcmath gd
|
RUN docker-php-ext-install mbstring exif pcntl bcmath gd
|
||||||
|
|
||||||
# Install dependencies
|
# Install dependencies
|
||||||
|
USER www-data
|
||||||
RUN composer install
|
RUN composer install
|
||||||
|
RUN php artisan migrate --force
|
||||||
|
USER root
|
||||||
|
|
||||||
COPY --from=assets --chown=www-data:www-data /app /var/www/html
|
COPY --from=assets --chown=www-data:www-data /app /var/www/html
|
||||||
|
|||||||
@ -5,7 +5,7 @@ services:
|
|||||||
context: .
|
context: .
|
||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
ports:
|
ports:
|
||||||
- "127.0.0.1:8000:8080"
|
- "127.0.0.1:8000:80"
|
||||||
environment:
|
environment:
|
||||||
- APP_ENV=production
|
- APP_ENV=production
|
||||||
- APP_URL="https://asm.pavo.pw"
|
- APP_URL="https://asm.pavo.pw"
|
||||||
|
|||||||
Reference in New Issue
Block a user