-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deploy wacruit-server (dev, prod) with sso #88
Merged
Merged
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
b14b120
Add codeowners
shp7724 ea68943
Add wacruit-dev
shp7724 c8c9563
Add wacruit-prod
shp7724 4f26f3b
Add wacruit service in kong gateway (dev, prod)
shp7724 4109e26
Rename iam roles
shp7724 ba82741
Add missing serviceAccountName
shp7724 5b329a2
Remove virtual service
shp7724 d1a54b5
Set resources: 100/128 for dev & 200/256 for prod
shp7724 0a4b54d
Use `wacruit.wafflestudio.com/api/*`, add dev configuration
shp7724 695b11a
Merge remote-tracking branch 'origin/main' into feature/wacruit-server
davin111 e63d766
modified
davin111 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Validating CODEOWNERS rules …
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
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,18 @@ | ||
apiVersion: argoproj.io/v1alpha1 | ||
kind: Application | ||
metadata: | ||
namespace: argocd | ||
name: wacruit-server-dev | ||
finalizers: | ||
- resources-finalizer.argocd.argoproj.io | ||
spec: | ||
project: default | ||
source: | ||
repoURL: {{ .Values.spec.source.repoURL }} | ||
targetRevision: HEAD | ||
path: apps/wacruit-dev/wacruit-server | ||
destination: | ||
server: {{ .Values.spec.destination.server }} | ||
namespace: argocd | ||
syncPolicy: | ||
{{- .Values.spec.syncPolicy | toYaml | nindent 4 }} |
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,18 @@ | ||
apiVersion: argoproj.io/v1alpha1 | ||
kind: Application | ||
metadata: | ||
namespace: argocd | ||
name: wacruit-server | ||
finalizers: | ||
- resources-finalizer.argocd.argoproj.io | ||
spec: | ||
project: default | ||
source: | ||
repoURL: {{ .Values.spec.source.repoURL }} | ||
targetRevision: HEAD | ||
path: apps/wacruit-prod/wacruit-server | ||
destination: | ||
server: {{ .Values.spec.destination.server }} | ||
namespace: argocd | ||
syncPolicy: | ||
{{- .Values.spec.syncPolicy | toYaml | nindent 4 }} |
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,73 @@ | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: wacruit-server | ||
labels: | ||
app: wacruit-server | ||
namespace: wacruit-dev | ||
spec: | ||
replicas: 1 | ||
selector: | ||
matchLabels: | ||
app: wacruit-server | ||
strategy: | ||
type: RollingUpdate | ||
rollingUpdate: | ||
maxSurge: 25% | ||
maxUnavailable: 25% | ||
revisionHistoryLimit: 4 | ||
template: | ||
metadata: | ||
labels: | ||
app: wacruit-server | ||
spec: | ||
serviceAccountName: wacruit-server | ||
containers: | ||
- image: 405906814034.dkr.ecr.ap-northeast-2.amazonaws.com/wacruit-dev/wacruit-server:5 | ||
name: wacruit-server | ||
resources: | ||
requests: | ||
cpu: 100m | ||
memory: 128Mi | ||
limits: | ||
cpu: 100m | ||
memory: 128Mi | ||
ports: | ||
- containerPort: 8080 | ||
--- | ||
apiVersion: v1 | ||
kind: ServiceAccount | ||
metadata: | ||
name: wacruit-server | ||
namespace: wacruit-dev | ||
annotations: | ||
eks.amazonaws.com/role-arn: arn:aws:iam::405906814034:role/wacruit-dev-role | ||
--- | ||
apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
namespace: wacruit-dev | ||
name: wacruit-server | ||
spec: | ||
type: ClusterIP | ||
selector: | ||
app: wacruit-server | ||
ports: | ||
- port: 80 | ||
targetPort: 8080 | ||
--- | ||
apiVersion: networking.istio.io/v1alpha3 | ||
kind: VirtualService | ||
metadata: | ||
namespace: wacruit-dev | ||
name: wacruit-server | ||
spec: | ||
gateways: | ||
- istio-ingress/waffle-ingressgateway | ||
- mesh | ||
hosts: | ||
- wacruit-server.wacruit-dev.svc.cluster.local | ||
http: | ||
- route: | ||
- destination: | ||
host: wacruit-server |
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,73 @@ | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: wacruit-server | ||
labels: | ||
app: wacruit-server | ||
namespace: wacruit-prod | ||
spec: | ||
replicas: 0 | ||
selector: | ||
matchLabels: | ||
app: wacruit-server | ||
strategy: | ||
type: RollingUpdate | ||
rollingUpdate: | ||
maxSurge: 25% | ||
maxUnavailable: 25% | ||
revisionHistoryLimit: 4 | ||
template: | ||
metadata: | ||
labels: | ||
app: wacruit-server | ||
spec: | ||
serviceAccountName: wacruit-server | ||
containers: | ||
- image: 405906814034.dkr.ecr.ap-northeast-2.amazonaws.com/wacruit-prod/wacruit-server:3 | ||
name: wacruit-server | ||
resources: | ||
requests: | ||
cpu: 200m | ||
memory: 256Mi | ||
limits: | ||
cpu: 200m | ||
memory: 256Mi | ||
ports: | ||
- containerPort: 8080 | ||
--- | ||
apiVersion: v1 | ||
kind: ServiceAccount | ||
metadata: | ||
name: wacruit-server | ||
namespace: wacruit-prod | ||
annotations: | ||
eks.amazonaws.com/role-arn: arn:aws:iam::405906814034:role/wacruit-prod-role | ||
--- | ||
apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
namespace: wacruit-prod | ||
name: wacruit-server | ||
spec: | ||
type: ClusterIP | ||
selector: | ||
app: wacruit-server | ||
ports: | ||
- port: 80 | ||
targetPort: 8080 | ||
--- | ||
apiVersion: networking.istio.io/v1alpha3 | ||
kind: VirtualService | ||
metadata: | ||
namespace: wacruit-prod | ||
name: wacruit-server | ||
spec: | ||
gateways: | ||
- istio-ingress/waffle-ingressgateway | ||
- mesh | ||
hosts: | ||
- wacruit-server.wacruit-prod.svc.cluster.local | ||
http: | ||
- route: | ||
- destination: | ||
host: wacruit-server |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
설정하는 것은 자유이시지만, https://github.com/wafflestudio/waffle-world/blob/main/apps/snutt-prod/snutt-timetable/snutt-timetable.yaml#L37-L49 이런 식으로 probe 설정하여서 고장난 container 에 대한 대응이 자동으로 이뤄질 수 있도록 할 수 있습니다. https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/
startupProbe 는 서버가 초반에 늦게 뜨는 경우에만 필요할 수 있습니다.
GET /health-check
같은 endpoint 는 직접 만들어두어야 합니다.