项目作者: dernasherbrezon

项目描述 :
Maven Wagon for OpenStack Swift
高级语言: Java
项目地址: git://github.com/dernasherbrezon/swift-maven.git
创建时间: 2018-05-19T15:18:24Z
项目社区:https://github.com/dernasherbrezon/swift-maven

开源协议:Apache License 2.0

下载


Swift Maven Wagon Build Status Quality Gate Status

This project is a Maven Wagon for OpenStack Swift. In order to publish artifacts to an swift container, the user (as identified by their username and password) must have access to the container.

Usage

To publish Maven artifacts to swift a build extension must be defined in a project’s pom.xml. The latest version of the wagon can be found on the swift-maven page in Maven Central.

  1. <project>
  2. ...
  3. <build>
  4. ...
  5. <extensions>
  6. ...
  7. <extension>
  8. <groupId>com.aerse</groupId>
  9. <artifactId>swift-maven</artifactId>
  10. <version>1.1</version>
  11. </extension>
  12. ...
  13. </extensions>
  14. ...
  15. </build>
  16. ...
  17. </project>

Once the build extension is configured distribution management repositories can be defined in the pom.xml with an swift:// scheme.

  1. <project>
  2. ...
  3. <distributionManagement>
  4. <repository>
  5. <id>container-name-snapshot</id>
  6. <url>swift://<host>/v3</url>
  7. </repository>
  8. <snapshotRepository>
  9. <id>container-name-release</id>
  10. <name><container name></name>
  11. <url>swift://<host>/v3</url>
  12. </snapshotRepository>
  13. </distributionManagement>
  14. ...
  15. </project>

Finally the ~/.m2/settings.xml must be updated to include username and password for the account.

  1. <settings>
  2. ...
  3. <servers>
  4. ...
  5. <server>
  6. <id>container-name-release</id>
  7. <username>0123456789ABCDEFGHIJ</username>
  8. <password>0123456789abcdefghijklmnopqrstuvwxyzABCD</password>
  9. </server>
  10. <server>
  11. <id>container-name-snapshot</id>
  12. <username>0123456789ABCDEFGHIJ</username>
  13. <password>0123456789abcdefghijklmnopqrstuvwxyzABCD</password>
  14. </server>
  15. ...
  16. </servers>
  17. ...
  18. </settings>