feature/33-postgres-database #79

Merged
kruti merged 5 commits from kruti/CFTunnels:feature/33-postgres-database into main 2025-10-18 11:38:08 +00:00
4 changed files with 8 additions and 9 deletions
Showing only changes of commit bbadd41ec4 - Show all commits

View File

@ -27,7 +27,6 @@ dependencies {
implementation 'org.springframework.boot:spring-boot-starter-web' implementation 'org.springframework.boot:spring-boot-starter-web'
testImplementation 'org.springframework.boot:spring-boot-starter-test' testImplementation 'org.springframework.boot:spring-boot-starter-test'
testRuntimeOnly 'org.junit.platform:junit-platform-launcher' testRuntimeOnly 'org.junit.platform:junit-platform-launcher'
implementation 'org.springframework.boot:spring-boot-starter-actuator'
implementation 'org.springframework.boot:spring-boot-starter-data-jpa' implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
runtimeOnly 'org.postgresql:postgresql' runtimeOnly 'org.postgresql:postgresql'
implementation 'org.hibernate.validator:hibernate-validator' implementation 'org.hibernate.validator:hibernate-validator'

View File

@ -15,10 +15,10 @@ services:
- POSTGRES_USER=${POSTGRES_USERNAME} - POSTGRES_USER=${POSTGRES_USERNAME}
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD} - POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
env_file: env_file:
- .env - stack.env
restart: unless-stopped restart: unless-stopped
postgres: postgres:
image: postgres:15 image: postgres:15-alpine
container_name: cftunnel-db container_name: cftunnel-db
environment: environment:
POSTGRES_DB: cftunnel POSTGRES_DB: cftunnel
@ -28,7 +28,4 @@ services:
ports: ports:
- "5432:5432" - "5432:5432"
volumes: volumes:
- pgdata:/var/lib/postgresql/data - ${DB_PATH}:/var/lib/postgresql/data
volumes:
pgdata: {}

View File

@ -6,3 +6,5 @@ management.endpoint.health.show-details=always
logging.level.org.hibernate.SQL=DEBUG logging.level.org.hibernate.SQL=DEBUG
debug=true debug=true
spring.datasource.url=jdbc:postgresql://localhost:5432/cftunnel

View File

@ -18,7 +18,7 @@ spring.security.oauth2.client.provider.cftunnels.user-info-uri=https://auth.hith
spring.security.oauth2.client.provider.cftunnels.jwk-set-uri=https://auth.hithomelabs.com/application/o/cftunnels/jwks/ spring.security.oauth2.client.provider.cftunnels.jwk-set-uri=https://auth.hithomelabs.com/application/o/cftunnels/jwks/
spring.security.oauth2.client.provider.cftunnels.issuer-uri=https://auth.hithomelabs.com/application/o/cftunnels/ spring.security.oauth2.client.provider.cftunnels.issuer-uri=https://auth.hithomelabs.com/application/o/cftunnels/
spring.datasource.url=jdbc:postgresql://localhost:5432/cftunnel spring.datasource.url=jdbc:postgresql://192.168.0.100:5432/cftunnel
spring.datasource.username=${POSTGRES_USERNAME} spring.datasource.username=${POSTGRES_USERNAME}
spring.datasource.password=${POSTGRES_PASSWORD} spring.datasource.password=${POSTGRES_PASSWORD}
spring.datasource.driver-class-name=org.postgresql.Driver spring.datasource.driver-class-name=org.postgresql.Driver
@ -26,5 +26,6 @@ spring.sql.init.mode=always
spring.jpa.hibernate.ddl-auto=update spring.jpa.hibernate.ddl-auto=update
spring.jpa.show-sql=true spring.jpa.show-sql=true
spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.PostgreSQLDialect
spring.jpa.open-in-view=false