-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: ozkanonur <[email protected]>
- Loading branch information
1 parent
685afa1
commit 40fae83
Showing
1 changed file
with
29 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
package search api for lpm repositories | ||
======================================= | ||
|
||
**API Configuration** | ||
|
||
DB_PATH(required): | ||
- export DB_PATH={repository_db_path_to_be_searched} | ||
|
||
API_PORT (optional, default is 8126): | ||
- export API_PORT={CUSTOM_PORT} | ||
|
||
**Builds** | ||
|
||
Development session | ||
- go run package-search-api.go | ||
|
||
Prod-level binary: | ||
- go build -ldflags "-s -w" package-search-api.go | ||
|
||
**Endpoints** | ||
|
||
Search for latest packages: | ||
- http://127.0.0.1:8126 | ||
|
||
Search with pattern matching: | ||
- http://127.0.0.1:8126/?package=lz | ||
|
||
Healthcheck: | ||
- http://127.0.0.1:8126/health |