Sign inSign up

opavlova/db-h2

By opavlova

•Updated about 10 years ago

H2 database server

Image
0

993

opavlova/db-h2 repository overview

⁠H2 database

http://www.h2database.com/html/download.html⁠

⁠Image tags

opavlova/db-h2

OS: GNU/Linux
Java version: java 7u111
H2 version: 1.3.176

⁠Usage

⁠How to connect to DB in IntelliJ IDEA
  1. Install docker https://docs.docker.com/engine/installation/⁠ https://docs.docker.com/engine/userguide/⁠

  2. Add Docker support https://www.jetbrains.com/help/idea/docker.html⁠

  3. Create a Dockerfile with the following content in IntelliJ IDEA:

FROM  opavlova/db-h2
  1. Create and run a New Run Configuration

    click on the "Run on Docker' gutter (near "FROM" in the Editor)  -> choose "New Run Configuration"
    enter "-p 1521:1521  -p 181:81"   into the  "Run options" field 
    Run  ( results are in the Services View )
    
  2. Create a connection to the database in the Database View:

    go to the Database View, add new Data Source
    add URL:  jdbc:h2:tcp://localhost:11521/default
    password and user are empty
    Connect.
    
    Web Console connection: http://localhost:181/ 
    
  3. Work with db, for example, create a table via DatabaseView ->console: CREATE TABLE PUBLIC.TEST(ID INT PRIMARY KEY, NAME VARCHAR(255));

Dockerfile for opavlova/db-h2 image: https://github.com/IdeaUJetBrains/DockerFiles/tree/master/docker-dir/db/h2⁠

Tag summary

Content type

Image

Digest

Size

247.6 MB

Last updated

about 10 years ago

docker pull opavlova/db-h2