※そもそも、サポート対象外のディストリビューションのバージョンなので、ちゃんと動くかどうかはまったく保証出来ません。
※前提として、awsコマンドインストール済みで、CodeDeployなどの各種設定済みであること
Ubuntu12.04でaws deploy install
しようとするとruby2.0が無いのでインストール失敗します。
E: Unable to locate package ruby2.0 E: Couldn't find any package by regex 'ruby2.0' Installing the AWS CodeDeploy Agent... ERROR Command '['apt-get', '-y', 'install', 'ruby2.0']' returned non-zero exit status 100 Install the AWS CodeDeploy Agent on the on-premises instance by following the instructions in "Configure Existing On-Premises Instances by Using AWS CodeDeploy" in the AWS CodeDeploy User Guide.
そこで、brightboxのレポジトリにruby2.0があるので、追加してあげた後にインストールしてあげると、うまくCodeDeploy-Agentがインストールできます。
apt-get install python-software-properties add-apt-repository ppa:brightbox/ruby-ng apt-get update apt-get install ruby2.0 aws deploy install --config-file codedeploy.onpremises.yml --override-config --region ap-northeast-1
ひとまず、動いている模様です。
# service codedeploy-agent status The AWS CodeDeploy agent is running as PID 18324 # tail -F /var/log/aws/codedeploy-agent/codedeploy-agent.log 2015-11-25 15:50:00 INFO [codedeploy-agent(18708)]: master 18708: Spawned child 1/1 2015-11-25 15:50:01 INFO [codedeploy-agent(18708)]: Started master 18708 with 1 children 2015-11-25 15:51:01 INFO [codedeploy-agent(18712)]: [Aws::CodeDeployCommand::Client 200 61.042376 0 retries] poll_host_command(host_identifier:"arn:aws:iam::1234:user/deploy") 2015-11-25 15:52:03 INFO [codedeploy-agent(18712)]: [Aws::CodeDeployCommand::Client 200 61.021466 0 retries] poll_host_command(host_identifier:"arn:aws:iam::1234:user/deploy")