Skip to content

Commit

Permalink
usecase validations folder
Browse files Browse the repository at this point in the history
  • Loading branch information
Emre Dogan committed Feb 18, 2025
1 parent ee0bf88 commit 16b6878
Show file tree
Hide file tree
Showing 16 changed files with 93 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

manifestVersion: 1.0
projects:
- name: awx
- name: usecase-validation

environmentGroups:
- name: default
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,22 +16,47 @@ configs:
schema: app:dynatrace.redhat.ansible:automation-controller.connection
scope: environment

# Jenkins connection
- id: workflowJenkinsConnection
config:
name: "Jenkins Connection"
template: jenkins-connection.json
parameters:
jenkins_url:
type: environment
name: JENKINS_URL
jenkins_username:
type: environment
name: JENKINS_USERNAME
jenkins_password:
type: environment
name: JENKINS_PASSWORD
type:
settings:
schema: app:dynatrace.jenkins.connector:connection
scope: environment

# workflow
- id: validator-workflow
config:
name: AWX Health Validation - Demo AR Workflow Ansible
template: awx-validator-wf.json
name: Usecase Validation - Demo AR Workflows Ansible
template: usecase-validation-wf.json
skip: false
parameters:
#wf related
wf_description: "AWX Health Validation Workflow that ensures availability and pipeline runs"
wf_description: "Demo AR Workflow Ansible usecase Health Validation Workflow that ensures availability and pipeline runs"
wf_isPrivate: false
awx_template_id: "7"
awx_connection_id:
configType: app:dynatrace.redhat.ansible:automation-controller.connection
property: id
type: reference
configId: workflowAWXConnection
jenkins_connection_id:
configType: app:dynatrace.jenkins.connector:connection
property: id
type: reference
configId: workflowJenkinsConnection
type:
automation:
resource: workflow
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"name": "{{ .name }}",
"url": "{{ .jenkins_url }}",
"username": "{{ .jenkins_username }}",
"password":"{{ .jenkins_password }}"
}
Original file line number Diff line number Diff line change
Expand Up @@ -36,17 +36,17 @@
"description": "Launch a job template in Red Hat Ansible Automation Controller",
"predecessors": []
},
"send_fail_email": {
"name": "send_fail_email",
"send_fail_email_awx": {
"name": "send_fail_email_awx",
"input": {
"cc": [],
"to": [
"[email protected]"
],
"bcc": [],
"taskId": "{{`{{`}} task().id {{`}}`}}",
"content": "Pipeline Failed",
"subject": "Pipeline Failed",
"content": "AWX Job Failed",
"subject": "AWX Job Failed",
"executionId": "{{`{{`}} execution().id {{`}}`}}",
"environmentUrl": "{{`{{`}} environment().url {{`}}`}}"
},
Expand All @@ -65,6 +65,52 @@
"predecessors": [
"launch_awx_job"
]
},
"trigger_jenkins_build_images": {
"name": "trigger_jenkins_build_images",
"input": {
"jobPath": "/job/demo-ar-workflows-ansible/job/1. Build images",
"connection": "{{ .jenkins_connection_id }}",
"awaitResult": true,
"buildParameters": []
},
"action": "dynatrace.jenkins.connector:trigger-build",
"position": {
"x": 1,
"y": 1
},
"description": "Triggers a job build and optionally awaits the result",
"predecessors": []
},
"send_fail_email_jenkins": {
"name": "send_fail_email_jenkins",
"input": {
"cc": [],
"to": [
"[email protected]"
],
"bcc": [],
"taskId": "{{`{{`}} task().id {{`}}`}}",
"content": "Jenkins Job Failed",
"subject": "Jenkins Job Failed",
"executionId": "{{`{{`}} execution().id {{`}}`}}",
"environmentUrl": "{{`{{`}} environment().url {{`}}`}}"
},
"action": "dynatrace.email:send-email",
"position": {
"x": 1,
"y": 2
},
"conditions": {
"custom": "{{`{{`}} result(\"trigger_jenkins_build_images\").state != \"SUCCESS\" {{`}}`}}",
"states": {
"launch_awx_job": "OK"
}
},
"description": "Send email",
"predecessors": [
"trigger_jenkins_build_images"
]
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

manifestVersion: 1.0
projects:
- name: gitlab
- name: usecase-validation

environmentGroups:
- name: default
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,12 @@ configs:
# workflow
- id: validator-workflow
config:
name: Gitlab Pipeline Health Validation - Demo AR Workflows
template: gitlab-validator-wf.json
name: Usecase Validation - Demo AR Workflows Gitlab
template: usecase-validation-wf.json
skip: false
parameters:
#wf related
wf_description: "Gitlab Pipeline Health Validation Workflow that ensures availability and pipeline runs"
wf_description: "Demo AR Workflows Gitlab Health Validation Workflow that ensures availability and pipeline runs"
wf_isPrivate: false

gitlab_connection_id:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

manifestVersion: 1.0
projects:
- name: gitlab
- name: usecase-validation

environmentGroups:
- name: default
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,12 @@ configs:
# workflow
- id: validator-workflow
config:
name: Gitlab Pipeline Health Validation - Demo SRG
template: gitlab-validator-wf.json
name: Usecase Validation - Demo Release Validation Gitlab
template: usecase-validation-wf.json
skip: false
parameters:
#wf related
wf_description: "Gitlab Pipeline Health Validation Workflow that ensures availability and pipeline runs"
wf_description: "Demo Release Validation Gitlab Health Validation Workflow that ensures availability and pipeline runs"
wf_isPrivate: false

gitlab_connection_id:
Expand Down

0 comments on commit 16b6878

Please sign in to comment.