Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(installation, ci, docker): add Dockerfile, updating README #81

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules
npm-debug.log
15 changes: 15 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
FROM node:14
# Create app directory
WORKDIR /usr/src/app
# Install app dependencies
# A wildcard is used to ensure both package.json AND package-lock.json are copied
# where available (npm@5+)
COPY package*.json ./

RUN npm install
# If you are building your code for production
# RUN npm ci --only=production
# Bundle app source
COPY . .
EXPOSE 9001
CMD [ "npm", "run", "storybook" ]
32 changes: 32 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,38 @@
ember install @denali-design/ember
```

## Containerizing

To build docker image locally make sure you have docker agent installed and deamon is running.

https://docs.docker.com/docker-for-windows/install/
https://docs.docker.com/docker-for-mac/install/

1. Command to build the docker image

```
docker build -t denali-ember .
```

2. Check docker images

```
docker images | grep denali-ember
```

3. Run the docker image and optionally map the port

```
docker run -p 49160:9001 -d denali-ember
```

4. Check docker container is running and you can tail logs using

```
docker ps
docker logs -f <CONTAINER ID>
```

## Contributing

See the [Contributing](CONTRIBUTING.md) guide for details.
Expand Down