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

Deploying git2consul in Kubernetes #5

Open
cdelpinogeo opened this issue Oct 17, 2016 · 10 comments
Open

Deploying git2consul in Kubernetes #5

cdelpinogeo opened this issue Oct 17, 2016 · 10 comments

Comments

@cdelpinogeo
Copy link

cdelpinogeo commented Oct 17, 2016

Hello,

I am trying to deploy the docker-git2consul container to kubernetes, but I have been unsuccessful in doing so. I am getting the following error when I try to deploy it:

2016-10-17T20:55:12.227582278Z Config value is not valid JSON: undefined

Here is the yaml file I created to deploy to kubernetes:

apiVersion: v1
kind: ReplicationController
metadata:
  name: git2consul
  labels:
    app: git2consul
spec:
  replicas: 1
  template:
    metadata:
      labels:
        app: git2consul
    spec:
      containers:
      - name: git2consul
        image: cimpress/git2consul
        env:
        - name: config_file
          value: '{"version":"1.0","repos [{"name":"config","url":"https://user:[email protected]:org/repo.git","branches":["master"],"hooks":[{"type":"polling","interval":"1"}]}]}'
        - name: endpoint
          value: "10.244.4.241"
        - name: port
          value: "8500"
@cdelpinogeo
Copy link
Author

I got a little further this time. I am now getting this error:

2016-10-17T21:10:29.972503690Z { [Error: consul: kv.get: connect ECONNREFUSED]
2016-10-17T21:10:29.972553323Z   code: 'ECONNREFUSED',
2016-10-17T21:10:29.972565137Z   errno: 'ECONNREFUSED',
2016-10-17T21:10:29.972593579Z   syscall: 'connect' }

@calvn
Copy link
Contributor

calvn commented Oct 18, 2016

This is probably due to the endpoint and/or port being incorrect, or the pod/node not having connectivity to the consul cluster.

@cnighojkar
Copy link

I too got the same issue , my endpoints are also correct.
any update o this?

@calvn
Copy link
Contributor

calvn commented May 4, 2017

Are you able to test running git2consul directly on the kube host (i.e. running the binary and not inside a container), connecting to the same endpoints?

@vigneshsenapathy
Copy link

@calvn : i am trying to get this working with ECS and i am getting the same error as @cdelpinogeo. can u tell me how i can pass the json file to the container. Also do i need to provide the gitlab/github user name and passworrd

@vigneshsenapathy
Copy link

@calvn i fixed the issue.. i had to add some ssh stuff

@zmjung
Copy link

zmjung commented Jun 19, 2018

is it because config_file should be config-file?

@vigneshsenapathy
Copy link

@zmjung : its config-file

@zmjung
Copy link

zmjung commented Jun 20, 2018

@vigneshsenapathy His yaml has the env variable as config_file

@asoleimanibo
Copy link

Do you think "ReplicationController" kind is suitable for git2consul?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants