Skip to content

Commit ef7f729

Browse files
committed
chore: dev 환경 어플리케이션과 모니터링 서비스 분리
1 parent 78b944c commit ef7f729

File tree

2 files changed

+98
-85
lines changed

2 files changed

+98
-85
lines changed

task-definition-dev.json

Lines changed: 2 additions & 85 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
"containerDefinitions": [
55
{
66
"name": "bitnagil-dev",
7-
"cpu": 700,
87
"portMappings": [
98
{
109
"containerPort": 8081,
@@ -48,7 +47,6 @@
4847
{
4948
"name": "redis-dev",
5049
"image": "redis:7-alpine",
51-
"cpu": 100,
5250
"portMappings": [
5351
{
5452
"name": "redis-dev-6379-tcp",
@@ -63,96 +61,15 @@
6361
"mountPoints": [],
6462
"volumesFrom": [],
6563
"systemControls": []
66-
},
67-
{
68-
"name": "prometheus",
69-
"image": "prometheus-image-placeholder",
70-
"cpu": 100,
71-
"essential": false,
72-
"portMappings": [
73-
{
74-
"containerPort": 9090,
75-
"hostPort": 0,
76-
"protocol": "tcp"
77-
}
78-
],
79-
"mountPoints": [
80-
{
81-
"sourceVolume": "prometheus-storage",
82-
"containerPath": "/prometheus"
83-
}
84-
],
85-
"logConfiguration": {
86-
"logDriver": "awslogs",
87-
"options": {
88-
"awslogs-group": "/ecs/prometheus-dev",
89-
"awslogs-region": "ap-northeast-2",
90-
"awslogs-stream-prefix": "ecs"
91-
}
92-
}
93-
},
94-
{
95-
"name": "grafana",
96-
"image": "grafana/grafana:10.4.1",
97-
"cpu": 100,
98-
"links": [
99-
"prometheus"
100-
],
101-
"portMappings": [
102-
{
103-
"containerPort": 3000,
104-
"hostPort": 0,
105-
"protocol": "tcp"
106-
}
107-
],
108-
"environment": [
109-
{
110-
"name": "GF_SERVER_ROOT_URL",
111-
"value": "https://dev.bitnagil.com/grafana"
112-
},
113-
{
114-
"name": "GF_SERVER_SERVE_FROM_SUB_PATH",
115-
"value": "true"
116-
}
117-
],
118-
"mountPoints": [
119-
{
120-
"sourceVolume": "grafana-storage",
121-
"containerPath": "/var/lib/grafana"
122-
}
123-
],
124-
"essential": false,
125-
"logConfiguration": {
126-
"logDriver": "awslogs",
127-
"options": {
128-
"awslogs-group": "/ecs/grafana-dev",
129-
"awslogs-region": "ap-northeast-2",
130-
"awslogs-stream-prefix": "ecs"
131-
}
132-
}
133-
}
134-
],
135-
"volumes": [
136-
{
137-
"name": "prometheus-storage",
138-
"host": {
139-
"sourcePath": "/ecs/prometheus-data"
140-
}
141-
},
142-
{
143-
"name": "grafana-storage",
144-
"host": {
145-
"sourcePath": "/ecs/grafana-data"
146-
}
14764
}
14865
],
14966
"taskRoleArn": "arn:aws:iam::750819668269:role/ecsTaskExecutionRole",
15067
"executionRoleArn": "arn:aws:iam::750819668269:role/ecsTaskExecutionRole",
15168
"requiresCompatibilities": [
15269
"EC2"
15370
],
154-
"cpu": "1024",
155-
"memory": "962",
71+
"cpu": "824",
72+
"memory": "662",
15673
"runtimePlatform": {
15774
"cpuArchitecture": "X86_64",
15875
"operatingSystemFamily": "LINUX"
Lines changed: 96 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,96 @@
1+
{
2+
"family": "bitnagil-monitoring-dev",
3+
"networkMode": "bridge",
4+
"containerDefinitions": [
5+
{
6+
"name": "prometheus",
7+
"image": "prometheus-image-placeholder",
8+
"essential": true,
9+
"portMappings": [
10+
{
11+
"containerPort": 9090,
12+
"hostPort": 0,
13+
"protocol": "tcp"
14+
}
15+
],
16+
"mountPoints": [
17+
{
18+
"sourceVolume": "prometheus-storage",
19+
"containerPath": "/prometheus"
20+
}
21+
],
22+
"logConfiguration": {
23+
"logDriver": "awslogs",
24+
"options": {
25+
"awslogs-group": "/ecs/prometheus-dev",
26+
"awslogs-region": "ap-northeast-2",
27+
"awslogs-stream-prefix": "ecs"
28+
}
29+
}
30+
},
31+
{
32+
"name": "grafana",
33+
"image": "grafana/grafana:10.4.1",
34+
"links": [
35+
"prometheus"
36+
],
37+
"portMappings": [
38+
{
39+
"containerPort": 3000,
40+
"hostPort": 0,
41+
"protocol": "tcp"
42+
}
43+
],
44+
"environment": [
45+
{
46+
"name": "GF_SERVER_ROOT_URL",
47+
"value": "https://dev.bitnagil.com/grafana"
48+
},
49+
{
50+
"name": "GF_SERVER_SERVE_FROM_SUB_PATH",
51+
"value": "true"
52+
}
53+
],
54+
"mountPoints": [
55+
{
56+
"sourceVolume": "grafana-storage",
57+
"containerPath": "/var/lib/grafana"
58+
}
59+
],
60+
"essential": true,
61+
"logConfiguration": {
62+
"logDriver": "awslogs",
63+
"options": {
64+
"awslogs-group": "/ecs/grafana-dev",
65+
"awslogs-region": "ap-northeast-2",
66+
"awslogs-stream-prefix": "ecs"
67+
}
68+
}
69+
}
70+
],
71+
"volumes": [
72+
{
73+
"name": "prometheus-storage",
74+
"host": {
75+
"sourcePath": "/ecs/prometheus-data"
76+
}
77+
},
78+
{
79+
"name": "grafana-storage",
80+
"host": {
81+
"sourcePath": "/ecs/grafana-data"
82+
}
83+
}
84+
],
85+
"taskRoleArn": "arn:aws:iam::750819668269:role/ecsTaskExecutionRole",
86+
"executionRoleArn": "arn:aws:iam::750819668269:role/ecsTaskExecutionRole",
87+
"requiresCompatibilities": [
88+
"EC2"
89+
],
90+
"cpu": "200",
91+
"memory": "300",
92+
"runtimePlatform": {
93+
"cpuArchitecture": "X86_64",
94+
"operatingSystemFamily": "LINUX"
95+
}
96+
}

0 commit comments

Comments
 (0)