We have already installed “git” on our CentOS virtual machine, and we clone a GitHub depot to use it as an example :

Ansible GitHub depot clone as an example

Clone this public depot :

[root@git ~]# mkdir ansible
[root@git ~]# cd ansible
[root@git ansible]# git clone https://github.com/ansible/ansible
Cloning into 'ansible'...
remote: Counting objects: 104800, done.
remote: Compressing objects: 100% (5/5), done.
remote: Total 104800 (delta 0), reused 0 (delta 0), pack-reused 104793
Receiving objects: 100% (104800/104800), 36.75 MiB | 811.00 KiB/s, done.
Resolving deltas: 100% (62652/62652), done.

Check this depot :

[root@git ansible]# cd ansible
[root@git ansible]# git status
# On branch devel
nothing to commit, working directory clean


Now, install “lighttpd” :

[root@git ansible]# yum -y install lighttpd
  lighttpd.x86_64 0:1.4.37-1.el7
Dependency Installed:
  gamin.x86_64 0:0.1.10-16.el7

Restart “lighttpd” :

[root@git ansible]# systemctl restart lighttpd

“firewalld” settings

Is firewalld running ?

[root@git ansible]# systemctl status firewalld | grep Active
 Active: active (running) since Fri 2016-01-01 12:05:47 CET; 23s ago

Yes, authorize WEB services :

[root@git ansible]# firewall-cmd --permanent --add-service=http

Authorize port # 1234 on TCP :

[root@git ansible]# firewall-cmd --permanent --add-port=1234/tcp
[root@git ansible]# firewall-cmd --reload

Open your favorite WEB browser to discover the welcome page :










Start “gitweb” for this depot :

[root@git ansible]# git instaweb
 No known browser available.

You will see on your browser :










You can navigate in files, for example :










To stop the service :

[root@git ansible]# git instaweb --stop



Create PDF    Send article as PDF   

Leave a Reply

Your email address will not be published. Required fields are marked *