Skip to content

Commit

Permalink
feat: add release workflow for GitHub actions
Browse files Browse the repository at this point in the history
  • Loading branch information
krudi committed Jun 16, 2024
1 parent c896c37 commit cd76b10
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Release the Ansible role to Ansible Galaxy

on:
push:
tags:
- "*"

jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout the current branch
uses: actions/checkout@v4

- name: Setup of Python 3
uses: actions/setup-python@v5
with:
python-version: "3.x"

- name: Install Ansible dependencies
run: pip3 install ansible-core

- name: Release the Ansible role
run: >-
ansible-galaxy role import --api-key ${{ secrets.ANSIBLE_GALAXY_API_KEY }}
$(echo ${{ github.repository }} | cut -d/ -f1) $(echo ${{ github.repository }} | cut -d/ -f2)

0 comments on commit cd76b10

Please sign in to comment.