Difference between revisions of "Git"

From SME Server
Jump to navigationJump to search
Line 73: Line 73:
 
=== Notes on using SME Server Git ===
 
=== Notes on using SME Server Git ===
  
==== Ignore self signed SSL certificates ====
+
==== Git client needs to ignore self signed SSL certificates ====
  
Git validates the HTTP SSL security certificate when accessing a repository. With the self signed certificates typical in SME systems you will get an error like '''certificate verify failed''' when accessing the Git repository. You can avoid this problem by disabling this check in your Git client with:
+
The Git client validates the HTTP SSL security certificate when accessing a repository. With the self signed certificates typical on SME servers, you will get an error like '''certificate verify failed''' when accessing the Git repository. You can avoid this problem by by setting the http sslVerify flag to false. Using a command line, you can do this in your Git client as follows:
  
 
  git config --global http.sslVerify false
 
  git config --global http.sslVerify false
 +
 +
In a git config file, this looks like:
 +
 +
[http]
 +
    sslVerify = false
  
 
=== Feedback ===
 
=== Feedback ===

Revision as of 02:21, 4 February 2015

PythonIcon.png Skill level: Developer
Risk of inconsistencies with Koozali SME Server methodology, upgrades & functionality is high. One must be knowledgeable about how changes impact their Koozali SME Server. Significant risk of irreversible harm.


Developer / Maintainer

Marco Hess

Status

As of 2 Feb 2015, RPM's are available from my personal repository (see below) for SME8 (Version 1.0) and SME9 (Version 1.1) in the noarch part of my repository. Both versions have been validated on a latest version of SME8 and SME9. Feedback will be appreciated.

A request has been put in to upload the RPM's to the smecontribs repository in the near future.

Description

This is a place holder for a Git integration contrib for SME server that is currently under development. It integrates git with git-http-backend and gitweb into SME8. Have a look http://through-ip.com/git for a live instance of the contrib.

right‎

The current feature list include:

  • Create & manage centralised git repositories through the SME server-manager panel.
  • Per repository network access configurable for either 'Local network Only' or 'Internet'.
  • Repositories accessed over HTTP/HTTPS for easy remote access through firewalls.
  • Separately configurable PULL and PUSH permissions.
  • Permissions based on SME server users and groups.
  • Support for Anonymous access PULL and/pr PUSH.
  • Separate name space for Git repositories using git as a prefix (i.e. independent of ibays and other resources on the server)
  • Email notification of push operations to all users that have either pull or push access to the repository
  • Web viewing of repositories through gitweb.
  • Special GitHub style theme for gitweb viewer (separately installable).
  • Gravatars support in gitweb
  • Automatic markdown of README.md into README.html and shown in gitweb repository summary.
Smeserver-git server manager home screen3.png

Installation

There are now RPMs available from my personal repository that can be found at

SME8: http://through-ip.com/packages/smeserver/i386/repoview/

SME9: http://through-ip.com/packages/smeserver/noarch/repoview/

Source RPMs are also available, as well as cloning with Git from either:

http://through-ip.com/git

or from GitHub:

  1. https://github.com/MarcoHess/smeserver-git/tree/smeserver-git
  2. https://github.com/MarcoHess/smeserver-git/tree/smeserver-gitweb
  3. https://github.com/MarcoHess/smeserver-git/tree/smeserver-gitweb-theme

Through IP Repositpory

The following command will configure the Through-IP repository on SME Server.

/sbin/e-smith/db yum_repositories set through-ip repository \
BaseURL http://through-ip.com/packages/smeserver/i386/ \
Name 'Through IP Pty. Ltd.' \
EnableGroups yes \
Visible yes \
GPGCheck no \
status disabled

After adding it to the database we have to update the changes to the configuration file:

signal-event yum-modify

Dag Repositpory

The Git packages comes from the Dag repository. Check the instructions on that wiki page and make sure you use the settings for SME8

Install the SME Server Git RPM's

yum --enablerepo=through-ip --enablerepo=dag install smeserver-git smeserver-gitweb smeserver-gitweb-theme

Subversion conflict with smeserver-subversion

The SME Server Subversion contribs currently has a small conflict in the subversion RPM's that are used for the smeserver-subversion (version 1.6.15 from smecontribs) and smeserver-git (vesion 1.6.11 from dag) contribs whereby the smecontribs repository does not have the subversion-perl package:

As a workaround both contribs can be installed together:

  1. Remove the smeserver-subversion and subversion rpms
  2. Install smeserver-git as above.
  3. Install smeserver-subversion with the steps below:
wget http://pkgs.repoforge.org/subversion/subversion-perl-1.6.15-0.1.el5.rfx.i386.rpm
yum localinstall subversion-perl-1.6.15-0.1.el5.rfx.i386.rpm install smeserver-subversion --enablerepo=smecontribs

Notes on using SME Server Git

Git client needs to ignore self signed SSL certificates

The Git client validates the HTTP SSL security certificate when accessing a repository. With the self signed certificates typical on SME servers, you will get an error like certificate verify failed when accessing the Git repository. You can avoid this problem by by setting the http sslVerify flag to false. Using a command line, you can do this in your Git client as follows:

git config --global http.sslVerify false

In a git config file, this looks like:

[http]
    sslVerify = false

Feedback

I welcome any feedback on this contrib for bugs, features or assistance (e.g. turning it into an RPM). Email me at the address found at the top of this page.

Additional information

More information about Git can be found on http://git-scm.com/.

Bugs

Please raise bugs under the SME-Contribs section in bugzilla and select the smeserver-git, smeserver-gitweb or smeserver-gitweb-theme component or use these links: smeserver-git , smeserver-gitweb , smeserver-gitweb-theme


Below is an overview of the current issues for these contribs:

smeserver-git

"No open bugs found."

smeserver-gitweb

"No open bugs found."

smeserver-gitweb-theme

"No open bugs found."