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
Add a Dockerfile for the cosmosdb-server service #62
base: main
Are you sure you want to change the base?
Conversation
Add a Dockerfile that uses Node.js 12.x to install the necessary project dependencies to run cosmosdb-server within a container. In addition, add support to the server itself to gracefully shutdown when given a subset of UNIX signals (e.g., SIGINT, SIGTERM).
|
||
on: | ||
push: | ||
tags: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To facilitate testing this workflow in GitHub Actions, this used to listen to pushes on a branch. Before opening the PR, I updated it specifically to listen to pushes on tags.
|
||
- name: Docker meta | ||
id: docker_meta | ||
uses: crazy-max/ghaction-docker-meta@v1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This step looks a little over-engineered, but was used because it was the recommended approach to annotating the container image to be published .
- name: Login to DockerHub | ||
uses: docker/login-action@v1 | ||
with: | ||
username: ${{ secrets.DOCKERHUB_USERNAME }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These credentials need to be supplied to the GitHub Actions execution context. This can be done at the GitHub repository level, or at the GitHub organization level:
@@ -0,0 +1,13 @@ | |||
FROM node:12-slim |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This Dockerfile
was heavily influenced by the existing WIP changes in master...ridhoq:docker.
Within a separate GitHub Actions workflow, build and publish the project container image to Docker Hub using credentials provided to the GitHub Actions execution context.
3354d3c
to
b793031
Compare
Thank you for the PR and sorry for the delay. The PR looks great but it's not ready to merge because we don't have an official account on dockerhub yet. I'm asking if we can prepare one. |
No worries! Happy to reengage whenever the DockerHub account gets created. |
This PR includes two distinct changes, but they're split across separate commits in case it isn't desirable to merge both at this time:
Dockerfile
that uses Node.js 12.x to install the necessary project dependencies to runcosmosdb-server
within a container. In addition, add support to the server itself to gracefully shutdown when given a subset of UNIX signals (e.g.,SIGINT
,SIGTERM
).DOCKERHUB_USERNAME
andDOCKERHUB_TOKEN
).Additionally:
azavea/cosmosdb-server
can be found here.Fixes #33