Skip to content

Commit

Permalink
minor config tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
doug-hahn committed Oct 13, 2020
1 parent 8675789 commit 9e31aff
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 19 deletions.
20 changes: 20 additions & 0 deletions avalon/rails_init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,25 @@ echo " notifempty" >> /etc/logrotate.conf
echo " copytruncate" >> /etc/logrotate.conf
echo "}" >> /etc/logrotate.conf

# batch ingest cronjob wouldn't autorun without this
touch /var/spool/cron/crontabs/root
touch /var/spool/cron/crontabs/app

chown -R app:1002 /mnt/avalon/masterfiles/
chmod -R 0777 /mnt/avalon/masterfiles/

chown -R app:1002 /mnt/avalon/ingest/
chmod -R 0777 /mnt/avalon/ingest/

chown -R app:1002 /mnt/avalon/dropbox
chmod -R 0777 /mnt/avalon/dropbox

echo "* * * * * /bin/bash -l -c '/mnt/avalon/master_rights.sh' >/dev/null 2>&1" >> /var/spool/cron/crontabs/root
echo "* * * * * /bin/bash -l -c '/mnt/avalon/ingest_rights.sh' >/dev/null 2>&1" >> /var/spool/cron/crontabs/root
echo "* * * * * /bin/bash -l -c '/mnt/avalon/dropbox_rights.sh' >/dev/null 2>&1" >> /var/spool/cron/crontabs/root

chmod 600 /var/spool/cron/crontabs/root
service cron reload

cd /home/app/avalon
su -m -c "bundle exec rake db:migrate" app
4 changes: 1 addition & 3 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ services:
- PGDATA=/data
- POSTGRES_USER=${POSTGRES_USER}
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
ports:
- "5432:5432"
fedora:
image: avalonmediasystem/fedora:4.7.5
build:
Expand Down Expand Up @@ -49,6 +47,7 @@ services:
ports:
- "8983:8983"
hls:
container_name: ${NGINX_CONTAINER_NAME}
hostname: localhost:8880
image: 10.55.134.48/avalon/nginx:${RANCHER_IMAGE_VERSION}
build:
Expand Down Expand Up @@ -159,6 +158,5 @@ services:
- env_streaming_content_path=/mnt/avalon/masterfiles
volumes:
- ./data/masterfiles:/mnt/avalon/masterfiles
- ./data/dropbox:/mnt/avalon/dropbox
- ./data/ingest:/mnt/avalon/ingest
ports: []
42 changes: 26 additions & 16 deletions dotenv.example
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,9 @@
RANCHER_IMAGE_VERSION=7.1.1
AVALON_CONTAINER_NAME=avalon
REDIS_CONTAINER_NAME=avalon_redis
NGINX_CONTAINER_NAME=avalon_nginx
VIC_SERVER=10.55.134.48

DISABLE_CHANGE_OWNER_FOR_TEST=false

#
# Redis Settings
# REDIS_HOST needs to match REDIS_CONTAINER_NAME
Expand All @@ -19,11 +18,11 @@ REDIS_HOST=avalon_redis
POSTGRES_USER=postgres
POSTGRES_PASSWORD=password

AVALON_DB_USER=
AVALON_DB_PASSWORD=
AVALON_DB_USER=avalon
AVALON_DB_PASSWORD=password

FEDORA_DB_USER=
FEDORA_DB_PASSWORD=
FEDORA_DB_USER=fedora
FEDORA_DB_PASSWORD=password

#
# Avalon Application settings
Expand All @@ -34,29 +33,40 @@ RAILS_ENV=production

DATABASE_URL=postgres://postgres:password@db/avalon
SOLR_URL=http://solr:8983/solr/avalon
FEDORA_URL=http://fedora:8080/fedora/rest/avalon
FEDORA_URL=http://fedoraAdmin:fedoraAdmin@fedora:8080/fedora/rest/avalon

FEDORA_USER=fedoraAdmin
FEDORA_PASSWORD=fedoraAdmin
FEDORA_HOST=fedora
FEDORA_PORT=8080
FEDORA_NAMESPACE=avalon

SOLR_HOST=solr
SOLR_PORT=8983
SOLR_BASE_PATH=avalon

SECRET_KEY_BASE=
SECRET_KEY_BASE=aaaa
AVALON_BRANCH=tamu_master
AVALON_REPO=https://github.com/TAMULib/avalon.git
AVALON_REPO_RAW=https://raw.githubusercontent.com/TAMULib/avalon/
AVALON_HOSTNAME=localhost

SETTINGS__DOMAIN=http://localhost:3000/
STREAMING_HOST=localhost

BASE_URL=http://localhost:3000/
CLIENT_MAX_BODY_SIZE=2050m

LDAP_USER=
LDAP_PASSWORD=

EMAIL_COMMENTS=
EMAIL_NOTIFICATION=
EMAIL_SUPPORT=
SMTP_ADDRESS=
EMAIL_COMMENTS=[email protected]
EMAIL_NOTIFICATION=[email protected]
EMAIL_SUPPORT=[email protected]
SMTP_ADDRESS=relay.tamu.edu
SMTP_PORT=25

# This is the hostname that Kaltura / nginx can get to
# so for local docker it is the avalon container name.
RTMP_AVALON_URL=http://avalon


# Optional Settings
# Z3950_HOST=
# Z3950_PORT=
Expand Down

0 comments on commit 9e31aff

Please sign in to comment.