sudo dnf install -y https://s3.amazonaws.com/session-manager-downloads/plugin/latest/linux_64bit/session-manager-plugin.rpmsudo systemctl start amazon-ssm-agent
Shell
복사
ngrep -q -W byline "" tcp port 8080
Shell
복사
User Container
TASKDEF_ARN=$(aws ecs list-tasks --cluster apdev-cluster --desired-status RUNNING --family user --region ap-northeast-2 --query "taskArns[0]" --output text)
Shell
복사
aws ecs execute-command \
--region ap-northeast-2 \
--cluster apdev-cluster \
--task $TASKDEF_ARN \
--container user \
--command "/bin/sh" \
--interactive
Shell
복사
Product Container
TASKDEF_ARN=$(aws ecs list-tasks --cluster apdev-cluster --desired-status RUNNING --family product --region ap-northeast-2 --query "taskArns[0]" --output text)
Shell
복사
aws ecs execute-command \
--region ap-northeast-2 \
--cluster apdev-cluster \
--task $TASKDEF_ARN \
--container product \
--command "/bin/sh" \
--interactive
Shell
복사
Stress Container
TASKDEF_ARN=$(aws ecs list-tasks --cluster apdev-cluster --desired-status RUNNING --family stress --region ap-northeast-2 --query "taskArns[0]" --output text)
Shell
복사
aws ecs execute-command \
--region ap-northeast-2 \
--cluster apdev-cluster \
--task $TASKDEF_ARN \
--container stress \
--command "/bin/sh" \
--interactive
Shell
복사
