2022-04-27 13:29:41 +02:00
|
|
|
name: Installers
|
2022-03-08 17:01:11 +01:00
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
paths-ignore:
|
|
|
|
- '.devcontainer/**'
|
|
|
|
- 'examples/**'
|
|
|
|
- 'lib/**'
|
|
|
|
- 'man/**'
|
|
|
|
- 'priv/**'
|
|
|
|
- '**.md'
|
|
|
|
pull_request:
|
|
|
|
paths-ignore:
|
|
|
|
- '.devcontainer/**'
|
|
|
|
- 'examples/**'
|
|
|
|
- 'lib/**'
|
|
|
|
- 'man/**'
|
|
|
|
- 'priv/**'
|
|
|
|
- '**.md'
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
binaries:
|
|
|
|
name: Binaries
|
2024-11-12 13:02:28 +01:00
|
|
|
runs-on: ubuntu-24.04
|
2022-03-08 17:01:11 +01:00
|
|
|
steps:
|
|
|
|
- name: Cache build directory
|
2024-02-01 17:02:44 +01:00
|
|
|
uses: actions/cache@v4
|
2022-03-08 17:01:11 +01:00
|
|
|
with:
|
|
|
|
path: ~/build/
|
2023-09-26 23:55:01 +02:00
|
|
|
key: ${{runner.os}}-ct-ng-1.26.0
|
2022-03-08 17:01:11 +01:00
|
|
|
- name: Install prerequisites
|
|
|
|
run: |
|
|
|
|
sudo apt-get -qq update
|
|
|
|
sudo apt-get -qq install makeself
|
|
|
|
# https://github.com/crosstool-ng/crosstool-ng/blob/master/testing/docker/ubuntu21.10/Dockerfile
|
|
|
|
sudo apt-get -qq install build-essential autoconf bison flex gawk
|
|
|
|
sudo apt-get -qq install help2man libncurses5-dev libtool libtool-bin
|
|
|
|
sudo apt-get -qq install python3-dev texinfo unzip
|
|
|
|
- name: Install FPM
|
|
|
|
run: |
|
|
|
|
gem install --no-document --user-install fpm
|
2022-12-13 17:33:46 +01:00
|
|
|
echo $HOME/.local/share/gem/ruby/*/bin >> $GITHUB_PATH
|
2022-03-08 17:01:11 +01:00
|
|
|
- name: Check out repository code
|
2023-09-11 08:16:03 +02:00
|
|
|
uses: actions/checkout@v4
|
2022-03-08 17:01:11 +01:00
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
|
|
|
- name: Build binary archives
|
|
|
|
run: CHECK_DEPS=false tools/make-binaries
|
|
|
|
- name: Build DEB and RPM packages
|
|
|
|
run: tools/make-packages
|
|
|
|
- name: Build installers
|
|
|
|
run: tools/make-installers
|
|
|
|
- name: Collect packages
|
|
|
|
run: |
|
|
|
|
mkdir ejabberd-packages
|
|
|
|
mv ejabberd_*.deb ejabberd-*.rpm ejabberd-*.run ejabberd-packages
|
|
|
|
- name: Upload packages
|
2024-02-01 17:02:44 +01:00
|
|
|
uses: actions/upload-artifact@v4
|
2022-03-08 17:01:11 +01:00
|
|
|
with:
|
|
|
|
name: ejabberd-packages
|
|
|
|
#
|
|
|
|
# Appending the wildcard character ("*") is a trick to make
|
|
|
|
# "ejabberd-packages" the root directory of the uploaded ZIP file:
|
|
|
|
#
|
|
|
|
# https://github.com/actions/upload-artifact#upload-using-multiple-paths-and-exclusions
|
|
|
|
#
|
|
|
|
path: ejabberd-packages*
|
|
|
|
retention-days: 14
|
2022-04-22 20:35:00 +02:00
|
|
|
|
|
|
|
release:
|
|
|
|
name: Release
|
|
|
|
needs: [binaries]
|
2024-11-12 13:02:28 +01:00
|
|
|
runs-on: ubuntu-24.04
|
2022-04-22 20:35:00 +02:00
|
|
|
if: github.ref_type == 'tag'
|
|
|
|
steps:
|
|
|
|
- name: Download packages
|
2024-02-01 17:02:44 +01:00
|
|
|
uses: actions/download-artifact@v4
|
2022-04-22 20:35:00 +02:00
|
|
|
with:
|
|
|
|
name: ejabberd-packages
|
|
|
|
- name: Draft Release
|
2024-03-11 07:17:51 +01:00
|
|
|
uses: softprops/action-gh-release@v2
|
2022-04-22 20:35:00 +02:00
|
|
|
with:
|
|
|
|
draft: true
|
|
|
|
files: ejabberd-packages/*
|