Commit b2d10a6d authored by Atte's avatar Atte
Browse files

Added a Dockerfile to create a container for running

the webserver cgi-scripts for VR conversions
parent 2d50d5d9
FROM bitnami/apache:2.4
COPY ./webserver/htdocs/NOMAD/ /opt/bitnami/apache/htdocs/NOMAD/
COPY ./webserver/cgi-bin/NOMAD/ /opt/bitnami/apache/cgi-bin/NOMAD/
...@@ -43,6 +43,15 @@ Subdirectories: ...@@ -43,6 +43,15 @@ Subdirectories:
htdocs: Web pages containing the VR software and documentation. htdocs: Web pages containing the VR software and documentation.
cgi-bin: cgi scripts to create suitable config files from a material number. cgi-bin: cgi scripts to create suitable config files from a material number.
Docker container running the VR webservices
# install docker
# add your NOMAD username and password in webserver/pass
# build container
sudo docker build -t nomadvr .
# run container
sudo docker run -d -p 8080:8080 nomadvr
# Test e.g. with you.rip.add.res:8080/cgi-bin/NOMAD/material?109702
RemoteVisualization: NOMAD2xyz app RemoteVisualization: NOMAD2xyz app
Transforms a json from encyclopedia or archive into an XYZ file Transforms a json from encyclopedia or archive into an XYZ file
Useful for the remote visualization infrastructure Useful for the remote visualization infrastructure
...@@ -54,6 +63,7 @@ Subdirectories: ...@@ -54,6 +63,7 @@ Subdirectories:
MD-Driver/SimpleMove and MD-Driver/PeriodicTable: see MD-Driver/Readme MD-Driver/SimpleMove and MD-Driver/PeriodicTable: see MD-Driver/Readme
Support for atom drag-and-drop functionality in OpenVR NOMAD VR. Support for atom drag-and-drop functionality in OpenVR NOMAD VR.
More platforms will be added in the future. More platforms will be added in the future.
The code is distributed under the Apache 2.0 License (See LICENSE file). The code is distributed under the Apache 2.0 License (See LICENSE file).
......
# note, copy this file to VR-demos folder first
FROM bitnami/apache:2.4
# copy NOMAD webservices
COPY ./webserver/htdocs/NOMAD/ /opt/bitnami/apache/htdocs/NOMAD/
COPY ./webserver/cgi-bin/NOMAD/ /opt/bitnami/apache/cgi-bin/NOMAD/
COPY ./webserver/pass /opt/bitnami/apache/
# allow cgi-bin
RUN sed -i 's%#LoadModule cgid_module modules/mod_cgid.so%LoadModule cgid_module modules/mod_cgid.so%' /opt/bitnami/apache/conf/httpd.conf
# add wget. gzip, curl, tar are there by default
USER root
RUN apt-get update \
&& apt-get install -y wget \
&& apt-get install -y zip \
&& rm -rf /var/lib/apt/lists/*
Docker file to build a container to perform the VR conversion webservices
* copy the Dockerfile to .. (VR-demos -folder)
* install docker
* add your NOMAD username and password in webserver/pass
* build container
sudo docker build -t nomadvr .
* run container
sudo docker run -d -p 8080:8080 nomadvr
* Test e.g. with you.rip.add.res:8080/cgi-bin/NOMAD/material?109702
* stop container
sudo docker stop <container-name>
File mode changed from 100644 to 100755
File mode changed from 100644 to 100755
...@@ -100,5 +100,5 @@ TOKEN=`grep data resp.json |cut -f 4 -d \"` ...@@ -100,5 +100,5 @@ TOKEN=`grep data resp.json |cut -f 4 -d \"`
cat $MAT.zip cat $MAT.zip
fi fi
cd .. cd ..
\rm -r $RAND # \rm -r $RAND
fi fi
File mode changed from 100644 to 100755
...@@ -3,5 +3,5 @@ export USER= ...@@ -3,5 +3,5 @@ export USER=
export PASS= export PASS=
#Notification email #Notification email
export EMAIL= export EMAIL
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment