- AWS EC2 인스턴스를 Ubuntu 22.04 로 생성할 경우 Ruby 3버전 이상부터 Codedeploy가 호환되지 않아 Codedeploy agent를 인스턴스에 설치할 수 없는 상황이 발생합니다.
- 이경우 다음과 같이 Codedeploy의 특정버전을 설치하여 해결할 수 있습니다.
sudo apt-get update sudo apt-get install ruby-full ruby-webrick wget -y cd /tmp wget https://aws-codedeploy-ap-northeast-2.s3.ap-northeast-2.amazonaws.com/releases/codedeploy-agent_1.3.2-1902_all.deb mkdir codedeploy-agent_1.3.2-1902_ubuntu22 dpkg-deb -R codedeploy-agent_1.3.2-1902_all.deb codedeploy-agent_1.3.2-1902_ubuntu22 sed 's/Depends:.*/Depends:ruby3.0/' -i ./codedeploy-agent_1.3.2-1902_ubuntu22/DEBIAN/control dpkg-deb -b codedeploy-agent_1.3.2-1902_ubuntu22/ sudo dpkg -i codedeploy-agent_1.3.2-1902_ubuntu22.deb systemctl list-units --type=service | grep codedeploy sudo service codedeploy-agent status
![[팀 08] 사이코](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F95482992-37b2-4340-9a70-77909ee02ece%2F%25E1%2584%258E%25E1%2585%25A5%25E1%2586%25AF%25E1%2584%2589%25E1%2585%25AE.jpg?table=block&id=0de3b72d-52fa-4b81-ac88-2a87252cc0a4&cache=v2)