Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create template in PostgreSQL #14

Open
speedlog opened this issue Jun 25, 2018 · 1 comment
Open

Create template in PostgreSQL #14

speedlog opened this issue Jun 25, 2018 · 1 comment
Assignees

Comments

@speedlog
Copy link
Member

speedlog commented Jun 25, 2018

  • run in production mode
  • add instruction to README.md (in server module) how to start docker image with PostgreSQL
  • add new profile postgresql with configuration to postgresql runned by docker
  • change current logic: after creation database connect to new database. Then run script "deployment.sql". At the end set two flags on new template database:
    UPDATE pg_database SET datistemplate = TRUE WHERE datname = 'NAZWA_BAZY'; UPDATE pg_database SET datallowconn = FALSE WHERE datname = 'NAZWA_BAZY';
    datistemplate - every user that has privilages to create database can use this database as template
    datallowconn - block connections to template database
@cardil
Copy link
Collaborator

cardil commented Jun 25, 2018

Proper profile management like that can be viewed in: https://github.com/coi-gov-pl/spring-clean-architecture

@speedlog speedlog self-assigned this Jun 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants