Skip to content

Commit

Permalink
on and on, still testing
Browse files Browse the repository at this point in the history
  • Loading branch information
cat-bro committed Feb 28, 2024
1 parent 99d99ba commit 4082f10
Show file tree
Hide file tree
Showing 4 changed files with 147 additions and 84 deletions.
130 changes: 66 additions & 64 deletions dev_playbook.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
- secret_group_vars/stats_server_vault
- secret_group_vars/dev_secrets
- secret_group_vars/sentry_vault
- secret_group_vars/history_mailer_vault
pre_tasks:
- name: Attach volume to instance
include_role:
Expand Down Expand Up @@ -44,68 +45,69 @@
enabled: false
state: stopped
roles:
- galaxyproject.repos
- common
- mounts
- install-tpv
- geerlingguy.pip
- gantsign.golang
- cyverse-ansible.singularity
- galaxyproject.galaxy
- role: galaxyproject.miniconda
become: true
become_user: galaxy
- usegalaxy_eu.galaxy_subdomains
- webhooks
- nginx-upload-module
- galaxyproject.nginx
- galaxyproject.tusd
- geerlingguy.nfs
- galaxyproject.slurm
# - galaxyproject.s3fs
- galaxyproject.cvmfs
- galaxyproject.gxadmin
- pg-post-tasks
- remote-pulsar-cron
- galaxy-pg-cleanup
#- galaxyproject.tiaas2 # broken in galaxy release_23.1 - missing static/style/base.css
- geerlingguy.docker
- dj-wasabi.telegraf
- postfix-mail-relay
#- login-override
- acl-on-startup
post_tasks:
- name: Ensure object store paths exist
file:
state: directory
path: "{{ item }}"
owner: galaxy
group: galaxy
with_items:
- /mnt/galaxy/data
- /mnt/galaxy/data-2
- /mnt/galaxy/data-3
- name: Make local_tool directory group-writable by machine users
file:
path: /mnt/galaxy/local_tools
owner: root
group: devs
mode: 0775
state: directory
- name: Install slurm-drmaa
package:
name: slurm-drmaa1
- name: Uninstall the existing web-dav-client
pip:
name: "webdavclient3"
virtualenv: "{{ galaxy_venv_dir }}"
state: absent
- name: Workaround content-length header bug in webdav through forcible update to newer version
pip:
name: "webdavclient3@git+https://github.com/ezhov-evgeny/webdav-client-python-3@0f17fa7946e66f7963db367d0d6b2e7f940ebeb8"
virtualenv: "{{ galaxy_venv_dir }}"
- name: Reload exportfs
command: exportfs -ra
become: yes
become_user: root
# - galaxyproject.repos
# - common
# - mounts
# - install-tpv
# - geerlingguy.pip
# - gantsign.golang
# - cyverse-ansible.singularity
# - galaxyproject.galaxy
# - role: galaxyproject.miniconda
# become: true
# become_user: galaxy
# - usegalaxy_eu.galaxy_subdomains
# - webhooks
# - nginx-upload-module
# - galaxyproject.nginx
# - galaxyproject.tusd
# - geerlingguy.nfs
# - galaxyproject.slurm
# # - galaxyproject.s3fs
# - galaxyproject.cvmfs
# - galaxyproject.gxadmin
# - pg-post-tasks
# - remote-pulsar-cron
# - galaxy-pg-cleanup
# #- galaxyproject.tiaas2 # broken in galaxy release_23.1 - missing static/style/base.css
# - geerlingguy.docker
# - dj-wasabi.telegraf
# - postfix-mail-relay
# #- login-override
# - acl-on-startup
- usegalaxy-au.history_mailer
# post_tasks:
# - name: Ensure object store paths exist
# file:
# state: directory
# path: "{{ item }}"
# owner: galaxy
# group: galaxy
# with_items:
# - /mnt/galaxy/data
# - /mnt/galaxy/data-2
# - /mnt/galaxy/data-3
# - name: Make local_tool directory group-writable by machine users
# file:
# path: /mnt/galaxy/local_tools
# owner: root
# group: devs
# mode: 0775
# state: directory
# - name: Install slurm-drmaa
# package:
# name: slurm-drmaa1
# - name: Uninstall the existing web-dav-client
# pip:
# name: "webdavclient3"
# virtualenv: "{{ galaxy_venv_dir }}"
# state: absent
# - name: Workaround content-length header bug in webdav through forcible update to newer version
# pip:
# name: "webdavclient3@git+https://github.com/ezhov-evgeny/webdav-client-python-3@0f17fa7946e66f7963db367d0d6b2e7f940ebeb8"
# virtualenv: "{{ galaxy_venv_dir }}"
# - name: Reload exportfs
# command: exportfs -ra
# become: yes
# become_user: root

58 changes: 58 additions & 0 deletions host_vars/dev.gvl.org.au.yml
Original file line number Diff line number Diff line change
Expand Up @@ -416,3 +416,61 @@ webhook_plugins:
- demo
- gtn
- news

### History mailer

# config
history_mailer_warn_days: 365
history_mailer_delete_days: 379
history_mailer_email_days_threshold: 14
history_mailer_purge_days_threshold: 6

history_mailer_galaxy_url: https://dev.gvl.org.au
history_mailer_galaxy_api_key: "{{ vault_jenkins_bot_dev_api_key }}" # TODO: add this!

history_mailer_galaxy_keeplist_group: "History Retention Keeplist"

# history_mailer_postal_base_url: "https://mail.usegalaxy.org.au/api/v1/"
# history_mailer_postal_api_key: "{{ vault_history_mailer_postal_api_key }}"

# history_mailer_email_template_warning: "{{ history_mailer_email_template_dir }}/email_warning.html"
# history_mailer_email_template_deletion: "{{ history_mailer_email_template_dir }}/email_deletion.html"

# history_mailer_mail_from: "Galaxy Australia <[email protected]>"
# history_mailer_mail_replyto: "[email protected]"

# history_mailer_slack_token: "{{ vault_history_mailer_slack_token }}"
# history_mailer_slack_alert_channel: "#alerts"
# history_mailer_slack_log_channel: "#galaxy-logs"
# history_mailer_alert_mentions: "<@Catherine>"
# history_mailer_log_mentions: "<@Catherine>"

# settings for ansible role
history_mailer_user: ubuntu
history_mailer_dir: "/home/{{ history_mailer_user }}/hm_TEST"

# history_mailer_use_postal: true # Must be true for history mailer to work

history_mailer_enable_cron_jobs: false # When not enabled, cron jobs will be entered in crontab in a disabled state

history_mailer_cron_jobs:
- name: warn_and_delete
weekday: "3"
hour: "11"
options:
- production
- warn
- dryrun
# - name: purge_histories
# weekday: "2"
# hour: "12"
# options:
# - production
# - purge
# - notify

# Delete these and use vault variables
vault_history_mailer_postal_api_key: nottherealkey # xGV6VbNrHOGO8rirFL2e2E6b
vault_history_mailer_slack_token: "xoxb"
vault_jenkins_bot_production_api_key: abcdefg # TODO: add the real one, add these to vault
vault_jenkins_bot_staging_api_key: xyz # TODO: add the real one, add these to vault
2 changes: 1 addition & 1 deletion requirements.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,5 +81,5 @@ roles:

- name: usegalaxy-au.history_mailer
src: https://github.com/usegalaxy-au/ansible-history-mailer
version: e01d8f1 # TODO: at the very least add a commit ID here
version: d6a5120 # TODO: at the very least add a commit ID here

41 changes: 22 additions & 19 deletions secret_group_vars/history_mailer_vault
Original file line number Diff line number Diff line change
@@ -1,20 +1,23 @@
$ANSIBLE_VAULT;1.1;AES256
65396138306261343536613661613663363030613266373439363961646666636630326339303832
3464323933373361646266373134613331393138306165330a393736326631636630363234313536
64356237666163386261356364313634306266333733386464666132386131633862623836393862
6166373261643361660a643566373634666536373330303265393531343263373466623938666664
62626166393361653061346334363933386164623863623031393033343538313966656638393136
62353238353361343638633364363036316438383336383535353261636238623033653531346432
39353763363366613933643563633263363830393835326164373864656534363639303939353666
38336230326565353261333764336633346463343032303562373236376330393732333636653333
65636162396663613031396138313036626337626237343937643265353630393434363439316131
39656139343039373061613737326537383463373533376234376437393862396565386137363165
39613833616463626534386264376139343066653331646236363965663531636430376330613936
66623734393339646635616461316139643965666365616266346532366137306536393536353130
65643734346439383565643437656664623838663964623835303239333962366236373663633962
31386465353861646339663137353139643037313562623964616166366566323834346666626535
64613530313463373635623437663930663139613839316430313132333363306238666238663762
35393730633365393965643636643435653666326164373533386264363733353833663861316237
33386638613434306135353966393537663065633337373139633962663662633862376435383730
65656165353764326434373235633837613332373435663830623639653862626636323363356432
353164613861343265396138313562393366
31616565623561373966653435633261313061623030303666653565633133633066343434663433
3364373839316366623839373838623236373365306230660a613235346463653064353765623030
36316166326664643765623939343566633231333030646130343736366431666566386430363230
6235643866386335640a633361303836663865343431616134363266623535623139616632353138
61373737323061343261383862333736393761666534306439633034336564646261323363393238
38626364376166663331386130333131656664633934323332316431376661656661303632393464
38636238303935373265343837653731306635623964326639316436386463313163366334373039
34626134353030623465303537653434333832303464663035326333653261393736393939326462
33346532366335333434653539613861353838333539643035636333333464656437396133666161
37366138386130613364333734323233323133393363663739663039326262343639626462313561
37346162623963376561393633653230396337313763343763613530383630386437653237666665
38643565383337613233616133643031393131623266646136663137353133643664653332373934
66373764623861363738633331656436356534656262303433616436316637393635336665306166
36633066393764616534303035613236386332633739626466623439353933383965316665366465
30623432383839396465646434313536333066663064323066343334386566323234353438336632
32643538363239373734623166333466653265303937393736363837666266363832363366313862
34643764303736343732666536343465636230393636303739333338303164653138383238343263
63663633373830626461336639626663356435343531626561336164663136666134613361326634
31303937623063313663616531626530353065356138646336323131356430343933646434373439
66663661623465326139326139393131356238306631383432303037623035333862323763653130
64663230353835646436323538383662633539643866363063643732313132343537353665396462
6566303835656131353431666435356362366633316338626466

0 comments on commit 4082f10

Please sign in to comment.