Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
Molstar
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Michal Malý
Molstar
Commits
49de188e
Commit
49de188e
authored
6 years ago
by
Cole Christie
Browse files
Options
Downloads
Patches
Plain Diff
Docker'ized the canvas example
parent
e4c42b83
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
.dockerignore
+4
-0
4 additions, 0 deletions
.dockerignore
Dockerfile
+40
-0
40 additions, 0 deletions
Dockerfile
README.md
+13
-0
13 additions, 0 deletions
README.md
with
57 additions
and
0 deletions
.dockerignore
0 → 100644
+
4
−
0
View file @
49de188e
.*
node_modules
npm-debug.log
*.sublime-project
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Dockerfile
0 → 100644
+
40
−
0
View file @
49de188e
# This is to build a container that demos the Molstar Canvas prototype
# Source material: https://nodejs.org/en/docs/guides/nodejs-docker-webapp/
# Source material: https://derickbailey.com/2017/05/31/how-a-650mb-node-js-image-for-docker-uses-less-space-than-a-50mb-image/
# Source material: https://hub.docker.com/_/node/
# Use the slimed NodeJS source, yielding a space savings of 600MB (~66% of total)
FROM
node:alpine
# Create app directory
WORKDIR
/usr/src/app
# Install app dependencies
# A wildcard is used to ensure both package.json AND package-lock.json AND tslint.json AND tsconfig.json are copied
# where available (npm@5+)
COPY
*.json ./
# Install all dependencies and copy results
RUN
npm
install
COPY
. .
# Build application and bundle results
RUN
npm run build
COPY
build/ build/
# Build Canvas application and bundle results
RUN
npm run build-canvas
COPY
build/ build/
# Open ports for HTTP
EXPOSE
8080/tcp
# Setup standalone simple webserver to run the demo
RUN
npm
install
http-server
-g
# Start NodeJS at container stand up
CMD
[ "http-server", "build/canvas/", "-p", "8080" ]
# Developer helpers (what is inside this container?)
RUN
node
-v
RUN
ls
-alh
This diff is collapsed.
Click to expand it.
README.md
+
13
−
0
View file @
49de188e
...
@@ -78,6 +78,19 @@ From the root of the project:
...
@@ -78,6 +78,19 @@ From the root of the project:
and navigate to
`build/viewer`
and navigate to
`build/viewer`
**Run via Docker**
Build the docker image
docker build -t molstar-proto .
Run the image
docker run -p 8080:8080 molstar-proto
### Code generation
### Code generation
**CIF schemas**
**CIF schemas**
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment