Skip to content

Conversation

@GabriFedi97
Copy link
Contributor

@GabriFedi97 GabriFedi97 commented Jan 13, 2026

Add Dagger and Taskfile implementation to run Chainsaw e2e for extension images.

Closes #14

Signed-off-by: Gabriele Fedi <[email protected]>
Signed-off-by: Gabriele Fedi <[email protected]>
@GabriFedi97 GabriFedi97 marked this pull request as ready for review January 13, 2026 11:03
@GabriFedi97 GabriFedi97 requested review from a team and NiccoloFei as code owners January 13, 2026 11:03
GabriFedi97 and others added 2 commits January 13, 2026 12:25
Signed-off-by: Niccolò Fei <[email protected]>
Signed-off-by: Gabriele Bartolini <[email protected]>
@gbartolini
Copy link
Contributor

gbartolini commented Jan 19, 2026

I have looked at the instructions in the BUILD.md file, and I must confess I have not been able to complete my local testing experience, and stopped when generating values.

I was able to create the environment, build and push the images, but when I tried to generate the values for Chainsaw, it failed. Maybe I am not running the proper command:

$ task e2e:generate-values EXTENSION_IMAGE="localhost:5000/pgvector-testing:0.8.1-202601190453-18-trixie" TARGET=pgvector
task: Task "e2e:create-docker-network" is up to date
task: Task "e2e:start-container-registry" is up to date
task: [e2e:start-dagger-engine] docker run -d -v /var/lib/dagger --name dagger-engine-pg-extensions --restart always --network pg-extensions-e2e --privileged registry.dagger.io/engine:v0.19.8

[e2e:start-dagger-engine] 7ba8ecbbc26bf5d92837c8a7bf2b3808a794104e4e694b8f792437fd9aeab7a0
[prereqs] Checking prerequisites...
[prereqs] All prerequisites satisfied!
task: [generate-values] echo -e "\033[0;34mGenerating values for target pgvector...\033[0m"
[generate-values-pgvector] Generating values for target pgvector...
task: [generate-values] dagger call -sm ./dagger/maintenance/ generate-testing-values --target pgvector --extension-image="registry.pg-extensions:5000/pgvector-testing:0.8.1-202601190453-18-trixie" export --path pgvector/values.yaml

[generate-values-pgvector]
[generate-values-pgvector] Error: Get "https://registry.pg-extensions:5000/v2/": dial tcp: lookup registry.pg-extensions on 10.87.0.1:53: no such host; Get "http://registry.pg-extensions:5000/v2/": dial tcp: lookup registry.pg-extensions on 10.87.0.1:53: no such host [traceparent:6a563035a6e379eb34ddc16a8c66ab52-5d9c3c5bcc40cd24]
task: Failed to run task "e2e:generate-values": task: Failed to run task "generate-values": exit status 1

In the meantime, I have reorganised the BUILD.md file a bit.

/cc @GabriFedi97 @NiccoloFei

@GabriFedi97
Copy link
Contributor Author

@gbartolini that was due to a missing definition of an env variable in the e2e:generate-values Taskfile entry. I pushed a commit to address that, now it should work.

Copy link
Contributor

@mbiagetti mbiagetti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tested latest fix and I'm able to generate testing data too

(⎈|kind-pg-extensions-1.34.2:N/A)➜  postgres-extensions-containers git:(dev/14) task e2e:generate-values EXTENSION_IMAGE="localhost:5000/pgvector-testing:0.8.1-202601191006-18-trixie" TARGET=pgvector

task: Task "e2e:create-docker-network" is up to date
task: Task "e2e:start-dagger-engine" is up to date
task: Task "e2e:start-container-registry" is up to date
[prereqs] Checking prerequisites...
[prereqs] All prerequisites satisfied!
task: [generate-values] echo -e "\033[0;34mGenerating values for target pgvector...\033[0m"
[generate-values-pgvector] Generating values for target pgvector...
task: [generate-values] dagger call -sm ./dagger/maintenance/ generate-testing-values --target pgvector --extension-image="registry.pg-extensions:5000/pgvector-testing:0.8.1-202601191006-18-trixie" export --path pgvector/values.yaml

[generate-values-pgvector]
[generate-values-pgvector] /Users/matteobiagetti/EnterpriseDB/postgres-extensions-containers/pgvector/values.yaml

Then test with

task e2e:export-kubeconfig KUBECONFIG_PATH=./kubeconfig INTERNAL=true
task e2e:test TARGET=pgvector KUBECONFIG_PATH="./kubeconfig"

@gbartolini
Copy link
Contributor

I have tried the whole process. While this is fine for now, I suggest that we create a single command that wraps the entire process for a single extension. It is quite cumbersome and error-prone to ask users to repeat the single steps (build, generate-values and test). Especially the generate values step is hard to understand if you are not familiar with the way Chainsaw works (like me).

Ideally, a user would have a new extension or their own extension to test. They need to launch two commands:

  • setup of the local env
  • a build+test command that transparently builds the image, places the image into the values file and runs the test

I am mergin this intermediate patch.

@gbartolini gbartolini merged commit 9d8ef22 into cloudnative-pg:main Jan 19, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Enable local testing of an extension image

4 participants