[ansible-lint] Use FQCN for module actions in opeshift playbooks
Signed-off-by: Ryan Lerch <rlerch@redhat.com>
This commit is contained in:
parent
13a490cbf3
commit
f89ed1cf08
27 changed files with 101 additions and 101 deletions
|
@ -19,26 +19,26 @@
|
|||
|
||||
post_tasks:
|
||||
- name: Apply node labels
|
||||
command: oc label --overwrite namespace application-monitoring monitoring-key=cpe
|
||||
ansible.builtin.command: oc label --overwrite namespace application-monitoring monitoring-key=cpe
|
||||
|
||||
- name: Apply node labels for bodhi POC
|
||||
command: oc label --overwrite namespace bodhi monitoring-key=cpe
|
||||
ansible.builtin.command: oc label --overwrite namespace bodhi monitoring-key=cpe
|
||||
|
||||
- name: Make other pods available to the application-monitoring project
|
||||
command: oc adm pod-network make-projects-global application-monitoring
|
||||
ansible.builtin.command: oc adm pod-network make-projects-global application-monitoring
|
||||
|
||||
- name: Copy files
|
||||
copy: src={{ roles_path }}/openshift-apps/application-monitoring/files/ dest=/etc/openshift_apps/application-monitoring/
|
||||
ansible.builtin.copy: src={{ roles_path }}/openshift-apps/application-monitoring/files/ dest=/etc/openshift_apps/application-monitoring/
|
||||
|
||||
- name: Prometheus CRDs
|
||||
command: oc -n application-monitoring apply -f /etc/openshift_apps/application-monitoring/prometheus-operator/example/prometheus-operator-crd/
|
||||
ansible.builtin.command: oc -n application-monitoring apply -f /etc/openshift_apps/application-monitoring/prometheus-operator/example/prometheus-operator-crd/
|
||||
|
||||
- name: Prometheus CRD RBAC
|
||||
command: oc -n application-monitoring apply -f /etc/openshift_apps/application-monitoring/prometheus-operator/example/rbac/prometheus-operator-crd/
|
||||
ansible.builtin.command: oc -n application-monitoring apply -f /etc/openshift_apps/application-monitoring/prometheus-operator/example/rbac/prometheus-operator-crd/
|
||||
|
||||
- name: Prometheus Operator RBAC
|
||||
command: oc -n application-monitoring apply -f /etc/openshift_apps/application-monitoring/prometheus-operator/example/rbac/prometheus-operator/
|
||||
ansible.builtin.command: oc -n application-monitoring apply -f /etc/openshift_apps/application-monitoring/prometheus-operator/example/rbac/prometheus-operator/
|
||||
|
||||
- name: Prometheus RBAC
|
||||
command: oc -n application-monitoring apply -f /etc/openshift_apps/application-monitoring/prometheus-operator/example/rbac/prometheus/
|
||||
ansible.builtin.command: oc -n application-monitoring apply -f /etc/openshift_apps/application-monitoring/prometheus-operator/example/rbac/prometheus/
|
||||
|
||||
|
|
|
@ -16,11 +16,11 @@
|
|||
|
||||
tasks:
|
||||
- name: DB user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "{{ tahrirDBUser }}"
|
||||
password: "{{ (env == 'production') | ternary(tahrirDBPassword, tahrirstgDBPassword) }}"
|
||||
- name: Database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "{{ badges_db_name }}"
|
||||
owner: "{{ tahrirDBUser }}"
|
||||
encoding: UTF-8
|
||||
|
@ -38,11 +38,11 @@
|
|||
|
||||
tasks:
|
||||
- name: DB user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "{{ tahrirDBUser }}"
|
||||
password: "{{ (env == 'production') | ternary(tahrirDBPassword, tahrirstgDBPassword) }}"
|
||||
- name: Grant the db user read only access to datanommer2
|
||||
postgresql_privs:
|
||||
community.postgresql.postgresql_privs:
|
||||
database: datanommer2
|
||||
privs: SELECT
|
||||
objs: ALL_IN_SCHEMA
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
tasks:
|
||||
- name: Install psycopg2 for the postgresql ansible modules
|
||||
package: name=python3-psycopg2 state=present
|
||||
ansible.builtin.package: name=python3-psycopg2 state=present
|
||||
tags:
|
||||
- packages
|
||||
|
||||
|
@ -21,16 +21,16 @@
|
|||
|
||||
tasks:
|
||||
- name: Create the database user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "{{ stg_blockerbugs_db_user }}"
|
||||
password: "{{ stg_blockerbugs_db_password }}"
|
||||
- name: Create the database itself
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "blockerbugs"
|
||||
owner: "{{ stg_blockerbugs_db_user }}"
|
||||
encoding: UTF-8
|
||||
- name: Test the database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "blockerbugs"
|
||||
owner: "{{ stg_blockerbugs_db_user }}"
|
||||
encoding: UTF-8
|
||||
|
@ -47,16 +47,16 @@
|
|||
|
||||
tasks:
|
||||
- name: Create the database user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "{{ prod_blockerbugs_db_user }}"
|
||||
password: "{{ prod_blockerbugs_db_password }}"
|
||||
- name: Create the database itself
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "blockerbugs"
|
||||
owner: "{{ prod_blockerbugs_db_user }}"
|
||||
encoding: UTF-8
|
||||
- name: Test the database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "blockerbugs"
|
||||
owner: "{{ prod_blockerbugs_db_user }}"
|
||||
encoding: UTF-8
|
||||
|
|
|
@ -20,11 +20,11 @@
|
|||
|
||||
pre_tasks:
|
||||
- name: Include Global Variables
|
||||
include_vars: dir=/srv/web/infra/ansible/vars/all/ ignore_files=README
|
||||
ansible.builtin.include_vars: dir=/srv/web/infra/ansible/vars/all/ ignore_files=README
|
||||
- name: Include Bodhi Variables
|
||||
include_vars: /srv/web/infra/ansible/vars/apps/bodhi.yml
|
||||
ansible.builtin.include_vars: /srv/web/infra/ansible/vars/apps/bodhi.yml
|
||||
- name: Set bodhi_version fact
|
||||
set_fact:
|
||||
ansible.builtin.set_fact:
|
||||
args:
|
||||
bodhi_version: "{{ bodhi_version }}"
|
||||
|
||||
|
@ -154,29 +154,29 @@
|
|||
|
||||
post_tasks:
|
||||
- name: Scale up pods
|
||||
command: oc -n bodhi scale dc/bodhi-consumer --replicas={{ bodhi_openshift_pods }}
|
||||
ansible.builtin.command: oc -n bodhi scale dc/bodhi-consumer --replicas={{ bodhi_openshift_pods }}
|
||||
when: env == "production"
|
||||
- name: Scale up pods
|
||||
command: oc -n bodhi scale dc/bodhi-celery --replicas={{ bodhi_openshift_pods }}
|
||||
ansible.builtin.command: oc -n bodhi scale dc/bodhi-celery --replicas={{ bodhi_openshift_pods }}
|
||||
when: env == "production"
|
||||
- name: Scale up pods
|
||||
command: oc -n bodhi scale dc/bodhi-web --replicas=2
|
||||
ansible.builtin.command: oc -n bodhi scale dc/bodhi-web --replicas=2
|
||||
when: env == "production"
|
||||
- name: Scale up pods
|
||||
command: oc -n bodhi scale dc/bodhi-consumer --replicas={{ bodhi_openshift_pods }}
|
||||
ansible.builtin.command: oc -n bodhi scale dc/bodhi-consumer --replicas={{ bodhi_openshift_pods }}
|
||||
when: env == "staging"
|
||||
- name: Scale up pods
|
||||
command: oc -n bodhi scale dc/bodhi-celery --replicas={{ bodhi_openshift_pods }}
|
||||
ansible.builtin.command: oc -n bodhi scale dc/bodhi-celery --replicas={{ bodhi_openshift_pods }}
|
||||
when: env == "staging"
|
||||
- name: Scale up pods
|
||||
command: oc -n bodhi scale dc/bodhi-web --replicas={{ bodhi_openshift_pods }}
|
||||
ansible.builtin.command: oc -n bodhi scale dc/bodhi-web --replicas={{ bodhi_openshift_pods }}
|
||||
when: env == "staging"
|
||||
- name: Set the timeout to the openshift route
|
||||
command: "oc -n bodhi annotate route bodhi-web --overwrite haproxy.router.openshift.io/timeout=180s"
|
||||
ansible.builtin.command: "oc -n bodhi annotate route bodhi-web --overwrite haproxy.router.openshift.io/timeout=180s"
|
||||
tags:
|
||||
- route-timeout
|
||||
- name: Trigger critpath cronjob
|
||||
command: "oc -n bodhi create job critpathcron-manual-{{ lookup('pipe', 'date +%s') }} --from=cronjob/fedora-bodhi-critpathcron"
|
||||
ansible.builtin.command: "oc -n bodhi create job critpathcron-manual-{{ lookup('pipe', 'date +%s') }} --from=cronjob/fedora-bodhi-critpathcron"
|
||||
tags:
|
||||
- never
|
||||
- critpathcron
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
|
||||
pre_tasks:
|
||||
- name: Include Global Variables
|
||||
include_vars: dir=/srv/web/infra/ansible/vars/all/ ignore_files=README
|
||||
ansible.builtin.include_vars: dir=/srv/web/infra/ansible/vars/all/ ignore_files=README
|
||||
|
||||
############################################
|
||||
# actions to create the project in OpenShift
|
||||
|
|
|
@ -19,12 +19,12 @@
|
|||
# Set the fedora_messaging_routing_keys var based on the environment
|
||||
pre_tasks:
|
||||
- name: Set the fedora_messaging_routing_keys var
|
||||
set_fact:
|
||||
ansible.builtin.set_fact:
|
||||
fedora_messaging_routing_keys:
|
||||
- "org.fedoraproject.stg.coreos.build.request.ostree-import"
|
||||
when: env == 'staging'
|
||||
- name: Set the fedora_messaging_routing_keys var
|
||||
set_fact:
|
||||
ansible.builtin.set_fact:
|
||||
fedora_messaging_routing_keys:
|
||||
- "org.fedoraproject.prod.coreos.build.request.ostree-import"
|
||||
when: env != 'staging'
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
pre_tasks:
|
||||
- name: Create project directory
|
||||
file:
|
||||
ansible.builtin.file:
|
||||
path: /etc/openshift_apps/openshift-config
|
||||
state: directory
|
||||
owner: root
|
||||
|
@ -25,4 +25,4 @@
|
|||
|
||||
post_tasks:
|
||||
- name: Patch ingress controller with custom error pages
|
||||
command: oc patch -n openshift-ingress-operator ingresscontroller/default --patch '{"spec":{"httpErrorCodePages":{"name":"fedora-error-code-pages"}}}' --type=merge
|
||||
ansible.builtin.command: oc patch -n openshift-ingress-operator ingresscontroller/default --patch '{"spec":{"httpErrorCodePages":{"name":"fedora-error-code-pages"}}}' --type=merge
|
||||
|
|
|
@ -11,11 +11,11 @@
|
|||
|
||||
tasks:
|
||||
- name: DB user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: datagrepper
|
||||
password: "{{ (env == 'production') | ternary(datagrepper_prod_db_password, datagrepper_stg_db_password) }}"
|
||||
- name: Grant the db user read only access to datanommer2
|
||||
postgresql_privs:
|
||||
community.postgresql.postgresql_privs:
|
||||
database: datanommer2
|
||||
privs: SELECT
|
||||
objs: ALL_IN_SCHEMA
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
|
||||
tasks:
|
||||
- name: Define Project
|
||||
include_role:
|
||||
ansible.builtin.include_role:
|
||||
name: openshift/project
|
||||
vars:
|
||||
description: Documentation translation
|
||||
|
@ -25,26 +25,26 @@
|
|||
- apply-appowners
|
||||
|
||||
- name: Define imagestream
|
||||
include_role:
|
||||
ansible.builtin.include_role:
|
||||
name: openshift/imagestream
|
||||
vars:
|
||||
imagename: builder
|
||||
|
||||
- name: Define buildconfig
|
||||
include_role:
|
||||
ansible.builtin.include_role:
|
||||
name: openshift/object
|
||||
vars:
|
||||
objectname: buildconfig.yml
|
||||
template: buildconfig.yml
|
||||
|
||||
- name: Start build
|
||||
include_role:
|
||||
ansible.builtin.include_role:
|
||||
name: openshift/start-build
|
||||
vars:
|
||||
buildname: docstranslation-build
|
||||
|
||||
- name: Define secrets
|
||||
include_role:
|
||||
ansible.builtin.include_role:
|
||||
name: openshift/object
|
||||
vars:
|
||||
objectname: secrets.yml
|
||||
|
@ -53,7 +53,7 @@
|
|||
- deploy-secrets
|
||||
|
||||
- name: Define configMap
|
||||
include_role:
|
||||
ansible.builtin.include_role:
|
||||
name: openshift/object
|
||||
vars:
|
||||
objectname: configmap.yml
|
||||
|
@ -62,7 +62,7 @@
|
|||
- deploy-config
|
||||
|
||||
- name: Define cron job
|
||||
include_role:
|
||||
ansible.builtin.include_role:
|
||||
name: openshift/object
|
||||
vars:
|
||||
template: cron.yml
|
||||
|
@ -75,7 +75,7 @@
|
|||
###############################################
|
||||
# to run: sudo rbac-playbook -l os_masters_stg[0] -t delete openshift-apps/docstranslation.yml
|
||||
- name: Delete project
|
||||
include_role:
|
||||
ansible.builtin.include_role:
|
||||
name: openshift/object-delete
|
||||
vars:
|
||||
objecttype: project
|
||||
|
|
|
@ -10,11 +10,11 @@
|
|||
|
||||
tasks:
|
||||
- name: Elections DB user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "{{ elections_db_user }}"
|
||||
password: "{{ elections_db_pass }}"
|
||||
- name: Elections database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "{{ elections_db_name }}"
|
||||
owner: "{{ elections_db_user }}"
|
||||
encoding: UTF-8
|
||||
|
|
|
@ -11,6 +11,6 @@
|
|||
|
||||
tasks:
|
||||
- name: Firmitas Role
|
||||
include_role:
|
||||
ansible.builtin.include_role:
|
||||
name: openshift-apps/firmitas
|
||||
tasks_from: main
|
||||
|
|
|
@ -15,11 +15,11 @@
|
|||
|
||||
tasks:
|
||||
- name: FMN DB user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: fmn
|
||||
password: "{{ (env == 'production') | ternary(fmn_prod_db_password, fmn_stg_db_password) }}"
|
||||
- name: FMN database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: fmn
|
||||
owner: fmn
|
||||
encoding: UTF-8
|
||||
|
@ -64,7 +64,7 @@
|
|||
|
||||
tasks:
|
||||
- name: Grant the fmn user access to the fmn vhost
|
||||
rabbitmq_user:
|
||||
community.rabbitmq.rabbitmq_user:
|
||||
user: "fmn{{ env_suffix }}"
|
||||
vhost: /fmn
|
||||
configure_priv: .*
|
||||
|
@ -82,7 +82,7 @@
|
|||
- rabbitmq_cluster
|
||||
|
||||
- name: Create the sending queues in the fmn vhost
|
||||
rabbitmq_queue:
|
||||
community.rabbitmq.rabbitmq_queue:
|
||||
name: "{{ item }}"
|
||||
vhost: /fmn
|
||||
auto_delete: no
|
||||
|
|
|
@ -99,7 +99,7 @@
|
|||
|
||||
tasks:
|
||||
- name: Set the timeout to the openshift route
|
||||
command: "oc -n greenwave annotate route {{ item }} --overwrite haproxy.router.openshift.io/timeout=750s"
|
||||
ansible.builtin.command: "oc -n greenwave annotate route {{ item }} --overwrite haproxy.router.openshift.io/timeout=750s"
|
||||
with_items:
|
||||
- greenwave-web
|
||||
- web-pretty
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
tasks:
|
||||
- name: Install psycopg2 for the postgresql ansible modules
|
||||
package: name=python3-psycopg2 state=present
|
||||
ansible.builtin.package: name=python3-psycopg2 state=present
|
||||
tags:
|
||||
- packages
|
||||
|
||||
|
@ -21,16 +21,16 @@
|
|||
|
||||
tasks:
|
||||
- name: Create the database user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "{{ kanban_db_user }}"
|
||||
password: "{{ kanban_db_pass }}"
|
||||
- name: Create the database itself
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "{{ kanban_db_name }}"
|
||||
owner: "{{ kanban_db_user }}"
|
||||
encoding: UTF-8
|
||||
- name: Test the database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "{{ kanban_db_name }}"
|
||||
owner: "{{ kanban_db_user }}"
|
||||
encoding: UTF-8
|
||||
|
@ -47,16 +47,16 @@
|
|||
|
||||
tasks:
|
||||
- name: Create the database user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "{{ kanban_db_user }}"
|
||||
password: "{{ kanban_db_pass_stg }}"
|
||||
- name: Create the database itself
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "{{ kanban_db_name }}"
|
||||
owner: "{{ kanban_db_user }}"
|
||||
encoding: UTF-8
|
||||
- name: Test the database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "{{ kanban_db_name }}"
|
||||
owner: "{{ kanban_db_user }}"
|
||||
encoding: UTF-8
|
||||
|
|
|
@ -10,11 +10,11 @@
|
|||
|
||||
tasks:
|
||||
- name: Kerneltest DB user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "{{ (env == 'production') | ternary(kerneltest_db_user, kerneltest_stg_db_user) }}"
|
||||
password: "{{ (env == 'production') | ternary(kerneltest_db_pass, kerneltest_stg_db_pass) }}"
|
||||
- name: Kerneltest database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "{{ kerneltest_db_name }}"
|
||||
owner: "{{ (env == 'production') | ternary(kerneltest_db_user, kerneltest_stg_db_user) }}"
|
||||
encoding: UTF-8
|
||||
|
@ -32,7 +32,7 @@
|
|||
|
||||
pre_tasks:
|
||||
- name: Include Global Variables
|
||||
include_vars: dir=/srv/web/infra/ansible/vars/all/ ignore_files=README
|
||||
ansible.builtin.include_vars: dir=/srv/web/infra/ansible/vars/all/ ignore_files=README
|
||||
|
||||
|
||||
roles:
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
|
||||
tasks:
|
||||
- name: Apply objects
|
||||
include_role: name=openshift/object
|
||||
ansible.builtin.include_role: name=openshift/object
|
||||
vars:
|
||||
template: "{{ item }}.yml"
|
||||
objectname: "{{ item }}.yml"
|
||||
|
@ -51,7 +51,7 @@
|
|||
- frontend-service
|
||||
|
||||
- name: Apply Deployment
|
||||
include_role: name=openshift/object
|
||||
ansible.builtin.include_role: name=openshift/object
|
||||
vars:
|
||||
template: backend-deployment.yml
|
||||
objectname: "{{ item.name }}-deployment.yml"
|
||||
|
@ -65,7 +65,7 @@
|
|||
label: "{{ item.name }}"
|
||||
|
||||
- name: Apply CronJob
|
||||
include_role: name=openshift/object
|
||||
ansible.builtin.include_role: name=openshift/object
|
||||
vars:
|
||||
template: cronjob.yml
|
||||
objectname: "{{ item.name }}-cronjob.yml"
|
||||
|
|
|
@ -71,28 +71,28 @@
|
|||
|
||||
post_tasks:
|
||||
- name: Run initial f.10 import
|
||||
command: "oc -n languages create job stats-10-{{ lookup('pipe', 'date +%s') }}-init --from=cronjob/stats-10"
|
||||
ansible.builtin.command: "oc -n languages create job stats-10-{{ lookup('pipe', 'date +%s') }}-init --from=cronjob/stats-10"
|
||||
tags:
|
||||
- never
|
||||
- init
|
||||
- f10
|
||||
|
||||
- name: Run initial f.20 import
|
||||
command: "oc -n languages create job stats-20-{{ lookup('pipe', 'date +%s') }}-init --from=cronjob/stats-20"
|
||||
ansible.builtin.command: "oc -n languages create job stats-20-{{ lookup('pipe', 'date +%s') }}-init --from=cronjob/stats-20"
|
||||
tags:
|
||||
- never
|
||||
- init
|
||||
- f20
|
||||
|
||||
- name: Run initial f.30 import
|
||||
command: "oc -n languages create job stats-30-{{ lookup('pipe', 'date +%s') }}-init --from=cronjob/stats-30"
|
||||
ansible.builtin.command: "oc -n languages create job stats-30-{{ lookup('pipe', 'date +%s') }}-init --from=cronjob/stats-30"
|
||||
tags:
|
||||
- never
|
||||
- init
|
||||
- f30
|
||||
|
||||
- name: Run initial f.latest import
|
||||
command: "oc -n languages create job stats-latest-{{ lookup('pipe', 'date +%s') }}-init --from=cronjob/stats-latest"
|
||||
ansible.builtin.command: "oc -n languages create job stats-latest-{{ lookup('pipe', 'date +%s') }}-init --from=cronjob/stats-latest"
|
||||
tags:
|
||||
- never
|
||||
- init
|
||||
|
|
|
@ -10,11 +10,11 @@
|
|||
|
||||
tasks:
|
||||
- name: Maubot DB user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: maubot
|
||||
password: "{{ (env == 'production') | ternary(maubot_prod_db_password, maubot_stg_db_password) }}"
|
||||
- name: Maubot database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: maubot
|
||||
owner: maubot
|
||||
encoding: UTF-8
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
|
||||
tasks:
|
||||
- name: Create the RabbitMQ user
|
||||
rabbitmq_user:
|
||||
community.rabbitmq.rabbitmq_user:
|
||||
user: "messaging-bridge{{ env_suffix }}.fedoraproject.org"
|
||||
vhost: /pubsub
|
||||
read_priv: "((a|z)mq\\.topic|amqp_to_zmq|amqp_bridge_verify_missing)"
|
||||
|
@ -23,7 +23,7 @@
|
|||
- rabbitmq_cluster
|
||||
|
||||
- name: Create the RabbitMQ queue amqp_to_zmq
|
||||
rabbitmq_queue:
|
||||
community.rabbitmq.rabbitmq_queue:
|
||||
name: amqp_to_zmq
|
||||
vhost: /pubsub
|
||||
login_user: admin
|
||||
|
@ -33,7 +33,7 @@
|
|||
- rabbitmq_cluster
|
||||
|
||||
- name: Create the RabbitMQ queue for verify-missing
|
||||
rabbitmq_queue:
|
||||
community.rabbitmq.rabbitmq_queue:
|
||||
name: amqp_bridge_verify_missing
|
||||
vhost: /pubsub
|
||||
durable: True
|
||||
|
@ -46,7 +46,7 @@
|
|||
- rabbitmq_cluster
|
||||
|
||||
- name: Create the amqp-to-zmq bindings
|
||||
rabbitmq_binding:
|
||||
community.rabbitmq.rabbitmq_binding:
|
||||
name: amq.topic
|
||||
destination: amqp_to_zmq
|
||||
destination_type: queue
|
||||
|
@ -58,7 +58,7 @@
|
|||
- rabbitmq_cluster
|
||||
|
||||
- name: Create the verify-missing bindings
|
||||
rabbitmq_binding:
|
||||
community.rabbitmq.rabbitmq_binding:
|
||||
name: "{{ item }}"
|
||||
destination: amqp_bridge_verify_missing
|
||||
destination_type: queue
|
||||
|
|
|
@ -16,11 +16,11 @@
|
|||
|
||||
tasks:
|
||||
- name: DB user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "{{ (env == 'production') | ternary(mirrormanager_db_user, mirrormanager_stg_db_user) }}"
|
||||
password: "{{ (env == 'production') | ternary(mirrormanager_db_pass, mirrormanager_stg_db_pass) }}"
|
||||
- name: FMN database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "{{ (env == 'production') | ternary(mirrormanager_db_name, mirrormanager_stg_db_name) }}"
|
||||
owner: "{{ (env == 'production') | ternary(mirrormanager_db_user, mirrormanager_stg_db_user) }}"
|
||||
encoding: UTF-8
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
|
||||
pre_tasks:
|
||||
- name: Include Global Variables
|
||||
include_vars: dir=/srv/web/infra/ansible/vars/all/ ignore_files=README
|
||||
ansible.builtin.include_vars: dir=/srv/web/infra/ansible/vars/all/ ignore_files=README
|
||||
|
||||
roles:
|
||||
- role: openshift/project
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
tasks:
|
||||
- name: Install psycopg2 for the postgresql ansible modules
|
||||
package: name=python3-psycopg2 state=present
|
||||
ansible.builtin.package: name=python3-psycopg2 state=present
|
||||
tags:
|
||||
- packages
|
||||
|
||||
|
@ -21,16 +21,16 @@
|
|||
|
||||
tasks:
|
||||
- name: Create the database user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "{{ oraculum_db_user }}"
|
||||
password: "{{ oraculum_db_pass }}"
|
||||
- name: Create the database itself
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "{{ oraculum_db_name }}"
|
||||
owner: "{{ oraculum_db_user }}"
|
||||
encoding: UTF-8
|
||||
- name: Test the database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "{{ oraculum_db_name }}"
|
||||
owner: "{{ oraculum_db_user }}"
|
||||
encoding: UTF-8
|
||||
|
|
|
@ -12,14 +12,14 @@
|
|||
|
||||
pre_tasks:
|
||||
- name: Setup Rabbit User
|
||||
include_role:
|
||||
ansible.builtin.include_role:
|
||||
name: rabbit/user
|
||||
vars:
|
||||
username: toddlers{{ env_suffix }}
|
||||
sent_topics: ^org\.fedoraproject\.{{ env_short }}\.toddlers\..*
|
||||
|
||||
- name: Setup Rabbit Queue
|
||||
include_role:
|
||||
ansible.builtin.include_role:
|
||||
name: rabbit/queue
|
||||
vars:
|
||||
username: toddlers{{ env_suffix }}
|
||||
|
|
|
@ -11,17 +11,17 @@
|
|||
|
||||
tasks:
|
||||
- name: Resultsdb DB user - prod
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "resultsdb"
|
||||
password: "{{ prod_resultsdb_db_password }}"
|
||||
when: env != 'staging'
|
||||
- name: Resultsdb DB user - staging
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "resultsdb"
|
||||
password: "{{ stg_resultsdb_db_password }}"
|
||||
when: env == 'staging'
|
||||
- name: Resultsdb database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "resultsdb"
|
||||
owner: "resultsdb"
|
||||
encoding: UTF-8
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
tasks:
|
||||
- name: Install psycopg2 for the postgresql ansible modules
|
||||
package: name=python3-psycopg2 state=present
|
||||
ansible.builtin.package: name=python3-psycopg2 state=present
|
||||
tags:
|
||||
- packages
|
||||
|
||||
|
@ -21,30 +21,30 @@
|
|||
|
||||
tasks:
|
||||
- name: Create the database user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "{{ testdays_db_user }}"
|
||||
password: "{{ testdays_db_pass }}"
|
||||
- name: Create the database itself
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "{{ testdays_db_name }}"
|
||||
owner: "{{ testdays_db_user }}"
|
||||
encoding: UTF-8
|
||||
- name: Test the database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "{{ testdays_db_name }}"
|
||||
owner: "{{ testdays_db_user }}"
|
||||
encoding: UTF-8
|
||||
- name: Create the database user (resultsdb)
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "{{ resultsdb_testdays_db_user }}"
|
||||
password: "{{ resultsdb_testdays_db_pass }}"
|
||||
- name: Create the database itself (resultsdb)
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "{{ resultsdb_testdays_db_name }}"
|
||||
owner: "{{ resultsdb_testdays_db_user }}"
|
||||
encoding: UTF-8
|
||||
- name: Test the database creation (resultsdb)
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "{{ resultsdb_testdays_db_name }}"
|
||||
owner: "{{ resultsdb_testdays_db_user }}"
|
||||
encoding: UTF-8
|
||||
|
|
|
@ -10,17 +10,17 @@
|
|||
|
||||
tasks:
|
||||
- name: Waiverdb DB user - prod
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "waiverdb"
|
||||
password: "{{ prod_waiverdb_db_password }}"
|
||||
when: env != 'staging'
|
||||
- name: Waiverdb DB user - staging
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: "waiverdb"
|
||||
password: "{{ stg_waiverdb_db_password }}"
|
||||
when: env == 'staging'
|
||||
- name: Waiverdb database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: "waiverdb"
|
||||
owner: "waiverdb"
|
||||
encoding: UTF-8
|
||||
|
|
|
@ -14,11 +14,11 @@
|
|||
|
||||
tasks:
|
||||
- name: Webhook2fedmsg DB user
|
||||
postgresql_user:
|
||||
community.postgresql.postgresql_user:
|
||||
name: webhook2fedmsg
|
||||
password: "{{ (env == 'production') | ternary(webhook2fedmsg_prod_db_password, webhook2fedmsg_stg_db_password) }}"
|
||||
- name: Webhook2fedmsg database creation
|
||||
postgresql_db:
|
||||
community.postgresql.postgresql_db:
|
||||
name: webhook2fedmsg
|
||||
owner: webhook2fedmsg
|
||||
encoding: UTF-8
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue