-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Production User
committed
Apr 26, 2023
0 parents
commit b518c7f
Showing
8 changed files
with
276 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
MIT License | ||
|
||
Copyright (c) 2022 codingstrand | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
|
||
Use this repo to create repos for other sites. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
# | ||
server { | ||
|
||
listen 80; | ||
|
||
root /var/www/html; | ||
|
||
server_name sample.breedbase.org; | ||
|
||
client_max_body_size 1G; | ||
|
||
location ~/brapi/ { | ||
auth_basic "off"; | ||
proxy_read_timeout 100m; | ||
proxy_pass http://127.0.0.1:8080; | ||
} | ||
|
||
location ~/user/login { | ||
auth_basic "off"; | ||
proxy_pass http://127.0.0.1:8080; | ||
} | ||
|
||
location ~/.well-known/openid-configuration { | ||
auth_basic "off"; | ||
proxy_pass http://127.0.0.1:8080; | ||
} | ||
|
||
location ~/brapi/authorize { | ||
auth_basic "off"; | ||
proxy_pass http://127.0.0.1:8080; | ||
} | ||
|
||
|
||
|
||
location / { | ||
proxy_pass http://127.0.0.1:8080; | ||
proxy_set_header X-Real-IP $remote_addr; | ||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | ||
proxy_set_header Host $host; | ||
proxy_read_timeout 100m; | ||
auth_basic "Restricted - Authorized Users Only"; | ||
auth_basic_user_file /etc/nginx/.htpasswd; | ||
} | ||
|
||
|
||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# /etc/crontab: system-wide crontab | ||
# Unlike any other crontab you don't have to run the `crontab' | ||
# command to install the new version when you edit this file | ||
# and files in /etc/cron.d. These files also have username fields, | ||
# that none of the other crontabs do. | ||
|
||
SHELL=/bin/sh | ||
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin | ||
|
||
# m h dom mon dow user command | ||
17 * * * * root cd / && run-parts --report /etc/cron.hourly | ||
25 6 * * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.daily ) | ||
47 6 * * 7 root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.weekly ) | ||
52 6 1 * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.monthly ) | ||
# | ||
|
||
### BREEDBASE SPECIFIC CRONTAB ENTRIES: | ||
# | ||
30 00 * * * root /db_dumps/dump | ||
|
||
###* * * * * root date |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
version: "3.7" | ||
|
||
services: | ||
breedbase: | ||
image: breedbase/breedbase:v0.70 | ||
depends_on: | ||
- breedbase_db | ||
container_name: breedbase_web | ||
ports: | ||
- 8080:8080 | ||
- 25:25 | ||
volumes: | ||
- webdata:/home/production/volume | ||
- type: bind | ||
source: /home/production/basesite/empty_db_without.test_users.sql | ||
target: /home/production/empty_dump.sql | ||
# - type: bind | ||
# source: /home/production/sgn | ||
# target: /home/production/cxgn/sgn | ||
- type: bind | ||
source: /home/production/basesite.breedbase.org/sgn_local.conf | ||
target: /home/production/cxgn/sgn/sgn_local.conf | ||
- type: bind | ||
source: /home/production/db_dumps | ||
target: /db_dumps | ||
- type: bind | ||
source: /home/production/basesite/crontab | ||
target: /etc/crontab | ||
|
||
breedbase_db: | ||
image: breedbase/pg:latest | ||
container_name: breedbase_db | ||
volumes: | ||
- dbdata:/var/lib/postgresql/data | ||
|
||
volumes: | ||
webdata: | ||
dbdata: | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#!/bin/bash | ||
|
||
export DATE=`date --iso-8601`; | ||
|
||
echo "Dumping breedbase db, $DATE"; | ||
|
||
rm $HOME/.pgpass | ||
|
||
echo "breedbase_db:5432:breedbase:postgres:postgres"> $HOME/.pgpass | ||
|
||
chmod 0600 $HOME/.pgpass | ||
|
||
ls -al $HOME/.pgpass | ||
|
||
pg_dump -h breedbase_db -U postgres -w -d breedbase > /db_dumps/breedbase_$DATE.sql | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#!/bin/bash | ||
|
||
# Firewall that will prevent port 8080 and 5432 to be accessible from the outside world | ||
|
||
echo "1" > /proc/sys/net/ipv4/ip_forward | ||
|
||
iptables -I FORWARD -p tcp ! -i 0.0.0.0 --dport 8080 -j DROP # 8080 only accessible through localhost | ||
iptables -I FORWARD -p tcp ! -i 0.0.0.0 --dport 5432 -j DROP # postgres only accessible through localhost |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,120 @@ | ||
dbhost breedbase_db | ||
dbname breedbase | ||
dbuser postgres | ||
dbpass postgres | ||
|
||
rootpath /home/production/cxgn | ||
basepath /home/production/cxgn/sgn | ||
|
||
#composable_cvs trait,toy # see below | ||
#composable_cvs_allowed_combinations Time Series|trait+toy | ||
|
||
homepage_files_dir /home/production/volume/public/static_content | ||
|
||
trial_download_logfile /home/production/volume/logs/cassava_trial_download_log | ||
static_datasets_url /data | ||
disable_login 0 | ||
brapi_require_login 0 | ||
require_login 1 | ||
|
||
www_user www-data | ||
www_group www-data | ||
|
||
contact_form_email info@codingstrand.com | ||
|
||
error_log /var/log/sgn/error.log | ||
access_log /var/log/sgn/access.log | ||
|
||
python_executable python3 | ||
|
||
preferred_species Manihot esculenta | ||
|
||
production_server 1 | ||
image_dir /images/ | ||
image_path /home/production/volume/public/images/ | ||
cluster_shared_tempdir /home/production/volume/tmp | ||
tempfiles_base /home/production/volume/tmp/breedbase-site | ||
static_datasets_path /home/production/volume/public | ||
static_content_url /static_content | ||
static_content_path /home/production/volume/public/static_content | ||
|
||
main_production_site_url https://sample.breedbase.org | ||
|
||
# github token for contact form | ||
github_access_token 96d462a40bc3504f4768559e752f7eec16ff2bc1 | ||
|
||
#Homepage controller customization | ||
homepage_display_phenotype_uploads 0 | ||
|
||
# jbrowse path | ||
jbrowse_path /jbrowse_cassavabase/?data=data/json | ||
|
||
#path for archving uploaded files | ||
archive_path /home/production/volume/archive/breedbase/ | ||
|
||
default_genotyping_protocol "GBS ApeKI Cassava genome v6_Oct2015" | ||
#default_genotyping_protocol "GBS ApeKI Cassava genome v5" | ||
|
||
identifier_prefix BB | ||
project_name Sample | ||
cview_db_backend Cassava | ||
|
||
# slurm config | ||
backend Slurm | ||
cluster_host "" | ||
cache_file_path /home/production/volume/cache | ||
solgs_dir /home/production/tmp/solgs/__USERNAME__ | ||
|
||
trait_ontology_db_name CO_322 | ||
|
||
trait_cv_name maize_trait | ||
|
||
#For display on onto tree | ||
#onto_root_namespaces NO (NCSU_ontology), GO (Gene Ontology), PO (Plant Ontology), SO (Sequence Ontology), PATO (Phenotype and Trait Ontology) | ||
#onto_root_namespaces CO_334 (Cassava Trait Ontology), GO (Gene Ontology), PO (Plant Ontology), SO (Sequence Ontology), PATO (Phenotype and Trait Ontology), DL_001 (Dawson Lab Ontology), TO (Time Ontology) | ||
onto_root_namespaces CO_322 (Maize Trait) | ||
|
||
#For display on trait search | ||
trait_variable_onto_root_namespaces CO_322 (Maize Trait), COMP (Composed Variables) | ||
|
||
composable_cvs trait,attribute | ||
composable_cvs_allowed_combinations trait+attribute+toy | ||
|
||
<Controller::Cview> | ||
cview_default_map_id 1 | ||
</Controller::Cview> | ||
|
||
r_qtl_temp_path /export/prod/tmp/solqtl___USERNAME__ | ||
|
||
submit_dir /home/production/public/submit-uploads | ||
|
||
blast_path "" | ||
blast_db_path /home/production/volume/blast/databases/current | ||
|
||
# path to our production_ftp site | ||
# | ||
ftpsite_root /home/production/volume/public | ||
|
||
<View::Mason> | ||
add_comp_root /home/production/cxgn/auburn/mason | ||
</View::Mason> | ||
|
||
<DatabaseConnection sgn_test> | ||
dsn dbi:Pg:host=localhost;dbname=cxgn | ||
user postgres | ||
password <your postgres user password> | ||
|
||
search_path public | ||
search_path sgn | ||
search_path annotation | ||
search_path genomic | ||
search_path insitu | ||
search_path metadata | ||
search_path pheno_population | ||
search_path phenome | ||
search_path physical | ||
search_path tomato_gff | ||
search_path biosource | ||
search_path gem | ||
|
||
</DatabaseConnection> |