install smb for win11 iso mount on pxe
This commit is contained in:
54
roles/samba/files/etc/samba/smb.conf
Normal file
54
roles/samba/files/etc/samba/smb.conf
Normal file
@@ -0,0 +1,54 @@
|
||||
## NAS Samba Configuration
|
||||
|
||||
[global]
|
||||
workgroup = SBX
|
||||
server string = pve
|
||||
security = user
|
||||
guest ok = yes
|
||||
map to guest = Bad Password
|
||||
|
||||
# Disable netbios/wins support
|
||||
disable netbios = no
|
||||
dns proxy = no
|
||||
|
||||
log file = /var/log/samba/%m.log
|
||||
max log size = 50
|
||||
printcap name = /dev/null
|
||||
load printers = no
|
||||
|
||||
# Samba Shares
|
||||
[Windows]
|
||||
path = /mnt/Windows
|
||||
public = yes
|
||||
browseable = yes
|
||||
read only = no
|
||||
guest ok = yes
|
||||
|
||||
# Samba Shares
|
||||
#[frigate]
|
||||
# path = /mnt/ssd/frigate
|
||||
# browseable = yes
|
||||
# read only = no
|
||||
# guest ok = no
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
10
roles/samba/handlers/main.yml
Normal file
10
roles/samba/handlers/main.yml
Normal file
@@ -0,0 +1,10 @@
|
||||
---
|
||||
- name: start samba service
|
||||
service:
|
||||
name: smbd
|
||||
state: started
|
||||
|
||||
- name: restart samba service
|
||||
service:
|
||||
name: smbd
|
||||
state: restarted
|
||||
25
roles/samba/tasks/main.yml
Normal file
25
roles/samba/tasks/main.yml
Normal file
@@ -0,0 +1,25 @@
|
||||
---
|
||||
- name: install samba
|
||||
apt:
|
||||
pkg: samba
|
||||
state: present
|
||||
notify: start samba service
|
||||
|
||||
- name: install samba config
|
||||
copy:
|
||||
src: etc/samba/smb.conf
|
||||
dest: /etc/samba/smb.conf
|
||||
owner: root
|
||||
group: root
|
||||
notify:
|
||||
- restart samba service
|
||||
|
||||
### nfs
|
||||
#- name: Ensure nfs root exists
|
||||
# ansible.builtin.file:
|
||||
# path: "{{ item }}"
|
||||
# owner: root
|
||||
# group: root
|
||||
# state: directory
|
||||
# loop:
|
||||
# - "{{ nfs_root_path }}"
|
||||
Reference in New Issue
Block a user