Skip to content

cats: scripts add option --no-psqlrc to psql#1900

Merged
BareosBot merged 3 commits intobareos:masterfrom
bruno-at-bareos:dev/bruno/psql-add--no-psqlrc
Aug 7, 2024
Merged

cats: scripts add option --no-psqlrc to psql#1900
BareosBot merged 3 commits intobareos:masterfrom
bruno-at-bareos:dev/bruno/psql-add--no-psqlrc

Conversation

@bruno-at-bareos
Copy link
Contributor

@bruno-at-bareos bruno-at-bareos commented Jul 23, 2024

  • script: add --if-exists to dropdb

    This commit will turn the error into a warning when we try to dropdb
    non existing database.

  • cats: add option --no-psqlrc to psql command in scripts

    While it is rare to have .psqlrc configuration file setup for user
    like bareos or postgres, it can contains configuration that
    may defeat our expectation in terms of return.
    --no-psqlrc is now added to all catalog scripts.

Thank you for contributing to the Bareos Project!

Please check

  • Short description and the purpose of this PR is present above this paragraph
  • Your name is present in the AUTHORS file (optional)

If you have any questions or problems, please give a comment in the PR.

Helpful documentation and best practices

Checklist for the reviewer of the PR (will be processed by the Bareos team)

Make sure you check/merge the PR using devtools/pr-tool to have some simple automated checks run and a proper changelog record added.

General
  • Is the PR title usable as CHANGELOG entry?
  • Purpose of the PR is understood
  • Commit descriptions are understandable and well formatted
  • Correct milestone is set
Source code quality
  • Source code changes are understandable
  • Variable and function names are meaningful
  • Code comments are correct (logically and spelling)

@sduehr sduehr self-requested a review July 30, 2024 09:50
@sduehr sduehr added this to the 24.0.0 milestone Aug 7, 2024
Copy link
Member

@sduehr sduehr left a comment

Choose a reason for hiding this comment

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

Thanks, looks good.

bruno-at-bareos and others added 3 commits August 7, 2024 22:27
--if-exists is supported since a decade introduced with
PostgreSQL 9.2

Signed-off-by: Bruno Friedmann <bruno.friedmann@bareos.com>
(cherry picked from commit d75dcf4)
While it is rare to have .psqlrc configuration file setup for user
like `bareos` or `postgres`, it may contains configuration that
may defeat our expectation in terms of return.
`--no-psqlrc` is now added to all catalog scripts.

Signed-off-by: Bruno Friedmann <bruno.friedmann@bareos.com>
@BareosBot BareosBot force-pushed the dev/bruno/psql-add--no-psqlrc branch from 3f01bef to 92916c8 Compare August 7, 2024 22:27
@BareosBot BareosBot merged commit 5a4997d into bareos:master Aug 7, 2024
@bruno-at-bareos bruno-at-bareos deleted the dev/bruno/psql-add--no-psqlrc branch August 8, 2024 08:02
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.

3 participants