Permalink
Cannot retrieve contributors at this time
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
67 lines (60 sloc)
2.01 KB
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
<html> | |
<head> | |
<title>PostGIS | Ebean ORM</title> | |
<meta name="layout" content="_layout2/base-docs.html"/> | |
<meta name="bread1" content="Database platforms" href="/docs/database"/> | |
<meta name="bread2" content="Postgres" href="/docs/database/postgres"/> | |
<meta name="bread3" content="PostGIS" href="/docs/database/postgres/postgis"/> | |
<#assign n0_docs="active"> | |
<#assign n1_platforms="active"> | |
<#assign n2_postgres="active"> | |
<#assign postgis="active"> | |
</head> | |
<body> | |
<h2 id="postgis">PostGIS</h2> | |
<p> | |
Below is a test setup using the <code>mdillon/postgis</code> docker container that | |
has PostGIS extension installed. | |
</p> | |
<p> | |
This will automatically download and run the container making live a little easier. | |
Note the use of the Postgis specfic driver and url. | |
</p> | |
<pre content="yml"> | |
ebean: | |
geometrySRID: 4674 # If we don't want the default geometrySRID of 4326 | |
test: | |
shutdown: none # stop | remove | none | |
platform: postgis | |
ddlMode: dropCreate # none | dropCreate | migrations | create | |
dbName: my_gisapp | |
</pre> | |
<p> | |
The above <code>postgis</code> platform is equivalent to the setup below which uses: | |
</p> | |
<table class="compact w100"> | |
<tr><th>username:</th><td>{databaseName}</td></tr> | |
<tr><th>password:</th><td>test</td></tr> | |
<tr><th>port:</th><td>7432</td></tr> | |
<tr><th>url:</th><td>jdbc:postgresql_lwgis://localhost:{port}/{databaseName}</td></tr> | |
<tr><th>driver:</th><td>org.postgis.DriverWrapperLW</td></tr> | |
<tr><th>image:</th><td>mdillon/postgis:{version}</td></tr> | |
</table> | |
<pre content="yml"> | |
ebean: | |
geometrySRID: 4674 | |
test: | |
shutdown: none # stop | remove | none | |
platform: postgres | |
ddlMode: dropCreate # none | dropCreate | migrations | create | |
dbName: my_gisapp | |
postgres: | |
containerName: postgis | |
image: mdillon/postgis | |
extensions: postgis | |
url: jdbc:postgresql_lwgis://127.0.0.1:7432/my_gisapp | |
driver: org.postgis.DriverWrapperLW | |
</pre> | |
<@next_edit "MySql" "/docs/database/mysql" "/docs/database/postgres/postgis.html"/> | |
</body> | |
</html> |