【Rails】 When auto-deploying with Capistrano, git stderr: fatal: not a valid object name: master
1
What is the error?
To deploy, execute the following command,
$ bundle exec cap production deploy
I was getting an error like this. (Excerpt)
# エラーログ
git stdout: Nothing written
git stderr: fatal: not a valid object name: master
cause
There was no branch called master, and the default branch name was main.
What to do
In config/deploy.rb, specify the branch to be deployed. (The following is added.) )
set :branch, "main"