Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docker/docker-compose.prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ services:
restart: always
ports:
- "8080:8080"
- "8081:8081" # actuator 포트
environment:
SPRING_PROFILES_ACTIVE: prod
MYSQL_USERNAME: ${MYSQL_USERNAME}
Expand Down
3 changes: 2 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,5 @@ quartzVersion=2.5.0
firebaseVersion=9.5.0
queryDslVersion=5.0.0
slackApiVersion=1.45.3
kotlinLoggingVersion=3.0.5
kotlinLoggingVersion=3.0.5
prometheusRegistryVersion=1.14.5
6 changes: 5 additions & 1 deletion nginx/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ http {
server api:8080;
}

upstream tuk-monitoring {
server api:8081;
}

server {
listen 80;
server_name api.tuk.kr;
Expand Down Expand Up @@ -57,7 +61,7 @@ http {
}

location /actuator/health {
proxy_pass http://tuk-api/actuator/health;
proxy_pass http://tuk-monitoring/actuator/health;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
Expand Down
5 changes: 4 additions & 1 deletion tuk-api/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,9 @@ dependencies {
// swagger
implementation("org.springdoc:springdoc-openapi-starter-webmvc-ui:${properties["swaggerVersion"]}")

// prometheus
implementation("io.micrometer:micrometer-registry-prometheus:${properties["prometheusRegistryVersion"]}")

// google oauth
implementation("com.google.api-client:google-api-client:${properties["googleApiClientVersion"]}")

Expand All @@ -61,7 +64,7 @@ dependencies {

// slack
implementation("com.slack.api:slack-api-client:${properties["slackApiVersion"]}")

// kotlin logging
implementation("io.github.microutils:kotlin-logging-jvm:${properties["kotlinLoggingVersion"]}")

Expand Down
10 changes: 9 additions & 1 deletion tuk-api/src/main/resources/application.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,12 @@ springdoc:
use-fqn: true

management:
server:
port: 8081
endpoints:
web:
exposure:
include: health
include: health, prometheus

oauth:
google:
Expand Down Expand Up @@ -97,6 +99,12 @@ slack:
error-alert: C099EEB4SQ7
enabled: true

management:
endpoints:
web:
exposure:
include: health, prometheus

---
spring:
jpa:
Expand Down
Loading