Amazon S3 plugin for Jenkins CI again

About once a year I revisit (link) this topic again (usually when the plugin causes trouble). Now I get this signature error

AWS Error Code: SignatureDoesNotMatch, AWS Error Message: The request signature we calculated does not match the signature you provided. Check your key and signing method., S3 Extended Request ID:..

The good news first:
The S3 plugin became mainstream, you can install it from the plugin page under Jenkins Administration | Plugin Manager. You dont need to build the plugin any longer by yourself and can skip the rest of this entry.

S3 Plugin

The long version:
It seems the error is caused by a ‘+’ sign in the access key troubling the encoding function used (see issue). The latest build (Sep 2012) should fix this problem.

If you want to build by yourself, you need to get the sourcecode from git and build the plugin file, beware as it requires Maven 3 now. Below instructions apply fro Ubuntu.

Upload plugin

 

 

Amazon S3 plugin for Jenkins CI

About one year back I found this plugin, that saves your build artifacts to Amazon S3 storage. Unfortunately the plugin does not properly work with the current Jenkins versions and the original plugin is not maintained. Luckily someone forked and updated the plugin at github. You need to build the plugin by yourself with the help of maven, you still can refer to my original post, just one change is required to make it work, the settings for your ~/.m2/settings/xml need to be changed according to the plugin page description. Please be patient, maven is going to download a lot !

<settings>
 <pluginGroups>
 <pluginGroup>org.jenkins-ci.tools</pluginGroup>
 </pluginGroups>

 <profiles>
 <!-- Give access to Jenkins plugins -->
 <profile>
 <id>jenkins</id>
 <activation>
 <activeByDefault>true</activeByDefault> <!-- change this to false, if you don't like to have it on per default -->
 </activation>
 <repositories>
 <repository>
 <id>maven.jenkins-ci.org</id>
 <url>http://maven.jenkins-ci.org/content/groups/artifacts/</url>
 </repository>
 </repositories>
 <pluginRepositories>
 <pluginRepository>
 <id>maven.jenkins-ci.org</id>
 <url>http://maven.jenkins-ci.org/content/groups/artifacts/</url>
 </pluginRepository>
 </pluginRepositories>
 </profile>
 </profiles>
</settings>

Otherwise you get errors like

[INFO] Scanning for projects...
Downloading: http://download.java.net/maven/2/org/jenkins-ci/plugins/plugin/1.434/plugin-1.434.pom
[INFO] Unable to find resource 'org.jenkins-ci.plugins:plugin:pom:1.434' in repository java.net2 (http://download.java.net/maven/2)
Downloading: http://repo1.maven.org/maven2/org/jenkins-ci/plugins/plugin/1.434/plugin-1.434.pom
[INFO] Unable to find resource 'org.jenkins-ci.plugins:plugin:pom:1.434' in repository central (http://repo1.maven.org/maven2)
[INFO] ------------------------------------------------------------------------
[ERROR] FATAL ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Error building POM (may not be this project's POM).

Backup of domains in Glassfish V3

This CLI asadmin function is not available for 3.0.1. All you get is

glassfish@ubuntu:/opt/app-server/bin$ ./asadmin backup-domain
CLI194 Previously supported command: backup-domain is not supported for this release.

It is planned to come back in the upcoming version 3.1. (link)

I tried to migrate a domain from server A to server B (same glassfish release) by copying the complete domain folder (10.000 plus files!). It did not work either.

ERROR: Error creating archive. (java.io.FileNotFoundException: /var/xyz/xyzdomain/osgi-cache/felix/bundle1/version0.-1/revision.location (No such file or directory))

Error starting domain

Right now no choice other than creating the domain again and redo the manual settings before deploying the application.