add a new magazine2

This commit is contained in:
Kevin Fenzi 2017-05-08 12:04:45 +00:00
parent e5ae96a511
commit 342cd0c379
3 changed files with 85 additions and 0 deletions

View file

@ -0,0 +1,28 @@
---
image: rhel7-20141015
instance_type: m1.large
keypair: fedora-admin-20130801
security_group: ssh-anywhere-persistent,web-80-anywhere-persistent,web-443-anywhere-persistent,allow-nagios-persistent,default,all-icmp-persistent
zone: nova
tcp_ports: [22, 80, 443]
inventory_tenant: persistent
inventory_instance_name: magazine
hostbase: magazine
public_ip: 209.132.184.52
root_auth_users: nb chrisroberts
description: Fedora Magazine
host_backup_targets: ['/backups', '/var/www/html']
dbs_to_backup: ['wp']
mariadb_root_password: "{{ magazine_mariadb_password }}"
extra_enablerepos: ''
cloud_networks:
# persistent-net
- net-id: "67b77354-39a4-43de-b007-bb813ac5c35f"
nagios_Check_Services:
nrpe: true
sshd: true
httpd: true

View file

@ -1116,6 +1116,7 @@ faitout.fedorainfracloud.org
communityblog.fedorainfracloud.org
# Fedora Magazine
magazine.fedorainfracloud.org
magazine2.fedorainfracloud.org
# Flock RegCfp instance
regcfp2.fedorainfracloud.org
# Modularity (ticket 5390)

View file

@ -0,0 +1,56 @@
- name: check/create instance
hosts: magazine2.fedorainfracloud.org
gather_facts: False
vars_files:
- /srv/web/infra/ansible/vars/global.yml
- /srv/private/ansible/vars.yml
- /srv/web/infra/ansible/vars/fedora-cloud.yml
- /srv/private/ansible/files/openstack/passwords.yml
tasks:
- include: "{{ tasks_path }}/persistent_cloud.yml"
- name: setup all the things
hosts: magazine2.fedorainfracloud.org
gather_facts: True
vars_files:
- /srv/web/infra/ansible/vars/global.yml
- /srv/private/ansible/vars.yml
- /srv/private/ansible/files/openstack/passwords.yml
- /srv/web/infra/ansible/vars/{{ ansible_distribution }}.yml
pre_tasks:
- include: "{{ tasks_path }}/cloud_setup_basic.yml"
- name: set hostname (required by some services, at least postfix need it)
hostname: name="{{inventory_hostname}}"
tasks:
- name: add packages
yum: state=present name={{ item }}
with_items:
- httpd
- php
- php-mysql
- mariadb-server
- mariadb
- mod_ssl
- php-mcrypt
- php-mbstring
- wget
- unzip
- postfix
- wordpress
- name: enable httpd service
service: name=httpd enabled=yes state=started
- name: configure postfix for ipv4 only
raw: postconf -e inet_protocols=ipv4
- name: enable local postfix service
service: name=postfix enabled=yes state=started
roles:
- nagios_client
- mariadb_server