Skip to content

Commit

Permalink
Rename special resource operator to gpu operator
Browse files Browse the repository at this point in the history
Signed-off-by: Renaud Gaubert <rgaubert@nvidia.com>
  • Loading branch information
Renaud Gaubert committed Apr 9, 2020
1 parent c150425 commit 36c1c87
Show file tree
Hide file tree
Showing 11 changed files with 17 additions and 18 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE.md
Expand Up @@ -5,7 +5,7 @@ _The template below is mostly useful for bug reports and support questions. Feel
- [ ] Are you running Kubernetes v1.13+?
- [ ] Are you running Docker (>= 18.06) or CRIO (>= 1.13+)?
- [ ] Do you have `i2c_core` and `ipmi_msghandler` loaded on the nodes?
- [ ] Did you apply the CRD (`kubectl describe specialresources --all-namespaces`)
- [ ] Did you apply the CRD (`kubectl describe clusterpolicies --all-namespaces`)

### 1. Issue or feature description

Expand Down
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -79,7 +79,7 @@ gpu-operator-resources nvidia-device-plugin-daemonset-8kd64 1/1 Ru
gpu-operator-resources nvidia-device-plugin-validation 0/1 Completed 0 2m47s
gpu-operator-resources nvidia-driver-daemonset-8nwcb 1/1 Running 0 5m4s
gpu-operator-resources nvidia-driver-validation 0/1 Completed 0 4m37s
gpu-operator special-resource-operator-576bf567c7-c9z9g 1/1 Running 0 5m19s
gpu-operator gpu-operator-576bf567c7-c9z9g 1/1 Running 0 5m19s
kube-system calico-kube-controllers-6b9d4c8765-7w5pb 1/1 Running 0 12m
kube-system calico-node-scfwp 1/1 Running 0 12m
kube-system coredns-6955765f44-9zjk6 1/1 Running 0 12m
Expand Down
2 changes: 1 addition & 1 deletion cmd/manager/main.go
Expand Up @@ -60,7 +60,7 @@ func main() {
}

// Become the leader before proceeding
err = leader.Become(context.TODO(), "special-resource-operator-lock")
err = leader.Become(context.TODO(), "gpu-operator-lock")
if err != nil {
log.Error(err, "")
os.Exit(1)
Expand Down
13 changes: 6 additions & 7 deletions deployments/gpu-operator/templates/operator.yaml
@@ -1,26 +1,25 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: special-resource-operator
name: gpu-operator
namespace: {{ $.Release.Namespace }}
spec:
replicas: 1
selector:
matchLabels:
name: special-resource-operator
name: gpu-operator
template:
metadata:
labels:
name: special-resource-operator
name: gpu-operator
annotations:
openshift.io/scc: restricted-readonly
spec:
serviceAccount: special-resource-operator
serviceAccountName: special-resource-operator
serviceAccountName: gpu-operator
# readOnlyRootFilesystem: true

containers:
- name: special-resource-operator
- name: gpu-operator
{{- if .Values.operator.tag}}
image: {{ .Values.operator.repository }}/{{ .Values.operator.image }}:{{ .Values.operator.tag }}
{{- else }}
Expand All @@ -41,7 +40,7 @@ spec:
fieldRef:
fieldPath: metadata.name
- name: OPERATOR_NAME
value: "special-resource-operator"
value: "gpu-operator"

readinessProbe:
exec:
Expand Down
Expand Up @@ -37,7 +37,7 @@ seLinuxContext:
supplementalGroups:
type: RunAsAny
users:
- system:serviceaccount:gpu-operator:special-resource-operator
- system:serviceaccount:gpu-operator:gpu-operator
volumes:
- configMap
- downwardAPI
Expand Down
2 changes: 1 addition & 1 deletion deployments/gpu-operator/templates/role.yaml
Expand Up @@ -2,7 +2,7 @@ apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
creationTimestamp: null
name: special-resource-operator
name: gpu-operator
rules:
{{- if .Values.platform.openshift }}
- apiGroups:
Expand Down
6 changes: 3 additions & 3 deletions deployments/gpu-operator/templates/rolebinding.yaml
@@ -1,12 +1,12 @@
kind: ClusterRoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: special-resource-operator
name: gpu-operator
subjects:
- kind: ServiceAccount
name: special-resource-operator
name: gpu-operator
namespace: {{ $.Release.Namespace }}
roleRef:
kind: ClusterRole
name: special-resource-operator
name: gpu-operator
apiGroup: rbac.authorization.k8s.io
2 changes: 1 addition & 1 deletion deployments/gpu-operator/templates/serviceaccount.yaml
@@ -1,5 +1,5 @@
apiVersion: v1
kind: ServiceAccount
metadata:
name: special-resource-operator
name: gpu-operator
namespace: {{ $.Release.Namespace }}
2 changes: 1 addition & 1 deletion pkg/apis/nvidia/v1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion tests/ci-run-e2e.sh
Expand Up @@ -100,7 +100,7 @@ test_restart_operator() {
# Sleep a reasonable amount of time for k8s to update the container status to crashing
sleep 10

state=$(kubectl get pods -n "$NS" -l name=special-resource-operator \
state=$(kubectl get pods -n "$NS" -l name=gpu-operator \
-o jsonpath='{.items[0].status.phase}')

echo "Checking state of the GPU Operator, it is: '$state'"
Expand Down

0 comments on commit 36c1c87

Please sign in to comment.