Skip to content

Commit

Permalink
Create db command
Browse files Browse the repository at this point in the history
  • Loading branch information
manuelmeister committed Jun 16, 2024
1 parent 5b69551 commit d4a111d
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 15 deletions.
10 changes: 0 additions & 10 deletions .github/test-postgres-initdb.d/create-ecamp3-test-database.sh

This file was deleted.

17 changes: 12 additions & 5 deletions .github/workflows/continuous-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -176,15 +176,16 @@ jobs:
runs-on: ubuntu-latest
env:
DATABASE_URL: postgresql://ecamp3:ecamp3@localhost:5432/ecamp3?serverVersion=15&charset=utf8
POSTGRES_HOST: postgres
POSTGRES_PORT: 5432

services:
postgres:
image: 'postgres:15-alpine'
env:
POSTGRES_PASSWORD: 'ecamp3'
POSTGRES_USER: 'ecamp3'
volumes:
- ${{ github.workspace }}/.github/test-postgres-initdb.d:/docker-entrypoint-initdb.d
POSTGRES_DB: 'ecamp3test'
ports:
- '5432:5432'
options: >-
Expand Down Expand Up @@ -230,15 +231,21 @@ jobs:
setfacl -dR -m u:www-data:rX -m u:"$(whoami)":rwX config/jwt
working-directory: api
- run: php bin/console doctrine:migrations:migrate --no-interaction -e test
- run: |
php bin/console doctrine:database:create --no-interaction -e test
php bin/console doctrine:migrations:migrate --no-interaction -e test
working-directory: api
- run: php bin/console doctrine:migrations:migrate --no-interaction -e test
- run: |
php bin/console doctrine:database:create --no-interaction -e test
php bin/console doctrine:migrations:migrate --no-interaction -e test
env:
TEST_TOKEN: 1
working-directory: api
- run: php bin/console doctrine:migrations:migrate --no-interaction -e test
- run: |
php bin/console doctrine:database:create --no-interaction -e test
php bin/console doctrine:migrations:migrate --no-interaction -e test
env:
TEST_TOKEN: 2
working-directory: api
Expand Down

0 comments on commit d4a111d

Please sign in to comment.