fix: support postgressql access via docker exec when psql client not installed#11512
fix: support postgressql access via docker exec when psql client not installed#11512lakshmimsft wants to merge 2 commits intomainfrom
Conversation
…lled Signed-off-by: lakshmimsft <ljavadekar@microsoft.com>
9dc113d to
9f685f3
Compare
There was a problem hiding this comment.
Pull request overview
Updates the Radius debug/development tooling to work when the local psql client is missing by falling back to docker exec against a running radius-postgres container, and refactors DB init/cleanup logic to be more centralized.
Changes:
- Add
docker execfallback paths for PostgreSQL command execution instart-radius.shandstop-radius.sh. - Refactor
start-radius.shDB initialization into a reusableinit_db_tableshelper. - Relax
debug-check-prereqsto accept Dockerized PostgreSQL whenpsqlis not installed.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 5 comments.
| File | Description |
|---|---|
| build/scripts/stop-radius.sh | Adds docker exec fallback for DB cleanup when psql is unavailable. |
| build/scripts/start-radius.sh | Adds docker exec fallback for DB init/connectivity detection; consolidates table creation. |
| build/debug.mk | Updates prereq checks to allow Dockerized PostgreSQL when psql is absent. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #11512 +/- ##
==========================================
+ Coverage 51.21% 51.23% +0.02%
==========================================
Files 699 699
Lines 44050 44050
==========================================
+ Hits 22560 22570 +10
+ Misses 19330 19325 -5
+ Partials 2160 2155 -5 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Signed-off-by: lakshmimsft <ljavadekar@microsoft.com>
cf3c4fa to
99bb507
Compare
Radius functional test overviewClick here to see the test run details
Test Status⌛ Building Radius and pushing container images for functional tests... |
Description
This pull request updates development tooling for PostgreSQL by enhancing the logic for detecting and interacting with PostgreSQL, whether running locally or in Docker. It also refactors and consolidates database initialization and cleanup routines. The changes ensure that both the
start-radius.shandstop-radius.shscripts, as well as the Makefile prerequisites check, can handle setups where either thepsqlclient or a Dockerized PostgreSQL instance is present.Type of change
Contributor checklist
Please verify that the PR meets the following requirements, where applicable: