Archlinux/Raspberry Pi - Setup SCM-Manager
Do 14 April 2016SCM-Manager
SCM-Manager is a lightweight version control server. SCM-Manager manages 3 systems: GIT, Subversion and Mercurial.
And it provides an easy installation and plugin support for stuff like LDAP authentication and much more.
Links/Download
- SCM-Manager Homepage
- SCM-Manager Wiki
- Java Commons Daemon (JSVC) ArchPackage
- JSVC 1.0.15-2 direct link
JSVC: Needed to execute SCM-Manager in daemon mode, but not shipped for arm cpu
Set-By-Step
-
Download required software First download required software (SCM-Manager and JSVC) like:
wget https://www.scm-manager.org/download-action/?download=/scm-server/1.46/scm-server-1.46-app.tar.gz wget http://mirror.archlinuxarm.org/armv6h/extra/java-jsvc-1.0.15-2-armv6h.pkg.tar.xz
-
Create directories and unpack
# untar downloaded archives tar -zxvf scm-server-1.46-app.tar.gz tar -xvJf java-jsvc-1.0.15-2-armv6h.pkg.tar.xz # move folder to opt sudo mv -v scm-server /opt/scm-server # create basedir for server sudo mkdir /var/scm # move jsvc to server libs sudo mv -v usr/bin/jsvc /opt/scm-server/libexec/jsvc-linux-armv6l rm -Rv usr # optional: remove downloaded
rm scm-server-1.46-app.tar.gz
-
Create new group and user scm for server
sudo useradd -rUs /usr/bin/nologin scm
-
Add your user to group scm
sudo gpasswd -a $USER scm
Relogin after this step
-
Change directory owner and permissions
# configure like tomcat http://superuser.com/a/825867/550494 sudo chown -Rhcv root:scm /opt/scm-server sudo chmod -cv 750 /opt/scm-server sudo chown -hcv root:scm /opt/scm-server/README.txt sudo chmod -cv 640 /opt/scm-server/README.txt sudo chown -Rhcv root:scm /opt/scm-server/bin sudo chmod -Rcv 740 /opt/scm-server/bin sudo chown -Rhcv root:scm /opt/scm-server/conf sudo chmod -Rcv 640 /opt/scm-server/conf sudo chown -Rhcv root:scm /opt/scm-server/lib sudo chmod -Rcv 640 /opt/scm-server/lib sudo chown -Rhcv root:scm /opt/scm-server/libexec sudo chmod -Rcv 750 /opt/scm-server/libexec sudo chown -Rhcv root:scm /opt/scm-server/var sudo chmod -Rcv 660 /opt/scm-server/var sudo chmod -R gu+S /opt/scm-server/var sudo chown -Rhcv scm:scm /opt/scm-server/work sudo chmod -Rcv 660 /opt/scm-server/work sudo chmod -R gu+S /opt/scm-server/work sudo chmod -Rcv ug+X /opt/scm-server sudo chown -Rhcv scm:scm /var/scm sudo chmod -Rcv 6770 /var/scm sudo chmod -Rcv gu+s /var/scm
-
Configure server
Change the user to scm and set working dirnano /opt/scm-manager/bin/scm-serverbash sh
-
Start daemon
# scm-server <start|stop> sudo /opt/scm-server/bin/scm-server start
-
Check logs
sudo tail -fn 50 /opt/scm-server/var/log/scm-server.out
-
Open SCM-Manager
name value server http://[server]:8080 adminuser scmadmin password scmadmin