Project

General

Profile

Actions

Task #1580

open

New testing environment - PostgreSQL

Added by Petr Fišer about 5 years ago. Updated almost 5 years ago.

Status:
In Progress
Priority:
Normal
Assignee:
Jan Kolařík
Category:
-
Target version:
-
Start date:
03/26/2019
Due date:
% Done:

90%

Estimated time:
Owner:

Description

Create / use some sensible PGSQL docker image.
This image will then be used as a base image for:
  • czechidm repository
  • end system (db table on postgres)

Task: primary task is to crete postgres docker image (with compose file) to server as repository for the CzechIdM.

Actions #1

Updated by Petr Fišer about 5 years ago

Docker images from https://hub.docker.com/_/postgres are usable, managed to spin up an v11 postgres instance.
Also no need to clone the git if we are not planning on making changes. This compose works well, although it will need a little bit of tweaking (the volume is created with polkitd:root ownership on the host).

version: '2.1'

services:

  database:
    image: postgres:latest
    environment:
      - "POSTGRES_PASSWORD=demodemo" 
    volumes:
      - "./data:/var/lib/postgresql/data" 
    ports:
      - "5432:5432" 
    restart: always

Actions #2

Updated by Jan Kolařík almost 5 years ago

developing postgres docker image

Actions #3

Updated by Jan Kolařík almost 5 years ago

  • % Done changed from 0 to 90

docker was image prepared

maybe some tuning will be needed when application image is done

version: '3'
services:
  postgresidm: 
    image: nexus.bcvsolutions.eu:8445/postgresimage:v1
    container_name: postgresidmcont
    volumes:
      - /etc/timezone:/etc/timezone:ro
      - /etc/localtime:/etc/localtime:ro
    ports:
      - 5432:5432
    environment:
      - INIT_DBNAME=czechidm
      - INIT_DBUSERNAME=czechidm
      - INIT_DBUSERPASSWORD=xxxxxxx
#in kilobytes!!!!, total memory according to https://pgtune.leopard.in.ua
      - DB_MEMORY_KB=2000000
    hostname: postgresidm

Actions #4

Updated by Jan Kolařík almost 5 years ago

  • Status changed from New to In Progress
Actions #5

Updated by Jan Kolařík almost 5 years ago

  • Assignee set to Jan Kolařík
Actions

Also available in: Atom PDF