Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Deploying a private nodejs repo with private package to Heroku

khaitov-eldar
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
October 14, 2018

I followed this article to set up pipelines https://confluence.atlassian.com/bitbucket/deploy-to-heroku-872013667.html

In Heroku I set default deployment from Heroku git. I don't have heroku cli on local machine.

The problem is that in bitbucket my deployments go green but I don't see any updates on Heroku and the app itself is on the last state when I migrated from github.

The yml file look like this (omitted comments):

 

environment.image: node:6.9.4

clone:
depth: full

pipelines:
  default:
    - step:
      caches:
      - node
nameDeploy to Heroku
      deploymenttest
      script:
        - npm install
        - git push https://heroku:$HEROKU_API_KEY@git.heroku.com/$HEROKU_APP_NAME.git HEAD

 

2 answers

0 votes
Giovani Silva
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
November 18, 2019
I prefer doing like this

pipelines:
default:
- step:
name: Build and Test
image: node:10.15.3
caches:
- node
script:
- npm install
# - npm test
- step:
name: Create artifact
script:
- tar czfv application.tgz *
artifacts:
- application.tgz
- step:
name: Publish
deployment: production
script:
- pipe: atlassian/heroku-deploy:1.1.0
variables:
HEROKU_API_KEY: $HEROKU_API_KEY
HEROKU_APP_NAME: 'app-name'
ZIP_FILE: 'application.tgz'
WAIT: 'true'
0 votes
StannousBaratheon
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
October 23, 2018

Hi @khaitov-eldar

I tested the same setup deploying to Heroku and it worked as expected. May I suggest you open a support ticket via https://support.atlassian.com/contact/ so that we can have a look at what's going on in your repository?

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events