Skip to content
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

Set GH_APP similar to other environment vars in start-nginx.sh #2711

Open
imnotjames opened this issue Mar 18, 2024 · 3 comments · May be fixed by #2712
Open

Set GH_APP similar to other environment vars in start-nginx.sh #2711

imnotjames opened this issue Mar 18, 2024 · 3 comments · May be fixed by #2712
Labels
bug Something isn't working Low Low Priority Issues (to be fixed or re-evaluated in 12 months Self-hosted Self-hosted

Comments

@imnotjames
Copy link

📣 Feedback / 🐛 Bugs

When setting up the codecov frontend, GH_APP isn't easy to specify. This means that users with non-codecov github apps won't be able to add new organizations.

codecov/self-hosted#22

Either we can do the string replace patching in start-nginx somehow (A little tricker since codecov as a string is pretty ubiquitous) or find a way to inject window.configEnv during start-nginx.

Is there a preferable path for anyone else?

@imnotjames
Copy link
Author

imnotjames commented Mar 18, 2024

To do the sed patching it'd be something like..

GITHUB_APP_BASE=${CODECOV_GITHUB_APP_SEARCH:=codecov}
if [ -n "${CODECOV_GITHUB_APP}" ]; then
  echo "Replacing Github App ${GITHUB_APP_BASE} for ${CODECOV_GITHUB_APP}"
  sed -i "s/GH_APP:\"${GH_APP_BASE}\"/GH_APP:\"${CODECOV_GITHUB_APP}\"/g" /var/www/app/gazebo/static/js/main.*
fi

I can open a PR but I'm not sure if that's the desired path forward.

@imnotjames
Copy link
Author

To make things faster I'll just open with that. After a bit of testing it seems to work fine and shouldn't have too many side effects. (As much as I think injecting window.configEnv is a better feature)

@thomasrockhu-codecov thomasrockhu-codecov added the bug Something isn't working label Apr 23, 2024
@thomasrockhu-codecov thomasrockhu-codecov added wontfix This will not be worked on and removed wontfix This will not be worked on labels Oct 10, 2024
@thomasrockhu-codecov
Copy link
Contributor

@thomasrockhu-codecov to add Low, Self-hosted labels

@thomasrockhu-codecov thomasrockhu-codecov added Self-hosted Self-hosted Low Low Priority Issues (to be fixed or re-evaluated in 12 months labels Oct 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Low Low Priority Issues (to be fixed or re-evaluated in 12 months Self-hosted Self-hosted
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants