Skip to content

PostgreSQL container images based on Red Hat Software Collections and intended for OpenShift and general usage. Users can choose between Red Hat Enterprise Linux, Fedora, and CentOS based images.

License

Notifications You must be signed in to change notification settings

dinaharan/postgresql-container

 
 

Repository files navigation

PostgreSQL container images

Build and push images to Quay.io registry

This repository contains Dockerfiles for PostgreSQL images for OpenShift. Users can choose between RHEL, Fedora and CentOS based images.

For more information about using these images with OpenShift, please see the official OpenShift Documentation.

For more information about contributing, see the Contribution Guidelines. For more information about concepts used in these container images, see the Landing page.

Versions

PostgreSQL versions currently supported are:

RHEL versions currently supported are:

  • RHEL7
  • RHEL8

CentOS versions currently supported are:

  • CentOS7

Installation

Choose either the CentOS7 or RHEL7 based image:

  • RHEL7 based image

    These images are available in the Red Hat Container Catalog. To download it run:

    podman pull registry.redhat.io/rhscl/postgresql-13-rhel7
    

    To build a RHEL7 based image, you need to run Docker build on a properly subscribed RHEL machine.

    $ git clone --recursive https://github.com/sclorg/postgresql-container.git
    $ cd postgresql
    $ make build TARGET=rhel7 VERSIONS=13
    
  • CentOS7 based image

    These images are available on Quay.io. To download it run:

    $ podman pull quay.io/centos7/postgresql-13-centos7
    

    To build a PostgreSQL image from scratch run:

    $ git clone --recursive https://github.com/sclorg/postgresql-container.git
    $ cd postgresql
    $ make build TARGET=centos7 VERSIONS=13
    

Note: while the installation steps are calling podman, you can replace any such calls by docker with the same arguments.

Notice: By omitting the VERSIONS parameter, the build/test action will be performed on all provided versions of PostgreSQL.

Contributing

In this repository distgen is used for generating image source files. If you'd like update a Dockerfile, please make changes in specs/multispec.yml and/or Dockerfile.template (or other distgen file) and run make generate.

Usage

For information about usage of Dockerfile for PostgreSQL 10, see usage documentation.

For information about usage of Dockerfile for PostgreSQL 12, see usage documentation.

For information about usage of Dockerfile for PostgreSQL 13, see usage documentation.

For versions which are not supported anymore:

Test

This repository also provides a test framework, which checks basic functionality of the PostgreSQL image.

Users can choose between testing PostgreSQL based on a RHEL or CentOS image.

  • RHEL based image

    To test a RHEL7 based PostgreSQL image, you need to run the test on a properly subscribed RHEL machine.

    $ cd postgresql
    $ make test TARGET=rhel7 VERSIONS=13
    
  • CentOS based image

    $ cd postgresql
    $ make test TARGET=centos7 VERSIONS=13
    

+By using the TESTS parameter you can choose a test case subset to be run against the image, eg:

$ cd postgresql
$ make test VERSIONS=13 TESTS="run_general_tests run_replication_test"

Notice: By omitting the VERSIONS parameter, the build/test action will be performed on all provided versions of PostgreSQL.

About

PostgreSQL container images based on Red Hat Software Collections and intended for OpenShift and general usage. Users can choose between Red Hat Enterprise Linux, Fedora, and CentOS based images.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 92.5%
  • Dockerfile 6.7%
  • Makefile 0.8%