On 1/20/06 9:15 AM, "Frank Russo" <[EMAIL PROTECTED]> wrote:

> I'm trying to use wagon to deploy to an internal server. We use ssh2, so
> I read that I'm supposed to use the sftp protocol.
>  
> Here are my entries in pom.xml:
> 
> ...
>        <extensions>
>            <extension>
>                <groupId>org.apache.maven.wagon</groupId>
>                <artifactId>wagon-ssh</artifactId>
>                <version>1.0-alpha-6</version>
>            </extension>
>        </extensions>
> ...
> 
>    <distributionManagement>
>        <repository>
>            <id>internal_repository</id>
>            <name>Internal Repository</name>
>            <url>s">ftp://internalrepo/maven_repository/</url>
<ftp://internalrepo/maven_repository/>
>        </repository>
>        <snapshotRepository>
>            <id>internal_repository</id>
>            <name>Internal Repository</name>
>            <url>s">ftp://internalrepo/maven_repository/</url>
<ftp://internalrepo/maven_repository/>
>        </snapshotRepository>
>    </distributionManagement>
> 
> Entries in settings.xml:
> 
>    <server>
>      <id>internal_repository</id>
>      <username>username</username>
>      <password>password</password>
>    </server>

Hmmm...I'm using Maven 2.0.2 as well and ssh2/sftp works for me, but I hate
putting my passphrase for my SSH key in a file. I prefer to use ssh-agent to
supply it. (I'm on Mac OSX, so it's basically UN*X.)

I'd prefer to use scpexe, and that works except that the g:w permission is
being stripped from my directories. My pom.xml and settings.xml are the same
as yours for sftp and the only changes for scpexe are to replace the sftp
with scpexe and in the <server> element in settings.xml I have the
following:

      <filePermissions>774</filePermissions>
      <directoryPermissions>775</directoryPermissions>

And of course, although I supply a username I don't supply a password.

Running "mvn -X -e deploy" gives me a lot of output, but I think the
relevant part is:

> [INFO] [deploy:deploy]
> [DEBUG] adding permissions to wagon connection: 774 775
> Uploading: 
> scpexe://myhost/mypathtorepo/edu/ku/middleware/argusfilter/2.5b1/argusfilter-2
> .5b1.jar 
> 4096/?^M8192/?^M12288/?^M16384/?^M19350/?^M[INFO] Retrieving previous metadata
> from itcm-repository
> [INFO] Uploading repository metadata for: 'artifact
> edu.ku.middleware:argusfilter'
> [DEBUG] adding permissions to wagon connection: 774 775
> [INFO] Retrieving previous metadata from itcm-repository
> [INFO] Uploading project information for argusfilter 2.5b1
> [DEBUG] adding permissions to wagon connection: 774 775
> [INFO] 
> ----------------------------------------------------------------------------
> [INFO] BUILD SUCCESSFUL

So apparently, someone thinks the perms are getting added, but although the
file perms are 775 the created directories come out as 755, making it
difficult for anyone else on my team to deploy after me. I had already added
775 to the edu/ku/middleware path, but the newly created argusfilter, and
2.5b1 directories had 755.

Any ideas why there¹d be a difference here? I¹m assuming it has something to
do with the external ssh connection, but why?

And should I submit a bug report?

--
Kathryn Huxtable
Middleware Architect
Core Middleware
Information Technology, a division of Information Services
The University of Kansas

Reply via email to