mirror of
https://github.com/tektoncd/catalog.git
synced 2024-11-25 06:17:50 +00:00
32f2913fd2
- Previously catalog's task has some images that are not tagged properly,this patch fixes these images by adding the digest - Soon once Catlin is added to the CI it will throw error for those images which don't have proper tags co-authored by:- @PuneetPunamiya Signed-off-by: vinamra28 <vinjain@redhat.com>
61 lines
1.7 KiB
YAML
61 lines
1.7 KiB
YAML
---
|
|
apiVersion: tekton.dev/v1beta1
|
|
kind: Task
|
|
metadata:
|
|
name: ansible-runner
|
|
labels:
|
|
app.kubernetes.io/version: '0.1'
|
|
app.kubernetes.io/ansible-version: '2.9.20'
|
|
app.kubernetes.io/ansible-k8s-version: '0.11.0'
|
|
annotations:
|
|
tekton.dev/pipelines.minVersion: '0.12.1'
|
|
tekton.dev/tags: cli
|
|
tekton.dev/displayName: 'Ansible Runner'
|
|
spec:
|
|
description: >-
|
|
Task to run Ansible playbooks using Ansible Runner
|
|
|
|
workspaces:
|
|
- name: runner-dir
|
|
description: The Ansibler runner directory
|
|
params:
|
|
- name: project-dir
|
|
description: The project directory under the workspace runner-dir
|
|
default: 'project'
|
|
- name: args
|
|
description: The arguments to pass ansible-runner
|
|
type: array
|
|
default:
|
|
- --help
|
|
steps:
|
|
- name: requirements
|
|
image: docker.io/ansible/ansible-runner:1.4.6@sha256:bd09ef403f2f90f2c6bd133d7533e939058903f69223c5f12557a49e3aed14bb #tag: 1.4.6
|
|
script: |
|
|
#!/bin/bash
|
|
set -e
|
|
|
|
if [ -f requirements.txt ];
|
|
then
|
|
pip3 install --user \
|
|
-r requirements.txt
|
|
fi
|
|
|
|
if [ -f requirements.yml ];
|
|
then
|
|
ansible-galaxy role install -vv \
|
|
-r requirements.yml
|
|
ansible-galaxy collection install -vv \
|
|
-r requirements.yml
|
|
fi
|
|
workingDir: '$(workspaces.runner-dir.path)/$(params.project-dir)'
|
|
|
|
- name: run-playbook
|
|
image: docker.io/ansible/ansible-runner:1.4.6@sha256:bd09ef403f2f90f2c6bd133d7533e939058903f69223c5f12557a49e3aed14bb #tag: 1.4.6
|
|
command: ['entrypoint']
|
|
args:
|
|
- ansible-runner
|
|
- run
|
|
- $(params.args)
|
|
- $(params.project-dir)
|
|
workingDir: '$(workspaces.runner-dir.path)'
|