I have created my first droplet, but I don’t know how to set the root application directory?
I tried to create a folder for my app name in /home/dokku/app_name
Then, I did cd app_name
and then git init
Then I added a remote repo:
git remote add dokku root@do.mydomain.com:app_name
But, when try to push I get error:
fatal: 'app_name' does not appear to be a git repository
fatal: The remote end hung up unexpectedly
How to configure this? How to set the root application directory?
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
You don’t have to create any directory on the host. Remove any folders or files you created.
When you run git push dokku <branch>
dokku
will automatically create the directories and files needed.
It’s not enough only to init git repository. Next steps could be:
But, it looks like you are trying to build your own “heroku”, in this case you have to look into dokku documentation, or appropriate tutorial on the DO portal. Unfortunately, not so experienced in this area.