如何从BitBucket中的两个不同分支推送到两个不同的Heroku应用程序?

时间:2018-07-03 12:35:09

标签: git heroku bitbucket

bitbucket-pipelines.yml

# This is a sample build configuration for JavaScript.
# Check our guides at https://confluence.atlassian.com/x/14UWN for more examples.
# Only use spaces to indent your .yml configuration.
# -----
# You can specify a custom docker image from Docker Hub as your build environment.
image: node:6
clone:
  depth: full
pipelines:
  branches:
    master:
        - step:
            script:
              - npm install
              - npm test
              - git config --global user.email "abc@abc.com"
              - git config --global user.name "abc@abc.com"
              - git push https://heroku:$HEROKU_API_KEY@git.heroku.com/$HEROKU_APP_NAME_PRODUCTION.git HEAD
    staging:
    - step:
        script:
          - npm install
          - npm test
          - git config --global user.email "abc@abc.com"
          - git config --global user.name "abc@abc.com"
          - git push https://heroku:$HEROKU_API_KEY@git.heroku.com/$HEROKU_APP_NAME.git HEAD

当前,当我部署到暂存分支但Heroku中没有任何更改时,管道可以成功运行。我该如何解决?

0 个答案:

没有答案
相关问题