Skip to content

Commit

Permalink
Fixes Debian artifact build (#403)
Browse files Browse the repository at this point in the history
  • Loading branch information
BradyBonnette authored Mar 6, 2024
1 parent ff6f46d commit 3c0ab7c
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions .github/docker/Dockerfile.debian-artifact-build
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ ENV PATH="/var/lib/postgresql/.cargo/bin:${PATH}"

# Install the version of PGRX that is dictated by Cargo.toml for this project
RUN PGRX_VERSION=$(cargo metadata --format-version 1 | jq -r '.packages[]|select(.name=="pgrx")|.version') && \
cargo install cargo-pgrx --force --version "$PGRX_VERSION"
cargo install cargo-pgrx --locked --force --version "$PGRX_VERSION"

# Necessary to build plrustc and company
RUN rustup component add llvm-tools-preview rustc-dev
Expand Down Expand Up @@ -161,7 +161,7 @@ EOF
# Package everything up based on whatever's in RELEASE_DIR, and send the resulting
# .deb file to the /out directory
RUN TOOLCHAIN_VER=$(</tmp/.toolchain-ver) && \
DEB_FILENAME="plrust-trusted-${PLRUST_VER}_$TOOLCHAIN_VER-debian-pg${PG_VER}-$(dpkg --print-architecture).deb" && \
DEB_FILENAME="plrust-trusted-${PLRUST_VER}_$TOOLCHAIN_VER-debian-bullseye-pg${PG_VER}-$(dpkg --print-architecture).deb" && \
cd ${RELEASE_DIR} && fpm \
-s dir \
-t deb \
Expand Down
2 changes: 1 addition & 1 deletion .github/scripts/install_cargo_pgrx.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ function install_cargo_pgrx() {

if TARGET_VERSION=$(cargo metadata --format-version 1 | jq -r '.packages[]|select(.name=="pgrx")|.version'); then
echo "Installing/upgrading cargo-pgrx to version $TARGET_VERSION"
cargo install cargo-pgrx --force --version "$TARGET_VERSION"
cargo install cargo-pgrx --locked --force --version "$TARGET_VERSION"
else
echo "Could not determine cargo-pgrx version to install."
exit 1
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.try
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ ENV PATH="/var/lib/postgresql/.cargo/bin:${PATH}"

# Build/install/remove all that is necessary in one step as to keep the resulting layer as small as possible.
RUN PGRX_VERSION=$(cargo metadata --format-version 1 | jq -r '.packages[]|select(.name=="pgrx")|.version') && \
cargo install cargo-pgrx --force --version "$PGRX_VERSION" && \
cargo install cargo-pgrx --locked --force --version "$PGRX_VERSION" && \
rustup component add llvm-tools-preview rustc-dev && \
cd /src/plrustc && ./build.sh && cp ../build/bin/plrustc ~/.cargo/bin && \
cargo pgrx init --pg15 $(which pg_config) && \
Expand Down

0 comments on commit 3c0ab7c

Please sign in to comment.