Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 11 additions & 4 deletions .docker/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
services:
web:
image: nginx:latest
platform: linux/amd64
ports:
- "80:80"
volumes:
Expand All @@ -9,9 +10,15 @@ services:
- app
app:
build:
context: .
dockerfile: ./php/Dockerfile
context: ..
dockerfile: .docker/php/Dockerfile
volumes:
- ..:/var/www/html
db:
image: mysql:5.7
image: mysql:8.0
platform: linux/amd64
volumes:
- ./mysql:/var/lib/mysql
- ./mysql:/var/lib/mysql
environment:
MYSQL_ROOT_PASSWORD: root
MYSQL_DATABASE: flutterwave
6 changes: 3 additions & 3 deletions .docker/php/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,13 @@ COPY --from=composer:2.4 /usr/bin/composer /usr/bin/composer
# This is enough to take advantage of docker cache and composer install will
# be executed only when composer.json or composer.lock have indeed changed!-
# https://medium.com/@softius/faster-docker-builds-with-composer-install-b4d2b15d0fff
COPY ./app/composer.* ./
COPY composer.* ./

# install
RUN composer install --prefer-dist --no-dev --no-scripts --no-progress --no-interaction

# copy application files to the working directory
COPY ./app .
COPY . .

# run composer dump-autoload --optimize
RUN composer dump-autoload --optimize
Expand All @@ -45,7 +45,7 @@ FROM app as app_dev
ENV XDEBUG_MODE=off

# Copy xdebug config file into container
COPY ./php/conf.d/xdebug.ini /usr/local/etc/php/conf.d/xdebug.ini
COPY .docker/php/conf.d/xdebug.ini /usr/local/etc/php/conf.d/xdebug.ini

# Install xdebug
RUN set -eux; \
Expand Down
Loading