Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move rails_app dependency out of sidekiq_worker role #5730

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions playbooks/bibdata.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,13 @@
# re-add nodejs when removed from rails_app
# can be run on only web machines
# - role: nodejs
# sidekiq_worker role must be before the rails_app & passenger roles so that nginx restarts on all boxes
- role: rails_app
- role: sidekiq_worker
when: "'worker' in inventory_hostname"
- role: bibdata_sqs_poller
when:
- "'worker' in inventory_hostname"
- "'1' in inventory_hostname"
- role: rails_app
- role: timezone
- role: bibdata
# samba must be before hr_share
Expand Down
8 changes: 8 additions & 0 deletions playbooks/dpul.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,14 @@
- ../group_vars/dpul/{{ runtime_env | default('staging') }}_solr.yml
- ../group_vars/dpul/vault.yml
roles:
- role: roles/redis
- role: roles/nodejs
- role: roles/openjdk
- role: roles/imagemagick
- role: roles/rails_app
- role: roles/shared_data
- role: roles/sidekiq_worker
- role: roles/sneakers_worker
- role: roles/dpul
- role: roles/datadog
when: runtime_env | default('staging') == "production"
Expand Down
1 change: 1 addition & 0 deletions playbooks/figgy_production.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
- ../group_vars/figgy/production_workers.yml
roles:
- role: roles/common
- role: roles/rails_app
- role: roles/sidekiq_worker
- role: roles/sidekiq_worker
sidekiq_worker_name: "figgy-realtime-workers"
Expand Down
1 change: 1 addition & 0 deletions playbooks/figgy_staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
roles:
- {role: roles/memcached, when: inventory_hostname == 'figgy-web-staging1.princeton.edu'}
- role: roles/rabbitmq
- role: roles/rails_app
- role: roles/sidekiq_worker
- role: roles/sidekiq_worker
sidekiq_worker_name: "figgy-realtime-workers"
Expand Down
2 changes: 2 additions & 0 deletions playbooks/pulfalight.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
roles:
- { role: 'roles/postgresql', tags: 'postgresql' }
- role: roles/openjdk
- role: roles/rails_app
- role: roles/sidekiq_worker # the staging box is both web and worker
when: runtime_env | default('staging') == "staging"
- role: roles/pulfalight
Expand Down Expand Up @@ -49,6 +50,7 @@
- { role: 'roles/postgresql', tags: 'postgresql' }
- role: roles/openjdk
- role: roles/sidekiq_worker
- role: roles/rails_app
- role: roles/pulfalight
- role: roles/datadog
when: runtime_env | default('staging') == "production"
Expand Down
5 changes: 5 additions & 0 deletions playbooks/pulmap.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,11 @@
tags: rubygems

roles:
- role: roles/samba
- role: roles/redis
- role: roles/rails_app
- role: roles/sidekiq_worker
- role: roles/sneakers_worker
- role: roles/pulmap
- role: datadog
when: runtime_env | default('staging') == "production"
Expand Down
1 change: 1 addition & 0 deletions playbooks/tigerdata.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
- role: roles/mailcatcher
- role: rails_app
- role: roles/redis
- role: roles/rails_app
- role: roles/sidekiq_worker
- role: datadog
when: runtime_env | default('staging') == "production"
Expand Down
12 changes: 2 additions & 10 deletions roles/dpul/meta/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,5 @@ galaxy_info:
platforms:
- name: Ubuntu
versions:
- bionic
dependencies:
- role: redis
- role: nodejs
- role: openjdk
- role: imagemagick
- role: rails_app
- role: shared_data
- role: sidekiq_worker
- role: sneakers_worker
- jammy
dependencies: []
9 changes: 9 additions & 0 deletions roles/dpul/molecule/default/converge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,15 @@
apt:
update_cache: true
cache_valid_time: 600
roles:
- role: redis
- role: nodejs
- role: openjdk
- role: imagemagick
- role: rails_app
- role: shared_data
- role: sidekiq_worker
- role: sneakers_worker
tasks:
- name: "Include dpul"
ansible.builtin.include_role:
Expand Down
2 changes: 2 additions & 0 deletions roles/figgy/molecule/default/converge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
apt:
update_cache: true
cache_valid_time: 600
roles:
- role: rails_app
tasks:
- name: "Include figgy"
include_role:
Expand Down
2 changes: 0 additions & 2 deletions roles/lib_jobs/meta/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,5 @@ galaxy_info:
dependencies:
- role: 'ruby_s'
- role: 'deploy_user'
- role: 'redis'
- role: 'sidekiq_worker'
- role: 'rails_app'
- role: 'mailcatcher'
2 changes: 2 additions & 0 deletions roles/pulfalight/molecule/default/converge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
apt:
update_cache: true
cache_valid_time: 600
roles:
- role: rails_app
tasks:
- name: "Include pulfalight"
include_role:
Expand Down
7 changes: 1 addition & 6 deletions roles/pulmap/meta/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,4 @@ galaxy_info:
- name: Ubuntu
versions:
- 18.04
dependencies:
- role: "samba"
- role: "redis"
- role: "rails_app"
- role: "sidekiq_worker"
- role: "sneakers_worker"
dependencies: []
6 changes: 6 additions & 0 deletions roles/pulmap/molecule/default/converge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@
apt:
update_cache: true
cache_valid_time: 600
roles:
- role: samba
- role: redis
- role: rails_app
- role: sidekiq_worker
- role: sneakers_worker
tasks:
- name: "Include pulmap"
include_role:
Expand Down
10 changes: 3 additions & 7 deletions roles/sidekiq_worker/meta/main.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
galaxy_info:
role_name: sidekiq_workers
role_name: sidekiq_worker
author: pulibrary
description: Sidekiq Workers
description: Sidekiq Worker
company: Princeton University Library

license: MIT
Expand All @@ -12,8 +12,4 @@ galaxy_info:
platforms:
- name: Ubuntu
versions:
- 16.04
- 18.04

dependencies:
- role: rails_app
- jammy
2 changes: 2 additions & 0 deletions roles/sidekiq_worker/molecule/default/converge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
apt:
update_cache: true
cache_valid_time: 600
roles:
- role: rails_app
tasks:
- name: "Include rails_app"
include_role:
Expand Down
Loading