-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
94b9471
commit cdf8701
Showing
5 changed files
with
86 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
## 개요 | ||
* kong httpbin 애플리케이션 |
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,40 @@ | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: httpbin | ||
namespace: default | ||
labels: | ||
app: httpbin | ||
spec: | ||
replicas: 1 | ||
selector: | ||
matchLabels: | ||
app: httpbin | ||
template: | ||
metadata: | ||
labels: | ||
app: httpbin | ||
spec: | ||
terminationGracePeriodSeconds: 30 | ||
containers: | ||
- name: httpbin | ||
image: kong/httpbin:0.2.1 | ||
ports: | ||
- containerPort: 80 | ||
readinessProbe: | ||
httpGet: | ||
path: /status/200 | ||
port: 80 | ||
initialDelaySeconds: 20 | ||
periodSeconds: 5 | ||
lifecycle: | ||
preStop: | ||
exec: | ||
command: [ "sh", "-c", "echo 'PreStop Hook: Waiting 15 seconds' && sleep 15" ] | ||
resources: | ||
limits: | ||
cpu: 300m | ||
memory: 128Mi | ||
requests: | ||
cpu: 300m | ||
memory: 128Mi |
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,28 @@ | ||
# AWS ALB Ingress Controller를 사용하여 Ingress 리소스를 생성합니다. | ||
apiVersion: networking.k8s.io/v1 | ||
kind: Ingress | ||
metadata: | ||
name: httpbin | ||
namespace: default | ||
annotations: | ||
alb.ingress.kubernetes.io/scheme: internet-facing | ||
alb.ingress.kubernetes.io/target-type: ip | ||
alb.ingress.kubernetes.io/target-group-attributes: deregistration_delay.timeout_seconds=60 | ||
alb.ingress.kubernetes.io/healthcheck-path: "/status/200" # readinessProbe와 동일한 경로 설정 | ||
alb.ingress.kubernetes.io/healthcheck-port: "80" # 컨테이너 포트 설정 | ||
alb.ingress.kubernetes.io/healthcheck-interval-seconds: "10" # 헬스체크 주기 (초) | ||
alb.ingress.kubernetes.io/healthcheck-timeout-seconds: "5" # 헬스체크 타임아웃 (초) | ||
alb.ingress.kubernetes.io/healthy-threshold-count: "2" # 헬스 체크 성공 기준 횟수 | ||
alb.ingress.kubernetes.io/unhealthy-threshold-count: "2" # 헬스 체크 실패 기준 횟수 | ||
spec: | ||
ingressClassName: alb | ||
rules: | ||
- http: | ||
paths: | ||
- path: / | ||
pathType: ImplementationSpecific | ||
backend: | ||
service: | ||
name: httpbin | ||
port: | ||
number: 80 |
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,15 @@ | ||
apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
name: httpbin | ||
namespace: default | ||
labels: | ||
app: httpbin | ||
spec: | ||
selector: | ||
app: httpbin | ||
ports: | ||
- protocol: TCP | ||
port: 80 | ||
targetPort: 80 | ||
type: ClusterIP |