fix for OAUTH_ENABLED check #17

Merged
jmakdah2 merged 1 commits from patch_5.1.1_release into main 2025-08-03 22:55:55 +00:00
Owner
No description provided.
jmakdah2 added 1 commit 2025-08-02 19:49:59 +00:00
fix for OAUTH_ENABLED check
Some checks failed
continuous-integration/drone/pr Build is failing
746413e31e
ammaratef45 approved these changes 2025-08-03 01:09:38 +00:00
decentral1se reviewed 2025-08-03 09:02:02 +00:00
@ -29,3 +29,1 @@
{{ if eq (env "OAUTH_ENABLED") "1" }}
file_env "OAUTH_APP_SECRET"
{{ end }}
if [ "$OAUTH_ENABLED" = "1" ]; then
Owner

Is there a reason you're not templating it? I would assume it would be better to stick to convention?

E.g.

compose.yml Lines 133 to 136 in 2744684292
app_entrypoint:
name: ${STACK_NAME}_app_entrypoint_${APP_ENTRYPOINT_VERSION}
file: entrypoint.sh.tmpl
template_driver: golang

The .tmpl in https://git.coopcloud.tech/coop-cloud/peertube/src/branch/main/entrypoint.sh.tmpl

Another one of our weird recipe-isms 😂

Is there a reason you're not templating it? I would assume it would be better to stick to convention? E.g. https://git.coopcloud.tech/coop-cloud/peertube/src/commit/2744684292d66053a9681ac57692b9f026863dde/compose.yml#L133-L136 The `.tmpl` in https://git.coopcloud.tech/coop-cloud/peertube/src/branch/main/entrypoint.sh.tmpl Another one of our weird recipe-isms 😂
Owner

Is this as simple as changing the file name to be end with .tmpl btw? @decentral1se

Is this as simple as changing the file name to be end with .tmpl btw? @decentral1se
Author
Owner

No reason, I was just working off of whatever was already there in the loomio recipe and didn't realize the convention is to have a .tmpl file for the entrypoint.

What are the benefits of it being a .tmpl file? Would you be ok with updating to .tmpl format in a separate change?

No reason, I was just working off of whatever was already there in the loomio recipe and didn't realize the convention is to have a .tmpl file for the entrypoint. What are the benefits of it being a .tmpl file? Would you be ok with updating to .tmpl format in a separate change?
Owner

@ammaratef45 @jmakdah2 The advantage of the .tmpl file is that you can inject values into it via the template engine (e.g. the {{ if eq (env "OAUTH_ENABLED") "1" }} syntax works). The .tmpl file naming is just convention also, the main thing required is the compose.yml snippet i shared in #17 (comment) where you specify the template_driver. It's ultimately up to y'all. I also have no strong feelings on how changes are done in this PR or whatever, up to you!

@ammaratef45 @jmakdah2 The advantage of the `.tmpl` file is that you can inject values into it via the template engine (e.g. the `{{ if eq (env "OAUTH_ENABLED") "1" }}` syntax works). The `.tmpl` file naming is just convention also, the main thing required is the `compose.yml` snippet i shared in https://git.coopcloud.tech/coop-cloud/loomio/pulls/17#issuecomment-25428 where you specify the `template_driver`. It's ultimately up to y'all. I also have no strong feelings on how changes are done in this PR or whatever, up to you!
Author
Owner

thanks @decentral1se, I agree would be better to stick to convention, but it doesn't feel like this is impacting us much now so I can look into updating it with another change or separately after this PR!

thanks @decentral1se, I agree would be better to stick to convention, but it doesn't feel like this is impacting us much now so I can look into updating it with another change or separately after this PR!
decentral1se marked this conversation as resolved
jmakdah2 merged commit a323593824 into main 2025-08-03 22:55:55 +00:00
Sign in to join this conversation.
No description provided.