Skip to content

Commit bc43a38

Browse files
committed
CI - fix release
1 parent 23c8ba2 commit bc43a38

File tree

1 file changed

+22
-5
lines changed

1 file changed

+22
-5
lines changed

.github/workflows/release.yml

Lines changed: 22 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,38 @@
11
---
2+
# This workflow requires a GALAXY_API_KEY secret present in the GitHub
3+
# repository or organization.
4+
#
5+
# See: https://github.com/marketplace/actions/publish-ansible-role-to-galaxy
6+
# See: https://github.com/ansible/galaxy/issues/46
7+
28
name: Release
39
'on':
410
push:
511
tags:
612
- '*'
713

14+
defaults:
15+
run:
16+
working-directory: 'my.role'
17+
818
jobs:
919

1020
release:
1121
name: Release
1222
runs-on: ubuntu-latest
1323
steps:
14-
- name: Check out the codebase
24+
- name: Check out the codebase.
1525
uses: actions/checkout@v2
16-
17-
- name: Publish to Galaxy
18-
uses: robertdebock/[email protected]
1926
with:
20-
galaxy_api_key: ${{ secrets.GALAXY_API_KEY }}
2127
path: 'my.role'
28+
29+
- name: Set up Python 3.
30+
uses: actions/setup-python@v2
31+
with:
32+
python-version: '3.x'
33+
34+
- name: Install Ansible.
35+
run: pip3 install ansible-base
36+
37+
- name: Trigger a new import on Galaxy.
38+
run: ansible-galaxy role import --api-key ${{ secrets.GALAXY_API_KEY }} $(echo ${{ github.repository }} | cut -d/ -f1) $(echo ${{ github.repository }} | cut -d/ -f2)

0 commit comments

Comments
 (0)