Skip to content

Commit

Permalink
Change api group to av.mittwald.de (#7)
Browse files Browse the repository at this point in the history
  • Loading branch information
dkorittki authored Dec 7, 2020
1 parent 5051977 commit df8a96f
Show file tree
Hide file tree
Showing 14 changed files with 26 additions and 28 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,10 @@ This operator consists of several components:

### Starting an AV scan on demand

An on-demand scan is modelled using the `VirusScan` custom resource (API group `av.mittwald.systems/v1beta1`). In the `.spec` of a virus scan you can specify which files to scan and which engine to use (currently, only ClamAV is supported):
An on-demand scan is modelled using the `VirusScan` custom resource (API group `av.mittwald.de/v1beta1`). In the `.spec` of a virus scan you can specify which files to scan and which engine to use (currently, only ClamAV is supported):

```yaml
apiVersion: av.mittwald.systems/v1beta1
apiVersion: av.mittwald.de/v1beta1
kind: VirusScan
metadata:
name: example-virusscan
Expand Down Expand Up @@ -107,7 +107,7 @@ example-virusscan Completed (1 infected files) 44s 11s 44s
The `.status.scanResults` property in the CR lists the individual files found by the scanner:

```yaml
apiVersion: av.mittwald.systems/v1beta1
apiVersion: av.mittwald.de/v1beta1
kind: VirusScan
metadata:
name: example-virusscan
Expand All @@ -134,7 +134,7 @@ status:
Periodic scanning can be configured using the `ScheduledVirusScan` resource.

```yaml
apiVersion: av.mittwald.systems/v1beta1
apiVersion: av.mittwald.de/v1beta1
kind: ScheduledVirusScan
metadata:
name: example-scheduledvirusscan
Expand Down
4 changes: 2 additions & 2 deletions deploy/clusterrole.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@ rules:
- get
- watch
- apiGroups:
- av.mittwald.systems
- av.mittwald.de
resources:
- virusscans
verbs:
- get
- list
- watch
- apiGroups:
- av.mittwald.systems
- av.mittwald.de
resources:
- virusscans/status
verbs:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
name: scheduledvirusscans.av.mittwald.systems
name: scheduledvirusscans.av.mittwald.de
spec:
group: av.mittwald.systems
group: av.mittwald.de
names:
kind: ScheduledVirusScan
listKind: ScheduledVirusScanList
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
apiVersion: av.mittwald.systems/v1beta1
apiVersion: av.mittwald.de/v1beta1
kind: ScheduledVirusScan
metadata:
name: example-scheduledvirusscan
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
apiVersion: av.mittwald.systems/v1beta1
apiVersion: av.mittwald.de/v1beta1
kind: VirusScan
metadata:
name: example-virusscan
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
name: virusscans.av.mittwald.systems
name: virusscans.av.mittwald.de
spec:
group: av.mittwald.systems
group: av.mittwald.de
names:
kind: VirusScan
listKind: VirusScanList
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
name: scheduledvirusscans.av.mittwald.systems
name: scheduledvirusscans.av.mittwald.de
spec:
group: av.mittwald.systems
group: av.mittwald.de
names:
kind: ScheduledVirusScan
listKind: ScheduledVirusScanList
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
name: virusscans.av.mittwald.systems
name: virusscans.av.mittwald.de
spec:
group: av.mittwald.systems
group: av.mittwald.de
names:
kind: VirusScan
listKind: VirusScanList
Expand Down
4 changes: 2 additions & 2 deletions deploy/helm-chart/kubeav/templates/clusterrole_agent.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@ rules:
- get
- watch
- apiGroups:
- av.mittwald.systems
- av.mittwald.de
resources:
- virusscans
verbs:
- get
- list
- watch
- apiGroups:
- av.mittwald.systems
- av.mittwald.de
resources:
- virusscans/status
verbs:
Expand Down
6 changes: 3 additions & 3 deletions deploy/helm-chart/kubeav/templates/clusterrole_operator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,21 +27,21 @@ rules:
- apiGroups: ["apps"]
resources: [daemonsets]
verbs: [list, watch, get]
- apiGroups: ['av.mittwald.systems']
- apiGroups: ['av.mittwald.de']
resources:
- virusscans
- scheduledvirusscans
verbs:
- get
- list
- watch
- apiGroups: ['av.mittwald.systems']
- apiGroups: ['av.mittwald.de']
resources:
- virusscans
verbs:
- create
- delete
- apiGroups: ['av.mittwald.systems']
- apiGroups: ['av.mittwald.de']
resources:
- virusscans/status
- scheduledvirusscans/status
Expand Down
2 changes: 1 addition & 1 deletion deploy/role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ rules:
verbs:
- get
- apiGroups:
- av.mittwald.systems
- av.mittwald.de
resources:
- '*'
- scheduledvirusscans
Expand Down
2 changes: 1 addition & 1 deletion pkg/apis/av/v1beta1/doc.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Package v1beta1 contains API Schema definitions for the av v1beta1 API group
// +k8s:deepcopy-gen=package,register
// +groupName=av.mittwald.systems
// +groupName=av.mittwald.de
package v1beta1
6 changes: 2 additions & 4 deletions pkg/apis/av/v1beta1/register.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// NOTE: Boilerplate only. Ignore this file.

// Package v1beta1 contains API Schema definitions for the av v1beta1 API group
// +k8s:deepcopy-gen=package,register
// +groupName=av.mittwald.systems
// +groupName=av.mittwald.de
package v1beta1

import (
Expand All @@ -12,7 +10,7 @@ import (

var (
// SchemeGroupVersion is group version used to register these objects
SchemeGroupVersion = schema.GroupVersion{Group: "av.mittwald.systems", Version: "v1beta1"}
SchemeGroupVersion = schema.GroupVersion{Group: "av.mittwald.de", Version: "v1beta1"}

// SchemeBuilder is used to add go types to the GroupVersionKind scheme
SchemeBuilder = &scheme.Builder{GroupVersion: SchemeGroupVersion}
Expand Down
2 changes: 1 addition & 1 deletion pkg/controller/scheduledvirusscan/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import (

var log = logf.Log.WithName("controller_scheduledvirusscan")

const labelScheduledBy = "kubeav.mittwald.systems/scheduled-by"
const labelScheduledBy = "kubeav.mittwald.de/scheduled-by"

// Add creates a new ScheduledVirusScan Controller and adds it to the Manager. The Manager will set fields on the Controller
// and Start it when the Manager is Started.
Expand Down

0 comments on commit df8a96f

Please sign in to comment.