I am using mac, and /etc
is just a symlink to /private/etc
, which contains hundreds of (important) configuration files, and the total size of /private/etc
directory is smaller than 1 MB.
Is it a good way to backup these files using git
? If not, why?
What might be some side effects?
Edit: as user ivanivan pointed out, there might be security concerns for some file containing passwords or keys. Can you give me some example of these files? (e.g. ssh keys and /etc/shadow
)
Edit: maybe I can encrypt the .git
dir before pushing it to a private remote repo?
Edit: git doesn't track file permission and files in /etc
have all kinds of permissions. using git may cause some serious problems. On the other hand, etckeeper handles file permissions properly.
/etc
– ivanivan Jun 26 '19 at 14:28git
or similar software is for keeping track of revisions and is not primarily for backing up files. – Kusalananda Jun 26 '19 at 14:58