Migrate to new networking.k8s.io/v1beta1 package
This commit is contained in:
parent
8cee8d5d9b
commit
84102eec2b
113 changed files with 834 additions and 648 deletions
|
|
@ -17,7 +17,7 @@ limitations under the License.
|
|||
package modsecurity
|
||||
|
||||
import (
|
||||
extensions "k8s.io/api/extensions/v1beta1"
|
||||
networking "k8s.io/api/networking/v1beta1"
|
||||
"k8s.io/ingress-nginx/internal/ingress/annotations/parser"
|
||||
"k8s.io/ingress-nginx/internal/ingress/resolver"
|
||||
)
|
||||
|
|
@ -65,7 +65,7 @@ type modSecurity struct {
|
|||
|
||||
// Parse parses the annotations contained in the ingress
|
||||
// rule used to enable ModSecurity in a particular location
|
||||
func (a modSecurity) Parse(ing *extensions.Ingress) (interface{}, error) {
|
||||
func (a modSecurity) Parse(ing *networking.Ingress) (interface{}, error) {
|
||||
var err error
|
||||
config := &Config{}
|
||||
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ import (
|
|||
"testing"
|
||||
|
||||
api "k8s.io/api/core/v1"
|
||||
extensions "k8s.io/api/extensions/v1beta1"
|
||||
networking "k8s.io/api/networking/v1beta1"
|
||||
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
"k8s.io/ingress-nginx/internal/ingress/annotations/parser"
|
||||
"k8s.io/ingress-nginx/internal/ingress/resolver"
|
||||
|
|
@ -59,12 +59,12 @@ func TestParse(t *testing.T) {
|
|||
{nil, Config{false, false, "", ""}},
|
||||
}
|
||||
|
||||
ing := &extensions.Ingress{
|
||||
ing := &networking.Ingress{
|
||||
ObjectMeta: meta_v1.ObjectMeta{
|
||||
Name: "foo",
|
||||
Namespace: api.NamespaceDefault,
|
||||
},
|
||||
Spec: extensions.IngressSpec{},
|
||||
Spec: networking.IngressSpec{},
|
||||
}
|
||||
|
||||
for _, testCase := range testCases {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue