{"id":21462842,"url":"https://github.com/igor-suhorukov/postgres_osquery","last_synced_at":"2025-10-08T02:10:24.045Z","repository":{"id":192878758,"uuid":"687638487","full_name":"igor-suhorukov/postgres_osquery","owner":"igor-suhorukov","description":"Running \"osquery\" queries from PostgreSQL","archived":false,"fork":false,"pushed_at":"2023-09-05T18:08:44.000Z","size":10,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-07-01T07:04:59.936Z","etag":null,"topics":["monitoring","osquery","performance-metrics","postgresql","siem"],"latest_commit_sha":null,"homepage":"https://medium.com/@igor.suhorukov/postgresql-and-osquery-integration-access-os-hardware-metrics-and-store-it-your-database-921ae4a6df27","language":"PLpgSQL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/igor-suhorukov.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-09-05T17:31:01.000Z","updated_at":"2024-04-02T12:53:05.000Z","dependencies_parsed_at":null,"dependency_job_id":"d8faf193-48df-49e6-a0ba-cb7ac9f545b4","html_url":"https://github.com/igor-suhorukov/postgres_osquery","commit_stats":null,"previous_names":["igor-suhorukov/postgres_osquery"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/igor-suhorukov/postgres_osquery","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/igor-suhorukov%2Fpostgres_osquery","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/igor-suhorukov%2Fpostgres_osquery/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/igor-suhorukov%2Fpostgres_osquery/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/igor-suhorukov%2Fpostgres_osquery/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/igor-suhorukov","download_url":"https://codeload.github.com/igor-suhorukov/postgres_osquery/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/igor-suhorukov%2Fpostgres_osquery/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278877092,"owners_count":26061381,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-08T02:00:06.501Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["monitoring","osquery","performance-metrics","postgresql","siem"],"created_at":"2024-11-23T07:17:14.813Z","updated_at":"2025-10-08T02:10:24.012Z","avatar_url":"https://github.com/igor-suhorukov.png","language":"PLpgSQL","funding_links":[],"categories":[],"sub_categories":[],"readme":"# postgres_osquery\nRunning \"osquery\" queries from PostgreSQL\n\nThe simplest way to integrate OSQuery into PostgreSQL is just to demonstrate the idea. The full implementation should be interacting with the running process using [unix sockets and Thrift serialization](https://github.com/osquery/osquery-python) and is not included in this repository.\n\nI use following Dockerfile to test queries in container\n``` Dockerfile\nFROM postgis/postgis:15-3.3\n\nRUN sh -c \"echo 'deb [arch=amd64] https://pkg.osquery.io/deb deb main' \u003e /etc/apt/sources.list.d/osquery.list\"\nRUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 1484120AC4E9F8A1A577AEEE97A80C63C9D8B80B\nRUN apt update \u0026\u0026 apt install -y osquery\n```\n\ninitialize postgresql functions for osquery:\n```psql\nCREATE EXTENSION plpython3u;\n\\i functions.sql\n\n--import types\n\\i osquery_types.sql\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Figor-suhorukov%2Fpostgres_osquery","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Figor-suhorukov%2Fpostgres_osquery","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Figor-suhorukov%2Fpostgres_osquery/lists"}