Skip to content

Commit

Permalink
refactor: remove "build-configuration.json" file
Browse files Browse the repository at this point in the history
Keep only:
- configuration.json
- keycloak.json
  • Loading branch information
laurentC35 committed Feb 22, 2023
1 parent 3cb338e commit 6f7cb8e
Show file tree
Hide file tree
Showing 5 changed files with 2 additions and 19 deletions.
7 changes: 0 additions & 7 deletions configuration/build-configuration.json

This file was deleted.

7 changes: 0 additions & 7 deletions public/build-configuration.json

This file was deleted.

2 changes: 1 addition & 1 deletion public/configuration.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"authenticationType": "${AUTHENTICATION_TYPE}",
"authenticationType": "NONE",
"_authenticationType_comment_": "Authentication type : OIDC or NONE",
"apiUrl": "${API_URL}",
"portail": "${PORTAIL_URL}",
Expand Down
2 changes: 0 additions & 2 deletions scripts/env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ do

done < .env
envsubst < "./configuration.json" > "configuration.temp"
envsubst < "./build-configuration.json" > "build-configuration.temp"
envsubst < "./keycloak.json" > "keycloak.temp"
mv configuration.temp configuration.json
mv build-configuration.temp build-configuration.json
mv keycloak.temp keycloak.json
3 changes: 1 addition & 2 deletions src/utils/configuration/get-configuration.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ import { getEnvVar } from './env';

const basePath = `${window.location.origin}`;

const nameConfigFile =
getEnvVar('NAME_CONFIG_FILE') ?? 'build-configuration.json';
const nameConfigFile = getEnvVar('NAME_CONFIG_FILE') ?? 'configuration.json';

const nameOidcFile = getEnvVar('NAME_OIDC_FILE') ?? 'keycloak.json';

Expand Down

0 comments on commit 6f7cb8e

Please sign in to comment.