You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit ff62ddb
Browse filesBrowse the repository at this point in the historyBrowse files
api: rename repository branch and path to revision and dir
Breaking change to v1alpha1:
- spec.repository.branch is now spec.repository.revision. It takes a
branch name or a full ref such as refs/tags/v1.0.0. Bare tag names and
commit hashes follow once sources are read with func's
NewFunctionFromGit.
- spec.repository.path is now spec.repository.dir, matching func's
build.source.dir and --source-dir.
- status.git.resolvedBranch is now status.git.resolvedRevision.
The operator no longer defaults an empty revision to main: the clone
takes the remote's default branch and resolvedRevision reports its name,
so repositories whose default branch is not main work without a
revision.
The sample CR used fields the CRD never had (spec.source.repositoryUrl,
spec.registry.path) and is rewritten against the current schema.
knative/func's Function CR sync still writes branch and path through
func-operator v0.2.1. The API server drops those unknown fields, so func
needs a matching change.
Copy file name to clipboardExpand all lines: README.md
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -204,7 +204,7 @@ kubectl get func my-function -o yaml
204
204
205
205
The status will include:
206
206
- Function name and conditions
207
-
- Git information (branch, commit, last checked time)
207
+
- Git information (revision, commit, last checked time)
208
208
- Deployment details (image, runtime, build time, deployer)
209
209
- Middleware status (current and available versions, auto-update settings, pending rebuild status)
210
210
- Service status (URL and readiness)
@@ -213,7 +213,7 @@ The status will include:
213
213
214
214
### Functions in Monorepos
215
215
216
-
For functions located in a subdirectory of a repository (e.g., in a monorepo), use the `repository.path` field to specify the path to your function:
216
+
For functions located in a subdirectory of a repository (e.g., in a monorepo), use the `repository.dir` field to specify the directory that holds your function:
| `repository.url` | string | Yes | URL of the Git repository. Supports HTTPS, HTTP, SSH (`ssh://`), and SCP-style (`git@host:path`) |
294
-
| `repository.branch` | string | No | Branch of the repository |
295
-
| `repository.path` | string | No | Path to the function inside the repository. Defaults to "." |
294
+
| `repository.revision` | string | No | Revision to build: a branch name or a full ref such as `refs/tags/v1.0.0`. Defaults to the repository's default branch |
295
+
| `repository.dir` | string | No | Directory within the repository that holds the function (its `func.yaml`). Defaults to the repository root |
296
296
| `repository.authSecretRef` | object | No | Reference to the auth secret for private repository authentication |
297
297
| `registry.authSecretRef` | object | No | Reference to the secret containing credentials for registry authentication |
298
298
| `autoUpdateMiddleware` | boolean | No | Defines if the operator should rebuild when outdated middleware is detected. When not specified, defaults to the operator-wide setting in the `func-operator-controller-config` ConfigMap (default: `true`). Function-level setting takes precedence over operator default |
@@ -303,7 +303,7 @@ See [CONTRIBUTING.md](CONTRIBUTING.md) for development setup, testing, and contr
303
303
|-------|------|-------------|
304
304
| `name` | string | Function name from metadata |
305
305
| `conditions` | array | Status conditions (see below) |
306
-
| `git.resolvedBranch` | string | Git branch that is being monitored |
306
+
| `git.resolvedRevision` | string | Revision that was checked out: `repository.revision`, or the default branch name when that is empty |
0 commit comments