insufficient permission for adding an object to repository database .git/objects code example
Example 1: Got an error creating the test database: permission denied to create database
=> ALTER USER django CREATEDB;
Example 2: error: insufficient permission for adding an object to repository database .git/objects
find .git/ -exec stat --format="%G %n" {} + |grep root
chown -R $(id -un):$(id -gn) .git/objects/
git commit -a -m "fixed git objects ownership"