Skip to content

Commit 89780f9

Browse files
Fix deps
1 parent 51fcf60 commit 89780f9

2 files changed

Lines changed: 69 additions & 1 deletion

File tree

.github/workflows/deploy.yml

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,14 +84,82 @@ jobs:
8484
8585
- name: Wait for API service stability
8686
run: |
87+
echo "Waiting for API service to stabilise..."
8788
aws ecs wait services-stable \
8889
--cluster ${{ vars.ECS_CLUSTER_NAME }} \
8990
--services ${{ vars.ECS_API_SERVICE_NAME }} \
9091
--region ${{ vars.AWS_REGION }}
9192
9293
- name: Wait for worker service stability
9394
run: |
95+
echo "Waiting for worker service to stabilise..."
9496
aws ecs wait services-stable \
9597
--cluster ${{ vars.ECS_CLUSTER_NAME }} \
9698
--services ${{ vars.ECS_WORKER_SERVICE_NAME }} \
9799
--region ${{ vars.AWS_REGION }}
100+
101+
- name: Get API service deployment status
102+
run: |
103+
echo "=== API Service Status ==="
104+
aws ecs describe-services \
105+
--cluster ${{ vars.ECS_CLUSTER_NAME }} \
106+
--services ${{ vars.ECS_API_SERVICE_NAME }} \
107+
--region ${{ vars.AWS_REGION }} \
108+
--query 'services[0].{Status:status,Running:runningCount,Desired:desiredCount,Deployments:deployments[*].{Status:rolloutState,TaskDef:taskDefinition,Running:runningCount}}' \
109+
--output table
110+
111+
- name: Get worker service deployment status
112+
run: |
113+
echo "=== Worker Service Status ==="
114+
aws ecs describe-services \
115+
--cluster ${{ vars.ECS_CLUSTER_NAME }} \
116+
--services ${{ vars.ECS_WORKER_SERVICE_NAME }} \
117+
--region ${{ vars.AWS_REGION }} \
118+
--query 'services[0].{Status:status,Running:runningCount,Desired:desiredCount,Deployments:deployments[*].{Status:rolloutState,TaskDef:taskDefinition,Running:runningCount}}' \
119+
--output table
120+
121+
- name: Get recent API task logs
122+
run: |
123+
echo "=== Recent API Task Logs ==="
124+
TASK_ARN=$(aws ecs list-tasks \
125+
--cluster ${{ vars.ECS_CLUSTER_NAME }} \
126+
--service-name ${{ vars.ECS_API_SERVICE_NAME }} \
127+
--region ${{ vars.AWS_REGION }} \
128+
--query 'taskArns[0]' \
129+
--output text)
130+
131+
if [ -n "$TASK_ARN" ] && [ "$TASK_ARN" != "None" ]; then
132+
TASK_ID=$(echo $TASK_ARN | cut -d'/' -f3)
133+
LOG_STREAM="ecs/api/$TASK_ID"
134+
135+
aws logs tail /ecs/${{ vars.ECS_CLUSTER_NAME }} \
136+
--log-stream-name-prefix "ecs/api" \
137+
--since 5m \
138+
--format short \
139+
--region ${{ vars.AWS_REGION }} || echo "No recent logs found"
140+
else
141+
echo "No running tasks found"
142+
fi
143+
144+
- name: Get recent worker task logs
145+
run: |
146+
echo "=== Recent Worker Task Logs ==="
147+
TASK_ARN=$(aws ecs list-tasks \
148+
--cluster ${{ vars.ECS_CLUSTER_NAME }} \
149+
--service-name ${{ vars.ECS_WORKER_SERVICE_NAME }} \
150+
--region ${{ vars.AWS_REGION }} \
151+
--query 'taskArns[0]' \
152+
--output text)
153+
154+
if [ -n "$TASK_ARN" ] && [ "$TASK_ARN" != "None" ]; then
155+
TASK_ID=$(echo $TASK_ARN | cut -d'/' -f3)
156+
LOG_STREAM="ecs/worker/$TASK_ID"
157+
158+
aws logs tail /ecs/${{ vars.ECS_CLUSTER_NAME }} \
159+
--log-stream-name-prefix "ecs/worker" \
160+
--since 5m \
161+
--format short \
162+
--region ${{ vars.AWS_REGION }} || echo "No recent logs found"
163+
else
164+
echo "No running tasks found"
165+
fi

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ dependencies = [
2020
"pydantic-settings>=2.6.0",
2121
"rich>=13.9.4",
2222
"tables>=3.10.2",
23-
"logfire[fastapi]>=0.60.0",
23+
"logfire[fastapi,httpx]>=0.60.0",
2424
"fastapi-cache2>=0.2.1",
2525
]
2626

0 commit comments

Comments
 (0)