How To Use etckeeper |
Server - Ubuntu |
etckeeper is a set of tools that allows you to maintain the /etc directory in a git, mercurial,darcs or bzr repository. This allows an administrator to commit changes once they have been reviewed.
Now the changes of the contents in the /etc directory will be stored in Version Control System (VCS) repository. The version control ties into the apt command to commit changes when packages are installed or updated. The main configuration file is /etc/etckeeper/etckeeper.conf and provides the option of which VCS to use. By default etckeeper is configured to use bzr for version control. By default uncommitted changes are made daily. If this is not what you want you can edit the config file and uncomment AVOID_DAILY_AUTOCOMMITS configuration option.
Commit changes manually by using:
etckeeper commit "jane password" Committing to: /etc/ modified .etckeeper modified shadow Committed revision 2. bzr log /etc/shadow ------------------------------------------------------------ revno: 2 committer: root <root@ub11.localdomain> branch nick: ub11 /etc repository timestamp: Mon 2011-08-15 18:31:36 -0600 message: jane password ------------------------------------------------------------ revno: 1 committer: root <root@ub11.localdomain> branch nick: ub11 /etc repository timestamp: Mon 2011-08-15 18:27:20 -0600 message: Initial commit
Exercise:
Install etckeeper
Change jane's password.
Check the status of the change.
Commit the change with a reason.
View the log of the changes.
Now install an application
Check for changes. |