From f7c19f88c1e3617600ca98d5b7800cf747ec2eed Mon Sep 17 00:00:00 2001 From: Martin Brooksbank Date: Mon, 18 Dec 2023 15:52:55 +0000 Subject: [PATCH] This commit provides a sample Dockerfile and instructions to build & run it Signed-off-by: Martin Brooksbank --- Dockerfile | 14 ++++++++++++++ README.md | 9 +++++++++ 2 files changed, 23 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 00000000..67c12476 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,14 @@ +FROM node:20-alpine + +WORKDIR /home/node/app + +RUN chown -R node:node /home/node/app + +USER node + +COPY package*.json ./ + +COPY --chown=node:node . . +RUN yarn install + +CMD ["yarn", "start"] \ No newline at end of file diff --git a/README.md b/README.md index 3e04db9f..e42952a6 100644 --- a/README.md +++ b/README.md @@ -112,6 +112,15 @@ Storybook is a development environment for UI components. It allows you to brows yarn storybook ``` +## Docker + +You can also run the mini-dashboard with Docker. + +```bash +docker build -t meilisearch-mini-dashboard . +docker run -it -e REACT_APP_MEILI_SERVER_ADDRESS=http://localhost:7700 -p 3000:3000 meilisearch-mini-dashboard +``` + ## Contributing If you want to contribute to this project, please make sure to read [the contributing guidelines](./CONTRIBUTING.md)