1) Install the SVN serveryum install -y subversion mod_dav_svnModify /etc/httpd/conf.d/subversion.confmkdir /etc/svn/htpasswd -cm /etc/svn/users jchenhtpasswd -m /etc/svn/users testmkdir /var/www/svncd /var/www/svnsvnadmin create mylabchown -R apache.apache mylabchcon -R -t httpd_sys_content_t mylabservice httpd restartchkconfig httpd on2) Intall the SVN clientyum install -y subversion
Author: Jackie Chen
Build Master/ Slave DNS in CentOS
1) Set up master DNS server (CentOS 6.5) yum install -y bind* Modify /etc/named.conf Create the zone files: /var/named/mylab.local /var/named/56.168.192.in-addr.arpa service named start chkconfig named on 2) Set up slave DNS server (CentOS 6.5) yum install -y bind* Modify /etc/named.conf service named start chkconfig named on 3) Reload the zone whenever the zone file … Continue reading Build Master/ Slave DNS in CentOS
Use sed to append a file to another
To append file2 to a specific line in file1, here is command: sed -i "<line>r file2" file1 Example:
Update puppet tags
This script allow you to apply the specified puppet tags to the listed hosts. It will do a dry run against the first host, if you are happy with the results then you can kick off the changes to all hosts. The script can be downloaded from here.
Push public key to remote hosts in a batch
Sometimes it is easy to use the passwordless SSH authentication against the remotes hosts. I wrote a script that can push your public key to remote hosts in a batch. The script can be downloaded from here