Browse Source

Add debian builds into github action

sisyphus
MateuszSC 3 years ago committed by GitHub
parent
commit
1420596148
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 58
      .github/actions/build/action.yml
  2. 35
      .github/workflows/build.yml
  3. 46
      .github/workflows/publish.yml
  4. 3
      .gitignore
  5. 24
      README.md

58
.github/actions/build/action.yml

@ -0,0 +1,58 @@
name: "Build Webgreeter"
description: "Builds webgreeter"
inputs:
target-distro:
required: true
description: "Target distro"
runs:
using: "composite"
steps:
-
name: Checkout
uses: actions/checkout@v2
-
name: Install dependencies
shell: bash
run: |
sudo apt update
sudo apt install \
liblightdm-gobject-1-dev \
libgirepository1.0-dev \
libqt5webengine5 \
pyqt5-dev-tools \
python3-gi \
python3-pyqt5 \
python3-ruamel.yaml \
python3-pyinotify \
python3-xlib \
python3-pip \
dpkg
-
name: Build web-greeter
shell: bash
run: make build
-
name: Prepare deb build (common)
shell: bash
run: |
cp -r build/DEBIAN/ build/install_root/
-
name: Prepare deb build (for Debian)
shell: bash
if: ${{ inputs.target-distro == 'debian' }}
run: |
sed -i "s/liblightdm-gobject-1-dev/liblightdm-gobject-dev/g" build/install_root/DEBIAN/control
-
name: Build deb
shell: bash
run: |
cd build/
dpkg-deb --root-owner-group --build install_root "web-greeter.deb"
dpkg --info "./web-greeter.deb"
-
name: 'Upload Artifact'
uses: actions/upload-artifact@v2
with:
name: build-${{ inputs.target-distro }}
path: ./build/web-greeter.deb
retention-days: 7

35
.github/workflows/build.yml

@ -1,26 +1,27 @@
name: Build Test
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
on: [push]
jobs:
build:
build-ubuntu:
runs-on: ubuntu-latest
steps:
-
name: Checkout
-
name: Checkout local actions
uses: actions/checkout@v2
-
name: Install dependencies
run: |
sudo apt update
sudo apt install liblightdm-gobject-1-dev libqt5webengine5 pyqt5-dev-tools python3-gi python3-pyqt5 python3-ruamel.yaml python3-pyinotify python3-xlib python3-pip libgirepository1.0-dev build-essential gobject-introspection
-
name: Build and install web-greeter
run: sudo make install
uses: "./.github/actions/build"
with:
target-distro: ubuntu
build-debian:
runs-on: ubuntu-latest
steps:
-
name: Checkout local actions
uses: actions/checkout@v2
-
name: Build web-greeter
uses: "./.github/actions/build"
with:
target-distro: debian

46
.github/workflows/publish.yml

@ -7,35 +7,43 @@ on:
workflow_dispatch:
jobs:
build:
name: Publish binaries
publish-ubuntu:
name: Publish ubuntu binaries
runs-on: ubuntu-latest
steps:
-
name: Checkout
-
name: Checkout local actions
uses: actions/checkout@v2
-
name: Install dependencies
run: |
sudo apt update
sudo apt install liblightdm-gobject-1-dev libqt5webengine5 pyqt5-dev-tools python3-gi python3-pyqt5 python3-ruamel.yaml python3-pyinotify python3-xlib python3-pip
sudo apt install dpkg
-
name: Build and install web-greeter
run: make install
uses: "./.github/actions/build"
with:
target-distro: ubuntu
- name: Upload binaries to release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: build/web-greeter.deb
asset_name: web-greeter-$tag-ubuntu.deb
tag: ${{ github.ref }}
overwrite: true
publish-debian:
name: Publish debian binaries
runs-on: ubuntu-latest
steps:
-
name: Checkout local actions
uses: actions/checkout@v2
-
name: Build deb
run: |
cd build/
cp -r DEBIAN/ install_root/
dpkg-deb --root-owner-group --build install_root "web-greeter.deb"
dpkg --info "./web-greeter.deb"
name: Build web-greeter
uses: "./.github/actions/build"
with:
target-distro: debian
- name: Upload binaries to release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: build/web-greeter.deb
asset_name: web-greeter-$tag.deb
asset_name: web-greeter-$tag-debian.deb
tag: ${{ github.ref }}
overwrite: true

3
.gitignore vendored

@ -58,3 +58,6 @@ Makefile.in
_book/
node_modules/
package-lock.json
# vscode
.vscode/

24
README.md

@ -41,18 +41,18 @@ apt install ./web-greeter-VER.deb
```
## Dependencies
| | arch | ubuntu | fedora | openSUSE |
|--------------------------|----------------------|-------------------------|---------------------|----------------------|
|**liblightdm-gobject** |lightdm |liblightdm-gobject-1-dev |lightdm-gobject-devel|liblightdm-gobject-1-0|
|**pygobject** |python-gobject |python3-gi |pygobject3 |python3-gobject |
|**pyqt5** |python-pyqt5 |python3-pyqt5 |python3-qt5 |python3-qt5 |
|**pyqt5-webengine** |python-pyqt5-webengine|python3-pyqt5.qtwebengine|python3-qt5-webengine|python3-qtwebengine |
|**python-yaml** |python-ruamel-yaml |python3-ruamel.yaml |python3-ruamel-yaml |python3-ruamel-yaml |
|**python-inotify** |python-pyinotify |python3-pyinotify |python3-inotify |python3-inotify |
|**qt5-webengine** |qt5-webengine |libqt5webengine5 |qt5-qtwebengine |libqt5-qtwebengine |
|**gobject-introspection** |gobject-introspection |gobject-introspection |gobject-introspection|gobject-introspection |
|**libxcb** |libxcb |libxcb1-dev |libxcb-devel |libxcb |
|**libx11** |libx11 |libx11-dev |libX11-devel |libx11 |
| | arch | ubuntu | fedora | openSUSE | debian |
|--------------------------|----------------------|-------------------------|---------------------|----------------------|-------------------------|
|**liblightdm-gobject** |lightdm |liblightdm-gobject-1-dev |lightdm-gobject-devel|liblightdm-gobject-1-0|liblightdm-gobject-dev |
|**pygobject** |python-gobject |python3-gi |pygobject3 |python3-gobject |python3-gi |
|**pyqt5** |python-pyqt5 |python3-pyqt5 |python3-qt5 |python3-qt5 |python3-pyqt5 |
|**pyqt5-webengine** |python-pyqt5-webengine|python3-pyqt5.qtwebengine|python3-qt5-webengine|python3-qtwebengine |python3-pyqt5.qtwebengine|
|**python-yaml** |python-ruamel-yaml |python3-ruamel.yaml |python3-ruamel-yaml |python3-ruamel-yaml |python3-ruamel.yaml |
|**python-inotify** |python-pyinotify |python3-pyinotify |python3-inotify |python3-inotify |python3-pyinotify |
|**qt5-webengine** |qt5-webengine |libqt5webengine5 |qt5-qtwebengine |libqt5-qtwebengine |libqt5webengine5 |
|**gobject-introspection** |gobject-introspection |gobject-introspection |gobject-introspection|gobject-introspection |gobject-introspection |
|**libxcb** |libxcb |libxcb1-dev |libxcb-devel |libxcb |libxcb1-dev |
|**libx11** |libx11 |libx11-dev |libX11-devel |libx11 |libx11-dev |
### Build dependencies

Loading…
Cancel
Save