-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
NBSNEBIUS-85: add manifests for nbs; support volume attach via nbd (#875
- Loading branch information
Showing
5 changed files
with
133 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
45 changes: 45 additions & 0 deletions
45
cloud/blockstore/tools/csi_driver/deploy/manifests/5-nbs-configmap.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
--- | ||
apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
name: nbs-server-config-node | ||
namespace: nbs-csi-ns | ||
data: | ||
nbs-server.txt: |- | ||
ServerConfig { | ||
Host: "localhost" | ||
Port: 9766 | ||
DataHost: "localhost" | ||
DataPort: 9767 | ||
StrictContractValidation: true | ||
UnixSocketPath: "/run/nbsd/grpc.sock" | ||
ThreadsCount: 4 | ||
VhostEnabled: true | ||
VhostThreadsCount: 4 | ||
NodeType: "nbs" | ||
EndpointStorageType: ENDPOINT_STORAGE_FILE | ||
EndpointStorageDir: "/Berkanavt/nbs-server/endpoints" | ||
NbdEnabled: true | ||
NbdThreadsCount: 4 | ||
GrpcKeepAliveTime: 10000 | ||
GrpcKeepAliveTimeout: 1000 | ||
GrpcKeepAlivePermitWithoutCalls: true | ||
GrpcHttp2MinRecvPingIntervalWithoutData: 1000 | ||
NbdDevicePrefix: "/mnt/dev/nbd" | ||
} | ||
LocalServiceConfig { | ||
DataDir: "/Berkanavt/nbs-server/data" | ||
} | ||
nbs_server.cfg: |- | ||
nbs_home="${nbs_home:-"/Berkanavt/nbs-server"}" | ||
nbs_config="${nbs_home}/cfg" | ||
nbs_server_file="${nbs_config}/nbs-server.txt" | ||
nbs_arg="${nbs_arg}${nbs_server_file:+ --server-file ${nbs_server_file}}" | ||
nbs_arg="${nbs_arg} --service=local" | ||
nbs_arg="${nbs_arg} --mon-port=8766" | ||
nbs_arg="${nbs_arg} --verbose" |
78 changes: 78 additions & 0 deletions
78
cloud/blockstore/tools/csi_driver/deploy/manifests/6-nbs-daemonset.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
--- | ||
apiVersion: apps/v1 | ||
kind: DaemonSet | ||
metadata: | ||
name: nbs-server-node | ||
namespace: nbs-csi-ns | ||
spec: | ||
selector: | ||
matchLabels: | ||
app: "nbs-server-app" | ||
template: | ||
metadata: | ||
labels: | ||
app: "nbs-server-app" | ||
spec: | ||
hostNetwork: true | ||
nodeSelector: | ||
kubernetes.io/os: linux | ||
initContainers: | ||
- name: modprobe-nbd | ||
image: cr.ai.nebius.cloud/mirror/io/docker/library/busybox:1.32.1 | ||
imagePullPolicy: IfNotPresent | ||
command: ["modprobe", "nbd", "nbds_max=1024"] | ||
securityContext: | ||
privileged: true | ||
resources: | ||
requests: | ||
cpu: "100m" | ||
memory: "16Mi" | ||
volumeMounts: | ||
- name: lib-modules | ||
mountPath: /lib/modules | ||
readOnly: false | ||
containers: | ||
- name: nbs-server | ||
securityContext: | ||
privileged: true | ||
image: cr.ai.nebius.cloud/crnvrq2hg2rgmbj3ebr9/nebius-blockstore-server:85.stable-23-3-21 | ||
imagePullPolicy: Always | ||
volumeMounts: | ||
- name: nbs-server | ||
mountPath: /Berkanavt/nbs-server | ||
readOnly: false | ||
- name: nbs-configs | ||
mountPath: /Berkanavt/nbs-server/cfg | ||
readOnly: true | ||
- name: nbs-run | ||
mountPath: /run/nbsd | ||
readOnly: false | ||
- name: dev | ||
mountPath: /mnt/dev | ||
readOnly: false | ||
volumes: | ||
- name: nbs-server-backups | ||
hostPath: | ||
path: /Berkanavt/nbs-server/backups | ||
type: DirectoryOrCreate | ||
- name: nbs-server-endpoints | ||
hostPath: | ||
path: /Berkanavt/nbs-server/endpoints | ||
type: DirectoryOrCreate | ||
- name: nbs-configs | ||
configMap: | ||
name: nbs-server-config-node | ||
- name: nbs-run | ||
hostPath: | ||
path: /run/nbsd | ||
type: DirectoryOrCreate | ||
- name: dev | ||
hostPath: | ||
path: /dev | ||
type: DirectoryOrCreate | ||
- name: lib-modules | ||
hostPath: | ||
path: /lib/modules | ||
type: DirectoryOrCreate | ||
imagePullSecrets: | ||
- name: nbs-puller-secret |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters