Add support for v1 of Gateway API `HTTPRoute`. Drop support for v1alpha2
as it was deprecated almost a year ago.
Signed-off-by: Sanskar Jaiswal <jaiswalsanskar078@gmail.com>
Adds Gateway API as a provider for progressive traffic shifting, A/B
testing and Blue-Green testing. Adds a new field in the Canary
`spec.service.gatewayRefs` which specifies the Gateway that Flagger
should use.
Signed-off-by: Sanskar Jaiswal <jaiswalsanskar078@gmail.com>
In my self project I reference this nice script, the go.sum look like this(after run go mod tidy and
download):
```
k8s.io/apimachinery v0.22.1/go.mod h1:O3oNtNadZdeOMxHFVxOreoznohCpy0z6mocxbZr7oJ0=
k8s.io/apiserver v0.22.1/go.mod h1:2mcM6dzSt+XndzVQJX21Gx0/Klo7Aen7i0Ai6tIa400=
k8s.io/client-go v0.22.1 h1:jW0ZSHi8wW260FvcXHkIa0NLxFBQszTlhiAVsU5mopw=
k8s.io/client-go v0.22.1/go.mod h1:BquC5A4UOo4qVDUtoc04/+Nxp1MeHcVc1HJm1KmG8kk=
k8s.io/code-generator v0.22.1/go.mod h1:eV77Y09IopzeXOJzndrDyCI88UBok2h6WxAlBwpxa+o=
k8s.io/component-base v0.22.1 h1:SFqIXsEN3v3Kkr1bS6rstrs1wd45StJqbtgbQ4nRQdo=
```
as you can see the, sometimes the go.sum only has `version/go.mod` line,
if we run the scripts, it will fail like this:
chmod: cannot access '/home/longkai/pkg/mod/k8s.io/code-generator@v0.22.1/go.mod/generate-groups.sh': Not a directory
so this pr fix this.
Finally, the list is sort by version ast, we want to choose the newer one.
Signed-off-by: longkai <im.longkai@gmail.com>
This commit fixes two things:
- it ensures the code generation works no matter the location of the
project directory
- as a side effect; fixes the `hack/verify-codegen.sh` ran during CI
The previous script (or more specific: the `code-generator` library)
made the assumption during execution that the project was placed
inside `$GOPATH/src` and made the modifications there.
The idea of Go Modules is however that a project and/or package can
be placed anywhere, and this is also what the CI did, resulting in a
comparison of two identical `cp -r` copied directories. Giving a
false green light on every CI run.
To work around this limitation in `code-generator`: create a
temporary directory, use this as an output base and copy
everything back once generated.