From 4f7ae05357f62214149c9642ec1a2d1cf6f606ba Mon Sep 17 00:00:00 2001 From: henryclw <97804910+henryclw@users.noreply.github.com> Date: Sat, 23 Apr 2022 17:19:43 -0700 Subject: [PATCH 1/2] Create Dockerfile --- Dockerfile | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 00000000..31807800 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,15 @@ +FROM node:lts-alpine + +RUN apk update + +WORKDIR /app + +COPY . ./ + +RUN yarn + +RUN yarn build + +EXPOSE 5000 + +ENTRYPOINT ["yarn", "start"] From 9fb8cf33391e7b7811f7c4eff2a839e8e9511999 Mon Sep 17 00:00:00 2001 From: henryclw <97804910+henryclw@users.noreply.github.com> Date: Sat, 23 Apr 2022 17:19:56 -0700 Subject: [PATCH 2/2] Add Docker instructions in README.md --- README.md | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index ec104db9..765faae4 100644 --- a/README.md +++ b/README.md @@ -77,8 +77,13 @@ You can discuss matrix.to in ## Build Instructions 1. Install [yarn](https://classic.yarnpkg.com/en/docs/install) -1. `git clone https://github.com/matrix-org/matrix.to` -1. `cd matrix.to` -1. `yarn` -1. `yarn start` -1. Go to http://localhost:5000 in your browser +2. `git clone https://github.com/matrix-org/matrix.to` +3. `cd matrix.to` +4. `yarn` +5. `yarn start` +6. Go to http://localhost:5000 in your browser + +## Docker instructions + +1. Build your own image, `docker build . -t matrixdotorg/matrix-to:dev` +2. Run, `docker run -it -d --name matrix-to-dev -p 5000:5000 matrixdotorg/matrix-to:dev`