user8603030
user8603030

Reputation:

Where to find option to change workspace path location in Jenkins?

I have recently installed Jenkin autodeploy tool. But I want to change it's default workspace location path which is pointing to my installable directory(c:) but now I want to keep my all projects in other drive so for that need to change workspace location.

But in my jenkin portal I am not finding that option.

Can anyone suggest me where can I find that?

Please see screen shot as well. See Here

Thanks Vijay

Upvotes: 3

Views: 16723

Answers (2)

Nick Jones
Nick Jones

Reputation: 4465

This option was removed in 2.121:

Build Record Root Directory and Workspace Root Directory can no longer be configured through the UI as these options were generally unsafe to use while Jenkins was running. Instead, these locations can now be customized using system properties on startup. Existing changes to these options will be retained unless and until overridden at startup.

Further details under JENKINS-50164.

Under the new model, one sets the workspace root with the hudson.model.Slave.workspaceRoot system property, which can be set as follows:

-Dhudson.model.Slave.workspaceRoot=/whatever

The exact mechanism for setting a property like this varies by OS/platform, but many typical options are described here. The full list of available system properties is on the Jenkins Wiki.

Upvotes: 6

Malenko
Malenko

Reputation: 743

Since I also couldn't find under Jenkins -> Manage Jenkins -> Configure System the Advanced option. Where you can add a different directory for Build Record Root Directory. You can change this property directly in the config.xml in the root folder of your Jenkins.

enter image description here

Here you can update the property to what you need to.

I would recommend using the following structure,

/path_to_the_folder/${ITEM_FULLNAME}/builds

Because using ${ITEM_FULLNAME} in the path, will put the builds of every job into its own folder.

Upvotes: 5

Related Questions