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

allow environment variables to be added to git-init containers #1328

Closed
jstrachan opened this issue Sep 18, 2019 · 7 comments
Closed

allow environment variables to be added to git-init containers #1328

jstrachan opened this issue Sep 18, 2019 · 7 comments
Labels
kind/feature Categorizes issue or PR as related to a new feature.

Comments

@jstrachan
Copy link

Expected Behavior

Provide some way (e.g. a ConfigMap?) to be able to add additional environment variables to the git-init container step

Actual Behavior

Some folks are evaluating Jenkins X + tekton on an internal gitlab which doesn't have a proper public certificate and the first git-init step generated by tekton is failing with SSL certificate problem: unable to get local issuer certificate errors.

It would be good to be able to configure tekton to add an environment variable to this step - e.g.
GIT_SSL_NO_VERIFY=true. From noodling the code I don't see a way to add environment variables without hacking the go source.

I guess a workaround for now is to build a custom git-init image with different env vars inside; but would be nice to make this more easily configurable

@vdemeester
Copy link
Member

/kind feature

So this is doable using StepTemplate in a Task but I don't think it applies to internal init container…

@tekton-robot tekton-robot added the kind/feature Categorizes issue or PR as related to a new feature. label Sep 20, 2019
@abayer
Copy link
Contributor

abayer commented Sep 24, 2019

The git clone step isn't run as an init container, but it is an internal step added by the git resource.

@berbiera
Copy link

Hi
Any update on that feature ? Is that feasible to integrate the variable ? We are waiting on that feature.
Thanks guys

@ravenchilde
Copy link

Also waiting on this, our Corp uses our own CA to sign the Git repo certificate. Our machines and servers all have this CA loaded, but I can't find a reasonable way to make Jenkins-X work with this.

@ghost
Copy link

ghost commented Feb 19, 2020

For sslVerify specifically we already have that parameterized. It's the sslVerify param mentioned here: https://github.com/tektoncd/pipeline/blob/master/docs/resources.md#git-resource

When sslVerify is set to false the git resource will tell git to ignore certificate errors.

@ravenchilde
Copy link

For sslVerify specifically we already have that parameterized. It's the sslVerify param mentioned here: https://github.com/tektoncd/pipeline/blob/master/docs/resources.md#git-resource

When sslVerify is set to false the git resource will tell git to ignore certificate errors.

Fantastic news... now... can I figure out where to configure that in Jenkins-X... 🤓

@ghost
Copy link

ghost commented Mar 20, 2020

I'm going to close this as fixed. I believe it's very closely related to #1663 which is now supported thanks to @pritidesai !

@ghost ghost closed this as completed Mar 20, 2020
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature Categorizes issue or PR as related to a new feature.
Projects
None yet
Development

No branches or pull requests

6 participants