瀏覽代碼

cleanup and complete env files and secrets

Olivier Massot 2 年之前
父節點
當前提交
f20a98b604

+ 0 - 2
.env

@@ -88,8 +88,6 @@ ELASTICSEARCH_PORT=9200
 MERCURE_URL=xxx
 # The public URL of the Mercure hub, used by the browser to connect
 MERCURE_PUBLIC_URL=xxx
-# The secret key used to sign the JWTs => TODO: make it a secret
-MERCURE_PUBLISHER_JWT_KEY=xxx
 ###< symfony/mercure-bundle ###
 
 ###> typo3 client ###

+ 1 - 1
config/packages/mercure.yaml

@@ -4,7 +4,7 @@ mercure:
             url: '%env(MERCURE_URL)%'
             public_url: '%env(MERCURE_PUBLIC_URL)%'
             jwt:
-                secret: '%env(MERCURE_PUBLISHER_JWT_KEY)%'
+                secret: '%env(MERCURE_JWT_SECRET)%'
                 algorithm: 'hmac.sha256'
                 publish: ['*']
 

+ 3 - 0
config/secrets/docker/docker.MERCURE_JWT_SECRET.88e4d2.php

@@ -0,0 +1,3 @@
+<?php // docker.MERCURE_JWT_SECRET.88e4d2 on Thu, 16 Nov 2023 15:43:03 +0000
+
+return "\x84i\x85\x29\x08\x82O3\xFF\x89\xD6\xC3\x3Cz\x20B\x7C\x267\xB1O\xFA\xD9\x19a\x85y\xB2j\xC7\x04dZT\x8A\xDFv\xC0\x2Cf\xF2\x0B\xCB\xA4\x80\xE7\x5C\x19\xF8\xE6\xA6\x40\xEDo\x16\x94\xEA\x80\xEExAr\xC8\xCA\x00\xBB\xC3\x0A7\xB9\x04\x00d\xE2\x3E\xC7\xBB\x83\x9D\xB8\x01g\x3A\xAAi\x00\xB8\xF1t\x9F\x80X\xC0\x06T\xC1\xAE\x28\x98\xC8\x23\x3E\xC0\xCC\xC68\x19\xB6\xA6\xCC\xDD\x0E";

+ 0 - 3
config/secrets/docker/docker.MERCURE_PUBLISHER_JWT_KEY.e0f9f1.php

@@ -1,3 +0,0 @@
-<?php // docker.MERCURE_PUBLISHER_JWT_KEY.e0f9f1 on Thu, 16 Nov 2023 10:30:07 +0000
-
-return "\xD5\x89\xC7\x1F\xA72L\xF2\xCD\xA5\x1Em\xD3\x2A\xEF1\xC9\x91M\xC9\xF1\x09X\xC4G\x94\x2B\xFC\xDAW\x05\x0Fa\x11\x13\xDE\x04\x08\xD5\x9B\xA8\x40es\xE7O\xBD\x8E\x84\xE9\xEA\x84\x8A\x1F\xED\x8B\x98_\x8D\x2F\x84\xE6\xD1\x3C\x3F\xA6\xF1cV4Y\x8E\xDC\xEAAI\xA2\xE9\x8D8\x90C\xF7\xBD\xED\x00te\x60\x9F\xF5\xC9\xB7\xA9\xF1c\xC0\xDD~\xE8eH\x9C\x0D\x86m\x05t\xD5\x2F\x16\x22";

+ 1 - 0
config/secrets/docker/docker.list.php

@@ -5,5 +5,6 @@ return [
     'DATABASE_AUDIT_URL' => null,
     'DATABASE_URL' => null,
     'DOLIBARR_API_TOKEN' => null,
+    'MERCURE_JWT_SECRET' => null,
     'MERCURE_PUBLISHER_JWT_KEY' => null,
 ];

+ 3 - 0
config/secrets/readme.md

@@ -0,0 +1,3 @@
+# Env files
+
+> @see doc/env.md

+ 0 - 14
env/.env.test1

@@ -3,10 +3,6 @@ APP_ENV=test
 APP_DEBUG=1
 ###< symfony/framework-bundle ###
 
-###> doctrine/doctrine-bundle ###
-DATABASE_URL=mysql://root:mysql2iopenservice369566@localhost:3306/opentalent?serverVersion=5.7
-###< doctrine/doctrine-bundle ###
-
 ###> api v1 ###
 API_LEG_BASE_URL=https://api.test1.opentalent.fr/api
 ###< files management ###
@@ -15,22 +11,12 @@ API_LEG_BASE_URL=https://api.test1.opentalent.fr/api
 TYPO3_BASE_URI=http://test1.opentalent.fr/ohcluses
 ###< typo3 client ###
 
-###> AdminAssos configuration ###
-DATABASE_ADMINASSOS_URL=mysql://root:mysql2iopenservice369566@test1:3306/adminassos?serverVersion=5.7
-###< AdminAssos configuration ###
-
-###> Audit configuration ###
-DATABASE_AUDIT_URL=mysql://root:mysql2iopenservice369566@test1:3306/audit?serverVersion=5.7
-###< Audit configuration ###
-
 ###> symfony/mercure-bundle ###
 # See https://symfony.com/doc/current/mercure.html#configuration
 # The URL of the Mercure hub, used by the app to publish updates (can be a local URL)
 MERCURE_URL=https://mercure.test.opentalent.fr/.well-known/mercure
 # The public URL of the Mercure hub, used by the browser to connect
 MERCURE_PUBLIC_URL=https://mercure.test.opentalent.fr/.well-known/mercure
-# The secret used to sign the JWTs
-MERCURE_JWT_SECRET=NQEupdREijrfYvCmF2mnvZQFL9zLKDH9RCYter6tUWzjemPqzicffhc2fSf0yEmM
 ###< symfony/mercure-bundle ###
 
 ###> filename log ###

+ 0 - 14
env/.env.test2

@@ -3,10 +3,6 @@ APP_ENV=test
 APP_DEBUG=1
 ###< symfony/framework-bundle ###
 
-###> doctrine/doctrine-bundle ###
-DATABASE_URL=mysql://root:mysql2iopenservice369566@localhost:3306/opentalent?serverVersion=5.7
-###< doctrine/doctrine-bundle ###
-
 ###> api v1 ###
 API_LEG_BASE_URL=https://api.test2.opentalent.fr/api
 ###< files management ###
@@ -15,22 +11,12 @@ API_LEG_BASE_URL=https://api.test2.opentalent.fr/api
 TYPO3_BASE_URI=http://test2.opentalent.fr/ohcluses
 ###< typo3 client ###
 
-###> AdminAssos configuration ###
-DATABASE_ADMINASSOS_URL=mysql://root:mysql2iopenservice369566@test2:3306/adminassos?serverVersion=5.7
-###< AdminAssos configuration ###
-
-###> Audit configuration ###
-DATABASE_AUDIT_URL=mysql://root:mysql2iopenservice369566@test2:3306/audit?serverVersion=5.7
-###< Audit configuration ###
-
 ###> symfony/mercure-bundle ###
 # See https://symfony.com/doc/current/mercure.html#configuration
 # The URL of the Mercure hub, used by the app to publish updates (can be a local URL)
 MERCURE_URL=https://mercure.test.opentalent.fr/.well-known/mercure
 # The public URL of the Mercure hub, used by the browser to connect
 MERCURE_PUBLIC_URL=https://mercure.test.opentalent.fr/.well-known/mercure
-# The secret used to sign the JWTs
-MERCURE_JWT_SECRET=NQEupdREijrfYvCmF2mnvZQFL9zLKDH9RCYter6tUWzjemPqzicffhc2fSf0yEmM
 ###< symfony/mercure-bundle ###
 
 ###> filename log ###

+ 0 - 14
env/.env.test3

@@ -3,10 +3,6 @@ APP_ENV=test
 APP_DEBUG=1
 ###< symfony/framework-bundle ###
 
-###> doctrine/doctrine-bundle ###
-DATABASE_URL=mysql://root:mysql2iopenservice369566@localhost:3306/opentalent?serverVersion=5.7
-###< doctrine/doctrine-bundle ###
-
 ###> api v1 ###
 API_LEG_BASE_URL=https://api.test3.opentalent.fr/api
 ###< files management ###
@@ -15,22 +11,12 @@ API_LEG_BASE_URL=https://api.test3.opentalent.fr/api
 TYPO3_BASE_URI=http://test3.opentalent.fr/ohcluses
 ###< typo3 client ###
 
-###> AdminAssos configuration ###
-DATABASE_ADMINASSOS_URL=mysql://root:mysql2iopenservice369566@test3:3306/adminassos?serverVersion=5.7
-###< AdminAssos configuration ###
-
-###> Audit configuration ###
-DATABASE_AUDIT_URL=mysql://root:mysql2iopenservice369566@test3:3306/audit?serverVersion=5.7
-###< Audit configuration ###
-
 ###> symfony/mercure-bundle ###
 # See https://symfony.com/doc/current/mercure.html#configuration
 # The URL of the Mercure hub, used by the app to publish updates (can be a local URL)
 MERCURE_URL=https://mercure.test.opentalent.fr/.well-known/mercure
 # The public URL of the Mercure hub, used by the browser to connect
 MERCURE_PUBLIC_URL=https://mercure.test.opentalent.fr/.well-known/mercure
-# The secret used to sign the JWTs
-MERCURE_JWT_SECRET=NQEupdREijrfYvCmF2mnvZQFL9zLKDH9RCYter6tUWzjemPqzicffhc2fSf0yEmM
 ###< symfony/mercure-bundle ###
 
 ###> filename log ###

+ 0 - 14
env/.env.test4

@@ -3,10 +3,6 @@ APP_ENV=test
 APP_DEBUG=1
 ###< symfony/framework-bundle ###
 
-###> doctrine/doctrine-bundle ###
-DATABASE_URL=mysql://root:mysql2iopenservice369566@localhost:3306/opentalent?serverVersion=5.7
-###< doctrine/doctrine-bundle ###
-
 ###> api v1 ###
 API_LEG_BASE_URL=https://api.test4.opentalent.fr/api
 ###< files management ###
@@ -15,22 +11,12 @@ API_LEG_BASE_URL=https://api.test4.opentalent.fr/api
 TYPO3_BASE_URI=http://test4.opentalent.fr/ohcluses
 ###< typo3 client ###
 
-###> AdminAssos configuration ###
-DATABASE_ADMINASSOS_URL=mysql://root:mysql2iopenservice369566@test4:3306/adminassos?serverVersion=5.7
-###< AdminAssos configuration ###
-
-###> Audit configuration ###
-DATABASE_AUDIT_URL=mysql://root:mysql2iopenservice369566@test4:3306/audit?serverVersion=5.7
-###< Audit configuration ###
-
 ###> symfony/mercure-bundle ###
 # See https://symfony.com/doc/current/mercure.html#configuration
 # The URL of the Mercure hub, used by the app to publish updates (can be a local URL)
 MERCURE_URL=https://mercure.test.opentalent.fr/.well-known/mercure
 # The public URL of the Mercure hub, used by the browser to connect
 MERCURE_PUBLIC_URL=https://mercure.test.opentalent.fr/.well-known/mercure
-# The secret used to sign the JWTs
-MERCURE_JWT_SECRET=NQEupdREijrfYvCmF2mnvZQFL9zLKDH9RCYter6tUWzjemPqzicffhc2fSf0yEmM
 ###< symfony/mercure-bundle ###
 
 ###> filename log ###

+ 0 - 14
env/.env.test5

@@ -3,10 +3,6 @@ APP_ENV=test
 APP_DEBUG=1
 ###< symfony/framework-bundle ###
 
-###> doctrine/doctrine-bundle ###
-DATABASE_URL=mysql://root:mysql2iopenservice369566@localhost:3306/opentalent?serverVersion=5.7
-###< doctrine/doctrine-bundle ###
-
 ###> api v1 ###
 API_LEG_BASE_URL=https://api.test5.opentalent.fr/api
 ###< files management ###
@@ -15,22 +11,12 @@ API_LEG_BASE_URL=https://api.test5.opentalent.fr/api
 TYPO3_BASE_URI=http://test5.opentalent.fr/ohcluses
 ###< typo3 client ###
 
-###> AdminAssos configuration ###
-DATABASE_ADMINASSOS_URL=mysql://root:mysql2iopenservice369566@test5:3306/adminassos?serverVersion=5.7
-###< AdminAssos configuration ###
-
-###> Audit configuration ###
-DATABASE_AUDIT_URL=mysql://root:mysql2iopenservice369566@test5:3306/audit?serverVersion=5.7
-###< Audit configuration ###
-
 ###> symfony/mercure-bundle ###
 # See https://symfony.com/doc/current/mercure.html#configuration
 # The URL of the Mercure hub, used by the app to publish updates (can be a local URL)
 MERCURE_URL=https://mercure.test.opentalent.fr/.well-known/mercure
 # The public URL of the Mercure hub, used by the browser to connect
 MERCURE_PUBLIC_URL=https://mercure.test.opentalent.fr/.well-known/mercure
-# The secret used to sign the JWTs
-MERCURE_JWT_SECRET=NQEupdREijrfYvCmF2mnvZQFL9zLKDH9RCYter6tUWzjemPqzicffhc2fSf0yEmM
 ###< symfony/mercure-bundle ###
 
 ###> filename log ###