Difference between revisions of "SVN"
(→Install SVN on the Jenkins system) |
|||
(3 intermediate revisions by one other user not shown) | |||
Line 1: | Line 1: | ||
== Install SVN on the Jenkins system == |
== Install SVN on the Jenkins system == |
||
<code>sudo yum install subversion |
<code>sudo yum install subversion |
||
+ | |||
svn --version</code> |
svn --version</code> |
||
Line 6: | Line 7: | ||
The <code>jenkins</code> user will be executing the script for LRM. |
The <code>jenkins</code> user will be executing the script for LRM. |
||
Log in as <code>jenkins</code>. |
Log in as <code>jenkins</code>. |
||
− | create a test directory, like mkdir ~jenkins/jobs/test |
+ | create a test directory, like '''<code>mkdir ~jenkins/jobs/test</code>''' |
cd to the test directory |
cd to the test directory |
||
run an SVN checkout command for a repository to access. For example: |
run an SVN checkout command for a repository to access. For example: |
||
− | svn checkout https://svns.lingoport.net/lrm/client/ |
+ | <code>svn checkout https://svns.lingoport.net/lrm/client/</code> |
+ | |||
+ | Give a first username / pwd, etc. |
||
+ | |||
+ | Edit <code>~/.subversion/servers</code> and define your global settings. Here is an example of how one could do it. A lot of possible configurations are possible. |
||
+ | <pre> |
||
+ | [global] |
||
+ | |||
+ | # Password / passphrase caching parameters: |
||
+ | store-passwords = yes |
||
+ | store-plaintext-passwords = yes |
||
+ | </pre> |
||
+ | |||
+ | Go back to the test directory, remove all files and checkout again: |
||
+ | |||
It will ask to persist the credentials: Choose permanent. |
It will ask to persist the credentials: Choose permanent. |
||
Line 18: | Line 33: | ||
SVN will checkout the project and then remember the credentials. |
SVN will checkout the project and then remember the credentials. |
||
+ | |||
+ | == Test == |
||
+ | Go to the test directory. |
||
+ | |||
+ | Remove all files (<code> rm -rf * </code> from that test directory) |
||
+ | |||
+ | Run an SVN checkout command: It won't ask for the credentials any longer as they are stored. |
Latest revision as of 15:46, 4 December 2018
Install SVN on the Jenkins system
sudo yum install subversion
svn --version
SVN for jenkins
The jenkins
user will be executing the script for LRM.
Log in as jenkins
.
create a test directory, like mkdir ~jenkins/jobs/test
cd to the test directory
run an SVN checkout command for a repository to access. For example:
svn checkout https://svns.lingoport.net/lrm/client/
Give a first username / pwd, etc.
Edit ~/.subversion/servers
and define your global settings. Here is an example of how one could do it. A lot of possible configurations are possible.
[global] # Password / passphrase caching parameters: store-passwords = yes store-plaintext-passwords = yes
Go back to the test directory, remove all files and checkout again:
It will ask to persist the credentials: Choose permanent.
It will ask for the password for 'jenkins': Don't give any It will ask for a username: Give that username (then pwd) for that access.
SVN will checkout the project and then remember the credentials.
Test
Go to the test directory.
Remove all files ( rm -rf *
from that test directory)
Run an SVN checkout command: It won't ask for the credentials any longer as they are stored.