{"id":27,"date":"2021-01-12T08:51:21","date_gmt":"2021-01-12T08:51:21","guid":{"rendered":"https:\/\/veltzer.net:8890\/?p=27"},"modified":"2021-01-12T08:51:21","modified_gmt":"2021-01-12T08:51:21","slug":"git-and-signing","status":"publish","type":"post","link":"https:\/\/veltzer.net:8890\/git-and-signing\/","title":{"rendered":"Git and signing"},"content":{"rendered":"\n
I\u2019m now using git heavily for configuration management and wanted to sign my objects. There were no complete guides out there that I found so here is the list of instructions that I finally arrived at:<\/p>\n\n\n\n
gpg2 --gen-key<\/code>. The program is interactive and very easy to use. The program comes with the gnupg2<\/code> package on Ubuntu or Debian. The keys are generated in ~\/.gnupg<\/code>. If you want to see that everything went well the you can list all keys using gpg2 --list-public-keys<\/code>.<\/li>- Configure git to use your email. This usually involves editing your git configuration file at
~\/.gitconfig<\/code> and setting the email<\/code> config option under the user<\/code> section to your email.<\/li>- Sign your change when you commit or tag it. If you commit then use \u201cgit -s commit\u201d. If you tag then use \u201cgit tag -s -m \u2018commit message\u2019 [tagname]\u201c.<\/li><\/ol>\n","protected":false},"excerpt":{"rendered":"
I\u2019m now using git heavily for configuration management and wanted to sign my objects. There were no complete guides out there that I found so here is the list of instructions that I finally arrived at: If you have a key that you are already using to sign things (email, code, whatever) then you can … <\/p>\n