view modules/inifile/.github/workflows/release.yml @ 399:2c6065b5be5e

Switch to config-based PHP extensions This makes it compatible with Ubuntu, otherwise it keeps trying to re-install the same module because the "phpX.X" package is a virtual package and the Puppet handling of Ubuntu's "is it installed" system is incapable of saying "yes" when a virtual package is installed.
author IBBoard <dev@ibboard.co.uk>
date Wed, 20 Apr 2022 19:08:14 +0100
parents 3fce34f642f1
children
line wrap: on
line source

name: "Publish module"

on:
  workflow_dispatch:
  
jobs:
  create-github-release:
    name: Deploy GitHub Release
    runs-on: ubuntu-20.04
    steps:
      - name: Checkout code
        uses: actions/checkout@v2
        with:
          ref: ${{ github.ref }}
          clean: true
          fetch-depth: 0
      - name: Get Version
        id: gv
        run: |
          echo "::set-output name=ver::$(jq --raw-output .version metadata.json)"
      - name: Create Release
        uses: actions/create-release@v1
        id: create_release
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
        with:
          tag_name: "v${{ steps.gv.outputs.ver }}"
          draft: false
          prerelease: false

  deploy-forge:
    name: Deploy to Forge
    runs-on: ubuntu-20.04
    steps:
      - name: Checkout code
        uses: actions/checkout@v2
        with:
          ref: ${{ github.ref }}
          clean: true
      - name: "PDK Build"
        uses: docker://puppet/pdk:nightly
        with:
          args: 'build'
      - name: "Push to Forge"
        uses: docker://puppet/pdk:nightly
        with:
          args: 'release publish --forge-token ${{ secrets.FORGE_API_KEY }} --force'