Comments (5)
I, thanks for using my container and writing this bug record.
Really strange, could you please provide your docker-compose.yml
(make sure to delete passwords and personal data)?
If you look on how this is written, it will only add the whole service if no 'dk' is found. after that, every other timemachine, will be integrated inside this service
-tag using a sed
replacement.
I don't really understand why the </service-group>
was missing in the first place...
ohh okay I found it - https://github.com/ServerContainers/samba/blob/master/scripts/entrypoint.sh#L85 deletes </service-group>
. so this should only be run the first time a timemachine volume is recognized. I'll create a fix and push it asap.
Thanks for reporting this bug! 👍 Have fun with the container!
P.S. I found your project as one of the easiest to adapt as a TimeMachine Samba container.
thanks, but didn't it work out of the box - did you need other improvements for it to work?
from samba.
fixed
from samba.
Here is the docker-compose.yml
.
I have a few MacBooks I was upgrading/moving and wanted to try this Dockerfile as a way of giving each their own set of user/pass and isolated shares.
I am using macvlan
as I wanted to test it out alongside the Samba/Avahi already running on the Docker host, and having the container act as a new network device seems to work. I haven't tested ipv6 as I haven't set it up on my home network yet, maybe one day.
The shares are on a ZFS pool, each share being it's own ZFS filesystem with its own quota set. This quota is then seen by the container as the amount of space available and is passed along to Time Machine clients.
I don't know if the vfs objects = fruit streams_xattr;
on each volume config is necessary, I added that while I was trying to get it working before I noticed the Avahi config bug. I copied that stanza from the Time Machine Samba setup I have on the Docker host for my older Mac computer.
# Tested with Docker Engine 19.03.14
# Version 2 is used, as I found it easier to understand the documentation without the Docker Swarm options in Version 3
version: '2.4'
services:
samba:
image: servercontainers/samba
networks:
smb_macvlan:
ipv4_address: 10.0.1.55
restart: unless-stopped
environment:
AVAHI_NAME: 'My TimeCapsule'
MODEL: 'TimeCapsule'
ACCOUNT_device_A: "deviceAPass"
ACCOUNT_device_B: "deviceBPass"
ACCOUNT_device_C: "deviceCPass"
SAMBA_VOLUME_CONFIG_device_A: "[TimeCapsule Device A]; path=/shares/device_a; valid users = device_A; guest ok = no; read only = no; browseable = no; fruit:time machine = yes; vfs objects = fruit streams_xattr;"
SAMBA_VOLUME_CONFIG_device_B: "[TimeCapsule Device B]; path=/shares/device_b; valid users = device_B; guest ok = no; read only = no; browseable = no; fruit:time machine = yes; vfs objects = fruit streams_xattr;"
SAMBA_VOLUME_CONFIG_device_C: "[TimeCapsule Device C]; path=/shares/device_c; valid users = device_C; guest ok = no; read only = no; browseable = no; fruit:time machine = yes; vfs objects = fruit streams_xattr;"
volumes:
- "/myzpool/backup/device_a:/shares/device_a"
- "/myzpool/backup/device_b:/shares/device_b"
- "/myzpool/backup/device_c:/shares/device_c"
networks:
smb_macvlan:
driver: macvlan
enable_ipv6: false
driver_opts:
parent: br0
ipam:
driver: default
config:
- gateway: 10.0.1.1
subnet: 10.0.1.0/24
Hope this helps anyone trying the same. 👍
from samba.
I thinks for the explanation, I also saw a very interesting setup you might be interessted in: https://github.com/sp00ls/SambaConfigs
He is using one timemachine share which points to a user specific one (I was thinking about implementing this feature into this container somehow... but I'm not sure how to do it in a proper way that people understand how to use it)
regarding your samba configs, you can just remove the vfs objects = fruit streams_xattr;
-part since my entrypoint
script adds this as soon as it recognizes a time machine = yes
in your config - so you don't need to worry about other settings than this one.
thanks for you config :), and also nice to see, that multiple timemachine volumes are possible on one server (I implemented it that way, but never tested it, since I only need one TS volume) and kind regards
from samba.
Just a small info - I just finised the multi user mode. you can now add a single timemachine path like ...; path = /shares/timemachine/%U; ...
and samba will create subfolders for each user and present the individual folder to each user 😁
maybe this can help to cleanup your samba config
from samba.
Related Issues (20)
- Remove network_mode: host from docker-compose.yml HOT 1
- Image builds broken HOT 3
- /etc/avahi/services/samba.service HOT 1
- users group always with the id 100 whatever HOT 2
- adduser not possible if gid = uid HOT 1
- Error loading shared library HOT 3
- No access to shared folder HOT 5
- Read-only shared folders HOT 2
- Question: Which version of Samba (v1/v2/v3/v4) is being used, and can it be changed for best performance? HOT 5
- force user = %U with timemachine HOT 5
- Why does turning on time machine modify my read and write permissions HOT 4
- Samba Server not visible HOT 5
- `disable netbios = yes` disregards `$NETBIOS_DISABLE` HOT 1
- Multiline not working HOT 3
- Cannot use UID and GID of a host user HOT 1
- differnce to dperson/samba HOT 1
- How to set the Time Machine share max size differently for different users HOT 6
- Why I can't create file? HOT 2
- Add configuration to change AVAHI service host name HOT 10
- Not Able to Delete Files HOT 14
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from samba.