Skip to content

Commit

Permalink
release: pg_idkit 0.2.1
Browse files Browse the repository at this point in the history
Signed-off-by: GitHub <[email protected]>
  • Loading branch information
t3hmrman committed Dec 19, 2023
1 parent f84f8f9 commit 44d419e
Show file tree
Hide file tree
Showing 7 changed files with 34 additions and 21 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/build-and-test-gnu/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ runs:
PGRX_PKG_PATH_PREFIX: ${{ inputs.cargo-target-dir }}
PKG_PG_VERSION: ${{ inputs.pg-version }}
SCCACHE_DIR: ${{ inputs.sccache-dir }}
USER: ${{ inputs.user }}
DOCKER_BUILD_USER: ${{ inputs.user }}
run: |
su idkit -c "cargo install --force cargo-get cargo-edit"
Expand All @@ -146,7 +146,7 @@ runs:
PGRX_PKG_PATH_PREFIX: ${{ inputs.cargo-target-dir }}
PKG_PG_VERSION: ${{ inputs.pg-version }}
SCCACHE_DIR: ${{ inputs.sccache-dir }}
USER: ${{ inputs.user }}
DOCKER_BUILD_USER: ${{ inputs.user }}
run: |
su idkit -c "just pgrx-init"
Expand All @@ -163,7 +163,7 @@ runs:
PGRX_PKG_PATH_PREFIX: ${{ inputs.cargo-target-dir }}
PKG_PG_VERSION: ${{ inputs.pg-version }}
SCCACHE_DIR: ${{ inputs.sccache-dir }}
USER: ${{ inputs.user }}
DOCKER_BUILD_USER: ${{ inputs.user }}
run: |
su idkit -c "cargo check"
Expand All @@ -180,7 +180,7 @@ runs:
PGRX_PKG_PATH_PREFIX: ${{ inputs.cargo-target-dir }}
PKG_PG_VERSION: ${{ inputs.pg-version }}
SCCACHE_DIR: ${{ inputs.sccache-dir }}
USER: ${{ inputs.user }}
DOCKER_BUILD_USER: ${{ inputs.user }}
run: |
su idkit -c "cargo build"
Expand All @@ -196,7 +196,7 @@ runs:
PGRX_PG_VERSION: ${{ inputs.pgrx-pg-version }}
PKG_PG_VERSION: ${{ inputs.pg-version }}
SCCACHE_DIR: ${{ inputs.sccache-dir }}
USER: ${{ inputs.user }}
DOCKER_BUILD_USER: ${{ inputs.user }}
run: |
su idkit -c "cargo test"
Expand All @@ -219,7 +219,7 @@ runs:
PKG_PG_VERSION: ${{ inputs.pg-version }}
PKG_TARBALL_SUFFIX: ${{ inputs.artifact-tarball-suffix }}
SCCACHE_DIR: ${{ inputs.sccache-dir }}
USER: ${{ inputs.user }}
DOCKER_BUILD_USER: ${{ inputs.user }}
run: |
su idkit -c "just package"
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/build-rpm/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ inputs:
default: 16.1
decription: |
Postgres version (ex. '15.5, '16.1')
user:
type: string
default: runner
outputs: {}
runs:
using: "composite"
Expand Down Expand Up @@ -61,6 +64,7 @@ runs:
- name: Build RPM
shell: bash
env:
DOCKER_BUILD_USER: ${{ inputs.user }}
PGRX_PG_VERSION: ${{ inputs.pgrx-pg-version }}
PKG_PG_VERSION: ${{ inputs.pg-version }}
run: just package build-rpm
Expand All @@ -69,6 +73,7 @@ runs:
id: rpm-output
shell: bash
env:
DOCKER_BUILD_USER: ${{ inputs.user }}
PGRX_PG_VERSION: ${{ inputs.pgrx-pg-version }}
PKG_PG_VERSION: ${{ inputs.pg-version }}
run: |
Expand Down
20 changes: 12 additions & 8 deletions .github/workflows/container.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,18 +46,22 @@ jobs:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build container image
run: just build-image
- name: Build container image (prerelease)
if: ${{ startsWith(github.ref, 'refs/heads/prep-release') }}
run: just build-image push-image
env:
CONTAINER_IMAGE_ARCH: ${{ matrix.config.container.arch }}
PGRX_PG_VERSION: ${{ matrix.config.container.pg_version }}
POSTGRES_IMAGE_VERSION: ${{ matrix.config.container.pg_version }}
POSTGRES_OS_IMAGE_VERSION: ${{ matrix.config.container.os_version }}
PGIDKIT_IMAGE_TAG_SUFFIX: "-prerelease"

- name: Push pre-release image
if: ${{ startsWith(github.ref, 'refs/heads/prep-release') }}
run: just push-image-preprelease

- name: Push release image
- name: Build container image
if: ${{ startsWith(github.ref, 'refs/tags/v') }}
run: just push-image
run: just build-image push-image
env:
CONTAINER_IMAGE_ARCH: ${{ matrix.config.container.arch }}
PGRX_PG_VERSION: ${{ matrix.config.container.pg_version }}
POSTGRES_IMAGE_VERSION: ${{ matrix.config.container.pg_version }}
POSTGRES_OS_IMAGE_VERSION: ${{ matrix.config.container.os_version }}

7 changes: 7 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
# Changelog
All notable changes to this project will be documented in this file.

## [0.2.1] - 2023-12-19

### Bug Fixes

- Fix release prep PR title
- Container generation and workflows

## [0.2.0] - 2023-12-12

### Bug Fixes
Expand Down
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "pg_idkit"
version = "0.2.0"
version = "0.2.1"
edition = "2021"
authors = ["Victor Adossi <[email protected]>"]
license = "MIT"
Expand Down
7 changes: 2 additions & 5 deletions Justfile
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,8 @@ pg_os_image_version := env_var_or_default("POSTGRES_OS_IMAGE_VERSION", "alpine3.

pgidkit_image_name := env_var_or_default("PGIDKIT_IMAGE_NAME", "ghcr.io/vadosware/pg_idkit")
pgidkit_image_tag := env_var_or_default("POSGRES_IMAGE_VERSION", version + "-" + "pg" + pg_image_version + "-" + pg_os_image_version + "-" + container_img_arch)
pgidkit_image_name_full := env_var_or_default("PGIDKIT_IMAGE_NAME_FULL", pgidkit_image_name + ":" + pgidkit_image_tag)
pgidkit_image_tag_suffix := env_var_or_default("PGIDKIT_IMAGE_TAG_SUFFIX", "")
pgidkit_image_name_full := env_var_or_default("PGIDKIT_IMAGE_NAME_FULL", pgidkit_image_name + ":" + pgidkit_image_tag + pgidkit_image_tag_suffix)
pgidkit_dockerfile_path := env_var_or_default("PGIDKIT_DOCKERFILE_PATH", "infra" / "docker" / pgidkit_image_tag + ".Dockerfile")

docker_password_path := env_var_or_default("DOCKER_PASSWORD_PATH", "secrets/docker/password.secret")
Expand Down Expand Up @@ -232,10 +233,6 @@ push-base-pkg-image:
build-image:
{{docker}} build {{docker_platform_arg}} {{docker_progress_arg}} -f {{img_dockerfile_path}} -t {{pgidkit_image_name_full}} --build-arg USER={{docker_build_user}} --build-arg PGIDKIT_REVISION={{revision}} --build-arg PGIDKIT_VERSION={{pgidkit_image_tag}} .

# Push the pre-release docker image for pg_idkit
push-image-prerelease:
{{docker}} push {{pgidkit_image_name_full}}-prerelease

# Push the docker image for pg_idkit
push-image:
{{docker}} push {{pgidkit_image_name_full}}
Expand Down

0 comments on commit 44d419e

Please sign in to comment.