Skip to content

Commit

Permalink
Created docker-composer for testing
Browse files Browse the repository at this point in the history
  • Loading branch information
Adrian Miu committed Dec 5, 2020
1 parent f5a8f82 commit 63aa690
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
# mysql root password: 'rootpass' # Required if "mysql user" is empty, default is empty. The root superuser password
- name: Setup DB services
run: |
cd docker
cd tests
docker-compose up -d
cd ..
Expand Down Expand Up @@ -81,7 +81,7 @@ jobs:
MYSQL_CONNECTION: 'mysql:host=127.0.0.1;port=13306dbname=siriusorm'
MYSQL_USER: 'root'
MYSQL_PASS: 'sirius'
POSTGRES_CONNECTION: 'pgsql:host=siriusorm_postgres;port=15423;dbname=siriusorm'
POSTGRES_CONNECTION: 'pgsql:host=127.0.0.1;port=15423;dbname=siriusorm'
run: |
mkdir -p build/logs
vendor/bin/phpunit
Expand Down
47 changes: 47 additions & 0 deletions tests/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
version: '3'

services:

### PHP ###################################################
# sqlserver:
# image: microsoft/mssql-server-linux
# container_name: siriusorm_mssql
# ports:
# - "11433:1433"
# environment:
# SA_PASSWORD: "SSpaSS__1"
# ACCEPT_EULA: "Y"
# networks:
# - local

mysql_latest:
image: mysql:latest
container_name: siriusorm_mysql
restart: 'always'
command: --default-authentication-plugin=mysql_native_password
ports:
- "13306:3306"
environment:
MYSQL_DATABASE: "siriusorm"
MYSQL_ROOT_PASSWORD: "sirius"
MYSQL_ROOT_HOST: "%"
networks:
- local

postgres:
image: postgres:12
container_name: siriusorm_postgres
restart: always
ports:
- "15432:5432"
environment:
POSTGRES_DB: "siriusorm"
POSTGRES_USER: "sirius"
POSTGRES_PASSWORD: "sirius"
networks:
- local

#Docker Networks
networks:
local:
driver: bridge

0 comments on commit 63aa690

Please sign in to comment.