error: RPC failed; result=22, HTTP code = 400

后端 未结 6 1846
忘掉有多难
忘掉有多难 2021-01-02 02:26

I am trying to push my app on to Heroku, but I am getting this error message. I have looked around, someone mentioned about GitHub recently started redirecting http reposito

相关标签:
6条回答
  • 2021-01-02 02:47

    change your postbuffer

    git config --global http.postBuffer 52428800
    

    then you postbuffer is 50M .

    0 讨论(0)
  • 2021-01-02 02:49

    The problem (could be) that you are probably used git clone --depth .. for your repository and that created so called shallow copy (without history). If you cloned somebody else repository (!), just delete /.git folder and create a recreate repository as new with

    cd <my-project>/
    git init
    

    Then you can push even with remote https://<youprojectname>.herokuapp.com/

    0 讨论(0)
  • 2021-01-02 02:53

    i hope this is not coming to late, but Heroku deployments require a full Git clone. By default, Pipelines clones your repository with a depth of 50 to shorten your build time. You can configure your Pipeline to do a full Git clone in your bitbucket-pipelines.yml file.

    try adding full clone depth to your yml file

      image: node:6
      clone:
         depth: full
    
    0 讨论(0)
  • 2021-01-02 02:55

    For Rails 4: make sure you add "rails_12factor" gem to your Gemfile.

    0 讨论(0)
  • 2021-01-02 03:04

    This may occur due the reason that Heroku's Git doesn't understand shallow clone as mentioned here.

    Workaround is to disable shallow clone before deployment.

    git fetch --unshallow
    
    0 讨论(0)
  • 2021-01-02 03:04

    It could be a glitch, as I mentioned in here.
    (Actually, right as I write this, GitHub is having a "Major service outage"!)

    Make sure you can reproduce the issue with an http or an https url.
    If that persists, simply try and swith to an ssh url

    git remote set-url heroku git@heroku.com:yourRepo
    

    (which is the recommended approach, since heroku normally support ssh only)

    0 讨论(0)
提交回复
热议问题