Skip to content

Commit

Permalink
Merge "CRD - Add the Pagure connection support"
Browse files Browse the repository at this point in the history
  • Loading branch information
Microzuul CI authored and Gerrit Code Review committed Dec 20, 2023
2 parents b170617 + 545ed92 commit c16a6a1
Show file tree
Hide file tree
Showing 4 changed files with 107 additions and 0 deletions.
23 changes: 23 additions & 0 deletions api/v1/softwarefactory_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,27 @@ type GerritConnection struct {
VerifySSL *bool `json:"verifyssl,omitempty"`
}

// Describes a Zuul connection using the [pagure driver](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#connection-configuration).
type PagureConnection struct {
// How the connection will be named in Zuul's configuration and appear in zuul-web
Name string `json:"name"`
// the [server](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure connection>.server)
Server string `json:"server,omitempty"`
// the [canonicalHostname](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure connection>.canonical_hostname)
CanonicalHostname string `json:"canonicalHostname,omitempty"`
// the (baseUrl)[https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-%3Cpagure%20connection%3E.baseurl)
BaseURL string `json:"baseUrl,omitempty"`
// Name of the secret which containes the following keys:
// the [api_token](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure connection>.api_token)
Secrets string `json:"secrets,omitempty"`
// the [appName](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure connection>.app_name)
AppName string `json:"appName,omitempty"`
// the [cloneUrl](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure connection>.cloneurl)
CloneURL string `json:"cloneUrl,omitempty"`
// the [sourceWhitelist](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure connection>.source_whitelist)
SourceWhitelist string `json:"sourceWhitelist,omitempty"`
}

// Describes a Zuul connection using the [git driver](https://zuul-ci.org/docs/zuul/latest/drivers/git.html#connection-configuration).
// When an optional parameter is not specified then Zuul's defaults apply
type GitConnection struct {
Expand Down Expand Up @@ -283,6 +304,8 @@ type ZuulSpec struct {
GitLabConns []GitLabConnection `json:"gitlabconns,omitempty"`
// The list of Git-based connections to add to Zuul's configuration
GitConns []GitConnection `json:"gitconns,omitempty"`
// The list of Pagure-based connections to add to Zuul's configuration
PagureConns []PagureConnection `json:"pagureconns,omitempty"`
// The list of ElasticSearch-based connections to add to Zuul's configuration
ElasticSearchConns []ElasticSearchConnection `json:"elasticsearchconns,omitempty"`
// Configuration of the executor microservices
Expand Down
20 changes: 20 additions & 0 deletions api/v1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -666,6 +666,48 @@ spec:
- realm
type: object
type: array
pagureconns:
description: The list of Pagure-based connections to add to Zuul's
configuration
items:
description: Describes a Zuul connection using the [pagure driver](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#connection-configuration).
properties:
appName:
description: the [appName](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure
connection>.app_name)
type: string
baseUrl:
description: the (baseUrl)[https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-%3Cpagure%20connection%3E.baseurl)
type: string
canonicalHostname:
description: the [canonicalHostname](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure
connection>.canonical_hostname)
type: string
cloneUrl:
description: the [cloneUrl](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure
connection>.cloneurl)
type: string
name:
description: How the connection will be named in Zuul's
configuration and appear in zuul-web
type: string
secrets:
description: 'Name of the secret which containes the following
keys: the [api_token](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure
connection>.api_token)'
type: string
server:
description: the [server](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure
connection>.server)
type: string
sourceWhitelist:
description: the [sourceWhitelist](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure
connection>.source_whitelist)
type: string
required:
- name
type: object
type: array
scheduler:
description: Configuration of the scheduler microservice
properties:
Expand Down
22 changes: 22 additions & 0 deletions doc/reference/api/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -331,6 +331,27 @@ _Appears in:_
| `statsdTarget` _string_ | The address to forward statsd metrics to (optional), in the form "host:port" | -|


#### PagureConnection



Describes a Zuul connection using the [pagure driver](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#connection-configuration).

_Appears in:_
- [ZuulSpec](#zuulspec)

| Field | Description | Default Value |
| --- | --- | --- |
| `name` _string_ | How the connection will be named in Zuul's configuration and appear in zuul-web | -|
| `server` _string_ | the [server](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure connection>.server) | -|
| `canonicalHostname` _string_ | the [canonicalHostname](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure connection>.canonical_hostname) | -|
| `baseUrl` _string_ | the (baseUrl)[https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-%3Cpagure%20connection%3E.baseurl) | -|
| `secrets` _string_ | Name of the secret which containes the following keys: the [api_token](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure connection>.api_token) | -|
| `appName` _string_ | the [appName](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure connection>.app_name) | -|
| `cloneUrl` _string_ | the [cloneUrl](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure connection>.cloneurl) | -|
| `sourceWhitelist` _string_ | the [sourceWhitelist](https://zuul-ci.org/docs/zuul/latest/drivers/pagure.html#attr-<pagure connection>.source_whitelist) | -|


#### Secret


Expand Down Expand Up @@ -536,6 +557,7 @@ _Appears in:_
| `githubconns` _[GitHubConnection](#githubconnection) array_ | The list of GitHub-based connections to add to Zuul's configuration | -|
| `gitlabconns` _[GitLabConnection](#gitlabconnection) array_ | The list of GitLab-based connections to add to Zuul's configuration | -|
| `gitconns` _[GitConnection](#gitconnection) array_ | The list of Git-based connections to add to Zuul's configuration | -|
| `pagureconns` _[PagureConnection](#pagureconnection) array_ | The list of Pagure-based connections to add to Zuul's configuration | -|
| `elasticsearchconns` _[ElasticSearchConnection](#elasticsearchconnection) array_ | The list of ElasticSearch-based connections to add to Zuul's configuration | -|
| `executor` _[ZuulExecutorSpec](#zuulexecutorspec)_ | Configuration of the executor microservices | -|
| `scheduler` _[ZuulSchedulerSpec](#zuulschedulerspec)_ | Configuration of the scheduler microservice | -|
Expand Down

0 comments on commit c16a6a1

Please sign in to comment.