Untitled

 avatar
unknown
plain_text
2 years ago
1.5 kB
3
Indexable
runcmd:
      # enable fstrim (needed for SSDs)
      - systemctl enable fstrim.timer
      - echo "installing ssm agent..."
      - dpkg -i /opt/meglo_glv_packages/amazon-ssm-agent.deb
      - dpkg -i /opt/meglo_glv_packages/amazon-cloudwatch-agent.deb
      # remove the tmp dir from the extracted tar files
      - tar xvf /opt/meglo_glv_packages/localpackages.tar --strip-components=1 -C /opt/meglo_glv_packages
      # intention to not have quotes around the !#/bin/sh command
      - echo "installing pre-downloaded packages..."
      - echo \!\#/bin/sh > /opt/meglo_glv_packages/local_package_install.sh
      - echo "pkgs=\`ls -v /opt/meglo_glv_packages/localpackages\`" >> /opt/meglo_glv_packages/local_package_install.sh
      - echo "for pkg in \$pkgs; do" >> /opt/meglo_glv_packages/local_package_install.sh
      - echo "  echo \"installing /opt/meglo_glv_packages/localpackages/\$pkg\"" >> /opt/meglo_glv_packages/local_package_install.sh
      - echo "  dpkg -i /opt/meglo_glv_packages/localpackages/\$pkg" >> /opt/meglo_glv_packages/local_package_install.sh
      - echo "done" >> /opt/meglo_glv_packages/local_package_install.sh
      - chmod 755 /opt/meglo_glv_packages/local_package_install.sh
      - /opt/meglo_glv_packages/local_package_install.sh
      # Note, we have codedeploy_install in /opt/meglo_glv_packages, but avoid installing it because of missing package dependencies
      # those missing package dependencies get installed during provisioning now
      # optional ssm activation command
      {SSM_ACTIVATION}
Editor is loading...
Leave a Comment