Difference: SubversionRepository (1 vs. 14)

Revision 142016-04-25 - GordonStewart

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
Changed:
<
<

Local Subversion Repository

>
>

Subversion

 
Changed:
<
<
A local subversion repository is being setup, when ready this page will describe how to access it.
>
>
PPE hosts several Subversion repositories:
 
Changed:
<
<
For more information on subversion see the Subversion book or the Subversion FAQs.
>
>
Repository Link WebSVN Link
atlas https://svn.ppe.gla.ac.uk/atlas https://websvn.ppe.gla.ac.uk/wsvn/atlas
lhcb https://svn.ppe.gla.ac.uk/lhcb https://websvn.ppe.gla.ac.uk/wsvn/lhcb
test https://svn.ppe.gla.ac.uk/test https://websvn.ppe.gla.ac.uk/wsvn/test
user https://svn.ppe.gla.ac.uk/user https://websvn.ppe.gla.ac.uk/wsvn/user
 
Changed:
<
<
>
>
You must have a grid certificate to access these repositories, and this must be registered with PPE IT support.
 
Changed:
<
<

Repository Organisation

>
>
In addition to our Subversion repositories, which have seen little use over the last couple of years, PPE also hosts revision control systems such as GitLab for specific projects. If you would like to discuss more up-to-date methods of revision control such as GitLab, either as an individual or for your project, please contact PPE IT support.
 
Deleted:
<
<
Currently there are four subversion repositories:
 
Changed:
<
<
>
>

Using Subversion

 
Changed:
<
<
The test repository is as the name suggests for testing and getting used to using subversion. It will be cleaned out and reset on an irregular basis and without notice.
>
>
For a complete guide to using Subversion, please refer to Version Control with Subversion. This section contains information specific to the PPE repository configuration.
 
Changed:
<
<
NB: Browsers will often repeatedly ask for you to choose a certificate at this point. To get around this, you can (in Firefox) choose Edit >> Preferences>> Advanced and click the radio button Select one Automatically in the certificates section.
>
>
Once you have registered for access, you will be granted full read and write access to all files in all repositories. Please take extreme care when committing changes not to unintentionally overwrite changes made by other users.
 
Deleted:
<
<
To request an additional repo contact the ITManagement
 
Changed:
<
<

Websvn Access

>
>

Creating a user or project directory

 
Changed:
<
<
The repos can also be viewed using websvn:
>
>
To keep the repositories organised, please do not commit files directly into the top level directory. Instead, create a directory named after your user or project, and store files under this directory:
 
Changed:
<
<
>
>
$ svn mkdir https://svn.ppe.gla.ac.uk/<REPOSITORY>/<DIRECTORY> -m <COMMIT MESSAGE>
 
Changed:
<
<
NB: Browsers will often repeatedly ask for you to choose a certificate at this point. To get around this, you can (in Firefox) choose Edit >> Preferences>> Advanced and click the radio button Select one Automatically in the certificates section.
>
>
For example, to create a directory called squirrel within the test repository:
 
Changed:
<
<

Using the repositories

>
>
$ svn mkdir https://svn.ppe.gla.ac.uk/test/squirrel -m "Directory for Squirrel project"
 
Deleted:
<
<
All users, once registered to access the repositories, have full read and write access to any files in any of the repositories. So please take care especially when committing changes and when setting up new directories.
 
Changed:
<
<
To help keep some order in the user repository please do not commit files into the top level repo directory. Instead create a directory named after your user name and store personal files/projects under this directory.
>
>

Setting up access

 
Changed:
<
<
Creating a subdirectory inside the user repo
$ svn mkdir https://svn.ppe.gla.ac.uk/user/pickford -m "user repo dir"
>
>
Before you can access the Subversion repositories, you must have a grid certificate and this must be registered with PPE IT support.
 
Changed:
<
<
For organising files/projects the subversion book http://svnbook.red-bean.com/ describes some recommended possible layouts, in the section Planning Your Repository Organization.
>
>
To configure the svn command to use your certificate, open the file ~/.subversion/servers in a text editor (run svn --version if it doesn't already exist). Add the following to the [groups] section:
 
Changed:
<
<

Setting up access

>
>
ppe = *.ppe.gla.ac.uk
 
Changed:
<
<
Access to the ppe subversion repository and the trac web pages is via grid certificate. Only users who have registered their certificate with the ITManagement can access to either the repository or the trac pages. To register your certificate for access to the repository email ppesysman@physics.gla.ac.uk with your certificate distinguished name (DN). This can be found with the openssl command (the example assumes your certificate is in ~/.globus/usercert.pem):
>
>
Next, add the following to the end of the file:
 
Changed:
<
<
Printing a certificates DN
$ openssl x509 -in ~/.globus/usercert.pem -noout -subject
>
>
ssl-client-cert-file = <PATH TO HOME DIRECTORY>/.globus/usercred.p12
ssl-authority-files = <PATH TO HOME DIRECTORY>/.globus/usercert.pem
 
Changed:
<
<
Once your certificate is registered for access no addition setup is require to access the trac pages however for access to the subversion repository additional setup is required.
>
>
This assumes that you have your certificate in both PKCS #12 and PEM format in the files usercred.p12 and usercert.pem respectively. Access to Subversion requires both these files. To convert a PKCS #12 file into PEM format, use the openssl command. For example, if the PKCS #12 file were named usercred.p12, you would use the following commands:
 
Changed:
<
<
First if you do not have a .subversion directory in your home directory run svn --version to create one.
>
>
$ openssl pkcs12 -in usercred.p12 -nokeys -clcerts -out usercert.pem
$ openssl pkcs12 -in usercred.p12 -nocerts -out userkey.pem
$ chmod 600 userkey.pem
 
Changed:
<
<
Inside the .subversion directory is the file servers this file requires editing to access the repository. Edit the groups section of the file adding the line:
>
>
You can check that you have configured things correctly by listing the contents of one of the repositories:
 
Changed:
<
<
ppe = *.ppe.gla.ac.uk
>
>
$ svn list https://svn.ppe.gla.ac.uk/test
 
Deleted:
<
<
to create a ppe group. It should look something like:
 
Changed:
<
<
[groups]
# group1 = *.collab.net
# othergroup = repository.blarggitywhoomph.com
# thirdgroup = *.example.com
ppe = *.ppe.gla.ac.uk
>
>

E-mail notification of commits

 
Changed:
<
<
note the [groups] line may need uncommenting by removing any leading #'s. Then add the following to the end of the servers file:

[ppe]
ssl-client-cert-file = /home/user_name/.globus/usercred.p12
ssl-authority-files = /home/user_name/.globus/usercert.pem

Replacing user_name as appropriate. This assumes who have the pkcs12 version of your certificate in /home/user_name/.globus/usercred.p12 and a x509 format copy of your certificate in /home/user_name/.globus/usercert.pem. Access to the subversion repository requires both.

To convert a pkcs12 certificate into a pem format certificate/key file pair, use openssl:

Creating an x509 certificate from a pkcs12 certificate
$ openssl pkcs12 -in usercred.p12 -nokeys -clcerts -out usercert.pem

Creating an x509 key from a pkcs12 certificate
$ openssl pkcs12 -in usercred.p12 -nocerts -out userkey.pem

The userkey.pem should then be made readable and writable only by the user by doing a chmod 600 userkey.pem. Note the password used to encrypt the userkey.pem file should be a strong one, this file is the private key for your grid certificate.

Then place userkey.pem and usercert.pem and usercred.p12 in ~/.globus/

Access to the repository can be tested using:

Testing repository access by listing the contents of the test repository
$ svn list https://svn.ppe.gla.ac.uk/test

you will be asked for your grid certificate password each time you access the repository.

Using a proxy certificate to access the repository

To avoid having to type a password in each time the repository is accessed a proxy certificate can be used. In order to do this the certificate pointed to in the ~/.subversion/servers file must be changed from:

ssl-client-cert-file = /home/user_name/.globus/usercred.p12

to:

ssl-client-cert-file = /tmp/pkcs12up_uXXXX

replacing XXXX with the output of the command id -u.

To create a proxy certificate first source grid-env.sh (or grid-env.csh, see GridServices) and then create the proxy using svn-grid-proxy-init

Creating a proxy certificate to access the svn repository
$ source /data/ppe01/sl5x/x86_64/grid/glite-ui/latest/external/etc/profile.d/grid-env.sh
$ svn-grid-proxy-init

After typing in your grid certificate password the script will generate a proxy valid for 12 hours. This works on Scientific Linux 5 ppe machines but not on Scientific Linux 6 machines.

On external machines the https://twiki.ppe.gla.ac.uk/pub/IT/SubversionRepository/svn-grid-proxy-init script should work on any system where the EGEE gLite tools are installed. For macs the standalone script https://twiki.ppe.gla.ac.uk/pub/IT/SubversionRepository/svn-proxy-init will do the same thing on an apple mac without requiring the gLite tools.

Setting up access with Ubuntu

It is possible that trying to use SVN with Ubuntu can give you the error message

svn: OPTIONS of 'https://ppesvn.physics.gla.ac.uk/svn/test': Could not read status line: SSL error: Key usage violation in certificate has been detected. (https://ppesvn.physics.gla.ac.uk)

If this is the case, it might be something to do with having too recent a version of subversion compared to what is used in SL. The fix (that worked for me) was found here.

Email notification of commits

To setup automatic email notification of commits create a file called !email-notify-list.svn containing a list of email addresses (one email address per line) in the subversion repository. When any changes are made to files in the directory containing !email-notify-list.svn or in any directory below this directory an email will sent out automatically to the email addresses listed in !email-notify-list.svn file. If the project layout follows the suggested subversion layout of branches, tags and trunk directories then the !email-notify-list.svn file should go in the same directory as the branch, tags and trunk directories. eg:

project_name/!email-notify-list.svn
project_name/branches
project_name/tags
project_name/trunk

Multiple !email.notify.list.svn files are also possible for example:

project_name/!email-notify-list.svn
project_name/branches
project_name/tags
project_name/trunk
project_name/trunk/!email-notify-list.svn

people listed in project_name/!email-notify-list.svn will be notified of all changes made to the project and people listed in project_name/trunk/!email-notify-list.svn will only be notified when changes are made in project_name/trunk/ and below.

Notes:

  • In the case of the same email address being listed multiple times (either in the same file or multiple files) only one email will be sent.
  • To edit files beginning with a ! from a linux shell the explanation mark requires escaping, i.e. nano \!email-notify-list.svn.

-- AndrewPickford - 12 Dec 2008

>
>
You can configure Subversion to notify you by e-mail when changes are committed to the repository. To do this, create a file called !email-notify-list.svn within the repository, containing the e-mail addresses (one per line) to be notified. A notification will be sent whenever a file in the same directory as !email-notify-list.svn, or in any subdirectory of the directory containing !email-notify-list.svn, is changed.
 
META FILEATTACHMENT attachment="svn-grid-proxy-init" attr="" comment="script to create a pkcs12 proxy using grid-proxy-init" date="1229100562" name="svn-grid-proxy-init" path="svn-grid-proxy-init" size="220" stream="svn-grid-proxy-init" tmpFilename="/usr/tmp/CGItemp39181" user="AndrewPickford" version="1"
META FILEATTACHMENT attachment="svn-proxy-init" attr="" comment="svn proxy init script for macs" date="1415878548" name="svn-proxy-init" path="svn-proxy-init" size="5006" user="AndrewPickford" version="1"

Revision 132016-04-14 - GordonStewart

Line: 1 to 1
 
META TOPICPARENT name="WebHome"

Local Subversion Repository

Line: 22 to 22
  NB: Browsers will often repeatedly ask for you to choose a certificate at this point. To get around this, you can (in Firefox) choose Edit >> Preferences>> Advanced and click the radio button Select one Automatically in the certificates section.
Changed:
<
<
To request an additional repo contact the SystemAdministrators
>
>
To request an additional repo contact the ITManagement
 

Websvn Access

Line: 51 to 51
 

Setting up access

Changed:
<
<
Access to the ppe subversion repository and the trac web pages is via grid certificate. Only users who have registered their certificate with the SystemAdministrators can access to either the repository or the trac pages. To register your certificate for access to the repository email ppesysman@physics.gla.ac.uk with your certificate distinguished name (DN). This can be found with the openssl command (the example assumes your certificate is in ~/.globus/usercert.pem):
>
>
Access to the ppe subversion repository and the trac web pages is via grid certificate. Only users who have registered their certificate with the ITManagement can access to either the repository or the trac pages. To register your certificate for access to the repository email ppesysman@physics.gla.ac.uk with your certificate distinguished name (DN). This can be found with the openssl command (the example assumes your certificate is in ~/.globus/usercert.pem):
 
Printing a certificates DN

Revision 122014-11-13 - AndrewPickford

Line: 1 to 1
 
META TOPICPARENT name="WebHome"

Local Subversion Repository

Line: 24 to 24
  To request an additional repo contact the SystemAdministrators
Changed:
<
<

Trac Access

>
>

Websvn Access

 
Changed:
<
<
All subversion subversion repositories have corresponding trac pages on the ppe web. They can be accessed at:
>
>
The repos can also be viewed using websvn:
 
Changed:
<
<
>
>
  NB: Browsers will often repeatedly ask for you to choose a certificate at this point. To get around this, you can (in Firefox) choose Edit >> Preferences>> Advanced and click the radio button Select one Automatically in the certificates section.
Line: 75 to 75
 # group1 = *.collab.net # othergroup = repository.blarggitywhoomph.com # thirdgroup = *.example.com
Changed:
<
<
ppe = *.physics.gla.ac.uk
>
>
ppe = *.ppe.gla.ac.uk
 

note the [groups] line may need uncommenting by removing any leading #'s. Then add the following to the end of the servers file:

Revision 112014-11-13 - AndrewPickford

Line: 1 to 1
 
META TOPICPARENT name="WebHome"

Local Subversion Repository

Line: 12 to 12
  Currently there are four subversion repositories:
Changed:
<
<
>
>
  The test repository is as the name suggests for testing and getting used to using subversion. It will be cleaned out and reset on an irregular basis and without notice.
Line: 28 to 28
  All subversion subversion repositories have corresponding trac pages on the ppe web. They can be accessed at:
Changed:
<
<
>
>
  NB: Browsers will often repeatedly ask for you to choose a certificate at this point. To get around this, you can (in Firefox) choose Edit >> Preferences>> Advanced and click the radio button Select one Automatically in the certificates section.
Line: 44 to 44
 
Creating a subdirectory inside the user repo
Changed:
<
<
$ svn mkdir https://ppesvn.physics.gla.ac.uk/svn/user/pickford -m "user repo dir"
>
>
$ svn mkdir https://svn.ppe.gla.ac.uk/user/pickford -m "user repo dir"
 

For organising files/projects the subversion book http://svnbook.red-bean.com/ describes some recommended possible layouts, in the section Planning Your Repository Organization.

Line: 65 to 65
 Inside the .subversion directory is the file servers this file requires editing to access the repository. Edit the groups section of the file adding the line:
Changed:
<
<
ppe = *.physics.gla.ac.uk
>
>
ppe = *.ppe.gla.ac.uk
 

to create a ppe group. It should look something like:

Line: 108 to 108
 
Testing repository access by listing the contents of the test repository
Changed:
<
<
$ svn list https://ppesvn.physics.gla.ac.uk/svn/test
>
>
$ svn list https://svn.ppe.gla.ac.uk/test
 

you will be asked for your grid certificate password each time you access the repository.

Line: 129 to 129
  replacing XXXX with the output of the command id -u.
Changed:
<
<
Then to create a proxy certificate first source grid-env.sh (or grid-env.csh, see GridServices) and then create the proxy using svn-grid-proxy-init
>
>
To create a proxy certificate first source grid-env.sh (or grid-env.csh, see GridServices) and then create the proxy using svn-grid-proxy-init
 
Creating a proxy certificate to access the svn repository
Changed:
<
<
$ source /data/ppe01/sl44/i386/grid/glite-ui/latest/external/etc/profile.d/grid-env.sh
>
>
$ source /data/ppe01/sl5x/x86_64/grid/glite-ui/latest/external/etc/profile.d/grid-env.sh
 
$ svn-grid-proxy-init
Changed:
<
<
After typing in your grid certificate password the script will generate a proxy valid for 12 hours. This works on both Scientific Linux 4 and Scientific Linux 5 ppe machines. On external machines the https://twiki.ppe.gla.ac.uk/pub/IT/SubversionRepository/svn-grid-proxy-init script should work on any system where the EGEE gLite tools are installed.
>
>
After typing in your grid certificate password the script will generate a proxy valid for 12 hours. This works on Scientific Linux 5 ppe machines but not on Scientific Linux 6 machines.

On external machines the https://twiki.ppe.gla.ac.uk/pub/IT/SubversionRepository/svn-grid-proxy-init script should work on any system where the EGEE gLite tools are installed. For macs the standalone script https://twiki.ppe.gla.ac.uk/pub/IT/SubversionRepository/svn-proxy-init will do the same thing on an apple mac without requiring the gLite tools.

 

Setting up access with Ubuntu

Line: 181 to 184
 -- AndrewPickford - 12 Dec 2008

META FILEATTACHMENT attachment="svn-grid-proxy-init" attr="" comment="script to create a pkcs12 proxy using grid-proxy-init" date="1229100562" name="svn-grid-proxy-init" path="svn-grid-proxy-init" size="220" stream="svn-grid-proxy-init" tmpFilename="/usr/tmp/CGItemp39181" user="AndrewPickford" version="1"
Added:
>
>
META FILEATTACHMENT attachment="svn-proxy-init" attr="" comment="svn proxy init script for macs" date="1415878548" name="svn-proxy-init" path="svn-proxy-init" size="5006" user="AndrewPickford" version="1"

Revision 102011-12-15 - AndrewPickford

Line: 1 to 1
 
META TOPICPARENT name="WebHome"

Local Subversion Repository

Line: 151 to 151
 

Email notification of commits

Changed:
<
<
To setup automatic email notification of commits create a file called !email-notify-list.svn containing a list of email addresses in the subversion repository. When any changes are made to files in the directory containing !email-notify-list.svn or in any directory below this directory an email will sent out automatically to the email addresses listed in !email-notify-list.svn file. If the project layout follows the suggested subversion layout of branches, tags and trunk directories then the !email-notify-list.svn file should go in the same directory as the branch, tags and trunk directories. eg:
>
>
To setup automatic email notification of commits create a file called !email-notify-list.svn containing a list of email addresses (one email address per line) in the subversion repository. When any changes are made to files in the directory containing !email-notify-list.svn or in any directory below this directory an email will sent out automatically to the email addresses listed in !email-notify-list.svn file. If the project layout follows the suggested subversion layout of branches, tags and trunk directories then the !email-notify-list.svn file should go in the same directory as the branch, tags and trunk directories. eg:
 
project_name/!email-notify-list.svn

Revision 92011-10-02 - AlistairGemmell

Line: 1 to 1
 
META TOPICPARENT name="WebHome"

Local Subversion Repository

Line: 139 to 139
  After typing in your grid certificate password the script will generate a proxy valid for 12 hours. This works on both Scientific Linux 4 and Scientific Linux 5 ppe machines. On external machines the https://twiki.ppe.gla.ac.uk/pub/IT/SubversionRepository/svn-grid-proxy-init script should work on any system where the EGEE gLite tools are installed.
Added:
>
>

Setting up access with Ubuntu

It is possible that trying to use SVN with Ubuntu can give you the error message

svn: OPTIONS of 'https://ppesvn.physics.gla.ac.uk/svn/test': Could not read status line: SSL error: Key usage violation in certificate has been detected. (https://ppesvn.physics.gla.ac.uk)

If this is the case, it might be something to do with having too recent a version of subversion compared to what is used in SL. The fix (that worked for me) was found here.

 

Email notification of commits

To setup automatic email notification of commits create a file called !email-notify-list.svn containing a list of email addresses in the subversion repository. When any changes are made to files in the directory containing !email-notify-list.svn or in any directory below this directory an email will sent out automatically to the email addresses listed in !email-notify-list.svn file. If the project layout follows the suggested subversion layout of branches, tags and trunk directories then the !email-notify-list.svn file should go in the same directory as the branch, tags and trunk directories. eg:

Revision 82009-10-13 - ChrisCollins

Line: 1 to 1
 
META TOPICPARENT name="WebHome"

Local Subversion Repository

Line: 20 to 20
  The test repository is as the name suggests for testing and getting used to using subversion. It will be cleaned out and reset on an irregular basis and without notice.
Added:
>
>
NB: Browsers will often repeatedly ask for you to choose a certificate at this point. To get around this, you can (in Firefox) choose Edit >> Preferences>> Advanced and click the radio button Select one Automatically in the certificates section.
 To request an additional repo contact the SystemAdministrators

Trac Access

Line: 32 to 34
 
Added:
>
>
NB: Browsers will often repeatedly ask for you to choose a certificate at this point. To get around this, you can (in Firefox) choose Edit >> Preferences>> Advanced and click the radio button Select one Automatically in the certificates section.
 

Using the repositories

All users, once registered to access the repositories, have full read and write access to any files in any of the repositories. So please take care especially when committing changes and when setting up new directories.

Revision 62009-05-14 - AndrewPickford

Line: 1 to 1
 
META TOPICPARENT name="WebHome"

Local Subversion Repository

Line: 52 to 52
 
$ openssl x509 -in ~/.globus/usercert.pem -noout -subject
Changed:
<
<
Once your certificate is registered for access no addition setup is require to access the trac pages however for access to the subversion repository additional setup is required. If you do not have a .subversion directory in your home directory run svn --version to create one.
>
>
Once your certificate is registered for access no addition setup is require to access the trac pages however for access to the subversion repository additional setup is required.
 
Changed:
<
<
Inside the .subversion directory is the file servers this file requires editing to access the repository. Edit the groups section of the file adding the line:
>
>
First if you do not have a .subversion directory in your home directory run svn --version to create one.

Inside the .subversion directory is the file servers this file requires editing to access the repository. Edit the groups section of the file adding the line:

 
ppe = *.physics.gla.ac.uk
Line: 70 to 72
 ppe = *.physics.gla.ac.uk
Changed:
<
<
then add the following to the end of the servers file:
>
>
note the [groups] line may need uncommenting by removing any leading #'s. Then add the following to the end of the servers file:
 
[ppe]

Revision 52009-05-13 - AndrewPickford

Line: 1 to 1
 
META TOPICPARENT name="WebHome"

Local Subversion Repository

Line: 10 to 10
 

Repository Organisation

Changed:
<
<
Currently there are three subversion repositories:
>
>
Currently there are four subversion repositories:
 
Added:
>
>
 
Line: 24 to 25
  All subversion subversion repositories have corresponding trac pages on the ppe web. They can be accessed at:
Added:
>
>
 

Revision 42009-02-19 - AndrewPickford

Line: 1 to 1
 
META TOPICPARENT name="WebHome"

Local Subversion Repository

Line: 12 to 12
  Currently there are three subversion repositories:
Changed:
<
<
>
>
  The test repository is as the name suggests for testing and getting used to using subversion. It will be cleaned out and reset on an irregular basis and without notice.
Line: 129 to 129
  After typing in your grid certificate password the script will generate a proxy valid for 12 hours. This works on both Scientific Linux 4 and Scientific Linux 5 ppe machines. On external machines the https://twiki.ppe.gla.ac.uk/pub/IT/SubversionRepository/svn-grid-proxy-init script should work on any system where the EGEE gLite tools are installed.
Added:
>
>

Email notification of commits

To setup automatic email notification of commits create a file called !email-notify-list.svn containing a list of email addresses in the subversion repository. When any changes are made to files in the directory containing !email-notify-list.svn or in any directory below this directory an email will sent out automatically to the email addresses listed in !email-notify-list.svn file. If the project layout follows the suggested subversion layout of branches, tags and trunk directories then the !email-notify-list.svn file should go in the same directory as the branch, tags and trunk directories. eg:

project_name/!email-notify-list.svn
project_name/branches
project_name/tags
project_name/trunk

Multiple !email.notify.list.svn files are also possible for example:

project_name/!email-notify-list.svn
project_name/branches
project_name/tags
project_name/trunk
project_name/trunk/!email-notify-list.svn

people listed in project_name/!email-notify-list.svn will be notified of all changes made to the project and people listed in project_name/trunk/!email-notify-list.svn will only be notified when changes are made in project_name/trunk/ and below.

Notes:

  • In the case of the same email address being listed multiple times (either in the same file or multiple files) only one email will be sent.
  • To edit files beginning with a ! from a linux shell the explanation mark requires escaping, i.e. nano \!email-notify-list.svn.
  -- AndrewPickford - 12 Dec 2008

Revision 32009-01-25 - AndrewPickford

Line: 1 to 1
 
META TOPICPARENT name="WebHome"

Local Subversion Repository

Changed:
<
<
A local subversion repository is being setup, when ready this page will describe how to access it.
>
>
A local subversion repository is being setup, when ready this page will describe how to access it.

For more information on subversion see the Subversion book or the Subversion FAQs.

 

Repository Organisation

Changed:
<
<
Currently there are two subversion repositories:
>
>
Currently there are three subversion repositories:
 
Added:
>
>

The test repository is as the name suggests for testing and getting used to using subversion. It will be cleaned out and reset on an irregular basis and without notice.

 
Changed:
<
<
The test repository is as the name suggests for testing and getting used to using subversion. It will be cleaned out and reset on an irregular and without notice basis.
>
>
To request an additional repo contact the SystemAdministrators
 

Trac Access

Line: 21 to 26
 
Added:
>
>

Using the repositories

All users, once registered to access the repositories, have full read and write access to any files in any of the repositories. So please take care especially when committing changes and when setting up new directories.

To help keep some order in the user repository please do not commit files into the top level repo directory. Instead create a directory named after your user name and store personal files/projects under this directory.

Creating a subdirectory inside the user repo
$ svn mkdir https://ppesvn.physics.gla.ac.uk/svn/user/pickford -m "user repo dir"

For organising files/projects the subversion book http://svnbook.red-bean.com/ describes some recommended possible layouts, in the section Planning Your Repository Organization.

 

Setting up access

Line: 31 to 50
 
$ openssl x509 -in ~/.globus/usercert.pem -noout -subject
Changed:
<
<
Once your certificate this registered for access no addition setup is require to access the trac pages however for access to the subversion repository additional setup is required. If you do not have a .subversion directory in your home directory run svn --version to create one.
>
>
Once your certificate is registered for access no addition setup is require to access the trac pages however for access to the subversion repository additional setup is required. If you do not have a .subversion directory in your home directory run svn --version to create one.
  Inside the .subversion directory is the file servers this file requires editing to access the repository. Edit the groups section of the file adding the line:

Revision 22008-12-17 - AndrewPickford

Line: 1 to 1
 
META TOPICPARENT name="WebHome"

Local Subversion Repository

A local subversion repository is being setup, when ready this page will describe how to access it.

Changed:
<
<

Setting up access

>
>
 
Changed:
<
<
Access to the ppe subversion repository is via grid certificate. Only users who have registered their certificate with the SystemAdministrators can access the repository. To register your certificate for access to the repository email ppesysman@physics.gla.ac.uk with your certificate distinguished name (DN). This can be found with the openssl command (the example assumes your certificate is in ~/.globus/usercert.pem):
>
>

Repository Organisation

Currently there are two subversion repositories:

The test repository is as the name suggests for testing and getting used to using subversion. It will be cleaned out and reset on an irregular and without notice basis.

Trac Access

All subversion subversion repositories have corresponding trac pages on the ppe web. They can be accessed at:

Setting up access

Access to the ppe subversion repository and the trac web pages is via grid certificate. Only users who have registered their certificate with the SystemAdministrators can access to either the repository or the trac pages. To register your certificate for access to the repository email ppesysman@physics.gla.ac.uk with your certificate distinguished name (DN). This can be found with the openssl command (the example assumes your certificate is in ~/.globus/usercert.pem):

 
Printing a certificates DN
$ openssl x509 -in ~/.globus/usercert.pem -noout -subject
Changed:
<
<
Once your certificate this registered for access subversion needs to be setup. If you do not have a .subversion directory in your home directory run svn --version to create one.
>
>
Once your certificate this registered for access no addition setup is require to access the trac pages however for access to the subversion repository additional setup is required. If you do not have a .subversion directory in your home directory run svn --version to create one.
  Inside the .subversion directory is the file servers this file requires editing to access the repository. Edit the groups section of the file adding the line:
Line: 66 to 84
  you will be asked for your grid certificate password each time you access the repository.
Changed:
<
<

Using a proxy certificate to access the repository

>
>

Using a proxy certificate to access the repository

  To avoid having to type a password in each time the repository is accessed a proxy certificate can be used. In order to do this the certificate pointed to in the ~/.subversion/servers file must be changed from:

Revision 12008-12-12 - AndrewPickford

Line: 1 to 1
Added:
>
>
META TOPICPARENT name="WebHome"

Local Subversion Repository

A local subversion repository is being setup, when ready this page will describe how to access it.

Setting up access

Access to the ppe subversion repository is via grid certificate. Only users who have registered their certificate with the SystemAdministrators can access the repository. To register your certificate for access to the repository email ppesysman@physics.gla.ac.uk with your certificate distinguished name (DN). This can be found with the openssl command (the example assumes your certificate is in ~/.globus/usercert.pem):

Printing a certificates DN
$ openssl x509 -in ~/.globus/usercert.pem -noout -subject

Once your certificate this registered for access subversion needs to be setup. If you do not have a .subversion directory in your home directory run svn --version to create one.

Inside the .subversion directory is the file servers this file requires editing to access the repository. Edit the groups section of the file adding the line:

ppe = *.physics.gla.ac.uk

to create a ppe group. It should look something like:

[groups]
# group1 = *.collab.net
# othergroup = repository.blarggitywhoomph.com
# thirdgroup = *.example.com
ppe = *.physics.gla.ac.uk

then add the following to the end of the servers file:

[ppe]
ssl-client-cert-file = /home/user_name/.globus/usercred.p12
ssl-authority-files = /home/user_name/.globus/usercert.pem

Replacing user_name as appropriate. This assumes who have the pkcs12 version of your certificate in /home/user_name/.globus/usercred.p12 and a x509 format copy of your certificate in /home/user_name/.globus/usercert.pem. Access to the subversion repository requires both.

To convert a pkcs12 certificate into a pem format certificate/key file pair, use openssl:

Creating an x509 certificate from a pkcs12 certificate
$ openssl pkcs12 -in usercred.p12 -nokeys -clcerts -out usercert.pem

Creating an x509 key from a pkcs12 certificate
$ openssl pkcs12 -in usercred.p12 -nocerts -out userkey.pem

The userkey.pem should then be made readable and writable only by the user by doing a chmod 600 userkey.pem. Note the password used to encrypt the userkey.pem file should be a strong one, this file is the private key for your grid certificate.

Then place userkey.pem and usercert.pem and usercred.p12 in ~/.globus/

Access to the repository can be tested using:

Testing repository access by listing the contents of the test repository
$ svn list https://ppesvn.physics.gla.ac.uk/svn/test

you will be asked for your grid certificate password each time you access the repository.

Using a proxy certificate to access the repository

To avoid having to type a password in each time the repository is accessed a proxy certificate can be used. In order to do this the certificate pointed to in the ~/.subversion/servers file must be changed from:

ssl-client-cert-file = /home/user_name/.globus/usercred.p12

to:

ssl-client-cert-file = /tmp/pkcs12up_uXXXX

replacing XXXX with the output of the command id -u.

Then to create a proxy certificate first source grid-env.sh (or grid-env.csh, see GridServices) and then create the proxy using svn-grid-proxy-init

Creating a proxy certificate to access the svn repository
$ source /data/ppe01/sl44/i386/grid/glite-ui/latest/external/etc/profile.d/grid-env.sh
$ svn-grid-proxy-init

After typing in your grid certificate password the script will generate a proxy valid for 12 hours. This works on both Scientific Linux 4 and Scientific Linux 5 ppe machines. On external machines the https://twiki.ppe.gla.ac.uk/pub/IT/SubversionRepository/svn-grid-proxy-init script should work on any system where the EGEE gLite tools are installed.

-- AndrewPickford - 12 Dec 2008

META FILEATTACHMENT attachment="svn-grid-proxy-init" attr="" comment="script to create a pkcs12 proxy using grid-proxy-init" date="1229100562" name="svn-grid-proxy-init" path="svn-grid-proxy-init" size="220" stream="svn-grid-proxy-init" tmpFilename="/usr/tmp/CGItemp39181" user="AndrewPickford" version="1"
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2020 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback