{"id":20445846,"url":"https://github.com/rapid7/cps","last_synced_at":"2025-04-13T00:44:11.160Z","repository":{"id":33812259,"uuid":"132199244","full_name":"rapid7/cps","owner":"rapid7","description":"CPS - Centralized Property Service","archived":false,"fork":false,"pushed_at":"2025-03-13T01:20:36.000Z","size":416,"stargazers_count":7,"open_issues_count":5,"forks_count":12,"subscribers_count":72,"default_branch":"master","last_synced_at":"2025-04-13T00:44:05.248Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rapid7.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-05-04T23:50:03.000Z","updated_at":"2025-04-10T22:13:44.000Z","dependencies_parsed_at":"2023-10-24T14:27:16.170Z","dependency_job_id":"93784ab2-1376-46a1-959d-54b33d450770","html_url":"https://github.com/rapid7/cps","commit_stats":null,"previous_names":[],"tags_count":18,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rapid7%2Fcps","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rapid7%2Fcps/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rapid7%2Fcps/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rapid7%2Fcps/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rapid7","download_url":"https://codeload.github.com/rapid7/cps/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248650419,"owners_count":21139672,"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","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":[],"created_at":"2024-11-15T10:14:51.007Z","updated_at":"2025-04-13T00:44:11.136Z","avatar_url":"https://github.com/rapid7.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CPS - Centralized Property Service\n\n[![Go Report](https://goreportcard.com/badge/github.com/rapid7/cps)](https://goreportcard.com/badge/github.com/rapid7/cps)\n\nCPS is a centralized dynamic property service. It serves up the precomputed properties for a service as well as dynamic consul properties in the form of `conqueso.service.ips=`. It also supports AWS SSM Parameter Store SecureStrings.\n\nSee [cps-property-generator](https://github.com/rapid7/cps-property-generator) for generating json property files and uploading them to s3.\n\n## configuration\n\nIn order to run this project you need to set the following values in `cps.json` at the root of the project:\n\n```json\n{\n  \"account\": \"000000000000\",\n  \"region\": \"us-east-1\",\n  \"s3\": {\n    \"bucket\": \"mys3propertiesbucket\",\n    \"region\": \"us-east-1\"\n  },\n  \"consul\": {\n    \"host\": \"localhost:8500\"\n  }\n}\n```\n\n## running locally\n\n- `mkdir -p ~/go/src`\n- add `export GOPATH=~/go` to your .bashrc or .zshrc\n- git clone to `~/go/src/cps`\n- `brew install go consul`\n- `make`\n- `consul agent -dev -advertise 127.0.0.1` in another tab.\n- export your awsaml creds\n- `./cps`\n\n\n## running on an ec2 instance\n\n- `make build-linux`\n- scp binary to the ec2 instance and run\n\n## running a dev instance with local files\n\nSometimes it is desirable to run locally using flat files. You can put your service json files into a directory and point to that directory. Note, when file mode is enabled s3 and consul watchers are both disabled. Here is a basic example of how to set up your config for local files:\n\n```\n{\n  \"account\": \"0000000000000\",\n  \"region\": \"us-east-1\",\n  \"file\": {\n    \"enabled\": true,\n    \"directory\": \"./local-files\"\n  }\n}\n```\n\nThe names of the files in the `./local-files` should be the name of the service.\n\n## running in docker\n\nThere is a Dockerfile at the root of the project that is meant to be used in local file mode. You can modify `dockerfiles/cps.json` and add/remove services from the `dockerfiles/services` directory to change what properties are returned. Here are the steps to get started quickly:\n\n1. Uncomment dockerfiles ADD in Dockerfile\n2. `docker build -t cps .`\n3. `docker run -p 9100:9100 -it cps`\n4. `curl localhost:9100/v1/properties/your-service`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frapid7%2Fcps","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frapid7%2Fcps","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frapid7%2Fcps/lists"}