Files
ansible-role-common/.woodpecker/test.yml

49 lines
1.3 KiB
YAML
Raw Normal View History

2023-10-05 16:41:38 +13:00
matrix:
2023-10-16 21:42:53 +13:00
include:
- MOLECULE_DISTRO: centos7
- MOLECULE_DISTRO: almalinux8
2024-01-04 15:53:09 +13:00
- MOLECULE_DISTRO: almalinux9
2023-10-16 21:42:53 +13:00
clone:
git:
image: woodpeckerci/plugin-git
settings:
recursive: true
submodule_update_remote: true
when:
event: [ push, manual ]
2023-10-06 07:04:43 +13:00
2023-10-05 16:41:38 +13:00
steps:
2023-10-05 17:19:05 +13:00
test:
name: Test on ${MOLECULE_DISTRO}
2023-10-05 16:41:38 +13:00
image: guisea/ansible-molecule
pull: true
environment:
2023-10-16 21:42:53 +13:00
PY_COLORS: '1'
ANSIBLE_FORCE_COLOR: '1'
2023-10-05 16:41:38 +13:00
volumes:
2023-10-16 21:42:53 +13:00
- /var/run/docker.sock:/var/run/docker.sock
2023-10-06 07:04:43 +13:00
commands:
2023-10-16 21:42:53 +13:00
- molecule test --scenario-name ${MOLECULE_SCENARIO:-default}
2024-01-02 23:03:16 +13:00
#secrets: [ auth_duo_host, auth_duo_ikey, auth_duo_skey, auth_duo_mirror_url ]
2023-10-05 16:41:38 +13:00
when:
2023-10-18 22:34:00 +13:00
event:
2023-10-16 21:42:53 +13:00
- push
- manual
2023-10-18 22:19:02 +13:00
ntfy:
image: codeberg.org/l-x/woodpecker-ntfy
settings:
url: https://ntfy.cybercinch.nz/ci-status
2023-10-18 22:34:00 +13:00
title: "Test failed for ${CI_REPO_NAME} - Distro: ${MOLECULE_DISTRO} Scenario: ${MOLECULE_SCENARIO:-default}"
2023-10-18 22:19:02 +13:00
priority: urgent
icon: https://woodpecker-ci.org/img/logo.svg
tags: robot,warning,rotating_light,${CI_BUILD_EVENT},${CI_REPO_NAME}
message: >
📝 Commit by ${CI_COMMIT_AUTHOR} on ${CI_COMMIT_BRANCH}:
${CI_COMMIT_MESSAGE}
when:
event: [ push, manual ]
status: [ failure ]
2023-10-06 07:04:43 +13:00
depends_on:
2023-10-06 07:02:26 +13:00
- lint