Try other samba share
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
|
||||
apiVersion: helm.toolkit.fluxcd.io/v2
|
||||
kind: HelmRelease
|
||||
metadata:
|
||||
|
||||
@@ -3,57 +3,29 @@ kind: ConfigMap
|
||||
metadata:
|
||||
name: samba-config
|
||||
data:
|
||||
config.json: |
|
||||
{
|
||||
"samba-container-config": "v0",
|
||||
"configs": {
|
||||
"local": {
|
||||
"shares": [
|
||||
"share"
|
||||
],
|
||||
"globals": [
|
||||
"default"
|
||||
],
|
||||
"instance_name": "SAMBA"
|
||||
}
|
||||
},
|
||||
"shares": {
|
||||
"share": {
|
||||
"options": {
|
||||
"path": "/share",
|
||||
"valid users": "sambauser",
|
||||
"writeable": "yes",
|
||||
"guest ok": "yes",
|
||||
"guest only": "yes"
|
||||
}
|
||||
}
|
||||
},
|
||||
"globals": {
|
||||
"default": {
|
||||
"options": {
|
||||
"security": "user",
|
||||
"server min protocol": "SMB2",
|
||||
"load printers": "no",
|
||||
"printing": "bsd",
|
||||
"printcap name": "/dev/null",
|
||||
"disable spoolss": "yes",
|
||||
"guest ok": "yes",
|
||||
"browsable": "yes",
|
||||
"writable": "yes",
|
||||
"guest account": "sambauser",
|
||||
"create mask": "0775",
|
||||
"directory mask": "0755",
|
||||
"map to guest": "bad user"
|
||||
}
|
||||
}
|
||||
},
|
||||
"users": {
|
||||
"all_entries": [
|
||||
{
|
||||
"name": "sambauser",
|
||||
"password": "samba"
|
||||
}
|
||||
]
|
||||
},
|
||||
"_footer": 1
|
||||
}
|
||||
smb.default: |
|
||||
[global]
|
||||
server string = samba
|
||||
idmap config * : range = 3000-7999
|
||||
security = user
|
||||
server min protocol = SMB2
|
||||
|
||||
map to guest = Bad User
|
||||
guest account = samba
|
||||
|
||||
# disable printing services
|
||||
load printers = no
|
||||
printing = bsd
|
||||
printcap name = /dev/null
|
||||
disable spoolss = yes
|
||||
|
||||
[Share]
|
||||
path = /storage
|
||||
comment = Shared
|
||||
valid users = @smb
|
||||
browseable = yes
|
||||
writable = yes
|
||||
read only = no
|
||||
|
||||
printable = no
|
||||
public = yes
|
||||
@@ -18,21 +18,9 @@ spec:
|
||||
spec:
|
||||
containers:
|
||||
- name: samba
|
||||
image: quay.io/samba.org/samba-server:latest
|
||||
securityContext:
|
||||
privileged: true
|
||||
capabilities:
|
||||
add: ["NET_ADMIN"]
|
||||
hostNetwork: true
|
||||
dnsPolicy: ClusterFirstWithHostNet
|
||||
image: dockurr/samba:latest
|
||||
ports:
|
||||
- containerPort: 445
|
||||
hostPort: 445
|
||||
env:
|
||||
- name: SAMBACC_CONFIG
|
||||
value: /etc/samba-container/config.json
|
||||
- name: SAMBA_CONTAINER_ID
|
||||
value: local
|
||||
resources:
|
||||
limits:
|
||||
cpu: 1000m
|
||||
@@ -41,14 +29,15 @@ spec:
|
||||
cpu: 10m
|
||||
memory: 64Mi
|
||||
volumeMounts:
|
||||
- mountPath: /share
|
||||
- mountPath: /storage
|
||||
name: local-path
|
||||
- mountPath: /etc/samba-container
|
||||
- mountPath: /etc/samba
|
||||
name: samba-config
|
||||
volumes:
|
||||
- name: local-path
|
||||
hostPath:
|
||||
path: /usr/local/data
|
||||
type: DirectoryOrCreate
|
||||
- name: samba-config
|
||||
configMap:
|
||||
name: samba-config
|
||||
@@ -2,5 +2,6 @@ apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
namespace: kube-system
|
||||
resources:
|
||||
- configmap.yaml
|
||||
- deployment.yaml
|
||||
- configmap.yaml
|
||||
- deployment.yaml
|
||||
- service.yaml
|
||||
|
||||
14
clusters/kairos/samba-server/service.yaml
Normal file
14
clusters/kairos/samba-server/service.yaml
Normal file
@@ -0,0 +1,14 @@
|
||||
kind: Service
|
||||
apiVersion: v1
|
||||
metadata:
|
||||
name: samba
|
||||
namespace: kube-system
|
||||
labels:
|
||||
app: samba
|
||||
spec:
|
||||
type: LoadBalancer
|
||||
selector:
|
||||
app: samba
|
||||
ports:
|
||||
- port: 445
|
||||
name: samba
|
||||
@@ -72,8 +72,6 @@ spec:
|
||||
serviceAccountName: system-upgrade
|
||||
cordon: false
|
||||
upgrade:
|
||||
# Here goes the image which is tied to the flavor being used.
|
||||
# Currently can pick between opensuse and alpine
|
||||
image: quay.io/kairos/debian:bookworm-standard-amd64-generic-v3.3.0-k3sv1.32.0-k3s1
|
||||
command:
|
||||
- "/bin/bash"
|
||||
|
||||
@@ -111,3 +111,10 @@ You should be able to access `http://traefik.k3s/dashboard#/` (at the time of wr
|
||||
## Grafana
|
||||
|
||||
Grab the admin user password from the `monitoring-grafana` secret
|
||||
|
||||
## Removing a PVC
|
||||
|
||||
After removing a pvc, you may need to force the removal by patching the finalize out
|
||||
|
||||
`kubectl delete pv <pv_name> --grace-period=0 --force`
|
||||
`kubectl patch pv <pv_name> -p '{"metadata": {"finalizers": null}}'`
|
||||
Reference in New Issue
Block a user