Use ubuntu 20.04 for builds, because some people still use it

pull/175/head
Frank Denis 1 year ago
parent 149849fdc8
commit 41cd192214

@ -10,9 +10,9 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-20.04, windows-latest]
include:
- os: ubuntu-latest
- os: ubuntu-20.04
target: x86_64-unknown-linux-gnu
target_alias: linux-x86_64
bin_suffix: ''
@ -29,7 +29,9 @@ jobs:
ARCHIVE_PATH: encrypted-dns_${{ github.ref_name }}_${{ matrix.target_alias }}${{ matrix.archive_suffix }}
steps:
- uses: actions/checkout@master
- uses: actions/checkout@v3
- uses: goto-bus-stop/setup-zig@v2
- uses: hecrj/setup-rust-action@master
with:
@ -45,20 +47,20 @@ jobs:
- name: Build
run: |
echo 'lto = "fat"' >> Cargo.toml
env RUSTFLAGS="-C link-arg=-s" cargo build --release
env RUSTFLAGS="-C strip=symbols" cargo build --release
mkdir encrypted-dns
cp target/release/encrypted-dns${{ matrix.bin_suffix }} encrypted-dns/
cp README.md example-encrypted-dns.toml encrypted-dns/
if [ "${{ matrix.os }}" = "ubuntu-latest" ]; then
if [ "${{ matrix.os }}" = "ubuntu-20.04" ]; then
tar cjpf ${ARCHIVE_PATH} encrypted-dns
elif [ "${{ matrix.os }}" = "windows-latest" ]; then
"/C/Program Files/7-Zip/7z" a ${ARCHIVE_PATH} encrypted-dns
fi
- name: Install cargo-deb and build Debian package
if: ${{ matrix.os == 'ubuntu-latest' }}
if: ${{ matrix.os == 'ubuntu-20.04' }}
run: |
cargo install --debug cargo-deb
cargo install cargo-deb
cargo deb --output=encrypted-dns_${{ github.ref_name }}_amd64.deb --no-build
- uses: actions/upload-artifact@master
@ -67,7 +69,7 @@ jobs:
path: ${{ env.ARCHIVE_PATH }}
- uses: actions/upload-artifact@master
if: ${{ matrix.os == 'ubuntu-latest' }}
if: ${{ matrix.os == 'ubuntu-20.04' }}
with:
name: encrypted-dns_deb-amd64
path: encrypted-dns_${{ github.ref_name }}_amd64.deb
@ -76,7 +78,7 @@ jobs:
if: startsWith(github.ref, 'refs/tags/')
needs:
- build
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
steps:
- uses: actions/download-artifact@v3

Loading…
Cancel
Save