Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
99 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
FROM java:8 | ||
|
||
USER root | ||
|
||
RUN apt-get install git | ||
|
||
RUN useradd -ms /bin/bash geotrellis | ||
|
||
USER geotrellis | ||
|
||
RUN set -x \ | ||
&& cd /home/geotrellis \ | ||
&& git clone https://github.com/locationtech/geotrellis /home/geotrellis/geotrellis \ | ||
&& cd /home/geotrellis/geotrellis \ | ||
&& git checkout 1.0 | ||
|
||
WORKDIR /home/geotrellis/geotrellis | ||
|
||
COPY .credentials /home/geotrellis/.ivy2/.credentials | ||
COPY ./gnupg/ /home/geotrellis/.gnupg/ | ||
COPY .credentials /home/geotrellis/.sbt/0.13/local.sbt | ||
|
||
USER root | ||
|
||
RUN chown -R geotrellis:geotrellis /home/geotrellis | ||
|
||
USER geotrellis |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
IMG := geotrellis/publish-geotrellis-container | ||
TAG := "latest" | ||
|
||
build: Dockerfile | ||
@cp ~/.ivy2/.credentials .credentials | ||
@cp ~/.sbt/0.13/local.sbt local.sbt | ||
@cp -r ~/.gnupg ./gnupg | ||
docker build --no-cache -t ${IMG}:${TAG} . | ||
@rm .credentials | ||
@rm -r ./gnupg | ||
@rm local.sbt | ||
|
||
run: | ||
docker run -it ${IMG}:${TAG} /bin/bash | ||
|
||
publish: | ||
docker run -it ${IMG}:${TAG} publish/publish-to-sonatype.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
## Publishing GeoTrellis Releases | ||
|
||
This directory contains the elements needed to publish GeoTrellis to Sonatype. | ||
|
||
## Setup | ||
|
||
You'll need to have the proper Sonatype credentials in `~/.ivy2/.credentials`, | ||
the proper PGP public and private key in `~/.gnupg`, | ||
and the password for the private key (for jar signing) in `~/.sbt/0.13/local.sbt`. | ||
As we change SBT versions, we'll need to modify the `Makefile` to point the correct | ||
file locations. | ||
|
||
We also have to change the branch that is checked out in the `Dockerfile` to the | ||
proper version branch as we change GeoTrellis versions. | ||
|
||
Note: Sonatype requires JARs be signd via PGP, so if you do not have keys | ||
with a distributed public key, you'll have to work through the instructions here: | ||
http://central.sonatype.org/pages/working-with-pgp-signatures.html | ||
|
||
## Building the container | ||
|
||
First build the container using `make build`. The image will always be rebuilt from | ||
scratch, cloning geotrellis and checking out the version branch. | ||
|
||
|
||
## Publishing | ||
|
||
Run `make publish`. This will run the `publish-to-sonatype.sh` script inside the | ||
container, and push everything to the sonatype staging repository. | ||
|
||
After that, you'll have to log in with the appropriate authentication to | ||
https://oss.sonatype.org/, and from there follow the release instructions | ||
at http://central.sonatype.org/pages/releasing-the-deployment.html. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
#!/bin/bash | ||
# Publish to sonatype for all supported scala version 2.11 | ||
|
||
./sbt "project macros" publish-signed \ | ||
&& ./sbt "project vector" publish-signed \ | ||
&& ./sbt "project proj4" publish-signed \ | ||
&& ./sbt "project raster" publish-signed \ | ||
&& ./sbt "project spark" publish-signed \ | ||
&& ./sbt "project s3" publish-signed \ | ||
&& ./sbt "project accumulo" publish-signed \ | ||
&& ./sbt "project cassandra" publish-signed \ | ||
&& ./sbt "project hbase" publish-signed \ | ||
&& ./sbt "project spark-etl" publish-signed \ | ||
&& ./sbt "project geomesa" publish-signed \ | ||
&& ./sbt "project geotools" publish-signed \ | ||
&& ./sbt "project shapefile" publish-signed \ | ||
&& ./sbt "project slick" publish-signed \ | ||
&& ./sbt "project util" publish-signed \ | ||
&& ./sbt "project vectortile" publish-signed \ | ||
&& ./sbt "project raster-testkit" publish-signed \ | ||
&& ./sbt "project vector-testkit" publish-signed \ | ||
&& ./sbt "project spark-testkit" publish-signed |