diff --git a/Jenkinsfile b/Jenkinsfile index 2011d57..cdbe641 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -27,7 +27,7 @@ spec: stage('Build with Kaniko') { git url: 'ssh://git@git.ervine.org/jonny/x86_64-alpine-dsm2slack.git', credentialsId: 'jenkins-to-git' container('kaniko') { - sh '/kaniko/executor -f `pwd`/Dockerfile -c `pwd` --cache=true --destination=harbor.ervine.dev/public/x86_64/alpine/dsm2slack:v1' + sh '/kaniko/executor -f `pwd`/Dockerfile -c `pwd` --cache=true --destination=harbor.ervine.dev/public/x86_64/alpine/dsm2slack:latest --destination=harbor.ervine.dev/public/x86_64/alpine/dsm2slack:v1' } } } diff --git a/main.go b/main.go index 09f5362..177b4ed 100644 --- a/main.go +++ b/main.go @@ -33,7 +33,8 @@ func PostHandler(w http.ResponseWriter, r *http.Request) { if r.Header.Get("api_key") != appConfig.APIKey { http.Error(w, "invalid api key", http.StatusUnauthorized) log.Printf("invalid api key") - log.Printf("Received key: ", r.Header.Get("api_key")) + api_key = r.Header.Get("api_key") + log.Printf("Received key: ", api_key) return }