μ΄λ²€νΈ ν°μΌ μ맀 μλΉμ€λ₯Ό μν μΉ μ΄ν리μΌμ΄μ
-
Common: Spring boot
-
Build tool: Gradle
-
Log: Slf4j, Elasticsearch, Logstash, Redis
-
Infra: MSA(Zuul+Eureka)
-
Test: Testcontainers, Junit5
-
etc: Spring Batch, Spring Data JPA
ubuntu-18.04μ jdk1.8νκ²½μμ μ€ννμμ΅λλ€.
cd gateway
./gradlew build
java -jar ./build/libs/gateway-0.0.1-SNAPSHOT.jar
cd eureka
./gradlew build
java -jar ./build/libs/eureka-0.0.1-SNAPSHOT.jar
# database type: mysql, database: userdb, username: root, password: oidc2020
cd member
./gradlew build
java -jar ./build/libs/member-0.0.1-SNAPSHOT.jar
# database type: mysql, database: reservation, username: root, password: oidc2020
cd reservation
./gradlew build
java -jar ./build/libs/reservation-0.0.1-SNAPSHOT.jar
# database type: postgresql, database: postgres, username: postgres, password: oidc2020
# ν
μ€νΈ μ§νμ dockerκ° μ€μΉλμ΄μμ΄μΌ νκ³ μ΄λ‘ μΈν΄ λΉλκ° μ€ν¨ν΄λ μλ²λ μ€νκ°λ₯ν©λλ€.
cd show
./gradlew build
java -jar ./build/libs/show-0.0.1-SNAPSHOT.jar
wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | apt-key add -
echo "deb https://artifacts.elastic.co/packages/6.x/apt stable main" | tee -a /etc/apt/sources.list.d/elastic-6.x.list
apt-get update
apt-get install elasticsearch
service elasticsearch start
wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | sudo apt-key add -
echo "deb https://artifacts.elastic.co/packages/7.x/apt stable main" | sudo tee -a /etc/apt/sources.list.d/elastic-7.x.list
apt-get install logstash
vi /etc/logstash/conf.d/elkr.conf
//μλ μ½λλ₯Ό elkr.confμ μ
λ ₯
input {
tcp {
port => 4560
codec => json_lines
}
}
output {
elasticsearch {
hosts => ["localhost:9200"]
index => "logstash-%{+YYYY.MM.dd}"
}
}
service logstash start
μ€μ λ°°ν¬ μλ²λ ELK+redis μν€ν μ²λ‘ ꡬμ±λμ΄μμ΅λλ€.