Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build geoserver.war from vendor/geoserver #1

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "vendor/geoserver"]
path = vendor/geoserver
url = git@github.com:koordinates/geoserver-plus-kx.git
8 changes: 4 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -58,15 +58,15 @@ FROM tomcat as download

ARG GS_VERSION=2.25.1
ARG GS_BUILD=release
ARG WAR_ZIP_URL=https://downloads.sourceforge.net/project/geoserver/GeoServer/${GS_VERSION}/geoserver-${GS_VERSION}-war.zip
ARG WAR_FILE=vendor/geoserver/src/web/app/target/geoserver.war
ENV GEOSERVER_VERSION=$GS_VERSION
ENV GEOSERVER_BUILD=$GS_BUILD

WORKDIR /tmp

RUN echo "Downloading GeoServer ${GS_VERSION} ${GS_BUILD}" \
&& wget -q -O /tmp/geoserver.zip $WAR_ZIP_URL \
&& unzip geoserver.zip geoserver.war -d /tmp/ \
COPY ${WAR_FILE} /tmp/geoserver.war

RUN echo "Extracting /tmp/geoserver.war (from ${WAR_FILE})" \
&& unzip -q /tmp/geoserver.war -d /tmp/geoserver \
&& rm /tmp/geoserver.war

Expand Down
21 changes: 21 additions & 0 deletions KOORDINATES.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Build geoserver.war
(at `vendor/geoserver/src/web/app/target/geoserver.war`):

```shell
mvn clean install -f vendor/geoserver/src -Dmaven.test.skip=true
```

(tests are currently failing due to koordinates-applicationContext.xml)

# Build docker image

```shell
docker build -t {YOUR_TAG} .
```

# Run

```shell
docker run -it -p 80:8080 {YOUR_TAG}
```

3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
> [!IMPORTANT]
> This README.md file covers official geoserver builds. See [KOORDINATES.md](KOORDINATES.md)

# A geoserver docker image

This Dockerfile can be used to create images for all geoserver versions since 2.5.
Expand Down
1 change: 1 addition & 0 deletions vendor/geoserver
Submodule geoserver added at 672e38