Compare commits

...

2 Commits

Author SHA1 Message Date
deploy d8022ab205 change docker container name to backend
Build and Deploy Docker / build (push) Successful in 8m35s
Build and Deploy Docker / deploy (push) Successful in 39s
2026-07-14 14:53:45 +02:00
deploy 71c14b0625 add env prod 2026-07-14 14:14:42 +02:00
3 changed files with 37 additions and 6 deletions
+5 -5
View File
@@ -44,8 +44,8 @@ jobs:
key: ${{ secrets.SERVER_SSH_KEY }}
script: |
cd /home/ryjek/docker/sprawozdania
docker compose pull
docker compose up -d
docker compose exec --workdir /var/www/html www APP_RUNTIME_ENV=prod php bin/console secrets:decrypt-to-local --force
docker compose exec --workdir /var/www/html www php ./bin/console doctrine:migration:migrate --dry-run
docker compose exec --workdir /var/www/html www php ./bin/console cache:clear
docker compose pull backend
docker compose up -d backend
docker compose exec --workdir /var/www/html backend APP_RUNTIME_ENV=prod php bin/console secrets:decrypt-to-local --force
docker compose exec --workdir /var/www/html backend php ./bin/console doctrine:migration:migrate --dry-run
docker compose exec --workdir /var/www/html backend php ./bin/console cache:clear
+32
View File
@@ -0,0 +1,32 @@
# In all environments, the following files are loaded if they exist,
# the latter taking precedence over the former:
#
# * .env contains default values for the environment variables needed by the app
# * .env.local uncommitted file with local overrides
# * .env.$APP_ENV committed environment-specific defaults
# * .env.$APP_ENV.local uncommitted environment-specific overrides
#
# Real environment variables win over .env files.
#
# DO NOT DEFINE PRODUCTION SECRETS IN THIS FILE NOR IN ANY OTHER COMMITTED FILES.
# https://symfony.com/doc/current/configuration/secrets.html
#
# Run "composer dump-env prod" to compile .env files for production use (requires symfony/flex >=1.2).
# https://symfony.com/doc/current/best_practices.html#use-environment-variables-for-infrastructure-configuration
###> symfony/framework-bundle ###
APP_ENV=prod
APP_SECRET=$env(APP_SECRET)$
###< symfony/framework-bundle ###
###> doctrine/doctrine-bundle ###
# Format described at https://www.doctrine-project.org/projects/doctrine-dbal/en/latest/reference/configuration.html#connecting-using-a-url
# IMPORTANT: You MUST configure your server version, either here or in config/packages/doctrine.yaml
#
# DATABASE_URL="sqlite:///%kernel.project_dir%/var/data.db"
DATABASE_URL="mysql://app:%env(DATABASE_PASSWORD)%@mariadb:3306/app?serverVersion=8.0.32&charset=utf8mb4"
#DATABASE_URL="mysql://app:%env(DATABASE_PASSWORD)%@mysql:3306/app?serverVersion=8.0.32&charset=utf8mb4"
# DATABASE_URL="mysql://app:!ChangeMe!@127.0.0.1:3306/app?serverVersion=10.11.2-MariaDB&charset=utf8mb4"
#DATABASE_URL="postgresql://app:!ChangeMe!@127.0.0.1:5432/app?serverVersion=16&charset=utf8"
###< doctrine/doctrine-bundle ###
REDIS_URL=redis://redis:6379?timeout=5
-1
View File
@@ -1,7 +1,6 @@
###> symfony/framework-bundle ###
.env
.env.prod
/.env.local
/.env.local.php
/.env.*.local