Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix deb builds #220

Merged
merged 11 commits into from
May 22, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 9 additions & 6 deletions .github/workflows/build_extension_deb.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,12 @@ jobs:
- 15
- 16
box:
- { runner: ubuntu-20.04, arch: amd64 }
- { runner: arm-runner, arch: arm64 }
runs-on: ${{ matrix.box.runner }}
- { runner: large-8x8, arch: amd64 }
- { runner: arm64, arch: arm64 }
runs-on:
- "dind"
- "self-hosted"
- ${{ matrix.box.runner }}
timeout-minutes: 90
steps:
- uses: actions/checkout@v4
Expand Down Expand Up @@ -67,8 +70,10 @@ jobs:
mkdir archive
cp `find target/release -type f -name "${{ matrix.extension_name }}*"` archive

deb_version=$(grep '^version' Cargo.toml | head -1 | awk -F '"' '{print $2}')

# name of the package directory before packaging
package_dir=${{ matrix.extension_name }}-${{ github.ref_name }}-pg${{ matrix.postgres }}-${{ matrix.box.arch }}-linux-gnu
package_dir=${{ matrix.extension_name }}-${deb_version}-pg${{ matrix.postgres }}-${{ matrix.box.arch }}-linux-gnu

# Copy files into directory structure
mkdir -p ${package_dir}/usr/lib/postgresql/lib
Expand All @@ -77,8 +82,6 @@ jobs:
cp archive/*.control ${package_dir}/var/lib/postgresql/extension
cp archive/*.sql ${package_dir}/var/lib/postgresql/extension

deb_version=$(grep '^version' Cargo.toml | head -1 | awk -F '"' '{print $2}')

mkdir -p ${package_dir}/DEBIAN
touch ${package_dir}/DEBIAN/control
echo 'Package: ${{ matrix.package_name }}' >> ${package_dir}/DEBIAN/control
Expand Down
Loading