-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Ability to set env vars in project admin #3992
Comments
@humitos what do you think of this feature + pypa/pip#3728 to support private repositories through pip? Maybe there is a way to also address git submodules? It feels a bit hacky still. A GitHub user looks to be the prescribed path, as much as i hate it. |
I like this because it's not something that we are hacking to support but it comes from upstream and also because it seems pretty easy to do, follow and understand what's happening.
Do you see any potential problem by exposing all the ENV vars to all the commands? I see as cons that we may end up sending secret data to places that should not be sent. On the other hand, as pros I think this will help users to expand other commands that we don't think to be expandable when implementing this: I see this a way of "allowing things from outside". For example, you can run custom code in But, if we don't want to expose all the ENV to all the commands we could match the ENV to a particular command: class EnvVariable(models.Model):
command = models.ChoiceField(choices=['sphinx-build', 'pip', 'git', ...])
name = models.CharField()
value = models.CharField()
project = models.ForeignKey(Project) with that model we could inject the variables only where they are needed. If it's a
This case is a little more complex to me. I found that what some CI do is to modify the submodule URL on the fly with a config withtout touching the user configs using |
Adding this link that contains useful information about how travis handles this: https://docs.travis-ci.com/user/best-practices-security/#Steps-Travis-CI-takes-to-secure-your-data |
I'd be -1 on this is think, it's too complex for the user. |
We can disregard the SSH use case for now. Users will potentially be able to use this for accessing GitHub, but it's multiple levels of bad UX at this point. |
Which pattern do we want to follow here?
I think it's clearer the one from Integrations. |
Yeah, integrations is more recent, it's the pattern to follow. |
This is now done. 🎉 |
We should allow users to inject env vars that can be maintained outside of source code. The use case here would be inputting shared secrets like API access tokens which would then be injected into the build processes. Heroku does something similar.
Eventually, we might auto generate an auth token for our api and inject this in the same way, so that Sphinx can automatically have access to our API as the user. This particular feature will likely be an API v3 feature though.
Phase I
Phase II
The text was updated successfully, but these errors were encountered: