-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat : ElasticSearch 이용하여 사용자 검색 API 마이그레이션 (#265) * feat: ElasticSearch 이용하여 사용자 검색 API 마이그레이션 (#230) * infra: ELK 구축 위한 docker 구성 파일 (#230) * bug: test단에 application.yml에 elasticsearch url 지정 안해서 test 실행 안되는 버그 해결 (#230) * refactor: 코드리뷰에 따른 elasticsearch 사용자 API 리펙토링 * refactor: 상수 아래에 개행 추가 (#230) (cherry picked from commit 4205788) * infra: Dev 서버용 CD Workflow 작성 (#270) * chore: application.yml에 es uris 추가 (#269) * chore: prod-cd 동기화 (#269) * infra: Dev용 CD Workflow 작성 및 Prod용 Workflow 수정 (#269) (cherry picked from commit 345a9fd) * infra: Dockerfile 수정 (#dev) (cherry picked from commit c32b4be) * infra: DEV CD Workflow 수정 (#dev) (cherry picked from commit 85dab2d) * infra: Prod CD Workflow 수정 (#dev) (cherry picked from commit e80fc08) * infra: 모니터링 대시보드 구축을 위한 메트릭 및 의존성 추가 (#273) * chore: dev 브랜치에 rebase (#252) * chore: micrometer-prometheus 의존성 추가 (#252) * infra: Prometheus에 대한 메트릭만 허용 (#273) * infra: 전체 메트릭 허용 (#273) * infra(dev-cd.yml): Spring 컨테이너 띄울 때 메트릭 포트 허용 (#273) * infra: 컨테이너 띄울 때 Profile 입력하도록 변경 (#273) * infra: Spring 컨테이너에 도커 네트워크 옵션 추가 (#273) * infra(prod-cd.yml): 메트릭 포트 바인딩 추가 및 Profile 설정 옵션 추가 (#273) --------- Co-authored-by: coPpark <[email protected]>
- Loading branch information
Showing
30 changed files
with
737 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Ignore OS artifacts | ||
**/.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ELK_VERSION=7.16.2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Declare files that will always have LF line endings on checkout. | ||
*.sh text eol=lf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
The MIT License (MIT) | ||
|
||
Copyright (c) 2015 Anthony Lapenna | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
version: '3.2' | ||
|
||
services: | ||
elasticsearch: | ||
build: | ||
context: elasticsearch/ # elasticsearch 전용 Dockerfile을 가져와 빌드 | ||
args: | ||
ELK_VERSION: $ELK_VERSION | ||
volumes: | ||
- type: bind | ||
source: ./elasticsearch/config/elasticsearch.yml | ||
target: /usr/share/elasticsearch/config/elasticsearch.yml | ||
read_only: true | ||
- type: volume | ||
source: elasticsearch | ||
target: /usr/share/elasticsearch/data | ||
ports: | ||
- "9200:9200" | ||
- "9300:9300" | ||
environment: | ||
ES_JAVA_OPTS: "-Xmx256m -Xms256m" | ||
# ELASTIC_PASSWORD: elastic | ||
# Use single node discovery in order to disable production mode and avoid bootstrap checks. | ||
# see: https://www.elastic.co/guide/en/elasticsearch/reference/current/bootstrap-checks.html | ||
discovery.type: single-node | ||
extra_hosts: | ||
- "host.docker.internal:host-gateway" | ||
networks: | ||
- elk | ||
|
||
logstash: | ||
build: | ||
context: logstash/ | ||
args: | ||
ELK_VERSION: $ELK_VERSION | ||
volumes: | ||
- type: bind | ||
source: ./logstash/config/logstash.yml | ||
target: /usr/share/logstash/config/logstash.yml | ||
read_only: true | ||
- type: bind | ||
source: ./logstash/config/pipelines.yml # 커스텀 pipeline을 사용할 수 있게 함 | ||
target: /usr/share/logstash/config/pipelines.yml | ||
read_only: true | ||
- type: bind | ||
source: ./logstash/pipeline # 커스텀 pipeline을 바인드 | ||
target: /usr/share/logstash/pipeline | ||
read_only: true | ||
- type: bind | ||
source: ./logstash/mysql-connector-j-8.0.33.jar # mysql을 연결할 수 있도록 커넥터 바인드 | ||
target: /usr/share/logstash/logstash-core/lib/jars/mysql-connector-j-8.0.33.jar | ||
ports: | ||
- "5044:5044" | ||
- "9600:9600" | ||
- "9900:9900" | ||
environment: | ||
LS_JAVA_OPTS: "-Xmx256m -Xms256m" | ||
extra_hosts: | ||
- "host.docker.internal:host-gateway" | ||
networks: | ||
- elk | ||
depends_on: | ||
- elasticsearch | ||
|
||
kibana: | ||
build: | ||
context: kibana/ | ||
args: | ||
ELK_VERSION: $ELK_VERSION | ||
volumes: | ||
- type: bind | ||
source: ./kibana/config/kibana.yml | ||
target: /usr/share/kibana/config/kibana.yml | ||
read_only: true | ||
ports: | ||
- "5601:5601" | ||
extra_hosts: | ||
- "host.docker.internal:host-gateway" | ||
networks: | ||
- elk | ||
depends_on: | ||
- elasticsearch | ||
|
||
networks: | ||
elk: | ||
driver: bridge | ||
|
||
volumes: | ||
elasticsearch: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
ARG ELK_VERSION | ||
|
||
# https://www.docker.elastic.co/ | ||
FROM docker.elastic.co/elasticsearch/elasticsearch:${ELK_VERSION} | ||
RUN elasticsearch-plugin install analysis-nori | ||
RUN bin/elasticsearch-plugin install https://github.com/netcrazy/elasticsearch-jaso-analyzer/releases/download/v7.16.2/jaso-analyzer-plugin-7.16.2-plugin.zip | ||
# Add your elasticsearch plugins setup here | ||
# Example: RUN elasticsearch-plugin install analysis-icu |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
--- | ||
## Default Elasticsearch configuration from Elasticsearch base image. | ||
## https://github.com/elastic/elasticsearch/blob/master/distribution/docker/src/docker/config/elasticsearch.yml | ||
# | ||
cluster.name: "docker-cluster" | ||
network.host: 0.0.0.0 | ||
|
||
## X-Pack settings | ||
## see https://www.elastic.co/guide/en/elasticsearch/reference/current/setup-xpack.html | ||
# | ||
#xpack.license.self_generated.type: basic | ||
#xpack.security.enabled: true | ||
#xpack.monitoring.collection.enabled: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
ARG ELK_VERSION | ||
|
||
# https://www.docker.elastic.co/ | ||
FROM docker.elastic.co/kibana/kibana:${ELK_VERSION} | ||
|
||
# Add your kibana plugins setup here | ||
# Example: RUN kibana-plugin install <name|url> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
--- | ||
## Default Kibana configuration from Kibana base image. | ||
## https://github.com/elastic/kibana/blob/master/src/dev/build/tasks/os_packages/docker_generator/templates/kibana_yml.template.ts | ||
# | ||
server.name: kibana | ||
server.host: 0.0.0.0 | ||
elasticsearch.hosts: [ "http://host.docker.internal:9200" ] | ||
monitoring.ui.container.elasticsearch.enabled: true | ||
|
||
## X-Pack security credentials | ||
# | ||
#elasticsearch.username: elastic | ||
#elasticsearch.password: elastic |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
ARG ELK_VERSION | ||
|
||
# https://www.docker.elastic.co/ | ||
FROM docker.elastic.co/logstash/logstash:${ELK_VERSION} | ||
|
||
# Add your logstash plugins setup here | ||
# Example: RUN logstash-plugin install logstash-filter-json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
--- | ||
## Default Logstash configuration from Logstash base image. | ||
## https://github.com/elastic/logstash/blob/master/docker/data/logstash/config/logstash-full.yml | ||
# | ||
http.host: "0.0.0.0" | ||
#xpack.monitoring.elasticsearch.hosts: [ "http://elasticsearch:9200" ] | ||
|
||
## X-Pack security credentials | ||
# | ||
#xpack.monitoring.enabled: true | ||
#xpack.monitoring.elasticsearch.username: elastic | ||
#xpack.monitoring.elasticsearch.password: elastic |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
- pipeline.id: pjs_logstash | ||
path.config: "/usr/share/logstash/pipeline/logstash.conf" |
Binary file not shown.
Oops, something went wrong.