LoginSignup
4
1

More than 3 years have passed since last update.

【AWS EC2】自動デプロイ設定後に、修正ファイルを再デプロイする手順

Posted at

①まずデスクトップアプリでgithubのmasterに編集ファイルをpushしてマージする。

②EC2でログインして該当ディレクトリまで移動

EC2にログイン

$ cd .ssh
$ ssh -i chat-space.pem ec2-user@[生成したElastic IP]

アプリまで移動

$ cd /var/www/app/

③②の位置でマスターをpull

$ git pull origin master

これで変更がEC2サーバー上にきたか確認

④念の為プロセスを切る

$ ps aux | grep unicorn
$ kill プロセス番号

⑤ローカルで自動デプロイする。

$ bundle exec cap production deploy

⑥デプロイしたIPで確認

4
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
1