[jbosstools-issues] [JBoss JIRA] (JBIDE-15375) File permissions for OpenShift actions hooks are sometimes incorrect when cloning repo

Andre Dietisheim (JIRA) jira-events at lists.jboss.org
Tue Aug 27 10:13:26 EDT 2013


    [ https://issues.jboss.org/browse/JBIDE-15375?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12799567#comment-12799567 ] 

Andre Dietisheim edited comment on JBIDE-15375 at 8/27/13 10:12 AM:
--------------------------------------------------------------------

So if I read you right you see file-permissions being wrong when clonging via EGit. When trying to reproduce I could spot the following file-permissions in the action-hooks directory:

- cloning via cmd line:
{code}
-rwxrwxr-x 1 adietish adietish 265 Aug 26 11:41 build
-rwxrwxr-x 1 adietish adietish 249 Aug 26 11:41 deploy
-rwxrwxr-x 1 adietish adietish 186 Aug 26 11:41 post_deploy
-rwxrwxr-x 1 adietish adietish 257 Aug 26 11:41 pre_build
{code}

- cloning via EGit:
{code}
-rwxrw-r-- 1 adietish adietish 265 Aug 26 11:43 build
-rwxrw-r-- 1 adietish adietish 249 Aug 26 11:43 deploy
-rwxrw-r-- 1 adietish adietish 186 Aug 26 11:43 post_deploy
-rwxrw-r-- 1 adietish adietish 257 Aug 26 11:43 pre_build
{code}

We had a similar issue when merging an OpenShift application into an existing project in https://issues.jboss.org/browse/JBIDE-13217. In this issue whe had no execute rights at all, after our fix we had the execute permissions set for the owner as it happens when cloning via EGit.
Back in that issue we were told by the OpenShift team that "on openshift some, not all scripts execution depends on this +x being set.". Furthermore we were told that execute rights for owner is sufficient. 
                
      was (Author: adietish):
    So if I read you right you see file-permissions being wrong when clonging via EGit. When trying to reproduce I could spot the following file-permissions in the action-hooks directory:

- cloning via cmd line:
{code}
-rwxrwxr-x 1 adietish adietish 265 Aug 26 11:41 build
-rwxrwxr-x 1 adietish adietish 249 Aug 26 11:41 deploy
-rwxrwxr-x 1 adietish adietish 186 Aug 26 11:41 post_deploy
-rwxrwxr-x 1 adietish adietish 257 Aug 26 11:41 pre_build
{code}

- cloning via EGit:
{code}
-rwxrw-r-- 1 adietish adietish 265 Aug 26 11:43 build
-rwxrw-r-- 1 adietish adietish 249 Aug 26 11:43 deploy
-rwxrw-r-- 1 adietish adietish 186 Aug 26 11:43 post_deploy
-rwxrw-r-- 1 adietish adietish 257 Aug 26 11:43 pre_build
{code}

We had a similar issue when merging an OpenShift application into an existing project in https://issues.jboss.org/browse/JBIDE-13217. In this issue whe had no execute rights at all, after our fix we had the execute permissions set for the owner as it happens when cloning via EGit.

                  
> File permissions for OpenShift actions hooks are sometimes incorrect when cloning repo
> --------------------------------------------------------------------------------------
>
>                 Key: JBIDE-15375
>                 URL: https://issues.jboss.org/browse/JBIDE-15375
>             Project: Tools (JBoss Tools)
>          Issue Type: Bug
>          Components: openshift
>    Affects Versions: 4.1.0.Final
>         Environment: Windows
>            Reporter: Andy Goldstein
>
> (filing on behalf of another user who is having login issues)
> When I clone a git repo (git at ...:user/myapp.git) using the Eclipse plugins, the file permissions for my action_hooks are set as:
> {code}
> /cygdrive/c/Users/user/git/myapp/.openshift/action_hooks
> $ ls -l
> total 45
> -rwx------+ 1 Administrators Domain Users  265 Aug 22 14:38 build
> -rwx------+ 1 Administrators Domain Users  264 Aug 22 14:38 deploy
> -rwx------+ 1 Administrators Domain Users  186 Aug 22 14:38 post_deploy
> -rwx------+ 1 Administrators Domain Users  645 Aug 22 14:38 post_start_jbossas-7
> -rwx------+ 1 Administrators Domain Users  645 Aug 22 14:38 post_stop_jbossas-7
> -rwx------+ 1 Administrators Domain Users  640 Aug 22 14:38 pre_build
> -rwx------+ 1 Administrators Domain Users  272 Aug 22 14:38 pre_build_jbossas-7
> -rwx------+ 1 Administrators Domain Users  645 Aug 22 14:38 pre_start_jbossas-7
> -rwx------+ 1 Administrators Domain Users  645 Aug 22 14:38 pre_stop_jbossas-7
> {code}
> When they are pushed to OpenShift, they can't be executed.
> {code}
> /var/lib/openshift/5216951d76c3b22b77000362/app-root/runtime/repo/.openshift/action_hooks/post_stop_jbossjsw-1.0: Permission denied
> remote: Failed to stop jbossjsw-1.0
> To
> ssh://5216951d76c3b22b77000362@ppon-tsujarit.qa02.shift.paypal.com/~/git/pp
> on.git/
> ! [remote rejected] master -> master (pre-receive hook declined)
> error: failed to push some refs to
> {code}
> On a different machine, when I clone using Eclipse, the file permission are set as expected:
> {code}
> -rwxr-xr-x 1 Administrators Domain Users  270 Aug 22 11:25 build
> -rwxr-xr-x 1 Administrators Domain Users  271 Aug 22 11:25 deploy
> -rwxr-xr-x 1 Administrators Domain Users  189 Aug 22 11:25 post_deploy
> -rwxr-xr-x 1 Administrators Domain Users  659 Aug 22 11:25 post_start_jbossas-7
> -rwxr-xr-x 1 Administrators Domain Users  659 Aug 22 11:25 post_stop_jbossas-7
> -rwxr-xr-x 1 Administrators Domain Users  650 Aug 22 11:25 pre_build
> -rwxr-xr-x 1 Administrators Domain Users  277 Aug 22 11:25 pre_build_jbossas-7
> -rwxr-xr-x 1 Administrators Domain Users  659 Aug 22 11:25 pre_start_jbossas-7
> -rwxr-xr-x 1 Administrators Domain Users  659 Aug 22 11:25 pre_stop_jbossas-7
> {code}
> Is it possible to set the file perms to +x on the action_hooks?

--
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


More information about the jbosstools-issues mailing list