Release: Remove aws-maven plugin/improve release docs

In order to have consistent deploys across several repositories,
we should deploy to sonatype first, then mirror those contents,
and then upload to s3.

This means, the aws wagon is not needed anymore.
This commit is contained in:
Alexander Reelsen 2015-08-17 11:43:47 +02:00
parent 8e052f0da2
commit d1c93fb573
5 changed files with 15 additions and 47 deletions

View File

@ -158,7 +158,7 @@ mkdir -p $centosdir
echo "RPM: Syncing repository for version $version into $centosdir"
$s3cmd sync s3://$S3_BUCKET_SYNC_FROM/elasticsearch/$version/centos/ $centosdir
rpm=distribution/rpm/target/releases/signed/elasticsearch*.rpm
rpm=distribution/rpm/target/releases/elasticsearch*.rpm
echo "RPM: Copying signed $rpm into $centosdir"
cp $rpm $centosdir

View File

@ -35,13 +35,6 @@
</configuration>
</plugin>
</plugins>
<extensions>
<extension>
<groupId>org.springframework.build</groupId>
<artifactId>aws-maven</artifactId>
<version>5.0.0.RELEASE</version>
</extension>
</extensions>
</build>
<profiles>
<profile>
@ -70,13 +63,6 @@
</plugin>
</plugins>
</build>
<distributionManagement>
<repository>
<id>aws-release</id>
<name>AWS Release Repository</name>
<url>${elasticsearch.s3.repository}</url>
</repository>
</distributionManagement>
</profile>
</profiles>
</project>

View File

@ -123,9 +123,19 @@ if __name__ == "__main__":
print('*** Done removing snapshot version. DO NOT COMMIT THIS, WHEN CREATING A RELEASE CANDIDATE.')
shortHash = subprocess.check_output('git log --pretty=format:"%h" -n 1', shell=True)
shortHash = subprocess.check_output('git log --pretty=format:"%h" -n 1', shell=True).decode('utf-8')
localRepo = '/tmp/elasticsearch-%s-%s', % (release_version, shortHash)
localRepoElasticsearch = localRepo + '/org/elasticsearch'
print('')
print('*** To create a release candidate run: ')
print(' mvn clean deploy -Prelease -DskipTests -Dgpg.keyname="D88E42B4" -Dpackaging.rpm.rpmbuild=/usr/bin/rpmbuild -Delasticsearch.s3.repository=s3://download.elasticsearch.org/elasticsearch/staging/elasticsearch-%s-%s' % (release_version, shortHash.decode('utf-8')))
print('');
print('NOTE: this command will promt you several times for the GPG passphrase of the key you specified you can alternatively pass it via -Dgpg.passphrase=yourPassPhrase');
print(' mvn clean install deploy -Prelease -DskipTests -Dgpg.keyname="D88E42B4" -Dpackaging.rpm.rpmbuild=/usr/bin/rpmbuild -Drpm.sign=true -Dmaven.repo.local=%s -Dno.commit.pattern="\\bno(n|)commit\\b" -Dforbidden.test.signatures=""' % (localRepo))
print(' 1. Remove all _remote.repositories: find %s -name _remote.repositories -exec rm {} \;' % (localRepoElasticsearch))
print(' 2. Rename all maven metadata files: for i in $(find %s -name "maven-metadata-local.xml*") ; do mv "$i" "${i/-local/}" ; done' % (localRepoElasticsearch))
print(' 3. Sync %s into S3 bucket' % (localRepoElasticsearch))
print (' s3cmd sync %s s3://download.elasticsearch.org/elasticsearch/staging/elasticsearch-%s-%s/maven/org/elasticsearch' % (localRepoElasticsearch, release_version, shortHash))
print(' 4. Create repositories: ')
print (' export S3_BUCKET_SYNC_TO="download.elasticsearch.org/elasticsearch/staging/elasticsearch-%s-%s/repos"' % (release_version, shortHash))
print (' export S3_BUCKET_SYNC_FROM="$S3_BUCKET_SYNC_TO"')
print(' dev-tools/build_repositories.sh %s' % (release_version))
print('')
print('NOTE: the above mvn command will promt you several times for the GPG passphrase of the key you specified you can alternatively pass it via -Dgpg.passphrase=yourPassPhrase')

14
pom.xml
View File

@ -1262,13 +1262,6 @@ org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UT
</plugin>
</plugins>
</pluginManagement>
<extensions>
<extension>
<groupId>org.springframework.build</groupId>
<artifactId>aws-maven</artifactId>
<version>5.0.0.RELEASE</version>
</extension>
</extensions>
</build>
<profiles>
<profile>
@ -1316,13 +1309,6 @@ org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UT
</plugin>
</plugins>
</build>
<distributionManagement>
<repository>
<id>aws-release</id>
<name>AWS Release Repository</name>
<url>${elasticsearch.s3.repository}</url>
</repository>
</distributionManagement>
</profile>
<!-- license profile, to generate third party license file -->
<profile>

View File

@ -35,13 +35,6 @@
</configuration>
</plugin>
</plugins>
<extensions>
<extension>
<groupId>org.springframework.build</groupId>
<artifactId>aws-maven</artifactId>
<version>5.0.0.RELEASE</version>
</extension>
</extensions>
</build>
<profiles>
<profile>
@ -70,13 +63,6 @@
</plugin>
</plugins>
</build>
<distributionManagement>
<repository>
<id>aws-release</id>
<name>AWS Release Repository</name>
<url>${elasticsearch.s3.repository}</url>
</repository>
</distributionManagement>
</profile>
</profiles>
</project>