GithubHelp home page GithubHelp logo

geobeyond / geoserver-docker Goto Github PK

View Code? Open in Web Editor NEW

This project forked from geonode/geoserver-docker

0.0 2.0 1.0 92 KB

Base image for geoserver in docker

Dockerfile 23.99% Shell 60.84% Python 15.16%

geoserver-docker's Introduction

geoserver-docker

GeoServer is an open source server for sharing geospatial data. This is a docker image that eases setting up a GeoServer running specifically for GeoNode with an additional separated data directory.

The image is based on the official Tomcat 9 image

Installation

This image is available as a trusted build on the docker hub, and is the recommended method of installation. Simple pull the image from the docker hub.

$ docker pull geonode/geoserver

Alternatively you can build the image locally

$ git clone https://github.com/geonode/geoserver-docker.git
$ cd geoserver-docker
$ docker build -t "geonode/geoserver" .

Quick start

You can quick start the image using the command line

$ docker run --name "geoserver" -v /var/run/docker.sock:/var/run/docker.sock -d -p 8080:8080 geonode/geoserver

Point your browser to http://localhost:8080/geoserver and login using GeoServer's default username and password:

  • Username: admin
  • Password: geoserver

How to use different versions

There are mainly two different versions of this image which are useful for running GeoNode with different authentication system types. These versions are released as specific tags for two authentication mechanisms:

Cookie based authn:

Oauth2 based authn:

You can declare what version to use along with the data directory tag which corresponds to the same version.

Configuration

Data volume

This GeoServer container keeps its configuration data at /geoserver_data/data which is exposed as volume in the dockerfile. The volume allows for stopping and starting new containers from the same image without losing all the data and custom configuration.

You may want to map this volume to a directory on the host. It will also ease the upgrade process in the future. Volumes can be mounted by passing the -v flag to the docker run command:

-v /your/host/data/path:/geoserver_data/data

Data volume container

In case you are running Compose for automatically having GeoServer up and running then a data volume container will be mounted with a default preloaded GEOSERVER_DATA_DIR at the configuration data directory of the container. Make sure that the image from the repository data-docker is available from the GeoNode Docker Hub or has been built locally:

docker build -t geonode/geoserver_data .

Persistance behavior

If you run:

docker-compose stop

Data are retained in the GEOSERVER_DATA_DIR and can then be mounted in a new GeoServer instance by running again:

docker-compose up

If you run:

docker-compose down

Data are completely gone but you can ever start from the base GeoServer Data Directory built for Geonode.

Data directory versions

There has to be a correspondence one-to-one between the data directory version and the tag of the GeoServer image used in the Docker compose file. So at the end you can consume these images below:

Database

GeoServer recommends the usage of a spatial database

PostGIS container (PostgreSQL + GIS Extension)

If you want to use a PostGIS container, you can link it to this image. You're free to use any PostGIS container. An example with kartooza/postgis image:

$ docker run -d --name="postgis" kartoza/postgis

For further information see kartooza/postgis.

Now start the GeoServer instance by adding the --link option to the docker run command:

--link postgis:postgis

geoserver-docker's People

Contributors

francbartoli avatar giohappy avatar ingenieroariel avatar jj0hns0n avatar jorgemartinezg avatar waybarrios avatar

Watchers

 avatar  avatar

Forkers

ptagliolato

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.