mirror of
https://pagure.io/fedora-infra/ansible.git
synced 2026-04-13 14:49:58 +08:00
[copr] set hostname before base role in all our playbooks;
install copr.repo before package installation removed double include of some tasks
This commit is contained in:
@@ -22,6 +22,8 @@
|
||||
|
||||
tasks:
|
||||
- include: "{{ tasks }}/cloud_setup_basic.yml"
|
||||
- name: set hostname (required by some services, at least postfix need it)
|
||||
shell: "hostname {{copr_hostbase}}.cloud.fedoraproject.org"
|
||||
|
||||
- name: provision instance
|
||||
hosts: copr-front:copr-front-stg
|
||||
|
||||
@@ -21,6 +21,8 @@
|
||||
|
||||
tasks:
|
||||
- include: "{{ tasks }}/cloud_setup_basic.yml"
|
||||
- name: set hostname (required by some services, at least postfix need it)
|
||||
shell: "hostname {{copr_hostbase}}.cloud.fedoraproject.org"
|
||||
|
||||
- name: provision instance
|
||||
#hosts: copr-keygen:copr-keygen-stg
|
||||
|
||||
@@ -3,14 +3,17 @@
|
||||
# This is the base set of files needed for copr
|
||||
|
||||
|
||||
- include: "{{ tasks }}/cloud_setup_basic.yml"
|
||||
- include: "{{ tasks }}/postfix_basic.yml"
|
||||
# again to late to do it here
|
||||
# - include: "{{ tasks }}/cloud_setup_basic.yml"
|
||||
# already included into the `base` role
|
||||
#- include: "{{ tasks }}/postfix_basic.yml"
|
||||
|
||||
- name: setup correct hostname for copr machine
|
||||
hostname: name="{{ copr_hostbase }}.cloud.fedoraproject.org"
|
||||
# hostname: name="{{ hostbase|regex_replace('.*-$', '')}}.cloud.fedoraproject.org"
|
||||
tags:
|
||||
- config
|
||||
# To late to do it here (
|
||||
#- name: setup correct hostname for copr machine
|
||||
# hostname: name="{{ copr_hostbase }}.cloud.fedoraproject.org"
|
||||
# # hostname: name="{{ hostbase|regex_replace('.*-$', '')}}.cloud.fedoraproject.org"
|
||||
# tags:
|
||||
# - config
|
||||
|
||||
- name: copy .forward file
|
||||
copy: src="{{ _forward_src }}" dest="/root/.forward" owner=root group=root
|
||||
@@ -18,6 +21,9 @@
|
||||
- name: deploy /etc/hosts file
|
||||
copy: src="hosts" dest=/etc/hosts owner=root group=root mode=644
|
||||
|
||||
- name: install copr repo
|
||||
copy: src="yum/copr.repo" dest="/etc/yum.repos.d/copr.repo"
|
||||
|
||||
- name: install common copr packages
|
||||
yum: state=present pkg={{ item }}
|
||||
with_items:
|
||||
@@ -42,6 +48,3 @@
|
||||
with_items:
|
||||
- fail2ban
|
||||
|
||||
- name: install copr repo
|
||||
copy: src="yum/copr.repo" dest="/etc/yum.repos.d/copr.repo"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user