small pipeline fixes

This commit is contained in:
Robert Kaussow 2019-03-25 22:17:21 +01:00
parent 7dd817f910
commit f49807ebf9
2 changed files with 50 additions and 2 deletions

View File

@ -26,6 +26,9 @@ local PipelineLinting = {
AnsibleVersions(version="latest", package="ansible"),
AnsibleVersions(version="master", package="git+https://github.com/ansible/ansible.git@devel"),
],
trigger: {
ref: ["refs/heads/master", "refs/tags/**", "refs/pull/**"],
},
};
local PipelineDeployment = {
@ -66,6 +69,9 @@ local PipelineDeployment = {
depends_on: [
"linting",
],
trigger: {
ref: ["refs/heads/master", "refs/tags/**"],
},
};
local PipelineNotifications = {
@ -91,12 +97,13 @@ local PipelineNotifications = {
"deployment",
],
trigger: {
event: [ "push", "tag" ],
status: [ "success", "failure" ],
ref: ["refs/heads/master", "refs/tags/**"],
},
};
[
PipelineLinting,
PipelineDeployment
PipelineDeployment,
PipelineNotifications,
]

View File

@ -31,6 +31,12 @@ steps:
depends_on:
- clone
trigger:
ref:
- refs/heads/master
- "refs/tags/**"
- "refs/pull/**"
---
kind: pipeline
name: deployment
@ -68,7 +74,42 @@ steps:
MOLECULE_CUSTOM_MODULES_REPO: https://gitea.rknet.org/ansible/custom_modules
PY_COLORS: 1
trigger:
ref:
- refs/heads/master
- "refs/tags/**"
depends_on:
- linting
---
kind: pipeline
name: notifications
platform:
os: linux
arch: amd64
steps:
- image: plugins/matrix
settings:
homeserver: https://matrix.rknet.org
password:
from_secret: matrix_password
roomid: MtidqQXWWAtQcByBhH:rknet.org
template: "Status: **{{ build.status }}**<br/> Build: [{{ repo.Owner }}/{{ repo.Name }}]({{ build.link }}) ({{ build.branch }}) by {{ build.author }}<br/> Message: {{ build.message }}"
username:
from_secret: matrix_username
trigger:
ref:
- refs/heads/master
- "refs/tags/**"
status:
- success
- failure
depends_on:
- deployment
...