mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2026-02-13 21:00:00 +00:00
Revert "Send configuration as part of the request for external configuration" (#5835)
Co-authored-by: 6543 <6543@obermui.de>
This commit is contained in:
@@ -42,10 +42,6 @@ class Request {
|
||||
repo: Repo;
|
||||
pipeline: Pipeline;
|
||||
netrc: Netrc;
|
||||
configuration: {
|
||||
name: string; // filename of the configuration file
|
||||
data: string; // content of the configuration file
|
||||
}[];
|
||||
}
|
||||
```
|
||||
|
||||
@@ -56,12 +52,15 @@ Checkout the following models for more information:
|
||||
- [netrc model](https://github.com/woodpecker-ci/woodpecker/blob/main/server/model/netrc.go)
|
||||
|
||||
:::tip
|
||||
The `netrc` data is pretty powerful as it contains credentials to access the repository. You can use this to clone the repository or even use the forge (Github or Gitlab, ...) API to get more information about the repository.
|
||||
The `netrc` data is pretty powerful as it contains credentials to access the repository. You can use this to fetch files or other information (like changed files, issues) from the repository using the forge api or even clone the repository.
|
||||
:::
|
||||
|
||||
Example request:
|
||||
|
||||
```json
|
||||
// Please check the latest structure in the models mentioned above.
|
||||
// This example is likely outdated.
|
||||
|
||||
{
|
||||
"repo": {
|
||||
"id": 100,
|
||||
@@ -123,12 +122,12 @@ Example request:
|
||||
"updated_at": 0,
|
||||
"verified": false
|
||||
},
|
||||
"configs": [
|
||||
{
|
||||
"name": ".woodpecker.yaml",
|
||||
"data": "steps:\n - name: backend\n image: alpine\n commands:\n - echo \"Hello there from Repo (.woodpecker.yaml)\"\n"
|
||||
}
|
||||
]
|
||||
"netrc": {
|
||||
"machine": "myforge.com",
|
||||
"login": "myUser",
|
||||
"password": "myPassword",
|
||||
"type": "forge"
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
@@ -187,6 +187,7 @@ The Webhook tokens have been changed for enhanced security and therefore existin
|
||||
Image pull secrets must now be set explicitly via env var `WOODPECKER_BACKEND_K8S_PULL_SECRET_NAMES` ([#4005](https://github.com/woodpecker-ci/woodpecker/pull/4005))
|
||||
|
||||
- Webhook signatures now use the `rfc9421` protocol
|
||||
- Replaced `configs` object by `netrc` in external configuration APIs
|
||||
|
||||
- Git is now the only officially supported SCM.
|
||||
No others were supported previously, but the existence of the env var `CI_REPO_SCM` indicated that others might be.
|
||||
|
||||
@@ -42,10 +42,6 @@ class Request {
|
||||
repo: Repo;
|
||||
pipeline: Pipeline;
|
||||
netrc: Netrc;
|
||||
configuration: {
|
||||
name: string; // filename of the configuration file
|
||||
data: string; // content of the configuration file
|
||||
}[];
|
||||
}
|
||||
```
|
||||
|
||||
@@ -56,12 +52,15 @@ Checkout the following models for more information:
|
||||
- [netrc model](https://github.com/woodpecker-ci/woodpecker/blob/main/server/model/netrc.go)
|
||||
|
||||
:::tip
|
||||
The `netrc` data is pretty powerful as it contains credentials to access the repository. You can use this to clone the repository or even use the forge (Github or Gitlab, ...) API to get more information about the repository.
|
||||
The `netrc` data is pretty powerful as it contains credentials to access the repository. You can use this to fetch files or other information (like changed files, issues) from the repository using the forge api or even clone the repository.
|
||||
:::
|
||||
|
||||
Example request:
|
||||
|
||||
```json
|
||||
// Please check the latest structure in the models mentioned above.
|
||||
// This example is likely outdated.
|
||||
|
||||
{
|
||||
"repo": {
|
||||
"id": 100,
|
||||
@@ -123,12 +122,12 @@ Example request:
|
||||
"updated_at": 0,
|
||||
"verified": false
|
||||
},
|
||||
"configs": [
|
||||
{
|
||||
"name": ".woodpecker.yaml",
|
||||
"data": "steps:\n - name: backend\n image: alpine\n commands:\n - echo \"Hello there from Repo (.woodpecker.yaml)\"\n"
|
||||
}
|
||||
]
|
||||
"netrc": {
|
||||
"machine": "myforge.com",
|
||||
"login": "myUser",
|
||||
"password": "myPassword",
|
||||
"type": "forge"
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user