Skip to content

Commit d06c3df

Browse files
committed
refactor: change .properties to .yaml for application
1 parent 7186384 commit d06c3df

File tree

5 files changed

+29
-12
lines changed

5 files changed

+29
-12
lines changed

.env.example

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
DB_URL=jdbc:postgresql://localhost:5432/climbup-db
1+
DB_URL=jdbc:postgresql://localhost:5432/climbup_db
22
DB_USERNAME=root
33
DB_PASSWORD=password
44

55
# PostgreSQL container configuration
6-
POSTGRES_DB=climbup-db
6+
POSTGRES_DB=climbup_db
77
POSTGRES_USER=root
88
POSTGRES_PASSWORD=password
99

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ COPY src ./src
66
RUN gradle clean build -x test --no-daemon
77

88
# Runtime stage
9-
FROM openjdk:17-jre-slim
9+
FROM openjdk:17-jdk-slim
1010
WORKDIR /app
1111
COPY --from=build /app/build/libs/*SNAPSHOT.jar project.jar
1212
EXPOSE 8080

build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,12 @@ dependencies {
2727
implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
2828
implementation 'org.springframework.boot:spring-boot-starter-web'
2929
compileOnly 'org.projectlombok:lombok'
30-
developmentOnly 'org.springframework.boot:spring-boot-devtools'
31-
developmentOnly 'org.springframework.boot:spring-boot-docker-compose'
3230
runtimeOnly 'org.postgresql:postgresql'
3331
annotationProcessor 'org.projectlombok:lombok'
3432
testImplementation 'org.springframework.boot:spring-boot-starter-test'
3533
testRuntimeOnly 'org.junit.platform:junit-platform-launcher'
34+
runtimeOnly("org.flywaydb:flyway-database-postgresql:11.10.2")
35+
implementation 'org.springdoc:springdoc-openapi-starter-webmvc-ui:2.8.9'
3636
}
3737

3838
tasks.named('test') {

src/main/resources/application.properties

Lines changed: 0 additions & 7 deletions
This file was deleted.
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
spring:
2+
application:
3+
name: climbup-server
4+
5+
datasource:
6+
url: ${DB_URL:jdbc:postgresql://localhost:5432/climbup_db}
7+
username: ${DB_USERNAME:root}
8+
password: ${DB_PASSWORD:password}
9+
10+
jpa:
11+
hibernate:
12+
ddl-auto: update
13+
show-sql: true
14+
15+
flyway:
16+
enabled: true
17+
locations: classpath:db/migration
18+
validate-on-migrate: true
19+
20+
springdoc:
21+
api-docs:
22+
path: /api-docs
23+
swagger-ui:
24+
path: /docs

0 commit comments

Comments
 (0)