Skip to content

Commit 86ba8d8

Browse files
committed
chore: more setup for staging AMI
1 parent 9ad5b69 commit 86ba8d8

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

.github/workflows/ami-release-nix.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
- name: Set PostgreSQL versions
3131
id: set-versions
3232
run: |
33-
VERSIONS=$(nix run nixpkgs#yq -- eval '.postgres_major[]' ansible/vars.yml | jq -R -s -c 'split("\n")[:-1]')
33+
VERSIONS=$(nix run nixpkgs#yq -- '.postgres_major[]' ansible/vars.yml | nix run nixpkgs#jq -- -R -s -c 'split("\n")[:-1]')
3434
echo "postgres_versions=$VERSIONS" >> $GITHUB_OUTPUT
3535
3636
build:
@@ -64,7 +64,7 @@ jobs:
6464
- name: Run checks if triggered manually
6565
if: ${{ github.event_name == 'workflow_dispatch' }}
6666
run: |
67-
SUFFIX=$(nix run nixpkgs#yq -- eval '.postgres_release["postgres${{ matrix.postgres_version }}"]' ansible/vars.yml | sed -E 's/[0-9\.]+(.*)$/\1/')
67+
SUFFIX=$(nix run nixpkgs#yq -- '.postgres_release["postgres${{ matrix.postgres_version }}"]' ansible/vars.yml | sed -E 's/[0-9\.]+(.*)$/\1/')
6868
if [[ -z $SUFFIX ]] ; then
6969
echo "Version must include non-numeric characters if built manually."
7070
exit 1
@@ -75,7 +75,7 @@ jobs:
7575

7676
- name: Generate common-nix.vars.pkr.hcl
7777
run: |
78-
PG_VERSION=$(nix run nixpkgs#yq -- eval '.postgres_release["postgres${{ matrix.postgres_version }}"]' ansible/vars.yml)
78+
PG_VERSION=$(nix run nixpkgs#yq -- '.postgres_release["postgres${{ matrix.postgres_version }}"]' ansible/vars.yml)
7979
echo "postgres-version = \"$PG_VERSION\"" > common-nix.vars.pkr.hcl
8080
8181
- name: Build AMI stage 1

ansible/vars.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ postgres_major:
1111

1212
# Full version strings for each major version
1313
postgres_release:
14-
postgres15: "15.8.1.003"
15-
postgres16: "16.3.1.000"
14+
postgres15: "15.8.1.003-staging"
15+
postgres16: "16.3.1.000-staging"
1616

1717
# Non Postgres Extensions
1818
pgbouncer_release: "1.19.0"

stage2-nix-psql.pkr.hcl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ packer {
5656
}
5757

5858
source "amazon-ebs" "ubuntu" {
59-
ami_name = "${var.ami_name}-${var.postgres-version}-staging"
59+
ami_name = "${var.ami_name}-${var.postgres-version}"
6060
instance_type = "c6g.4xlarge"
6161
region = "${var.region}"
6262
source_ami_filter {

0 commit comments

Comments
 (0)