peewhy
peewhy

Reputation: 1

Hudson creates files with wrong user name

I am running hudson in Resin, startet by user joe. Builds use Maven but the failed with the following error:

Failed to chmod /local/.hudson/jobs/MyJob/site/apidocs/background.png : Operation not permitted

When looking at the file, I can see it has been created (it is a copy comming from the scm) with another owner name, so Hudson can't chmod it.

I did not find any configuration option about user name use for builds, and I though the use name used to launch Hudson was used. But it seems it is not the case.

BTW, the hudson workdir (.hudson) was copied from another installation and chown was run recursively to change the owner. Before the build, all files belong to user 'joe'. After the build, some new files belong to the user of the original workdir. So I guess ther must be a configuration somewher saying that for some operation, the former user name is used.

Any idea where this can be configured ?

Upvotes: 0

Views: 161

Answers (1)

Jayan
Jayan

Reputation: 18458

I guess the username you see the same as the user running resin. Hudson runs under a user and all operations are performed with the same user(creation of file etc).

Work around: You may create tasks that does ssh/rsh to correct user and then do actions that you want under the user.

Upvotes: 1

Related Questions