-
Notifications
You must be signed in to change notification settings - Fork 54
/
deploy-examples.playbook.yaml
executable file
·44 lines (37 loc) · 1.29 KB
/
deploy-examples.playbook.yaml
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
#############################################################
## NOT FOR PRODUCTION USE. ##
## THE CONTENT OF THIS FILE IS FOR LEARNING PURPOSES ONLY ##
## created by David Surey, Amazon Web Services, 2020 ##
#############################################################
- name: Setup Kubernetes Example Deployments
hosts: localhost
gather_facts: no
vars:
ansible_ssh_private_key_file: "./secrets/id_rsa_eks"
ansible_user: ec2-user
tasks:
- name: check ansible version
when: (ansible_version.major == 2 and ansible_version.minor < 10 ) or (ansible_version.major < 2)
run_once: yes
fail:
msg: Please use Ansible 2.10 or newer
- name: import static var data
include_vars:
dir: ../../vars/static
ignore_unknown_extensions: True
extensions:
- yaml
- name: import dynamic var data
include_vars:
dir: ../../vars/dynamic
ignore_unknown_extensions: True
extensions:
- yaml
- name: Get AWS Account Information
delegate_to: "{{ EKSBastionInstancePublicIP }}"
aws_caller_info:
register: caller_info
- name: setup kube services
include_tasks: "{{ item }}"
loop:
- ./tasks/microservice-example.task.yaml