* Added the option to use --scale for setting MinScale and MaxScale to the
same value
* Updated service create/update to resolve test issues
* Removed scale from the annotation section - there isn't a scale
annotation
* Renamed test service name so that it doesn't match a previous test
* Addressed most issues/changes
* Added tests for multiple flags being used at the same time
* Cleaned up the update tests
* Added negative value tests and cleaned up tests in create_test.go
* feat: Add --file flag to service create cmd
* fix: Fix linter warnings
* fix: Remove unecessary changes
* fix: Reflect review feedback
* fix: Change flag --file to -f,--filename
* fix: Reflect review feedback
* fix: Move test cleanup to correct place
* fix: Refactor name param restrictions
* fix: Fix flag name string in func
* Update unit test for invalid concurrency target value
* Vendor v0.16.0 eventing and serving
* Commit the LICENSES generated by hack/update-deps.sh
* Spare third_party dir from license check in hack/build.sh
* Update eventing and serving version for 'kn version'
* Use DeprecatedInjectionAnnotation key for backward compatibility
Fixes#918
Use DeprecatedInjectionAnnotation, i.e. "knative-eventing-injection"
for reconciling broker via namespace labeling and trigger annotations.
From eventing v0.16.0 release, this key is changed to "eventing.knative.dev/injection"
however, older eventing installation wont recognize it. So we continue
using the deprecated key until the sugar-controller would support reconciling
on either keys.
* Fix(kn version): Display eventing.knative.dev at v1beta1 version
We've been showing 'v1alpha1' in kn version while we actually
vendor and refer v1beta1 for eventing.knative.dev
* chore(e2e): Run tests against serving/eventing v0.16.0 release
* Update test for concurrency-target to expect new error message
the new error message for incorrect concurrency-target value contains "should be at least 0.01"
* Setup sugar-controller for released eventing version setup
- reuse knative_setup util from common lib for latest-release CI setup
* Fix typo in YAML URL and add subheader for sugar-controller install
We'll need sugar controller for reconciling broker for tests
which labels namespace and annotates the triggers.
Currently, sugar controller is not part of the eventing nightly release setup
by test-infra libs. This changeset adds install of same for nightly
CI setup.
* add kn export type
* add kn export type
* add kn export type
* Update pkg/apis/client/register.go
Co-authored-by: Matt Moore <mattmoor@vmware.com>
* e2e test for kn export type
* e2e test for kn export type
* add new type for kn export
* rebase
* rebase
Co-authored-by: Roland Huß <rhuss@redhat.com>
Co-authored-by: Matt Moore <mattmoor@vmware.com>
Co-authored-by: Roland Huß <roland@ro14nd.de>
* Refactor main flow, plugin and configuration handling
* The plugin handling has been moved out of the `KnDefaultCommand` constructor where it was executed as a side-effect. The original code from `kubectl` suffers from the same issue that plugin handling is not a top-level concern but was very likely introduced as an after-thought. Instead, the plugin handling is done now by a `PluginManager` which is explicitly called in `main()`.
* Configuration and bootstrap option handling is centralized in the package `option`. After the bootstrap happened, the content of the configuration file, as well as any other global configuration, can be obtained from methods on `config.GlobalConfig`. Also, all flag handling is delegated to cobra so that no own parsing is needed.
* Many of the logic in `pkg/kn/commands/plugin` for plugin management has been moved up to `pkg/kn/plugin` as this code is not only relevant for `plugin list` but also for the bootstrap process.
* fix: invalid subcommands will lead to a proper error message
* Update pkg/kn/config/types.go
Co-authored-by: Navid Shaikh <nshaikh@redhat.com>
* Update pkg/kn/plugin/manager.go
Co-authored-by: Navid Shaikh <nshaikh@redhat.com>
* Update hack/generate-docs.go
Co-authored-by: Navid Shaikh <nshaikh@redhat.com>
* Update hack/generate-docs.go
Co-authored-by: Navid Shaikh <nshaikh@redhat.com>
* chore: Add missing links
* chore: recert to shas in links in developer guide for now.
Co-authored-by: Navid Shaikh <nshaikh@redhat.com>
* return error message from using --untag with nonexistent tag
* improve err message for --untag and add e2e test
* change untagRevision to return bool and add traffic e2e tests
* update changelog
* Update flag names to --request and --limit
- Use singular flag names and support comma separated or repeated flag values
- Update tests and docs
* Update CHANGELOG
* Update the flag description and examples
* Remove release 0.15.0 header from CHANGELOG
* prevent plugins that shadow commands of exsiting groups, e.g., kn-service-create is NOT OK
* list plugins that extend existing groups
* warn plugins that shadow command of existing groups
* add UTs for above
* Add --requests and --limits resource flags
Fixes#490
- Add deprecation message for --requests-cpu, --requests-memory,
--limits-cpu and --limits-memory flag usage.
- Add error message if new and deprecated, requests and limits flags
are used together.
* Add resources requests and limits example for service create
* Add mock style unit tests
* Update existing unit tests for deprecated flags
* Add integration tests
* Add CHANGELOG entry
* Fix lint warnings
* Add unit tests for resource flags
* Fix typo for service name in e2e tests
* Refactor resource validation utility into test lib
* Remove commented out code
* Add references about managing resources and GPU in example
* Update image references in examples
* fix(e2e): Create next namespace if one exists
Do not error out if the namespace to run e2e into exists, try creating
next one in row. Retry at 20 next namespaces, before erroring out.
* Tag plugin tests as !serving and !eventing
* Debug: Create a test namespace to see if its skipped
* Revert "Debug: Create a test namespace to see if its skipped"
This reverts commit 8b45fcef4d.
* Refactor file utils from e2e tests to test lib
* fix(e2e): Refactor e2e utils and resource actions
brings commonly re-used utilities into lib/test so they can be resused
and e2e can be run selectively for eventing/serving.
* Refactor service and revision e2e test utils into test lib
* Docstrings for exported e2e test utils
* refactor kn service export to export revisions
* refactor kn service export to export revisions
* refactor kn service export to export revisions
* refactor kn service export to export revisions
* kn service export refactor
* kn service export refactor
* kn service export refactor
* kn service export refactor
* review changes for #819
* chore: Update to Knative serving/eventing 0.14.0
and also move ApiServerSource to v1alpha2, adapting the option
(from "controller" to "labelSelector")
* fix go.sum
* chore: Update and fix tests
* chore: fix go.sum
* Use buildah task from master branch and paramterize FORMAT
* Configure pipeline v0.11.1
* DNM: Run tekton e2e in this PR
* Revert "DNM: Run tekton e2e in this PR"
This reverts commit 903f5bec409c90174a37cc84acd561a405ef896e.
* Add e2e test for different service and revision label
- Store results from one call and validate both revision and service labels
- Update var name for more better readability
Signed-off-by: Andrew Su <asu@pivotal.io>
* Test verifies expected labels are exact match to received labels
I find that I'm using annotations more and more and since `-a`
wasn't being used I decided we should save people from typing too much
Signed-off-by: Doug Davis <dug@us.ibm.com>
* (refactor) address the e2e extract / refactor of issue #763
* various updates to address reviewers feedback
* renamed lib/test/integration to lib/test and package to test
When specified on 'service create' the '--cluster-local' flag will
make the created service 'private' by setting its config visibility
to 'cluster-local'. This is done with label:
serving.knative.dev/visibility: cluster-local
The --no-cluster-local will remove the label.
* feat(source): Add 'kn source list'
Fixes#480
- Add 'kn source list' listing the available sources COs
- Use dynamic client to
- find out available source types
- find the COs in given namespace for each source type
- Add --type flag to filter source list based on source type
- Add unit tests
- Add e2e tests
- Add CHANGELOG entry
* Update group for ApiServerSource in tests
* Add kn duck source type for holding common eventing source fileds
- Common infromation from sources are extracted into a struct
for source list command output
- Printer function picks the information from this struct object
and doesn't know the details about extracting this info from multiple
types of sources received
- Group and Version for list is set to empty string and Kind to 'List',
if printed a source list with multiple types of sources in machine readable
format
- Group, Version and Kind for list are kept intact if printed a source list
with same type of source objects in machine readable format
* Update go.sum
* Add WithType builder for listing source
- Separate the flags definition
- WithType builder can be re-used to filter the source types
- Add unit tests
* Update ApiServer source group to apiserversources.sources.knative.dev
* Fix typos and align
Co-authored-by: Roland Huß <roland@ro14nd.de>