I am trying to test each step by step for creating a Jenkins pipeline job. For that, I am trying to test with svn checkout first for my sample pipeline. And I added declarative pipeline and added the svn checkout step. But I am getting the error like following:
svn: E215004: No more credentials or we tried too many times.
And I added my pipeline job like the following:
pipeline
{
agent any
stages
{
stage ('Checkout')
{
steps
{
sh 'svn co http://192.168.16.174/repository/pipeline'
}
}
}
}
My observation
According to my observation, I did not added the svn repository credentials here. I am new to Jenkins and CI/CD. When I learning I saw that we can create credentials in Jenkins and can refer that ID here. But I did not got exactly how to add. Also another thing is that, I planned to add this in a Jenkinsfile which is storing in repository root directory.
My confusion
- If I am referring the created credentials here , how i can refer?
- If I am keeping my Jenkinsfile in my project root directory to pull, Is there any problem if I am adding the credentials ID inside my Jenkinsfile?
I have here lot of confusions related with credentials inside Jenkinsfile. Please correct me if I went in wrong direction.