Add Create Infra and Create VM demo
This commit is contained in:
willtome
2022-03-22 17:53:28 -05:00
committed by GitHub
parent cf90f1e145
commit 51273afedd
18 changed files with 478 additions and 5 deletions

103
cloud/setup.yml Normal file
View File

@@ -0,0 +1,103 @@
---
user_message:
- Update AWS credential with Access and Secret key
- Update Workshop Credential with password used to login to Controller
controller_components:
- credentials
- inventory_sources
- job_templates
controller_credentials:
- name: AWS
credential_type: Amazon Web Services
organization: Default
update_secrets: false
inputs:
username: REPLACEME
password: REPLACEME
controller_inventory_sources:
- name: AWS Inventory
organization: Default
source: ec2
inventory: Workshop Inventory
credential: AWS
overwrite: true
source_vars:
hostnames:
- tag:Name
compose:
ansible_host: public_ip_address
groups:
cloud_aws: true
keyed_groups:
- key: platform
prefix: os
controller_templates:
- name: Cloud / Create Infra
job_type: run
organization: Default
credentials:
- AWS
project: Ansible official demo project
playbook: cloud/create_infra.yml
inventory: Workshop Inventory
execution_environment: Default execution environment
survey_enabled: true
extra_vars:
aws_region: us-east-2
survey:
name: ''
description: ''
spec:
- question_name: Infra Provider
type: multiplechoice
variable: infra_provider
required: true
choices:
- aws
- question_name: AWS Public Key (only required for aws provider)
type: textarea
required: false
variable: aws_public_key
- name: Cloud / Create VM
job_type: run
organization: Default
credentials:
- AWS
- Workshop Credential
project: Ansible official demo project
playbook: cloud/create_vm.yml
inventory: Workshop Inventory
execution_environment: Default execution environment
survey_enabled: true
extra_vars:
aws_region: us-east-2
survey:
name: ''
description: ''
spec:
- question_name: Name
type: text
variable: vm_name
required: true
- question_name: Owner
type: text
variable: vm_owner
required: true
- question_name: Provider
type: multiplechoice
variable: vm_provider
required: true
choices:
- aws
- question_name: Blueprint
type: multiplechoice
variable: vm_blueprint
required: true
choices: #"{{ lookup('fileglob', 'blueprints/*.yml') | regex_replace(',','\n') | regex_findall('.*/(.*)(?=.yml)') | list }}"
- windows
- rhel8
- rhel7