Git Repo to mantain the app configurations in several servers

Posted by user62904 on Server Fault See other posts from Server Fault or by user62904
Published on 2011-01-13T12:34:50Z Indexed on 2011/01/13 12:55 UTC
Read the original article Hit count: 169

Filed under:

Hi!

I need to versioning in a GIT repository, configurations of a particular platform, spread across multiple servers. Take into account that in each of these servers there are completely different configurations, while the application is the same. What is the best way to do this?

  1. Create a branch for each server

    • repository.git:conf --> [branch Server 1]
    • repository.git:conf --> [branch Server 2]
    • repository.git:conf --> [branch Server N]
    • Note: This method seems to me, that is difficult to maintain because each change in the server configurations, I need to create subbranches which becomes confusing.
  2. Create a single repo with a different directory for each server

    • repository.git:conf/Server 1
    • repository.git:conf/Server 2
    • repository.git:conf/Server N
    • Note: This is easy to mantain
  3. Create a repo for each server

    • repository_1.git:conf
    • repository_2.git:conf
    • repository_N.git:conf
    • Note: This method requires me to create a branch for each new server.

There are other methods, what are the best practices in this case? Should I use the one that I feel most comfortable?

Tks,

Gulden PT

© Server Fault or respective owner

Related posts about git