maven-wagon-plugin을 사용하여 ec2 우분투 인스턴스에서 scp를 통해 일부 인형 파일을 복사하려고합니다. 내 개인 키 파일의 경로를 settings.xml에 추가하고 pom.xml (아래 참조) 내에서 플러그인 사용법을 정의했습니다.ec2 인스턴스에서 maven-wagon-ssh/scp를 통해 파일을 설치하는 방법은 무엇입니까?
나는 퍼티로 기계에 연결할 수 있습니다. 그러나
The authenticity of host 'ec2-....compute-1.amazonaws.com' can't be established.
RSA key fingerprint is 79:..:c7.
Are you sure you want to continue connecting? (yes/no): yes
, 플러그인 내 인증이 잘못된 것을 알려줍니다 :
는[ERROR] Failed to execute goal org.codehaus.mojo:wagon-maven-plugin:1.0-beta-
4:upload (upload-puppet-module) on project ...:
Unable to create a Wagon instance for scp://ec2-...compute-1.amazonaws.com/:
Cannot connect. Reason: Auth fail -> [Help 1]
내 Settings.XML의는 다음과 같습니다 그것은 나를 알 수 있기 때문에, 왜건, 연결을 esatblish 할 수있을 것 같다 :
...
<server>
<id>ec2-node</id>
<username>ubuntu</username>
<privateKey>.../path/to/privatekey.ppk</privateKey>
</server>
...
내 pom.xml 파일은 다음과 같습니다
<build>
<extensions>
<extension>
<groupId>org.apache.maven.wagon</groupId>
<artifactId>wagon-ssh</artifactId>
<version>2.4</version>
</extension>
</extensions>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>wagon-maven-plugin</artifactId>
<version>1.0-beta-4</version>
<executions>
<execution>
<id>upload-puppet-module</id>
<phase>pre-integration-test</phase>
<goals>
<goal>upload</goal>
</goals>
<configuration>
<id>ec2-node</id>
<fromDir>${basedir}/src/main/resources/puppet-module</fromDir>
<includes>*</includes>
<url>scp://ec2-...compute-1.amazonaws.com/</url>
<toDir>/etc/puppet/modules/</toDir>
<filePermissions>664</filePermissions>
<directoryPermissions>775</directoryPermissions>
</configuration>
</execution>
</executions>
내가 할 수있는 제안이 있으면 효과가 있습니까?
미리 감사드립니다.
짧은 도움말 포함 짧은 자체 포함 올바른 예. –
구성을 위해이 [예제] (http://mojo.codehaus.org/wagon-maven-plugin/usage.html) –