docs: update docs some more

main
Jef Roosens 2022-12-19 11:24:22 +01:00
parent 26796f2228
commit b66d1161ed
Signed by untrusted user: Jef Roosens
GPG Key ID: B75D4F293C7052DB
4 changed files with 49 additions and 5 deletions

View File

@ -33,10 +33,37 @@ force | Whether it's a forced build (true if present)
<aside class="warning"> <aside class="warning">
This endpoint is used by the agents and should not be used manually. It's just This endpoint is used by the agents and should not be used manually. It's just
here for completeness. here for completeness. Requests to this endpoint modify the build queue,
meaning manual requests can cause builds to be skipped.
</aside> </aside>
```shell
curl \
-H 'x-api-key: secret' \
'https://example.com/api/v1/jobs/poll?arch=x86_64&max=2'
```
> JSON output format
```json
{
"message": "",
"data": [
{
"target_id": 1,
"kind": "git",
"url": "https://aur.archlinux.org/discord-ptb.git",
"branch": "master",
"path": "",
"repo": "bur",
"base_image": "archlinux:base-devel",
"force": true
}
]
}
```
Poll the server for new builds. Poll the server for new builds.
### HTTP Request ### HTTP Request

View File

@ -125,8 +125,8 @@ id | ID of requested log
<aside class="warning"> <aside class="warning">
You should probably not use this endpoint, as it's used by the build system to This endpoint is used by the agents and should not be used manually unless you
publish its logs. know what you're doing. It's just here for completeness.
</aside> </aside>
@ -152,6 +152,13 @@ Plaintext contents of the build log.
## Remove a build log ## Remove a build log
```shell
curl \
-XDELETE \
-H 'X-Api-Key: secret' \
https://example.com/api/v1/logs/1
```
Remove a build log from the server. Remove a build log from the server.
### HTTP Request ### HTTP Request

View File

@ -27,6 +27,7 @@ curl \
"kind": "git", "kind": "git",
"url": "https://aur.archlinux.org/discord-ptb.git", "url": "https://aur.archlinux.org/discord-ptb.git",
"branch": "master", "branch": "master",
"path" : "",
"repo": "bur", "repo": "bur",
"schedule": "", "schedule": "",
"arch": [ "arch": [
@ -73,8 +74,9 @@ curl \
"kind": "git", "kind": "git",
"url": "https://aur.archlinux.org/discord-ptb.git", "url": "https://aur.archlinux.org/discord-ptb.git",
"branch": "master", "branch": "master",
"path": "",
"repo": "bur", "repo": "bur",
"schedule": "0 3", "schedule": "0 2",
"arch": [ "arch": [
{ {
"id": 1, "id": 1,
@ -124,6 +126,7 @@ Parameter | Description
kind | Kind of target to add; one of 'git', 'url'. kind | Kind of target to add; one of 'git', 'url'.
url | URL of the Git repository. url | URL of the Git repository.
branch | Branch of the Git repository. branch | Branch of the Git repository.
path | Subdirectory inside Git repository to use.
repo | Vieter repository to publish built packages to. repo | Vieter repository to publish built packages to.
schedule | Cron build schedule (syntax explained [here](https://rustybever.be/docs/vieter/usage/builds/schedule/)) schedule | Cron build schedule (syntax explained [here](https://rustybever.be/docs/vieter/usage/builds/schedule/))
arch | Comma-separated list of architectures to build package on. arch | Comma-separated list of architectures to build package on.
@ -149,12 +152,20 @@ Parameter | Description
kind | Kind of target; one of 'git', 'url'. kind | Kind of target; one of 'git', 'url'.
url | URL of the Git repository. url | URL of the Git repository.
branch | Branch of the Git repository. branch | Branch of the Git repository.
path | Subdirectory inside Git repository to use.
repo | Vieter repository to publish built packages to. repo | Vieter repository to publish built packages to.
schedule | Cron build schedule schedule | Cron build schedule
arch | Comma-separated list of architectures to build package on. arch | Comma-separated list of architectures to build package on.
## Remove a target ## Remove a target
```shell
curl \
-XDELETE \
-H 'X-Api-Key: secret' \
https://example.com/api/v1/targets/1
```
Remove a target from the server. Remove a target from the server.
### HTTP Request ### HTTP Request

View File

@ -13,4 +13,3 @@ api_update_frequency = 2
image_rebuild_frequency = 1 image_rebuild_frequency = 1
max_concurrent_builds = 3 max_concurrent_builds = 3
max_log_age = 64 max_log_age = 64
log_removal_schedule = '*/2 *'