Skip to content

Commit

Permalink
Fixes Docker setup
Browse files Browse the repository at this point in the history
Added docker-compose.yml, which was ignored in .gitignore
until now. Reorganized related files.
  • Loading branch information
k00ni committed Nov 22, 2024
1 parent e7ac9c2 commit 1ef59fe
Show file tree
Hide file tree
Showing 5 changed files with 47 additions and 2 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
.php_cs.cache
.phpunit.result.cache
composer.lock
docker/docker-compose.yml
plugins/*
triggers/*
tests/coverage/*
Expand Down
2 changes: 1 addition & 1 deletion docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local

# add custom PHP.ini settings
RUN mv "$PHP_INI_DIR/php.ini-development" "$PHP_INI_DIR/php.ini"
COPY ./includes/custom.ini /usr/local/etc/php/conf.d/custom.ini
COPY ./custom.ini /usr/local/etc/php/conf.d/custom.ini

WORKDIR /var/www/html/

Expand Down
File renamed without changes.
46 changes: 46 additions & 0 deletions docker/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
version: '3'

services:
arc2:
build:
context: .
dockerfile: Dockerfile
container_name: arc2
volumes:
- ./../:/var/www/html/
depends_on:
- db
links:
- db:mysql

db:
image: mariadb:10.3.29
container_name: db
environment:
MYSQL_DATABASE: arc2
MYSQL_ROOT_PASSWORD: Pass123
volumes:
# server is empty at the start because it uses RAM to store data
- data:/var/cache
- data:/var/lib/mysql
# for SQL commands to be run after the server starts
- ./sql:/docker-entrypoint-initdb.d

phpmyadmin:
image: phpmyadmin/phpmyadmin
container_name: phpmyadmin
links:
- db:mysql
ports:
- 8002:80
environment:
MYSQL_USERNAME: root
MYSQL_ROOT_PASSWORD: Pass123
PMA_HOST: mysql
UPLOAD_LIMIT: 2G

volumes:
data:
driver_opts:
type: tmpfs
device: tmpfs
File renamed without changes.

0 comments on commit 1ef59fe

Please sign in to comment.