Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-59471

app/sidecar.py tries to process resources of multiple jenkins deployments

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Not A Defect
    • Icon: Major Major
    • kubernetes-plugin
    • None
    • Jenkins: 2.176.3
      kubernetes plugin: 1.19.0
      k8s: 1.12.1
      helm.sh/chart: jenkins-1.5.0
      image: jenkins/jenkins:lts
      image: shadwell/k8s-sidecar:0.0.2

      I deployed two instances of jenkins using the helm/stable/jenkins chart in the same namespace. The release names are modest-lionfish (test instance) and melting-manatee (producion instance).  The sidecar logs show the python script trying to process the configmaps of both releases. I assumed the script should handle the existence of resources from multiple releases. Feel free to close if this is as designed.

      kp logs melting-manatee-jenkins-848cc67cf6-77rv8 jenkins-sc-config
      2019-09-22 00:28:08 INFO Starting config map collector
      2019-09-22 00:28:08 INFO label is: melting-manatee-jenkins-jenkins-config
      2019-09-22 00:28:08 INFO targetFolder is: /var/jenkins_home/casc_configs
      2019-09-22 00:28:08 INFO Config for cluster api loaded...
      2019-09-22 00:28:08 INFO namespace is: production
      2019-09-22 00:28:08 INFO ssh_port is: 1044
      2019-09-22 00:28:08 INFO admin_user is: replaceme
      2019-09-22 00:28:08 INFO Jenkins is contactable, continuing.
      2019-09-22 00:28:09 INFO Working on configmap production/modest-lionfish-jenkins
      2019-09-22 00:28:09 INFO Working on configmap production/modest-lionfish-jenkins
      2019-09-22 00:28:09 INFO Working on configmap production/modest-lionfish-jenkins-jenkins-config-environment-settings
      2019-09-22 00:28:09 INFO Working on configmap production/modest-lionfish-jenkins-jenkins-config-environment-settings
      2019-09-22 00:28:09 INFO Working on configmap production/modest-lionfish-jenkins-jenkins-config-welcome-message
      2019-09-22 00:28:09 INFO Working on configmap production/modest-lionfish-jenkins-jenkins-config-welcome-message
      2019-09-22 00:28:09 INFO Working on configmap production/melting-manatee-jenkins-jenkins-config-unclassified-settings
      2019-09-22 00:28:09 INFO Working on configmap production/melting-manatee-jenkins-jenkins-config-unclassified-settings
      2019-09-22 00:28:09 INFO Configmap with label found
      2019-09-22 00:28:09 INFO File in configmap unclassified-settings.yaml ADDED
      Traceback (most recent call last):
      File "/app/sidecar.py", line 190, in <module>
      main()
      File "/app/sidecar.py", line 185, in main
      ssh_port)
      File "/app/sidecar.py", line 123, in watchForChanges
      jenkinsReloadConfig(admin_private_key, admin_user, ssh_port, logger)
      File "/app/sidecar.py", line 22, in jenkinsReloadConfig
      ssh_client.connect('127.0.0.1', port=ssh_port, username=admin_user, pkey=private_key)
      File "/usr/local/lib/python3.6/site-packages/paramiko/client.py", line 437, in connect
      passphrase,
      File "/usr/local/lib/python3.6/site-packages/paramiko/client.py", line 749, in _auth
      raise saved_exception
      File "/usr/local/lib/python3.6/site-packages/paramiko/client.py", line 649, in _auth
      self._transport.auth_publickey(username, pkey)
      File "/usr/local/lib/python3.6/site-packages/paramiko/transport.py", line 1507, in auth_publickey
      return self.auth_handler.wait_for_response(my_event)
      File "/usr/local/lib/python3.6/site-packages/paramiko/auth_handler.py", line 250, in wait_for_response
      raise e
      paramiko.ssh_exception.AuthenticationException: Authentication failed.

            Unassigned Unassigned
            bassplay3r David Bellizzi
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: