Skip to content

[IMP] runbot: create database inside docker#1432

Open
Xavier-Do wants to merge 1 commit into
19.0from
19.0-no-create-db-xdo
Open

[IMP] runbot: create database inside docker#1432
Xavier-Do wants to merge 1 commit into
19.0from
19.0-no-create-db-xdo

Conversation

@Xavier-Do

@Xavier-Do Xavier-Do commented Jun 16, 2026

Copy link
Copy Markdown
Contributor

To allow to run postgres in docker we cannot make any maintenance on database from outside the docker anymore, meaning that the database creations needs to be done in the docker.

@C3POdoo C3POdoo requested a review from a team June 16, 2026 06:53
db_suffix = re.sub(r'[^a-z0-9\-_]', '_', db_suffix.lower())
db_name = '%s-%s' % (build.dest, db_suffix)
if modules_to_install and self.create_db:
build._local_pg_createdb(db_name)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not really needed since runbot will pass the db-template in the config.
There are also no known case where we want to automatically drop a database with the same name silently, should be done explicitly.

@Xavier-Do Xavier-Do force-pushed the 19.0-no-create-db-xdo branch from bcbaeea to 29aaad8 Compare June 16, 2026 07:01
To allow to run postgress in docker we cannot make any maintenance on
database from outside the docker anymore, meaning that the database
creations needs to be done in the docker.
@Xavier-Do Xavier-Do force-pushed the 19.0-no-create-db-xdo branch from 29aaad8 to 992ffa0 Compare June 16, 2026 07:05
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

Successfully merging this pull request may close these issues.

1 participant