Merge branch 'trallnag-patch-1' into dev/master #286
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI/CD Dev Build Deployment | |
on: | |
push: | |
branches: | |
- dev/** | |
- lts/** | |
jobs: | |
debbuild: | |
name: Debian | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install Pre-requisites | |
run: | | |
sudo apt-get update -qq | |
sudo apt-get install -qq apt-utils build-essential gzip devscripts debhelper bats | |
- name: Build Debian Package | |
run: | | |
git clone https://github.com/wslutilities/wslu-debian builder | |
cd builder/ | |
bash ./build.sh --ci dev debian unstable | |
cd ../ | |
mkdir -p ./pkgs | |
mv ../wsl*.* ./pkgs | |
- uses: actions/upload-artifact@v1 | |
with: | |
name: DebianDEBs | |
path: pkgs | |
pgwbuild: | |
name: Pengwin | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install Pre-requisites | |
run: | | |
sudo apt-get update -qq | |
sudo apt-get install -qq apt-utils build-essential gzip devscripts debhelper bats | |
- name: Build Debian Package | |
run: | | |
git clone https://github.com/wslutilities/wslu-debian builder | |
cd builder/ | |
bash ./build.sh --ci dev pengwin | |
cd ../ | |
mkdir -p ./pkgs | |
mv ../wsl*.* ./pkgs | |
- uses: actions/upload-artifact@v1 | |
with: | |
name: PengwinDEBs | |
path: pkgs | |
pgwspdeploy: | |
name: Pengwin Deploying | |
needs: pgwbuild | |
runs-on: ubuntu-20.04 | |
container: cimg/ruby:2.7 | |
steps: | |
- name: Retrive package for deployment | |
uses: actions/download-artifact@v1 | |
with: | |
name: PengwinDEBs | |
- run: gem install package_cloud | |
- name: deploy to the dev | |
env: | |
PACKAGECLOUD_TOKEN: ${{ secrets.PGW_DEV_DEPLOY_KEY }} | |
run: package_cloud push whitewaterfoundry/wslu/debian/bullseye ./PengwinDEBs/*.deb --skip-errors | |
rpmobsbuild: | |
name: RPM - OpenSUSE Build Service | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install Pre-requisites | |
run: | | |
sudo apt-get update -qq | |
sudo apt-get install -qq build-essential tar | |
- name: configure | |
run: | | |
bash ./configure.sh --rpm obs_canary | |
cp extras/build/rpm/obs/wslu.spec ../wslu-canary.spec | |
rm -rf * | |
mkdir -p SOURCES | |
mkdir -p SPECS | |
cp ../wslu-*.tar.gz SOURCES | |
cp ../wslu-canary.spec SPECS | |
- name: rpmbuild | |
uses: ./.github/actions/rpmbuild/ | |
- name: moving files | |
run: | | |
mkdir obs_res | |
cp ../wslu-*.tar.gz obs_res | |
cp ../wslu-canary.spec obs_res | |
- uses: actions/upload-artifact@v1 | |
with: | |
name: OBS_RES | |
path: obs_res | |
obsdeploy: | |
name: OpenSUSE Build Service Deploying | |
needs: rpmobsbuild | |
runs-on: ubuntu-latest | |
steps: | |
- name: Retrive package for deployment | |
uses: actions/download-artifact@v1 | |
with: | |
name: OBS_RES | |
- name: Install Pre-requisites | |
run: | | |
sudo apt-get update -qq | |
sudo apt-get install -qq osc python3-m2crypto | |
- name: Install API token for osc | |
env: | |
API_TOKEN_CONTENT: ${{ secrets.OBS_API_TOKEN }} | |
run: | | |
mkdir -p "$HOME/.config/osc" | |
echo -e "[general]\napiurl = https://api.opensuse.org\n[https://api.opensuse.org]\nuser = wslutilities\npass = $API_TOKEN_CONTENT" > "$HOME/.config/osc/oscrc" | |
- name: Uploading OBS source files | |
run: | | |
osc checkout home:wslutilities | |
cp OBS_RES/* home:wslutilities/wslu-canary/ | |
cd home:wslutilities/wslu-canary/ | |
osc addremove | |
osc commit -m "Build at $(date)" | |
rpmcoprbuild: | |
name: RPM - Cool Other Package Repo | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install Pre-requisites | |
run: | | |
sudo apt-get update -qq | |
sudo apt-get install -qq build-essential tar | |
- name: configure | |
run: | | |
bash ./configure.sh --rpm copr | |
cp extras/build/rpm/copr/wslu.spec ../wslu.spec | |
rm -rf * | |
mkdir -p SOURCES | |
mkdir -p SPECS | |
cp ../wslu-*.tar.gz SOURCES | |
cp ../wslu.spec SPECS | |
- name: rpmbuild | |
uses: ./.github/actions/rpmbuild/ | |
- name: moving files | |
run: | | |
mkdir compiled_rpms | |
cp SRPMS/* compiled_rpms | |
cp RPMS/noarch/* compiled_rpms | |
#uses: robertdebock/rpmbuild-action@1.1.1 | |
- uses: actions/upload-artifact@v1 | |
with: | |
name: COPRRPMs | |
path: compiled_rpms | |
coprdeploy: | |
name: Cool Other Package Repo Deploying | |
needs: rpmcoprbuild | |
container: fedora:latest | |
runs-on: ubuntu-latest | |
steps: | |
- name: Retrive package for deployment | |
uses: actions/download-artifact@v1 | |
with: | |
name: COPRRPMs | |
- name: Install API token for copr-cli | |
env: | |
API_TOKEN_CONTENT: ${{ secrets.COPR_API_TOKEN }} | |
run: | | |
mkdir -p "$HOME/.config" | |
echo "$API_TOKEN_CONTENT" > "$HOME/.config/copr" | |
- name: Install tooling for source RPM build | |
run: | | |
dnf -y install @development-tools @rpm-development-tools | |
dnf -y install copr-cli make | |
- name: Submit the build by uploading the source RPM | |
run: copr-cli build wslutilities/wslu-canary COPRRPMs/*.src.rpm |