-
Notifications
You must be signed in to change notification settings - Fork 17
/
site.step-20-persistent.yml
112 lines (109 loc) · 4.42 KB
/
site.step-20-persistent.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
- import_playbook: site.common.group-current-hosts.yml
- hosts: persistent:¤t:!immutable
roles:
- role: cs.aws-node-facts
delegate_to: localhost
become: no
when: aws_use
- role: cs.aws-vpc-facts
delegate_to: localhost
delegate_facts: no
become: no
when: aws_use
- role: cs.aws-security-group-facts
delegate_to: localhost
delegate_facts: no
become: no
when: aws_use
- role: cs.switch-to-dnf
- role: cs.versionlock
node_name: persistent
versionlock_packages: "{{ versionlock_persistent_packages + versionlock_persistent_packages_base + versionlock_persistent_packages_extra }}"
versionlock_ban_packages: "{{ versionlock_persistent_ban_packages + versionlock_persistent_ban_packages_base + versionlock_persistent_ban_packages_extra }}"
- role: cs.selinux-disable
- role: cs.optimize-kernel
- role: cs.tuned
- role: cs.swap
- role: cs.earlyoom
when: mageops_earlyoom_enable
- role: cs.systemd-oomd
when: mageops_oomd_enable
- role: cs.packages
packages_mirrorlist_countrycode: "{{ mageops_packages_mirrorlist_countrycode | default(false) }}"
packages_install: "{{ mageops_packages_common + mageops_packages_persistent + mageops_packages_persistent_extra }}"
packages_remove: "{{ mageops_packages_banned }}"
packages_full_update: no
- role: cs.mageops-cli-profile
- role: cs.mageops-cli-user
mageops_cli_user: root
mageops_cli_user_bashrc_fragments:
- elasticsearch
- redis
- role: cs.mageops-authorize-keys
- role: cs.aws-cli
when: aws_use
- role: cs.cron
- role: geerlingguy.ntp
- role: cs.elasticsearch
tags: elasticsearch
when: mageops_elasticsearch_create
- role: cs.redis
when: mageops_redis_create and not redis_aws_elasticache_use
- role: cs.redis
redis_instance_name: sessions
redis_databases: 1
redis_port: "{{ mageops_redis_sessions_port }}"
redis_maxmemory_policy: "{{ redis_sessions_maxmemory_policy }}"
redis_maxmemory: "{{ redis_sessions_maxmemory }}"
redis_persistence_enable: "{{ redis_sessions_persistence_enable }}"
when: mageops_redis_sessions_create
- role: cs.varnish-purge-proxy
varnish_pp_listen_port: "{{ varnish_port }}"
when: varnish_is_in_autoscaling_group
- role: cs.aws-logs
aws_logs_stream_name: "{{ mageops_node_role }}"
aws_logs_log_magento_crash_reports: no
aws_logs_loggers: "{{ aws_logs_loggers_persistent_default | combine(aws_logs_loggers_persistent_extra | default({}), recursive=True) }}"
when: aws_use
- role: cs.sftp-access
sftp_authorized_keys: "{{ mageops_root_ssh_keys_global + mageops_sftp_ssh_keys }}"
when: sftp_access_enabled
- role: cs.aws-efs
efs_name: "{{ magento_efs_app_node_name }}"
efs_tags: "{{ aws_tags_default | combine(aws_tags_role_storage, aws_tags_role_shared_storage) }}"
efs_mounts: "{{ magento_sftp_basic_efs_mounts + magento_sftp_efs_mounts }}"
when: aws_use and sftp_access_enabled
- role: cs.rabbitmq
rabbitmq_virtual_hosts: ["{{ magento_rabbitmq_virtual_host }}"]
rabbitmq_users:
- vhost: "{{ magento_rabbitmq_virtual_host }}"
username: "{{ magento_rabbitmq_username }}"
password: "{% if magento_rabbitmq_queue %}{{ magento_rabbitmq_password | mandatory }}{% endif %}"
when: mageops_rabbitmq_create
- role: cs.magento-cron-http-trigger
when: mageops_app_is_magesuite
- role: cs.ssh-proxy-user
when: mageops_ssh_proxy_persistant
- role: cs.tinyproxy
tinyproxy_enabled: "{{ mageops_tinyproxy_persistant_enabled }}"
- role: cs.monitoring
monitoring_node_exporter_enabled: yes
monitoring_elasticsearch_exporter_enabled: yes
monitoring_redis_exporter_enabled: yes
when: mageops_monitoring_enabled
- role: cs.packages
- role: cs.tracer
- role: cs.pkg-mgr-cleanup
tasks:
- set_fact:
mageops_extra_tasks_persistent_node:
["{{ mageops_extra_tasks_persistent_node }}"]
when: |
mageops_extra_tasks_persistent_node is defined
and mageops_extra_tasks_persistent_node is string
- include_tasks: "{{ item }}"
loop: "{{ mageops_extra_tasks_persistent_node }}"
when: mageops_extra_tasks_persistent_node is defined
vars:
mageops_node_role: persistent
magento_facts_detect_from_artifacts: yes