Issue Type: Bug Bug
Affects Versions: current
Assignee: vjuranek
Components: ws-cleanup
Created: 21/Apr/14 12:58 AM
Description:

Some projects create root owned files in the project's work directory. The project work space cannot be cleaned up using ws-cleanup plugin before building the project again, because root-owned files cannot be deleted.

Here are the steps to test:
1. Select "Delete workspace before build starts
2. Clicking "Advanced" button
3. Enter command "sudo rm -rf %s" into "External Deletion Command".
4. Add build step to do "ls -alF" so that you can see if the previous build's files exists or did the clean-up work.
5. Start rebuilding the project.

I have tried this on a slave host and it doesn't work there, at least.

The jenkins-user is in sudoers file (in the slave host) and sudo is configured not to require password.

An interesting detail is that the "/var/log/auth.log" shows a log row for a correct command-line, but that still doesn't work:

Apr 21 03:30:06 imx7 sudo:  jenkins : TTY=unknown ; PWD=/var/lib/jenkins ; USER=root ; COMMAND=/bin/rm -rf "/var/lib/jenkins/workspace/my-test-project-with-root-owned-files"
Environment: Ubuntu 12.04 LTS
Jenkins WAR v1.559
ws-clean plug-in v0.20

    
Project: Jenkins
Priority: Major Major
Reporter: Harry Flink
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira

--
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to