Skip to content

Commit 9ef7be3

Browse files
authored
Docker container readme and dockerfile (#6693)
1 parent b179b66 commit 9ef7be3

File tree

3 files changed

+7
-41
lines changed

3 files changed

+7
-41
lines changed

Dockerfile

Lines changed: 5 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -4,24 +4,16 @@ FROM node:18-alpine
44
WORKDIR /usr/src/app
55

66
# Install dependencies
7-
RUN apk --no-cache add g++ gcc libgcc libstdc++ linux-headers make python3 tini
8-
RUN ln -s /usr/bin/python3 /usr/bin/python
7+
RUN apk --no-cache add g++ gcc libgcc libstdc++ linux-headers make vips-dev python3 tini git
98
RUN npm install --quiet node-gyp -g
109
# Add Tini
1110
ENTRYPOINT ["/sbin/tini", "--"]
1211

13-
# Install app dependencies
14-
COPY package.json .
15-
COPY package-lock.json .
16-
RUN npm ci --only=production
17-
18-
# Make sure to get latest
19-
ADD "https://www.random.org/cgi-bin/randbyte?nbytes=10&format=h" skipcache
20-
2112
# Bundle app source
2213
COPY . .
2314

15+
# Install app dependencies
16+
RUN npm ci
17+
2418
EXPOSE 80 8080
25-
WORKDIR "platform"
26-
ENV NODE_ENV=production
27-
CMD ["node", "serve.js"]
19+
CMD ["/bin/sh"]

Dockerfile.development

Lines changed: 0 additions & 27 deletions
This file was deleted.

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,8 @@ You can contribute your changes back to the main repository by [creating a pull
131131

132132
## Setup with Docker
133133

134-
We provide a Dockerfile for development based on one of the official Python-images. When using this you can skip setting up Python and a local installation of Grow on your machine. Though make sure you completed all other installation steps, like cloning the repository, installing all Node.js dependencies and exporting a valid GitHub token as outlined in [Fork & clone the repository](#fork--clone-the-repository) and [Develop](#develop). When those steps are completed instead of running the project with `npm run develop` you can build a development Docker image with the followiung command, run from the project root directory:
134+
We provide a Dockerfile for development based on one of the official Python-images. When using this you can skip setting up Python and a local installation of Grow on your machine. Though make sure you completed all other installation steps, like cloning the repository, installing all Node.js dependencies and exporting a valid GitHub token as outlined in [Fork & clone the repository](#fork--clone-the-repository) and [Develop](#develop). When those steps are completed instead of running the project with `npm run develop` you can build a Docker image with the followiung command, run from within the Docker container:
135+
135136

136137
```sh
137138
$ npx gulp developImageBuild

0 commit comments

Comments
 (0)