-
Notifications
You must be signed in to change notification settings - Fork 31
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
[Docs] Add Docker COPY from Example #31
Comments
Ideally, create a FROM postgres:latest
COPY --from=ghcr.io/fboulnois/pg_uuidv7:1.5.0-extension /PGEXTENSION/${PG_MAJOR} / Where that tree under |
Edit: maybe it's not exactly what was asked for, leaving it here anyways. if you need this alongside other extensions, it might not be the most ergonomic way of doing it, but it does work. Hey there, while I'm not the maintainer for this extension, I did see this and figured this could be done pretty easily. Here's an example I put together
I'm using this alongside Docker Compose, so I've got the environment variables that Postgres needs during setup defined there instead of in this Dockerfile. That looks like this:
|
Here are two other ways to accomplish this directly using the ghcr.io image. v1:
v2:
|
@fboulnois I am doing the V2, but I wish I didn't have to know all file names (for example, 1.5.sql may change in the future) and there was a "safe" way to copy everything into my existing container. Therefore, the files under a given directory must be clean and only include the extension-required code; otherwise, the container that was built may unintentionally override things. I know I am asking for extra work on your end (I can try to contribute with your support to the feature), but honestly, the ecosystem would benefit from this. I am just learning about so many tools to manage PG Extensions that barely take advantage of Docker. |
closes [Docs] Add Docker COPY from Example fboulnois#31 Signed-off-by: Yordis Prieto <[email protected]>
closes fboulnois#31 Signed-off-by: Yordis Prieto <[email protected]>
I made a PR showcasing more and less what I mean. Hopefully, I set the CI correctly! |
Hey there, I wonder if we could "merge" the
pg_uuidv7
image into the base image.I have other extension requirements aside from
pg_uuidv7
, and I am hoping that such a pattern becomes familiar enough so Extension Authors could provide a straightforward image toCOPY
from instead of relying on tools likepgxn
orpgxman
, or deal with "complex" (unfamiliar) installations steps and instead take advantage of Official Docker Image.I appreciate any help you can provide.
The text was updated successfully, but these errors were encountered: