diff --git a/aio/aio-builds-setup/dockerbuild/Dockerfile b/aio/aio-builds-setup/dockerbuild/Dockerfile index 234ddf4214..5f90646113 100644 --- a/aio/aio-builds-setup/dockerbuild/Dockerfile +++ b/aio/aio-builds-setup/dockerbuild/Dockerfile @@ -49,7 +49,7 @@ RUN apt-get update -y && apt-get install -y \ openssl \ rsyslog \ yarn -RUN yarn global add pm2 +RUN yarn global add pm2@2 # Set up cronjobs @@ -104,11 +104,8 @@ RUN ln -s /etc/nginx/sites-available/aio-builds-test.conf /etc/nginx/sites-enabl # Set up pm2 -RUN pm2 startup systemv -u root > /dev/null \ - # Ugly! - || echo " ---> Working around https://github.com/Unitech/pm2/commit/a788e523e#commitcomment-20851443" \ - && chkconfig --add pm2 > /dev/null -RUN chkconfig pm2 on +RUN pm2 startup systemv -u root > /dev/null +RUN chkconfig pm2-root on # Set up the shell scripts diff --git a/aio/aio-builds-setup/dockerbuild/scripts-sh/health-check.sh b/aio/aio-builds-setup/dockerbuild/scripts-sh/health-check.sh index 159770ea37..de08632ace 100644 --- a/aio/aio-builds-setup/dockerbuild/scripts-sh/health-check.sh +++ b/aio/aio-builds-setup/dockerbuild/scripts-sh/health-check.sh @@ -19,7 +19,7 @@ services=( rsyslog cron nginx - pm2 + pm2-root ) for s in ${services[@]}; do service $s status > /dev/null diff --git a/aio/aio-builds-setup/dockerbuild/scripts-sh/init.sh b/aio/aio-builds-setup/dockerbuild/scripts-sh/init.sh index 5666a9d70a..2ee7b982da 100755 --- a/aio/aio-builds-setup/dockerbuild/scripts-sh/init.sh +++ b/aio/aio-builds-setup/dockerbuild/scripts-sh/init.sh @@ -10,6 +10,6 @@ service rsyslog start service cron start service dnsmasq start service nginx start -service pm2 start +service pm2-root start aio-upload-server-prod start echo [`date`] - Services started successfully.