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

Create Dockerfile #20

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Create Dockerfile #20

wants to merge 1 commit into from

Conversation

sbhavani
Copy link

No description provided.

@@ -0,0 +1,8 @@
FROM node:7.7.2-alpine
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm curious - why this version? Seems kind of old.

@sbhavani
Copy link
Author

sbhavani commented Oct 23, 2019 via email

@sbhavani
Copy link
Author

I'm trying to combine this with a docker compose file that also runs couchdb but running into some issues. Let me know if you were able to successfully launch both services together

@pieper
Copy link
Contributor

pieper commented Oct 25, 2019

Hi @sbhavani - Yes, I think it makes sense to have a docker compose to make this easy to deploy, but I haven't done that yet. I did a single dockerfile test that added couchdb and dicomweb-server to the same container, but that's not a good pattern. Then started looking into kubernetes but now thing that's overkill for most cases.

So yes, would love to see docker compose worked out. What issues did you have?

@dannyrb
Copy link
Member

dannyrb commented Oct 26, 2019

I have a tiny project I've been working on locally:

  1. A docker-compose that:
  • Adds dicomweb-server
    • Provides a "builder" for dicomweb-server
    • Depends on couchdb
  • Adds couchdb
    • Persists to local mount point
  1. A quick python script that:
  • Uses dicomweb_client
  • If test file doesn't exist when requested from dicomweb-server:
    • Seeds data with DICOM files from a local directory
    • OR seeds using provided list of resolvable URIs for resources

My goal being to use it for some more-or-less immutable and local test data for a separate project. I'll be sure to share what I end up with here, and you're more than welcome to incorporate whatever bits of it you may find useful/helpful.

@dannyrb
Copy link
Member

dannyrb commented Oct 28, 2019

@sbhavani I have the start of something here:

If you have specific questions, let me know. I'll be playing with improvements as we begin to integrate our E2E tests with this. I'm also all ears for any improvements you think would make sense ^_^

@sbhavani
Copy link
Author

services: couchdb: image: couchdb ports: - "5984:5984" dicomweb: build: . depends_on: - couchdb ports: - "5985:5985" command: npm start

This was my simple docker compose file but the issue I was having was couchdb needs to be initialized with a users table (e.g. curl -X PUT http://localhost:5984/_users) and even after doing that I was having trouble with communication between containers.

I'm sure there's an elegant way to solve this by defining networks and environment variables but I'm happy to use your single dockerfile test if that works well.

@dannyrb
Copy link
Member

dannyrb commented Oct 29, 2019

@sbhavani, hmm...
I'm just setting the hostname for each image in my docker-compose
That allows me to update my configuration so that dbServer: 'http://couchdb', is able to resolve and connect to couchdb

@emelalkim
Copy link
Contributor

Hi @sbhavani , you need to update development.js to have either the ip of the host or the container name as @dannyrb suggested. In ePad, we use dicomweb-server in addition to some other containers and we have a docker-compose file and instructions on how to set it. You can download it from here and use as a reference if you want. We are binding the configuration files as volumes to the containers so that they can be updated from outside of the container. Current docker compose file uses the images that are built via dockerfiles and hosted on dockerhub but you can change it easily. The dockerfile that is used to create the image in dockerhub for dicomweb-server is in the dockerization branch. It also includes some improvements like tls and prefix support.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants