blob: 1ab1e8041080e97792e0a675fd21db12cbd3db08 (
plain)
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
|
---
- hosts: localhost
connection: local
gather_facts: no
tasks:
- name: Require openshift_aws_base_ami
fail:
msg: "A base AMI is required for AMI building. Please ensure `openshift_aws_base_ami` is defined."
when: openshift_aws_base_ami is undefined
- name: "Alert user to variables needed and their values - {{ item.name }}"
debug:
msg: "{{ item.msg }}"
with_items:
- name: openshift_aws_clusterid
msg: "openshift_aws_clusterid={{ openshift_aws_clusterid | default('default') }}"
- name: openshift_aws_region
msg: "openshift_aws_region={{ openshift_aws_region | default('us-east-1') }}"
- include: provision_vpc.yml
- include: provision_ssh_keypair.yml
- include: provision_sec_group.yml
vars:
openshift_aws_node_group_type: compute
- include: provision_instance.yml
vars:
openshift_aws_node_group_type: compute
- hosts: nodes
gather_facts: False
tasks:
- name: set the user to perform installation
set_fact:
ansible_ssh_user: "{{ openshift_aws_build_ami_ssh_user | default('root') }}"
# This is the part that installs all of the software and configs for the instance
# to become a node.
- include: ../../common/openshift-node/image_prep.yml
- include: seal_ami.yml
vars:
openshift_aws_ami_name: "openshift-gi-{{ lookup('pipe', 'date +%Y%m%d%H%M')}}"
|