jenkins-x-charts / environment-controller

kubernetes controller for environments, handles deployments via gitops webhook events
Apache License 2.0
2 stars 13 forks source link

Can't start environment controller #64

Open Goodsmileduck opened 5 years ago

Goodsmileduck commented 5 years ago

installed it using the command:

jx create addon envctl -s https://github.com/Goodsmileduck/environment-jx-digitalocean

but it didn't work

kubectl -n jx logs environment-controller-7f9b56998b-krx97
using require GitHub headers: true
using environment source directory https://github.com/Goodsmileduck/environment-jx-digitalocean and external webhook URL: http://174.138.106.243/
verifying that the webhook is registered for the git repository https://github.com/Goodsmileduck/environment-jx-digitalocean
error: failed to create git provider for git URL https://github.com/Goodsmileduck/environment-jx-digitalocean kind github: Running in batch mode and no default API token found

Kubernetes cluster on digitalocean

apiloqbc commented 5 years ago

Same error. just a note: in the doc page the -s parameter has the suffix .git in the url.

In my case I also used the parameters:

--user myuser --token mytoken

I also checked the secrets and it has the correct user / token provided in the command above. What I found strange are his parameters:

Namespace:    jx
Labels:       jenkins.io/chart-release=jxet
              jenkins.io/created-by=jx
              jenkins.io/credentials-type=usernamePassword
              jenkins.io/kind=git
              jenkins.io/namespace=jx
              jenkins.io/service-kind=github
              jenkins.io/version=0.0.92
Annotations:  jenkins.io/chart: environment-controller
              jenkins.io/credentials-description: API Token for acccessing git for GitOps
              jenkins.io/name: Git
              jenkins.io/url: https://github.com

Type:  Opaque

Data
====
password:  40 bytes
username:  9 bytes

the password contains the token provided?! is it correct? jenkins.io/credentials-type=usernamePassword is correct?

apiloqbc commented 5 years ago

there is probably an issue in the command line tool:

jx create addon envctl

if I use directly the hel the controller runs without errors.