Skip to content

Commit 7d728a2

Browse files
committed
Ongoing work to restore reproducible builds
Missing JBrowse, Primer3, BLAST, Dicey installs
1 parent 012edd8 commit 7d728a2

File tree

5 files changed

+122
-37
lines changed

5 files changed

+122
-37
lines changed

.dockerignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
*

.editorconfig

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
root = true
2+
3+
[*]
4+
end_of_line = lf
5+
charset = utf-8
6+
trim_trailing_whitespace = true
7+
insert_final_newline = true
8+
max_line_length = 120

Dockerfile

100755100644
+28-15
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,36 @@
1-
FROM ubuntu:16.04
2-
LABEL maintainer="[email protected]"
3-
ENV DEBIAN_FRONTEND noninteractive
1+
FROM ubuntu/apache2:2.4-20.04_beta
2+
3+
RUN ln -sf /dev/stdout /var/log/apache2/access.log && ln -sf /dev/stderr /var/log/apache2/error.log && a2enmod cgi
4+
RUN apt update -y && apt install -y mongodb ca-certificates curl python python3-pip && rm -rf /var/lib/apt/lists/* && curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python
5+
RUN pip install --no-cache-dir numpy==1.11.2 pymongo==3.8.0 requests==2.22.0 && pip3 install --no-cache-dir numpy==1.17.2 pymongo==3.8.0 requests==2.20.0 Jinja2==2.10.1 GitPython==3.0.5
6+
7+
CMD service mongodb start && exec apache2-foreground
8+
# Install JBrowse
9+
# Install GuideFinder dependencies?
10+
# Install Primer3, NCBI Blast, Dicey
11+
12+
13+
14+
#FROM ubuntu:16.04
15+
#LABEL maintainer="[email protected]"
16+
#ENV DEBIAN_FRONTEND noninteractive
417

518
# INSTALL BASE REQUIREMENTS
6-
RUN apt-get update && \
7-
apt-get install -y git sudo apache2 && \
8-
cd /var/www/html && \
9-
rm index.html
19+
#RUN apt-get update && \
20+
# apt-get install -y git sudo apache2 && \
21+
# cd /var/www/html && \
22+
# rm index.html
1023

1124
# CHANGE DOCUMENT ROOT AND SERVERNAME
12-
WORKDIR /etc/apache2
13-
RUN sed -i -e "/DocumentRoot/a \ \t\<Directory \'\/var\/www\/html\'\>\n\t\tOptions +ExecCGI\n\t\tAddHandler cgi-script .py\n\t\tAllow from all\n\t</Directory\>" sites-available/000-default.conf
14-
RUN sed -i '1 i\ServerName FORCAST' apache2.conf
25+
#WORKDIR /etc/apache2
26+
#RUN sed -i -e "/DocumentRoot/a \ \t\<Directory \'\/var\/www\/html\'\>\n\t\tOptions +ExecCGI\n\t\tAddHandler cgi-script .py\n\t\tAllow from all\n\t</Directory\>" sites-available/000-default.conf
27+
#RUN sed -i '1 i\ServerName FORCAST' apache2.conf
1528

1629
# GET HOST CODE
17-
COPY . /var/www/html/
18-
WORKDIR /var/www/html/
30+
#COPY . /var/www/html/
31+
#WORKDIR /var/www/html/
1932

2033
# INSTALL DEPENDENCIES
21-
RUN cd src/installation && \
22-
./install.sh /var/www/html && \
23-
./setPermissions.sh
34+
#RUN cd src/installation && \
35+
# ./install.sh /var/www/html && \
36+
# ./setPermissions.sh

docker-compose.yaml

100755100644
+46-22
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,47 @@
1-
version: '2'
2-
1+
version: "3.9"
32
services:
4-
webserver:
5-
image: helrick/forcast
6-
expose:
7-
- ${APACHE2_PORT}
8-
ports:
9-
- ${APACHE2_PORT}:${APACHE2_PORT}
10-
volumes:
11-
- ./mongodb:/data/db
12-
- ./src:/var/www/html/src
13-
- ./jbrowse:/var/www/html/jbrowse
14-
command: >
15-
bash -c "sudo mongod --fork --logpath /var/log/mongodb.log
16-
&& cd /var/www/html/jbrowse
17-
&& ./setup.sh
18-
&& python3 /var/www/html/src/setup/setup.py -r /var/www/html -g ${ORGANISM} -v ${ASSEMBLY} -fa2bit /var/www/html/bin/faToTwoBit -b /var/www/html/bin/ncbi-blast-2.7.1+/bin
19-
&& /var/www/html/src/setup/enable_dicey.sh ${ORGANISM} ${ASSEMBLY}
20-
&& cd /var/www/html/src/installation
21-
&& sudo ./setPermissions.sh
22-
&& sudo service apache2 start
23-
&& tail -f /dev/null"
3+
# mongo:
4+
# image: mongo:3.6
5+
# ports:
6+
# - 127.0.0.1:27017:27017
7+
forcast:
8+
build: .
9+
image: ghcr.io/ccmbioinfo/forcast
10+
ports:
11+
- 80:80
12+
volumes:
13+
- ./sites-enabled:/etc/apache2/sites-enabled
14+
- ./:/var/www/html
15+
- mongodb:/var/lib/mongodb
16+
volumes:
17+
mongodb:
18+
19+
20+
21+
# Install genome and enable dicey
22+
23+
24+
25+
#version: '2'
26+
27+
#services:
28+
# webserver:
29+
# image: helrick/forcast
30+
# expose:
31+
# - ${APACHE2_PORT}
32+
# ports:
33+
# - ${APACHE2_PORT}:${APACHE2_PORT}
34+
# volumes:
35+
# - ./mongodb:/data/db
36+
# - ./src:/var/www/html/src
37+
# - ./jbrowse:/var/www/html/jbrowse
38+
# command: >
39+
# bash -c "sudo mongod --fork --logpath /var/log/mongodb.log
40+
# && cd /var/www/html/jbrowse
41+
# && ./setup.sh
42+
# && python3 /var/www/html/src/setup/setup.py -r /var/www/html -g ${ORGANISM} -v ${ASSEMBLY} -fa2bit /var/www/html/bin/faToTwoBit -b /var/www/html/bin/ncbi-blast-2.7.1+/bin
43+
# && /var/www/html/src/setup/enable_dicey.sh ${ORGANISM} ${ASSEMBLY}
44+
# && cd /var/www/html/src/installation
45+
# && sudo ./setPermissions.sh
46+
# && sudo service apache2 start
47+
# && tail -f /dev/null"

sites-enabled/000-default.conf

+39
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
<VirtualHost *:80>
2+
# The ServerName directive sets the request scheme, hostname and port that
3+
# the server uses to identify itself. This is used when creating
4+
# redirection URLs. In the context of virtual hosts, the ServerName
5+
# specifies what hostname must appear in the request's Host: header to
6+
# match this virtual host. For the default virtual host (this file) this
7+
# value is not decisive as it is used as a last resort host regardless.
8+
# However, you must set it for any further virtual host explicitly.
9+
#ServerName www.example.com
10+
11+
ServerAdmin webmaster@localhost
12+
DocumentRoot /var/www/html
13+
14+
# Available loglevels: trace8, ..., trace1, debug, info, notice, warn,
15+
# error, crit, alert, emerg.
16+
# It is also possible to configure the loglevel for particular
17+
# modules, e.g.
18+
#LogLevel info ssl:warn
19+
20+
ErrorLog ${APACHE_LOG_DIR}/error.log
21+
CustomLog ${APACHE_LOG_DIR}/access.log combined
22+
23+
# For most configuration files from conf-available/, which are
24+
# enabled or disabled at a global level, it is possible to
25+
# include a line for only one particular virtual host. For example the
26+
# following line enables the CGI configuration for this host only
27+
# after it has been globally disabled with "a2disconf".
28+
#Include conf-available/serve-cgi-bin.conf
29+
30+
# FORCAST modification from base configuration
31+
<Directory "/var/www/html">
32+
Options +ExecCGI
33+
AddHandler cgi-script .py
34+
Require all granted
35+
</Directory>
36+
# End modification
37+
</VirtualHost>
38+
39+
# vim: syntax=apache ts=4 sw=4 sts=4 sr noet

0 commit comments

Comments
 (0)