Repository navigation
How to update Heroku parser-server with latest code from github? #879
Description
Activity
To clone the project you've deployed with the heroku button, you use the Heroku Toolbelt, the command line tool: https://toolbelt.heroku.com/
They explain how to use it to clone a deployed app: https://devcenter.heroku.com/articles/git-clone-heroku-app
edit: see the much easier version below:
There is an easier way:
- clone project from heroku
- in project folder
- run
$ git submodule add [email protected]:ParsePlatform/parse-server.git - run
$ npm link parse-server ./parse-server
In details:
$ git submodule add [email protected]:ParsePlatform/parse-server.gitThis will add parse-server as a submodule, heroku will understand that and fetch it when you push to heroku (see here)
$ npm link parse-server ./parse-serverThis tells npm to use ./parse-server directory, that now contains the sources to use that directory for parse-server
You should be good to go.
When it comes to update your submodule,
# in your heroku project directory # change to the submodule directory cd parse-server # checkout desired branch git checkout master # update git pull # get back to your project root cd .. # now the submodules are in the state you want, so # this will commit all changes git commit -am "Pulled last version of parse-server"Thanks I updated but it appears to not have solved the issue I had, I'll open a new issue explaining it in more details.
Hi,
I followed steps you have mentioned. i encountered errors when running step 2 so ran with sudo and it worked.
but git push heroku master fails with below log. I tried everything i could find on stackverflow.com etc but nothing worked. tried deleting keys from Heroku account, generated new keys, login, logout from Heroku. All effort failed. I am new to Node, Heroku etc so finding even more difficult to solve.please help. What could be wrong? My directory structure is as below:
app name
|- node_modules
|- parse-server
|- package.jsonCounting objects: 4590, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (4184/4184), done.
Writing objects: 100% (4590/4590), 3.36 MiB | 79.00 KiB/s, done.
Total 4590 (delta 943), reused 0 (delta 0)
remote: Git submodules detected, installing:
remote: Submodule 'parse-server' ([email protected]:ParsePlatform/parse-server.git) registered for path 'parse-server'
remote: Cloning into 'parse-server'...
remote: Host key verification failed.
remote: fatal: Could not read from remote repository.
remote:
remote: Please make sure you have the correct access rights
remote: and the repository exists.
remote: Clone of '[email protected]:ParsePlatform/parse-server.git' into submodule path 'parse-server' failed
remote:
remote: ! Push rejected, submodule install failed
remote:
To https://git.heroku.com/appname.git
! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'https://git.heroku.com/appname.git'Permission denied (publickey).
fatal: Could not read from remote repository.Please make sure you have the correct access rights
and the repository exists.
Clone of '[email protected]:ParsePlatform/parse-server.git' into submodule path 'parse-server' failedam i missing something
solved it by using: git submodule add https://github.com/ParsePlatform/parse-server.git
Sorry but this may be a really dumb question and I googled but had no luck, but I am not sure how to update my Heroku parse-server with the latest code on github. I used the "1 button push" installation on Heroku, so I'm not even sure which version they installed at the time (nor how to find out).
I'd like to get the latest code base because it appears a fix for an issue holding me back has been made.
#773
Which I am having this exact issue someone posted here:
#783
I tried updating the version in my package.json to 2.1.4 (it was 2.1.2) and pushed it but it appears I'm still getting the same error as the guy in #783 so I didn't think it actually worked.
The latest code on github has that change so I'm just wondering how I can update my parse-server code on there, thanks!