mirror of
https://github.com/bunkerity/bunkerweb
synced 2026-05-24 09:28:37 +00:00
Bumps [actions/checkout](https://github.com/actions/checkout) from 4.1.4 to 4.1.5.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](0ad4b8fada...44c2b7a8a4)
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
111 lines
4.6 KiB
YAML
111 lines
4.6 KiB
YAML
name: Push packagecloud (REUSABLE)
|
|
|
|
on:
|
|
workflow_call:
|
|
inputs:
|
|
SEPARATOR:
|
|
required: true
|
|
type: string
|
|
SUFFIX:
|
|
required: true
|
|
type: string
|
|
REPO:
|
|
required: true
|
|
type: string
|
|
LINUX:
|
|
required: true
|
|
type: string
|
|
VERSION:
|
|
required: true
|
|
type: string
|
|
PACKAGE:
|
|
required: true
|
|
type: string
|
|
BW_VERSION:
|
|
required: true
|
|
type: string
|
|
ARCH:
|
|
required: true
|
|
type: string
|
|
PACKAGE_ARCH:
|
|
required: true
|
|
type: string
|
|
secrets:
|
|
PACKAGECLOUD_TOKEN:
|
|
required: true
|
|
|
|
jobs:
|
|
push:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
# Prepare
|
|
- name: Check out repository code
|
|
uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5
|
|
- name: Install ruby
|
|
uses: ruby/setup-ruby@cacc9f1c0b3f4eb8a16a6bb0ed10897b43b9de49 # v1.176.0
|
|
with:
|
|
ruby-version: "3.0"
|
|
- name: Install packagecloud
|
|
run: gem install package_cloud
|
|
# Download packages
|
|
- uses: actions/download-artifact@65a9edc5881444af0b9093a5e628f2fe47ea3b2e # v4.1.7
|
|
if: inputs.LINUX != 'el' && inputs.LINUX != 'el9'
|
|
with:
|
|
name: package-${{ inputs.LINUX }}-${{ inputs.PACKAGE_ARCH }}
|
|
path: /tmp/${{ inputs.LINUX }}
|
|
- uses: actions/download-artifact@65a9edc5881444af0b9093a5e628f2fe47ea3b2e # v4.1.7
|
|
if: inputs.LINUX == 'el' || inputs.LINUX == 'el9'
|
|
with:
|
|
name: package-rh${{ inputs.LINUX }}-${{ inputs.PACKAGE_ARCH }}
|
|
path: /tmp/${{ inputs.LINUX }}
|
|
# Remove existing packages
|
|
- name: Remove existing package
|
|
if: inputs.LINUX != 'el9' && inputs.LINUX != 'ubuntu-noble'
|
|
run: package_cloud yank bunkerity/${{ inputs.REPO }}/${{ inputs.LINUX }}/${{ inputs.VERSION }} bunkerweb${{ inputs.SEPARATOR }}${{ inputs.BW_VERSION }}${{ inputs.SEPARATOR }}${{ inputs.SUFFIX }}${{ inputs.PACKAGE_ARCH }}.${{ inputs.PACKAGE }}
|
|
continue-on-error: true
|
|
env:
|
|
PACKAGECLOUD_TOKEN: ${{ secrets.PACKAGECLOUD_TOKEN }}
|
|
- name: Remove existing package el9
|
|
if: inputs.LINUX == 'el9'
|
|
run: package_cloud yank bunkerity/${{ inputs.REPO }}/el/9 bunkerweb${{ inputs.SEPARATOR }}${{ inputs.BW_VERSION }}${{ inputs.SEPARATOR }}${{ inputs.SUFFIX }}${{ inputs.PACKAGE_ARCH }}.${{ inputs.PACKAGE }}
|
|
continue-on-error: true
|
|
env:
|
|
PACKAGECLOUD_TOKEN: ${{ secrets.PACKAGECLOUD_TOKEN }}
|
|
- name: Remove existing package ubuntu-noble
|
|
if: inputs.LINUX == 'ubuntu-noble'
|
|
run: package_cloud yank bunkerity/${{ inputs.REPO }}/ubuntu/noble bunkerweb${{ inputs.SEPARATOR }}${{ inputs.BW_VERSION }}${{ inputs.SEPARATOR }}${{ inputs.SUFFIX }}${{ inputs.PACKAGE_ARCH }}.${{ inputs.PACKAGE }}
|
|
continue-on-error: true
|
|
env:
|
|
PACKAGECLOUD_TOKEN: ${{ secrets.PACKAGECLOUD_TOKEN }}
|
|
# Update name
|
|
# - name: Rename package
|
|
# if: inputs.BW_VERSION == 'testing'
|
|
# run: sudo apt install -y rename && rename 's/[0-9]\.[0-9]\.[0-9]/testing/' /tmp/${{ inputs.LINUX }}/*.${{ inputs.PACKAGE }}
|
|
# Push package
|
|
- name: Push package to packagecloud
|
|
if: inputs.LINUX != 'el9' && inputs.LINUX != 'ubuntu-noble'
|
|
uses: danielmundi/upload-packagecloud@46cd0e61152bf952dbc0d1759e609d3d22649030 # v1
|
|
with:
|
|
PACKAGE-NAME: /tmp/${{ inputs.LINUX }}/*.${{ inputs.PACKAGE }}
|
|
PACKAGECLOUD-USERNAME: bunkerity
|
|
PACKAGECLOUD-REPO: ${{ inputs.REPO }}
|
|
PACKAGECLOUD-DISTRIB: ${{ inputs.LINUX }}/${{ inputs.VERSION }}
|
|
PACKAGECLOUD-TOKEN: ${{ secrets.PACKAGECLOUD_TOKEN }}
|
|
- name: Push package to packagecloud for el9
|
|
if: inputs.LINUX == 'el9'
|
|
uses: danielmundi/upload-packagecloud@46cd0e61152bf952dbc0d1759e609d3d22649030 # v1
|
|
with:
|
|
PACKAGE-NAME: /tmp/${{ inputs.LINUX }}/*.${{ inputs.PACKAGE }}
|
|
PACKAGECLOUD-USERNAME: bunkerity
|
|
PACKAGECLOUD-REPO: ${{ inputs.REPO }}
|
|
PACKAGECLOUD-DISTRIB: el/9
|
|
PACKAGECLOUD-TOKEN: ${{ secrets.PACKAGECLOUD_TOKEN }}
|
|
- name: Push package to packagecloud for ubuntu-noble
|
|
if: inputs.LINUX == 'ubuntu-noble'
|
|
uses: danielmundi/upload-packagecloud@46cd0e61152bf952dbc0d1759e609d3d22649030 # v1
|
|
with:
|
|
PACKAGE-NAME: /tmp/${{ inputs.LINUX }}/*.${{ inputs.PACKAGE }}
|
|
PACKAGECLOUD-USERNAME: bunkerity
|
|
PACKAGECLOUD-REPO: ${{ inputs.REPO }}
|
|
PACKAGECLOUD-DISTRIB: ubuntu/noble
|
|
PACKAGECLOUD-TOKEN: ${{ secrets.PACKAGECLOUD_TOKEN }}
|