Skip to content

Commit 67819fa

Browse files
committed
Ajout de symfony/dotenv
1 parent fba0907 commit 67819fa

27 files changed

Lines changed: 137 additions & 83 deletions

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ test-functional: data config htdocs/uploads tmp
108108
make clean-test-deprecated-log
109109
$(DOCKER_COMP) run --no-deps --rm -u localUser apachephptest ./bin/console cache:warmup --env=test
110110
$(DOCKER_COMP) run --no-deps --rm -u localUser apachephptest ./bin/bdi detect drivers
111-
$(DOCKER_COMP) run --no-deps --rm -u localUser apachephptest ./bin/behat
111+
$(DOCKER_COMP) run --no-deps --rm -u localUser apachephptest ./bin/behat --colors
112112
make var/logs/test.deprecations_grouped.log
113113
$(DOCKER_COMP) stop dbtest apachephptest mailcatcher
114114

app/config/config.php

Lines changed: 0 additions & 32 deletions
This file was deleted.

app/config/config.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
11
imports:
2-
- { resource: config.php }
32
- { resource: services.yml }
43
- { resource: packages/*.yaml }

app/config/config_dev.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ monolog:
3333

3434
parameters:
3535
paybox_ips: [127.0.0.1, 192.168.42.1]
36+
database_host: "db"
3637

3738
#swiftmailer:
3839
# delivery_address: me@example.com

app/config/config_prod.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
imports:
22
- { resource: config.yml }
33

4+
parameters:
5+
database_host: "%env(DATABASE_HOST)%"
6+
47
#doctrine:
58
# orm:
69
# metadata_cache_driver: apc
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
ewz_recaptcha:
2-
public_key: '%recaptcha_public_key%'
3-
private_key: '%recaptcha_private_key%'
2+
public_key: '%env(RECAPTCHA_PUBLIC_KEY)%'
3+
private_key: '%env(RECAPTCHA_PRIVATE_KEY)%'

app/config/packages/framework.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ framework:
44
fallbacks: ["%locale%"]
55
enabled: true
66
default_path: "%kernel.project_dir%/../translations"
7-
secret: "%secret%"
7+
secret: "%env(SECRET)%"
88
router:
99
resource: "%kernel.project_dir%/config/routing.yml"
1010
strict_requirements: ~

app/config/packages/knpu_oauth2_client.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ knpu_oauth2_client:
33
# will create a service: knpu.oauth2.client.facebook_main
44
github_main:
55
type: github
6-
client_id: "%github_client_id%"
7-
client_secret: "%github_client_secret%"
6+
client_id: "%env(GITHUB_CLIENT_ID)%"
7+
client_secret: "%env(GITHUB_CLIENT_SECRET)%"
88
# see below
99
redirect_route: connection_github_check

app/config/packages/security.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ security:
6868
- { path: ^/admin/(members/reporting|association/relances|talk|slackmembers/check|healthcheck), roles: ROLE_ADMIN}
6969
- { path: ^/member, roles: [ROLE_USER, ROLE_MEMBER_EXPIRED]}
7070
- { path: ^/admin/, roles: ROLE_MEMBER_EXPIRED }
71-
- { path: ^/blog, allow_if: "request.getClientIp() in ['217.70.189.71', '127.0.0.1', '192.168.42.1'] or request.server.get('ALLOW_BLOG_FROM_ALL') == 1 or request.headers.get('x-afup-blog-api-key') == '%blog_api_key%'" }
71+
- { path: ^/blog, allow_if: "request.getClientIp() in ['217.70.189.71', '127.0.0.1', '192.168.42.1'] or request.server.get('ALLOW_BLOG_FROM_ALL') == 1 or request.headers.get('x-afup-blog-api-key') == '%env(BLOG_API_KEY)%'" }
7272
- { path: ^/blog, roles: ROLE_NO_ACCESS }
7373
- { path: ^/(event/\w+/tickets|association)paybox-callback, roles: PUBLIC_ACCESS, ips: "%paybox_ips%" }
7474
- { path: ^/(event/\w+/tickets|association)paybox-callback, roles: ROLE_SUPER_ADMIN }

app/config/packages/ting.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ ting:
55
charset: utf8mb4
66
master:
77
host: "%database_host%"
8-
port: "%database_port%"
9-
user: "%database_user%"
10-
password: "%database_password%"
8+
port: "%env(int:DATABASE_PORT)%"
9+
user: "%env(DATABASE_USER)%"
10+
password: "%env(DATABASE_PASSWORD)%"
1111

1212
repositories:
1313
event:

0 commit comments

Comments
 (0)