Skip to content

Commit

Permalink
Merge pull request #58 from bigbluebutton/github-workflows-update
Browse files Browse the repository at this point in the history
Update github workflow actions for deprecations
  • Loading branch information
kepstin authored Dec 11, 2024
2 parents c8cbb96 + 8cb39b7 commit 2be6362
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 83 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,12 @@ jobs:
- name: Install system dependencies
run: |
sudo apt-get update
DEBIAN_FRONTEND=noninteractive sudo apt-get install build-essential libgirepository1.0-dev gir1.2-glib-2.0 gir1.2-poppler-0.18 gir1.2-gtk-3.0 gir1.2-gdkpixbuf-2.0 gir1.2-pango-1.0
DEBIAN_FRONTEND=noninteractive sudo apt-get install build-essential libgirepository1.0-dev gir1.2-glib-2.0 gir1.2-poppler-0.18 gir1.2-gtk-3.0 gir1.2-gdkpixbuf-2.0 gir1.2-pango-1.0 libcairo2-dev
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: "3.8"
python-version: "3.10"
cache: pip
cache-dependency-path: |
setup.cfg
Expand All @@ -51,8 +51,8 @@ jobs:
- name: Install package and dependencies
run: |
pip install -r requirements-dev.txt -c constraints-ubuntu-focal.txt
pip install -e . -c constraints-ubuntu-focal.txt
pip install -r requirements-dev.txt -c constraints-ubuntu-jammy.txt
pip install -e . -c constraints-ubuntu-jammy.txt
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
Expand Down
82 changes: 8 additions & 74 deletions .github/workflows/package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends debhelper devscripts equivs git git-buildpackage pristine-tar
- name: Checkout source code
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: source
fetch-depth: 0
Expand Down Expand Up @@ -68,105 +68,39 @@ jobs:
ls ..
- name: Upload artifacts
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: ubuntu-${{ matrix.UBUNTU_VERSION }}
path: "*.deb"
if-no-files-found: error

amazonlinux-2:
runs-on: ubuntu-latest
container: amazonlinux:2
defaults:
run:
shell: bash
steps:
- name: Install Python and package build dependencies
run: |
amazon-linux-extras enable python3.8 ruby3.0
yum clean metadata
yum install -y \
python38 python38-devel python38-wheel \
git gcc make \
cairo-gobject-devel gobject-introspection-devel \
ruby ruby-devel ruby-irb rubygem-rake rubygem-json rubygems \
rpm-build
pip3.8 install virtualenv-tools3
gem install --no-document fpm
- name: Checkout source code
uses: actions/checkout@v3
with:
fetch-depth: 0
path: bbb-presentation-video

- name: Build and install package to image directory
run: |
python3.8 -m venv bbb-presentation-video-image/opt/bbb-presentation-video
bbb-presentation-video-image/opt/bbb-presentation-video/bin/python -m pip install ./bbb-presentation-video -c ./bbb-presentation-video/constraints-amazonlinux-2.txt
virtualenv-tools --update-path /opt/bbb-presentation-video bbb-presentation-video-image/opt/bbb-presentation-video
mkdir -pv bbb-presentation-video-image/usr/bin
ln -sv /opt/bbb-presentation-video/bin/bbb-presentation-video bbb-presentation-video-image/usr/bin
- name: Use fpm to build rpm package
run: |
pushd bbb-presentation-video
eval "$(./dch_version.sh)"
popd
fpm --verbose \
--name bbb-presentation-video \
--input-type dir \
--chdir bbb-presentation-video-image \
--output-type rpm \
--version "${DCH_VERSION}" \
--rpm-dist amzn2 \
--rpm-autoreqprov \
--depends python3.8 \
--depends gobject-introspection \
--depends poppler-glib \
--depends gdk-pixbuf2 \
--depends gtk3 \
--depends pango \
--depends liberation-fonts \
--depends ffmpeg \
.
- name: Upload artifacts
uses: actions/upload-artifact@v3
with:
name: amazonlinux-2
path: "*.rpm"

assets:
name: "Upload assets to release"
needs: [ ubuntu, amazonlinux-2 ]
needs: [ ubuntu ]
runs-on: ubuntu-latest
if: ${{ github.ref_type == 'tag' }}
permissions:
contents: write
actions: read

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- uses: actions/download-artifact@v3
- uses: actions/download-artifact@v4
with:
name: ubuntu-20.04
path: ubuntu-20.04

- uses: actions/download-artifact@v3
with:
name: amazonlinux-2
path: amazonlinux-2

- name: Create release asset archives
run: |
for asset in ubuntu-20.04 amazonlinux-2 ; do
for asset in ubuntu-20.04 ; do
zip --junk-paths --recurse-paths --compression-method store "${asset}.zip" "${asset}"
done
- name: Upload release assets
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
for asset in ubuntu-20.04 amazonlinux-2 ; do
for asset in ubuntu-20.04 ; do
gh release upload ${{ github.ref_name }} "${asset}.zip"
done
5 changes: 2 additions & 3 deletions .github/workflows/test-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,11 @@ jobs:

steps:
- name: Download test results
uses: dawidd6/action-download-artifact@v2
uses: action/download-artifact@v4
with:
name: junit
path: junit/
workflow: ${{ github.event.workflow.id }}
workflow_conclusion: ""
github-token: ${{ secrets.GH_PAT }}
run_id: ${{ github.event.workflow_run.id }}

- name: Publish test report
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
steps:

- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Install system dependencies
run: |
Expand Down Expand Up @@ -64,7 +64,7 @@ jobs:

- name: Upload test results
if: ${{ success() || failure() }}
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: junit
path: junit/

0 comments on commit 2be6362

Please sign in to comment.