You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openserverless.apache.org by "mobs75 (via GitHub)" <gi...@apache.org> on 2026/08/20 16:11:09 UTC

[I] OPERATOR_IMG hardcoded via awk in Dockerfile blocks clean builds from a fork [openserverless]

mobs75 opened a new issue, #221:
URL: https://github.com/apache/openserverless/issues/221

   The operator image name is extracted via `awk` from the Dockerfile (`ARG OPERATOR_IMAGE_DEFAULT=...`) instead of being parameterized, which prevents clean builds from a fork without a manual workaround.
   
   Current workaround:
   ```
   OPERATOR_IMG=ghcr.io/<fork>/openserverless-operator task build
   docker tag ghcr.io/<fork>/openserverless-operator:<tag> <expected-namespace>/openserverless-operator:<tag>
   ```
   
   It would help contributors working from forks if `OPERATOR_IMG` were a proper Taskfile variable with a sane default, rather than being derived by parsing the Dockerfile with awk.
   
   (Relevant files: `olaris-op/Dockerfile`, Taskfile build target.)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@openserverless.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] OPERATOR_IMG hardcoded via awk in Dockerfile blocks clean builds from a fork [openserverless]

Posted by "sciabarracom (via GitHub)" <gi...@apache.org>.
sciabarracom commented on issue #221:
URL: https://github.com/apache/openserverless/issues/221#issuecomment-5358642931

   you can overwtite it witn an env yi MY_OPERATOR_IMG


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@openserverless.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] OPERATOR_IMG hardcoded via awk in Dockerfile blocks clean builds from a fork [openserverless]

Posted by "d4rkstar (via GitHub)" <gi...@apache.org>.
d4rkstar closed issue #221: OPERATOR_IMG hardcoded via awk in Dockerfile blocks clean builds from a fork
URL: https://github.com/apache/openserverless/issues/221


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@openserverless.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] OPERATOR_IMG hardcoded via awk in Dockerfile blocks clean builds from a fork [openserverless]

Posted by "mobs75 (via GitHub)" <gi...@apache.org>.
mobs75 commented on issue #221:
URL: https://github.com/apache/openserverless/issues/221#issuecomment-5369318515

   Yes, please go ahead and close it. Confirmed the MY_OPERATOR_IMAGE mechanism works as expected, thanks again for the pointer.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@openserverless.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] OPERATOR_IMG hardcoded via awk in Dockerfile blocks clean builds from a fork [openserverless]

Posted by "mobs75 (via GitHub)" <gi...@apache.org>.
mobs75 commented on issue #221:
URL: https://github.com/apache/openserverless/issues/221#issuecomment-5369212673

   Thanks, that's clear now! Tested MY_OPERATOR_IMAGE=ghcr.io/mobs75/openserverless-operator task b:build --dry from inside olaris-op and it produces exactly the right docker build command with my fork's image name and tag. Much cleaner than the two-step workaround I was using before (build then manual docker tag). Thanks for pointing me to TaskfileBuild.yml, I'd never checked that one.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@openserverless.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] OPERATOR_IMG hardcoded via awk in Dockerfile blocks clean builds from a fork [openserverless]

Posted by "mobs75 (via GitHub)" <gi...@apache.org>.
mobs75 commented on issue #221:
URL: https://github.com/apache/openserverless/issues/221#issuecomment-5368896283

   Thanks Michele! Just double-checked and I don't see `MY_OPERATOR_IMG` referenced anywhere in the repo (searched the whole tree including all submodules). Did you mean the CLI-style override I've been using as a workaround — `OPERATOR_IMG=ghcr.io/mobs75/openserverless-operator task build`? That one does work today. If `MY_OPERATOR_IMG` is something you're planning to add, happy to help wire it up.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@openserverless.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] OPERATOR_IMG hardcoded via awk in Dockerfile blocks clean builds from a fork [openserverless]

Posted by "d4rkstar (via GitHub)" <gi...@apache.org>.
d4rkstar commented on issue #221:
URL: https://github.com/apache/openserverless/issues/221#issuecomment-5369143042

   Hi @mobs75 some clarifications.
   
   The build task in [Taskfile.yml](https://github.com/apache/openserverless-operator/blob/7337d43fa7d4f16aff81c712c701805f758aa8e0/Taskfile.yml#L382)  is related to kaniko build: but this is not used to build on Docker, but on k3s (and also for k3s seems not to work properly and it requires some fixes for sure).
   
   However, to build on Docker, you should user tasks with `b:` prefix from [TaskfileBuild.yml](https://github.com/apache/openserverless-operator/blob/7337d43fa7d4f16aff81c712c701805f758aa8e0/TaskfileBuild.yml#L37)
   
   If you see there is a `MY_OPERATOR_IMAGE` env that you can set to override the image. This is then passed to the build via build args:
   
   ```
   build: 
       - >
         docker build .
         -t ${MY_OPERATOR_IMAGE:-{{.OPERATOR_IMAGE}}}:{{.OPERATOR_TAG}}
         --build-arg OPERATOR_IMAGE_DEFAULT=${MY_OPERATOR_IMAGE:-{{.OPERATOR_IMAGE}}}
         --build-arg OPERATOR_TAG_DEFAULT={{.OPERATOR_TAG}}  --load
   ```
   
   Hope I've answered to your question
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@openserverless.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] OPERATOR_IMG hardcoded via awk in Dockerfile blocks clean builds from a fork [openserverless]

Posted by "d4rkstar (via GitHub)" <gi...@apache.org>.
d4rkstar commented on issue #221:
URL: https://github.com/apache/openserverless/issues/221#issuecomment-5369232625

   If it's ok, can I close this issue?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@openserverless.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org