Hi There,
I am trying to deploy my first Go application to Heroku, and I am using bitbucket pipelines. When I run deploy, I got an error.
Here is error message cannot find module for path _/opt/atlassian/pipelines/agent/build/__PACKAGE_PATH_/connection
Here is my bitbucket-pipelines.yml file
image: golang:1.12.3clone: depth: fullpipelines:
default: - step: name: test deployment: production script: #start to deploy it #- echo "start to deploy" # - pipe: atlassian/heroku-deploy:0.1.1 # variables: # HEROKU_API_KEY: $HEROKU_API_KEY # HEROKU_APP_NAME: $HEROKU_APP_NAME - PACKAGE_PATH="\${GOPATH}/src/bitbucket.org/\${BITBUCKET_REPO_OWNER}/\${BITBUCKET_REPO_SLUG}" - mkdir -pv "\${PACKAGE_PATH}" - tar -cO --exclude-vcs --exclude=bitbucket-pipelines.yml . | tar -xv -C "\${PACKAGE_PATH}" - cd "\${PACKAGE_PATH}" - go get -v - go build -v - git push https://heroku:$HEROKU_API_KEY@git.heroku.com/$HEROKU_APP_NAME.git HEAD
Hi @[deleted]
It looks like this is go error. I suspect that it is occurring because a specific file cannot be found.
My first suggestion would be to try to debug this build locally using the instructions here https://confluence.atlassian.com/bitbucket/debug-your-pipelines-locally-with-docker-838273569.html. I would be specifically looking for the 'connection' file/folder and the interactions of the variables.
If this works correctly it might be a problem with the PACKAGE_PATH variable. Try echoing that to confirm that it is what you expect.
If none of that works can I ask you to paste your bitbucket-pipelines.yml file again in a code block with the formatting the file normally has and point out the specific step that is throwing the error.
Cheers,
Tom
Validate your expertise in managing Jira Service Projects for Cloud. Master configuration, optimize workflows, and manage users seamlessly. Earn global 🗺️ recognition and advance your career as a trusted Jira Service management expert.
Get Certified! ✍️Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.