HSQLDB in a Docker Container
10K+
Exactly what it says on the tin. Useful in Spring and other Java applications. This image uses JDK 12 on Oracle Linux.
$ docker run -d -p 9001:9001 --name hsqldb mitchtalmadge/hsqldb
Connection Details:
jdbc:hsqldb:hsql://localhost/testThis image is optimized for use with docker compose.
You can specify the Username and Password with the environment variables HSQLDB_USER and HSQLDB_PASSWORD.
$ docker run -d --name hsqldb \
-e "HSQLDB_USER=sa" \
-e "HSQLDB_PASSWORD=password" \
-p 9001:9001 \
mitchtalmadge/hsqldb
If you do not set the environment variables, the defaults are:
You can adjust the Database Alias with the environment variable: HSQLDB_DATABASE_ALIAS
This will change the JDBC URL.
Example:
$ docker run -d --name hsqldb \
-e "HSQLDB_DATABASE_ALIAS=example" \
-p 9001:9001 \
mitchtalmadge/hsqldb
The correct JDBC URL is now: jdbc:hsqldb:hsql://localhost/example
You can specify the Database Name with the environment variable HSQLDB_DATABASE_NAME
Example:
$ docker run -d --name hsqldb \
-e "HSQLDB_DATABASE_NAME=hsqldb" \
-p 9001:9001 \
mitchtalmadge/hsqldb
Database hsqldb will be available in folder /opt/database
The database files are inside the volume /opt/database and can be mounted.
Example:
$ docker run -d --name hsqldb \
-v ./database:/opt/database \
-p 9001:9001 \
mitchtalmadge/hsqldb
This container supports the following additional settings:
HSQLDB_TRACE="false"HSQLDB_SILENT="true"HSQLDB_REMOTE="false"Example:
$ docker run -d --name hsqldb \
-e "HSQLDB_TRACE=false" \
-e "HSQLDB_SILENT=true" \
-e "HSQLDB_REMOTE=false" \
-p 9001:9001 \
mitchtalmadge/hsqldb
You can define start up parameters for the Java Virtual Machine, e.g. setting the memory size.
$ docker run -d --name hsqldb \
-e "JAVA_VM_PARAMETERS=-Xmx512m -Xms256m" \
-p 9001:9001 \
mitchtalmadge/hsqldb
Content type
Image
Digest
Size
324.2 MB
Last updated
about 7 years ago
docker pull mitchtalmadge/hsqldb