This repository has been archived by the owner on Dec 14, 2023. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
update docker containers to node v8 (#1178)
* update docker containers to node v8
- Loading branch information
1 parent
9693b67
commit 38c38ae
Showing
11 changed files
with
8,095 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -50,3 +50,4 @@ web/locale/* | |
# Bower | ||
web/public/components | ||
.bower | ||
.yarn.sha1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,15 @@ | ||
FROM mhart/alpine-node:0.10.48 | ||
FROM node:8-alpine | ||
MAINTAINER butlerx <butlerx@notthe.cloud> | ||
ARG DEP_VERSION=latest | ||
RUN if [ "$SOURCE_BRANCH" = "staging" ]; then DEP_VERSION=staging; fi && \ | ||
apk add --update git make gcc g++ python && \ | ||
RUN apk add --update git make gcc g++ python && \ | ||
mkdir -p /usr/src/app | ||
WORKDIR /usr/src/app | ||
COPY . /usr/src/app/ | ||
RUN npm install && \ | ||
npm install cp-zen-frontend@$DEP_VERSION cp-translations@$DEP_VERSION && \ | ||
RUN yarn && \ | ||
yarn add cp-zen-frontend@"$DEP_VERSION" cp-translations@"$DEP_VERSION" && \ | ||
node_modules/.bin/bower install --allow-root && \ | ||
npm run build && \ | ||
yarn build && \ | ||
apk del make gcc g++ python && \ | ||
rm -rf /tmp/* /root/.npm /root/.node-gyp | ||
EXPOSE 8000 | ||
CMD ["node", "service.js"] | ||
CMD ["yarn", "start"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,15 @@ | ||
#! /usr/bin/env sh | ||
# Dont `set -e` as the post install is going to fail | ||
set -e | ||
cd /usr/src/app || exit | ||
touch .pkg.sha1 | ||
OLD_SHA=$(cat .pkg.sha1) | ||
NEW_SHA=$(sha1sum package.json) | ||
touch .yarn.sha1 | ||
OLD_SHA=$(cat .yarn.sha1) | ||
NEW_SHA=$(sha1sum yarn.lock) | ||
if [ "$OLD_SHA" != "$NEW_SHA" ]; then | ||
echo "$NEW_SHA" > .pkg.sha1 | ||
npm install | ||
echo "$NEW_SHA" > .yarn.sha1 | ||
yarn | ||
rm -rf node_modules/cp-translations | ||
rm -rf node_modules/cp-zen-frontend | ||
ln -s /usr/src/cp-translations node_modules/cp-translations | ||
ln -s /usr/src/cp-zen-frontend node_modules/cp-zen-frontend | ||
./node_modules/.bin/bower install --allow-root | ||
fi | ||
npm run dev | ||
yarn dev |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.