Closed q131172019 closed 4 years ago
I'm working on a better fix for this, but a quick workaround is to clone your dev env repo locally and run jx boot
from in it - it'll recreate the secret properly. But before you do that, could you do a kubectl get service
and see if there's a hook
service? Thanks.
I'm working on a better fix for this, but a quick workaround is to clone your dev env repo locally and run
jx boot
from in it - it'll recreate the secret properly.
Good to know. I will create new AWS EKS cluster to try this quick workaround. Last night I had rolled back to jx-v2.0.1258 + jenkins-x-versions-v1.0.406 to move forward to set up Jenkins X CI/CD pipeline environment and tested successfully for our PHP applications due to tight schedule of my project.
But before you do that, could you do a
kubectl get service
and see if there's ahook
service? Thanks.
There is no hook
service when I run kubectl get service
command. I know if I choose "stateless"
type (Prow + Tekton) installation, the service 'hook' as part of Prow should be running. This weekend I will test whether newest fix resolves the issue. Thanks for your quick response and quick fix!
IT-SEA17490-MBP:~ q1447100$ kg services
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
exdns-external-dns ClusterIP 172.20.57.34 <none> 7979/TCP 13h
heapster ClusterIP 172.20.239.250 <none> 8082/TCP 13h
jenkins ClusterIP 172.20.168.79 <none> 8080/TCP 13h
jenkins-agent ClusterIP 172.20.163.66 <none> 50000/TCP 13h
jenkins-x-chartmuseum ClusterIP 172.20.50.14 <none> 8080/TCP 13h
nexus ClusterIP 172.20.24.163 <none> 80/TCP 13h
tekton-pipelines-controller ClusterIP 172.20.250.26 <none> 9090/TCP 13h
Yup, that means something went wrong when it deleted Prow after installing Lighthouse - they both have a service named hook
. I'll see what I can do with that.
Yup, that means something went wrong when it deleted Prow after installing Lighthouse - they both have a service named
hook
. I'll see what I can do with that.
If the configuration is 'webook: jenkins' other than default 'webhook: prow' in jx-requirements.yml, is the service 'hook' still running? Since this Feburary when I tried Jenkins Static Master mode, I have never seen the service 'hook' is running. I check my working logs and never see 'hook' service. this weekend I definitely test your new fix and see happens. Thanks a lot!
If you're using static masters, no, there won't be a hook service.
@abayer: I download jx-2.1.30 and jenkins-x-version-v1.0.451 and both are newest version to me. I use 'jx boot' to install Jenkins X static master on another very clean AWS EKS v1.15 cluster. I got the following similar error (lighthouse-hmac-token) in same "STEP: update-webhooks".
STEP: update-webhooks command: /bin/sh -c jx update webhooks --verbose --warn-on-fail in dir: /Users/q1447100/SREProjects/JenkinsX-TMP/jenkins-x-boot-config/repositories
**error: secrets "lighthouse-hmac-token" not found
error: failed to interpret pipeline file jenkins-x.yml: failed to run '/bin/sh -c jx update webhooks --verbose --warn-on-fail' command in directory 'repositories', output: ''**
IT-SEA17490-MBP:jenkins-x-boot-config q1447100$ jx version
NAME VERSION
jx 2.1.30
Kubernetes cluster v1.15.11-eks-af3caf
kubectl v1.16.2
helm client 2.14.3
git 2.20.1 (Apple Git-117)
Operating System Mac OS X 10.14.6 build 18G103
verifying packages
IT-SEA17490-MBP:jenkins-x-boot-config q1447100$ kg services --all-namespaces
NAMESPACE NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
default kubernetes ClusterIP 172.20.0.1 <none> 443/TCP 4d8h
jx exdns-external-dns ClusterIP 172.20.249.4 <none> 7979/TCP 22m
jx heapster ClusterIP 172.20.176.40 <none> 8082/TCP 19m
jx jenkins ClusterIP 172.20.233.187 <none> 8080/TCP 18m
jx jenkins-agent ClusterIP 172.20.90.113 <none> 50000/TCP 18m
jx jenkins-x-chartmuseum ClusterIP 172.20.175.18 <none> 8080/TCP 19m
jx nexus ClusterIP 172.20.148.159 <none> 80/TCP 18m
jx tekton-pipelines-controller ClusterIP 172.20.201.226 <none> 9090/TCP 18m
kube-system jxing-nginx-ingress-controller LoadBalancer 172.20.146.15 a24a7236a99c7408684f13c339668d86-50bde5423a5337d6.elb.us-east-1.amazonaws.com 80:30736/TCP,443:30454/TCP 4d7h
kube-system jxing-nginx-ingress-default-backend ClusterIP 172.20.51.102 <none> 80/TCP 4d7h
kube-system kube-dns ClusterIP 172.20.0.10 <none> 53/UDP,53/TCP 4d8h
kube-system tiller-deploy ClusterIP 172.20.100.75 <none> 44134/TCP 4d7h
I'm working on a better fix for this, but a quick workaround is to clone your dev env repo locally and run
jx boot
from in it - it'll recreate the secret properly.Good to know. I will create new AWS EKS cluster to try this quick workaround. Last night I had rolled back to jx-v2.0.1258 + jenkins-x-versions-v1.0.406 to move forward to set up Jenkins X CI/CD pipeline environment and tested successfully for our PHP applications due to tight schedule of my project.
But before you do that, could you do a
kubectl get service
and see if there's ahook
service? Thanks.There is no
hook
service when I runkubectl get service
command. I know if I choose "stateless" type (Prow + Tekton) installation, the service 'hook' as part of Prow should be running. This weekend I will test whether newest fix resolves the issue. Thanks for your quick response and quick fix!IT-SEA17490-MBP:~ q1447100$ kg services NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE exdns-external-dns ClusterIP 172.20.57.34 <none> 7979/TCP 13h heapster ClusterIP 172.20.239.250 <none> 8082/TCP 13h jenkins ClusterIP 172.20.168.79 <none> 8080/TCP 13h jenkins-agent ClusterIP 172.20.163.66 <none> 50000/TCP 13h jenkins-x-chartmuseum ClusterIP 172.20.50.14 <none> 8080/TCP 13h nexus ClusterIP 172.20.24.163 <none> 80/TCP 13h tekton-pipelines-controller ClusterIP 172.20.250.26 <none> 9090/TCP 13h
I clone my dev env repo locally and run 'jx boot' from in it - it is not recreated the secret properly with the same error.
STEP: update-webhooks command: /bin/sh -c jx update webhooks --verbose --warn-on-fail in dir: /Users/q1447100/SREProjects/JenkinsX-TMP/environment-jenkinsx-eks-115-dev/repositories
error: secrets "lighthouse-hmac-token" not found
error: failed to interpret pipeline file jenkins-x.yml: failed to run '/bin/sh -c jx update webhooks --verbose --warn-on-fail' command in directory 'repositories', output: ''
IT-SEA17490-MBP:environment-jenkinsx-eks-115-dev q1447100$ pwd
/Users/q1447100/SREProjects/JenkinsX-TMP/environment-jenkinsx-eks-115-dev
@q131172019 I just had the same issue. Upgraded JX to 2.1.31 and reran jx boot. Now it works.
I have the same error if i try to run jx boot with this jx-requirements.yml
autoUpdate:
enabled: false
schedule: ""
bootConfigURL: https://github.com/***/jx-boot-config
cluster:
clusterName: coon
devEnvApprovers:
- luca-dichiro
environmentGitOwner: ***
environmentGitPublic: true
gitKind: github
gitName: github
gitServer: https://github.com
namespace: jx
project: norse-fiber-275614
provider: gke
zone: europe-west2-a
environments:
- ingress:
domain: *******.nip.io
externalDNS: false
namespaceSubDomain: -jx.
tls:
email: ""
enabled: false
production: false
key: dev
repository: environment-coon-dev
- ingress:
domain: ""
externalDNS: false
namespaceSubDomain: ""
tls:
email: ""
enabled: false
production: false
key: staging
repository: environment-coon-staging
- ingress:
domain: ""
externalDNS: false
namespaceSubDomain: ""
tls:
email: ""
enabled: false
production: false
key: production
repository: environment-coon-production
gitops: true
ingress:
domain: ********.nip.io
externalDNS: false
namespaceSubDomain: -jx.
tls:
email: ""
enabled: false
production: false
kaniko: true
repository: nexus
secretStorage: local
storage:
backup:
enabled: false
url: ""
logs:
enabled: false
url: ""
reports:
enabled: false
url: ""
repository:
enabled: false
url: ""
vault: {}
velero:
schedule: ""
ttl: ""
versionStream:
ref: v1.0.465
url: https://github.com/jenkins-x/jenkins-x-versions.git
webhook: jenkins
do you have any update on this?
Do you have any update on this?
I am using jx version 2.01139. Downgraded from 2.01286.
I am using Classic Jenkins.
I get the same error when my environment-cluster-staging runs to promote.
WARNING: no REPO_OWNER provided error: fail to acquire the lock: no REPO_OWNER provided
Does jx version 2.1.31 supports classic Jenkins? cprovencher mentioned upgrading to 2.1.31 fixed this issue for him but I am not sure if I can upgrade because I am using Classic Jenkins.
@abayer
I had the same issue.
jx version
version: 3.1.15
error as below
jx gitops postprocess
there is no post processing Secret jx-post-process in namespace default so not performing any additional post processing steps
changing to the jx namespace to verify
jx ns jx --quiet
Now using namespace 'jx' on server ''.
jx verify ingress --ingress-service ingress-nginx-controller
now verifying docker registry ingress setup
jx gitops webhook update --warn-on-fail
Error: failed to validate options: failed to find hmac token from secret: could not find lighthouse hmac token lighthouse-hmac-token in namespace jx: secrets "lighthouse-hmac-token" not found
Usage:
update [flags]
Examples:
# update all the webhooks for all SourceRepository and Environment resource:
jx-gitops update
# only update the webhooks for a given owner
jx-gitops update --org=mycorp
# use a custom hook webhook endpoint (e.g. if you are on premise using node ports or something)
jx-gitops update --endpoint http://mything.com
Flags:
-b, --batch-mode Runs in batch mode without prompting for user input
--endpoint string Don't use the endpoint from the cluster, use the provided endpoint
--exact-hook-url-match Whether to exactly match the hook based on the URL (default true)
--git-kind string the kind of git server to connect to
--git-server string the git server URL to create the scm client
--git-token string the git token used to operate on the git repository. If not specified it's loaded from the git credentials file
--git-username string the git username used to operate on the git repository. If not specified it's loaded from the git credentials file
-h, --help help for update
--hmac string Don't use the HMAC token from the cluster, use the provided token
--log-level string Sets the logging level. If not specified defaults to $JX_LOG_LEVEL
-o, --owner string The name of the git organisation or user to filter on
--previous-hook-url string Whether to match based on an another URL
-r, --repo string The name of the repository to filter on
--verbose Enables verbose output. The environment variable JX_LOG_LEVEL has precedence over this flag and allows setting the logging level to any value of: panic, fatal, error, warn, info, debug, trace
--warn-on-fail If enabled lets just log a warning that we could not update the webhook
error: failed to validate options: failed to find hmac token from secret: could not find lighthouse hmac token lighthouse-hmac-token in namespace jx: secrets "lighthouse-hmac-token" not found
make: *** [versionStream/src/Makefile.mk:145: verify] Error 1
boot Job pod jx-boot-b12ae738-a383-4eb7-9a87-703d8c4f838f-nb29j has Failed
Summary
When I had same problem "error: fail to acquire the lock: no REPO_OWNER provided" from the output of command 'jx step helm apply' which was reported by issue #7106 yesterday, I saw 'daveconde' merged the new fix for this issue #7106 in the issue #7128 6 days ago. Therefore, this morning I upgraded newest version of jx to v2.1.23 from v2.0.1240, and upgraded newest version of jenkins-x-versions to v1.0.444 from v1.0.406 in the file jx-requirements.yml. Then used 'jx boot' to install Jenkins X with gitlab server and stoped at step "update-webhooks" after successful "STEP: install-pipelines"
STEP: update-webhooks command: /bin/sh -c jx update webhooks --verbose --warn-on-fail in dir: /Users/q1447100/SREProjects/JenkinsX-TMP/jenkins-x-boot-config/repositories
error: secrets "hmac-token" not found error: failed to interpret pipeline file jenkins-x.yml: failed to run '/bin/sh -c jx update webhooks --verbose --warn-on-fail' command in directory 'repositories', output: ''
Steps to reproduce the behavior
$ jx update webhooks --verbose --warn-on-fail DEBUG: Finding service url for jenkins in namespace jx DEBUG: Found service url http://jenkins.jx.jenkinsxgitlabinfra.stg.store.aws.z8s.io error: secrets "hmac-token" not found
Expected behavior
The command to update webhooks should be successful. And "STEP: update-webhooks" should be completed.
Actual behavior
The "STEP: update-webhooks" in jenkins-x.yml was stopped and the command 'jx boot' was stopped accordingly.
Jx version
The output of
jx version
is:Jenkins Type
Helm Version
Kubernetes cluster
What kind of Kubernetes cluster are you using & how did you create it? Use Terraform customized AWS EKS module to creat AWS EKS v1.15(newest)
Operating system / Environment
In which environment are you running the jx CLI? Mac OS X 10.14.6 build 18G103
What is the contents of the file jx-requirements.yml?