2022-05-05 00:49:33 +03:00
|
|
|
FROM epicmorg/nodejs:node10
|
|
|
|
|
|
|
|
RUN git clone https://github.com/ArekSredzki/electron-release-server.git /usr/src/electron-release-server && \
|
|
|
|
tree /usr/src/electron-release-server
|
2021-09-01 16:39:06 +03:00
|
|
|
|
2022-05-05 00:49:33 +03:00
|
|
|
WORKDIR /usr/src/electron-release-server
|
2021-09-01 16:39:06 +03:00
|
|
|
|
|
|
|
RUN npm install \
|
|
|
|
&& ./node_modules/.bin/bower install --allow-root \
|
|
|
|
&& npm cache clean --force \
|
|
|
|
&& npm prune --production
|
|
|
|
|
|
|
|
# Bundle app source
|
2022-05-05 00:49:33 +03:00
|
|
|
RUN cp -rfv /usr/src/electron-release-server/config/docker.js /usr/src/electron-release-server/config/local.js
|
2021-09-01 16:39:06 +03:00
|
|
|
|
2022-03-21 18:48:36 +03:00
|
|
|
#healthcheck. good practice
|
|
|
|
HEALTHCHECK --interval=2m --timeout=3s CMD curl -f http://localhost:80/ || exit 1
|
|
|
|
|
|
|
|
# Add image configuration and scripts
|
|
|
|
COPY docker-entrypoint.sh /usr/bin/docker-entrypoint.sh
|
|
|
|
RUN chmod 755 /usr/bin/docker-entrypoint.sh
|
|
|
|
|
|
|
|
#Final config
|
2022-05-05 00:49:33 +03:00
|
|
|
EXPOSE 80 5000
|
2021-09-01 16:39:06 +03:00
|
|
|
|
2022-03-21 18:48:36 +03:00
|
|
|
ENTRYPOINT ["tini", "-s", "--", "docker-entrypoint.sh"]
|
2022-05-05 00:49:33 +03:00
|
|
|
CMD ["docker-entrypoint.sh"]
|