diff --git a/.github/workflows/build-client-packages.yml b/.github/workflows/build-client-packages.yml index b9d136b9..0a493759 100644 --- a/.github/workflows/build-client-packages.yml +++ b/.github/workflows/build-client-packages.yml @@ -17,6 +17,7 @@ jobs: build-packages: runs-on: ubuntu-latest steps: + - name: Checkout - uses: actions/checkout@v2 - name: Get the version number for the packages @@ -57,7 +58,7 @@ jobs: fpm_args: "etc" fpm_opts: "--debug -n cvmfs-config-eessi -v ${{ steps.get_version.outputs.version }} -t deb -a all -s dir -C ./package --description 'CVMFS config repository package for EESSI.'" - - name: Find filenames of downloaded packages + - name: Find filenames of generated packages id: find_filenames shell: bash run: | @@ -100,7 +101,7 @@ jobs: run: ln -s inventory/group_vars - name: Install Ansible - run: pip install ansible + run: pip3 install ansible - name: Prepare package source run: ansible-playbook --connection=local ./prepare-client-packages.yml @@ -114,7 +115,7 @@ jobs: - name: Build package run: "fpm --debug -n cvmfs-config-eessi -v ${{ steps.get_version.outputs.version }} -t osxpkg -a all -s dir -C ./package --description 'CVMFS config repository package for EESSI.' etc" - - name: Find filename of package + - name: Find filename of generated package id: find_filenames shell: bash run: | @@ -142,14 +143,21 @@ jobs: with: name: RPM package + - name: Download macOS package + uses: actions/download-artifact@v2 + with: + name: macOS package + - name: Find filenames of downloaded packages id: find_filenames shell: bash run: | rpmfile="$(ls -1 *.rpm)" debfile="$(ls -1 *.deb)" + pkgfile="$(ls -1 *.pkg)" echo ::set-output name=rpmfile::${rpmfile} echo ::set-output name=debfile::${debfile} + echo ::set-output name=pkgfile::${pkgfile} - name: Create Release id: create_release @@ -180,4 +188,14 @@ jobs: upload_url: ${{ steps.create_release.outputs.upload_url }} asset_path: ${{ steps.find_filenames.outputs.debfile }} asset_name: ${{ steps.find_filenames.outputs.debfile }} - asset_content_type: application/x-debian-package + asset_content_type: application/x-deb + + - name: Upload Pkg as release asset + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + asset_path: ${{ steps.find_filenames.outputs.pkgfile }} + asset_name: ${{ steps.find_filenames.outputs.pkgfile }} + asset_content_type: application/x-newton-compatible-pkg