Ryan Schmidt wrote:
> On Jun 4, 2009, at 01:08, J. Bakshi wrote:
>
>
>>>> It repeated again and again even after " svn cleanup". I also
>>>> tried " chmod -R 777 .svn" once more but the same error.
>>>>
>>> Please confirm: even after running "svn cleanup", running "svn
>>> update" tells you the working copy is locked? Is this only when
>>> running "svn update" from the hook script or also when running "svn
>>> update" from the command line?
>>>
>> "svn up" from command line is working well
>>
>> `````````````````````````````````````````````````
>> [root_at_192 POSTCOMMIT]# vim newfile
>> [root_at_192 POSTCOMMIT]# svn commit -m "check 24" newfile
>> Sending newfile
>> Transmitting file data .
>> Committed revision 24.
>>
>> Warning: 'post-commit' hook failed with error output:
>> svn: Working copy '/var/www/html/POSTCOMMIT' locked
>> svn: run 'svn cleanup' to remove locks (type 'svn help cleanup' for
>> details)
>>
>> [root_at_192 POSTCOMMIT]# svn cleanup
>> [root_at_192 POSTCOMMIT]# svn up newfile
>> At revision 24.
>>
>
> Wait. You are committing from within the POSTCOMMIT directory! So of
> course the working copy will be locked -- a commit is currently in
> progress in it.
>
> You should not be committing from the POSTCOMMIT directory. That
> working copy should only be manipulated by the post-commit hook, and
> not by you.
>
> Get a different working copy, somewhere else, and commit in it. Your
> post-commit hook should be working fine.
>
Hello Ryan,
Thanks for your kind guidance. This time I have created a new folder and
chekout the repo within that folder . Then I did some modification in
the "newfile" and tried to commit. As you expected there is no such
errors as before. The repo has been updated BUT post-commit failed with
``````````````````````````````````````````````````````````````````````````
Sending newfile
Transmitting file data .
Committed revision 36.
Warning: 'post-commit' hook failed with error output:
Error validating server certificate for 'https://192.168.1.1:443':
- The certificate is not issued by a trusted authority. Use the
fingerprint to validate the certificate manually!
- The certificate hostname does not match.
Certificate information:
- Hostname: gateway.clarkconnect.lan
- Valid: from Jul 8 05:19:27 2008 GMT until Jul 6 05:19:27 2018 GMT
- Issuer: Typo3, Kolkata Infoservices Pvt Ltd, Kolkata, West Bengal, IN
- Fingerprint: 10:ea:91:68:4e:46:c8:71:5b:d6:98:db:38:2a:cb:12:b2:bd:61:15
(R)eject, accept (t)emporarily or accept (p)ermanently? svn: PROPFIND
request failed on '/repos/test'
svn: PROPFIND of '/repos/test': Server certificate verification failed:
certificate issued for a different hostname, issuer is not trusted
(https://192.168.1.1)
``````````````````````````````````````````````````````````````````````````````````
Surprisingly svn list https://192.168.1.1/repos/test with out any
hitch.
Also the manual test as you suggested is working well
`````````````````````````````````````````````
env -i ./post-commit /var/www/html/POSTCOMMIT/ 36
svn post commit called
U /var/www/html/POSTCOMMIT/newfile
```````````````````````````````````````````````
What might be then the problem with updating via https ? svn list is
working well but not the hook !!!
Here is again my post-commit script
``````````````````````````````````````````````````
#! /bin/bash
#REPOS="$1"
#REV="$2"
echo " svn post commit called "
/usr/bin/svn up /var/www/html/POSTCOMMIT || exit $?
````````````````````````````````````````````````````````
Please suggest any mistake which I might still overlooking ???
>
>
>>> Note also that hook scripts run in an empty environment. When you
>>> manually execute the hook script, it inherits the environment (PATH,
>>> etc.) from your shell and is thus not necessarily a good test. You
>>> can get closer by running the hook script through the env command to
>>> clear the environment:
>>>
>>> env -i ./post-commit /path/to/repo $REV
>>>
>> Ok, I have done it
>>
>> ````````````````````````````
>> env -i ./post-commit https://192.168.1.1:/repos/test
>> svn post commit called
>> At revision 24.
>> ~~~~~~~~~~~~~~~~~
>>
>
> It's not really relevant here, since your post-commit hook doesn't
> use any of the parameters given to it, but note that the first
> parameter to the post-commit script is the path to the repository on
> disk, not its URL; and the second parameter is the revision that was
> just committed.
>
> ------------------------------------------------------
> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2359544
>
> To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
>
>
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2359599
To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-06-05 07:23:29 CEST