feat: single .env file
This commit is contained in:
parent
184642a750
commit
e7cb8cf469
20
Makefile
20
Makefile
@ -7,7 +7,7 @@ clean:
|
||||
@rm -f docker-compose.yaml
|
||||
@rm -f .env
|
||||
@rm -f front/MyINPulse-front/.env
|
||||
|
||||
@rm -f MyINPulse-back/.env
|
||||
|
||||
# Install npm packages
|
||||
front/MyINPulse-front/.installed:
|
||||
@ -18,24 +18,28 @@ vite: ./front/MyINPulse-front/.installed
|
||||
|
||||
|
||||
dev-front: clean vite
|
||||
@cp config/frontdev.front.env front/MyINPulse-front/.env
|
||||
@cp config/frontdev.main.env .env
|
||||
@cp config/frontdev.env front/MyINPulse-front/.env
|
||||
@cp config/frontdev.env .env
|
||||
@cp config/frontdev.env MyINPulse-back/.env
|
||||
@cp config/frontdev.docker-compose.yaml docker-compose.yaml
|
||||
@docker compose up -d --build
|
||||
@cd ./front/MyINPulse-front/ && npm run dev
|
||||
|
||||
prod: clean
|
||||
@cp config/prod.front.env front/MyINPulse-front/.env
|
||||
@cp config/prod.main.env .env
|
||||
@cp config/prod.env front/MyINPulse-front/.env
|
||||
@cp config/prod.env .env
|
||||
@cp config/prod.env .env
|
||||
@cp config/prod.docker-compose.yaml docker-compose.yaml
|
||||
@docker compose up -d --build
|
||||
|
||||
|
||||
|
||||
dev-back:
|
||||
@cp config/backdev.front.env front/MyINPulse-front/.env
|
||||
@cp config/backdev.main.env .env
|
||||
@cp config/backdev.env front/MyINPulse-front/.env
|
||||
@cp config/backdev.env .env
|
||||
@cp config/backdev.env MyINPulse-back/.env
|
||||
@cp config/backdev.docker-compose.yaml docker-compose.yaml
|
||||
@docker compose up -d --build
|
||||
@echo "cd MyINPulse-back"
|
||||
@echo "cd MyINPulse-back" && echo 'export $$(cat .env | xargs)'
|
||||
@echo "./gradlew bootRun --args='--server.port=8081'"
|
||||
|
@ -2,11 +2,8 @@ spring.application.name=myinpulse
|
||||
spring.security.oauth2.resourceserver.jwt.jwk-set-uri=http://localhost:7080/realms/test/protocol/openid-connect/certs
|
||||
spring.security.oauth2.resourceserver.jwt.issuer-uri=http://localhost:7080/realms/test
|
||||
logging.level.org.springframework.security=DEBUG
|
||||
#spring.datasource.url=jdbc:postgresql://postgres/${POSTGRES_DB}
|
||||
spring.datasource.url=jdbc:postgresql://localhost:5433/backend_db
|
||||
spring.datasource.username=backend_db_user
|
||||
spring.datasource.password=backend_db_user_password
|
||||
spring.datasource.url=jdbc:postgresql://${DATABASE_URL}/${BACKEND_DB}
|
||||
spring.datasource.username=${BACKEND_USER}
|
||||
spring.datasource.password=${BACKEND_PASSWORD}
|
||||
spring.jpa.hibernate.ddl-auto=update
|
||||
spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.PostgreSQLDialect
|
||||
|
||||
spring.data.rest.base-path=/my/base/path
|
@ -12,3 +12,11 @@ KEYCLOAK_PASSWORD=keycloak_db_user_password
|
||||
BACKEND_DB=backend_db
|
||||
BACKEND_USER=backend_db_user
|
||||
BACKEND_PASSWORD=backend_db_user_password
|
||||
|
||||
DATABASE_URL=localhost:5433
|
||||
|
||||
VITE_KEYCLOAK_URL=http://localhost:7080
|
||||
VITE_KEYCLOAK_CLIENT_ID=myinpulse
|
||||
VITE_KEYCLOAK_REALM=test
|
||||
VITE_APP_URL=http://localhost:8080
|
||||
VITE_BACKEND_URL=http://localhost:8081/
|
@ -1,5 +0,0 @@
|
||||
VITE_KEYCLOAK_URL=http://localhost:7080
|
||||
VITE_KEYCLOAK_CLIENT_ID=myinpulse
|
||||
VITE_KEYCLOAK_REALM=test
|
||||
VITE_APP_URL=http://localhost:8080
|
||||
VITE_BACKEND_URL=http://localhost:8081/
|
@ -12,3 +12,11 @@ KEYCLOAK_PASSWORD=keycloak_db_user_password
|
||||
BACKEND_DB=backend_db
|
||||
BACKEND_USER=backend_db_user
|
||||
BACKEND_PASSWORD=backend_db_user_password
|
||||
|
||||
DATABASE_URL=MyINPulse-DB
|
||||
|
||||
VITE_KEYCLOAK_URL=http://localhost:7080
|
||||
VITE_KEYCLOAK_CLIENT_ID=myinpulse-dev
|
||||
VITE_KEYCLOAK_REALM=test
|
||||
VITE_APP_URL=http://localhost:5173
|
||||
VITE_BACKEND_URL=http://localhost:8081/
|
@ -1,5 +0,0 @@
|
||||
VITE_KEYCLOAK_URL=http://localhost:7080
|
||||
VITE_KEYCLOAK_CLIENT_ID=myinpulse-dev
|
||||
VITE_KEYCLOAK_REALM=test
|
||||
VITE_APP_URL=http://localhost:5173
|
||||
VITE_BACKEND_URL=http://localhost:8081/
|
@ -12,3 +12,11 @@ KEYCLOAK_PASSWORD=keycloak_db_user_password
|
||||
BACKEND_DB=backend_db
|
||||
BACKEND_USER=backend_db_user
|
||||
BACKEND_PASSWORD=backend_db_user_password
|
||||
|
||||
DATABASE_URL=MyINPulse-DB
|
||||
|
||||
VITE_KEYCLOAK_URL=https://0549cd63f912d5dc9b31278d6f.eirb.fr
|
||||
VITE_KEYCLOAK_CLIENT_ID=myinpulse-eirb
|
||||
VITE_KEYCLOAK_REALM=test
|
||||
VITE_APP_URL=https://0549cd63f912d5dc9b31278d6f.piair.dev
|
||||
VITE_BACKEND_URL=http://TODO/
|
@ -1,5 +0,0 @@
|
||||
VITE_KEYCLOAK_URL=https://0549cd63f912d5dc9b31278d6f.eirb.fr
|
||||
VITE_KEYCLOAK_CLIENT_ID=myinpulse-eirb
|
||||
VITE_KEYCLOAK_REALM=test
|
||||
VITE_APP_URL=https://0549cd63f912d5dc9b31278d6f.piair.dev
|
||||
VITE_BACKEND_URL=http://TODO/
|
Loading…
x
Reference in New Issue
Block a user