Home > Software engineering >  Aws code deploy failing at BeforeBlockTraffic step by timing out even after updating policies
Aws code deploy failing at BeforeBlockTraffic step by timing out even after updating policies

Time:08-05

I have a simple test angular application. I am following a tutorial to learn AWS Code Pipeline and failed in the Code Deploy stage. enter image description here

Below is the appspec.yml file I am using. Am I missing anything in this file as well ??

version: 0.0
os: linux
files:
  - source: /
    destination: /var/www/html/
hooks:
  BeforeInstall:
    - location: scripts/remove_root_dir
      timeout: 900
      runas: root
  ApplicationStart:
    - location: scripts/install_dependencies
      timeout: 300
      runas: root
    - location: scripts/start_server
      timeout: 300
      runas: root
  ApplicationStop:
    - location: scripts/stop_server
      timeout: 300
      runas: root

CodePudding user response:

Check if you have enabled the CodeDeploy agent on your ec2 machine. You can also log in to your ec2 machine and perform the below steps to install the CodeDeploy agent manually.

sudo yum update
sudo yum install ruby
sudo yum install wget
wget https://aws-codedeploy-us-east-1.s3.amazonaws.com/latest/install
chmod  x ./install
sudo ./install auto
  • Related