Skip to content

Add param localService #350

Description

@sias32

Is your feature request related to a problem? Please describe.
pgscv is running in a container, but it sees the network and ports of all services, which is why it believes that they are local and spams a warning/error in the logs about file unavailability.

{"level":"error","service":"pgscv","time":"2026-06-09T08:15:30Z","message":"get data_directory size failed: lstat /var/lib/postgresql/data: no such file or directory; skip"}
{"level":"error","service":"pgscv","time":"2026-06-09T08:15:30Z","message":"find tablespaces mountpoint failed: lstat /var/lib/postgresql/data: no such file or directory"}
{"level":"error","service":"pgscv","time":"2026-06-09T08:15:30Z","message":"get WAL directory size failed: conn busy"}
{"level":"error","service":"pgscv","time":"2026-06-09T08:15:30Z","message":"find log directory mountpoint failed: lstat /var/lib/postgresql/data/: no such file or directory"}
{"level":"error","service":"pgscv","time":"2026-06-09T08:15:30Z","message":"get total size of temp files failed: conn busy"}

Describe the solution you'd like
Change the logic of the `LocalService' by making a flag to manually specify the type of service, and it is also possible to specify the path to the files.

// Determine is service running locally.
config.localService = isAddressLocal(pgconfig.Host)

config:

system_target: false

# or

services:
  custom_name:
    service_type: postgres
    local_type: false
    local_path: /var/lib/custom_name/postgres/data

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions