首页 公告 项目 RSS

⬇️⬇️⬇️ 欢迎关注我的 telegram 频道和 twitter ⬇️⬇️⬇️


联系方式: Twitter Github Email Telegram

Setting Up a Mac Backup Server Using netatalk

June 16, 2025 本文有 133 个字 需要花费 1 分钟阅读

Introduction

Compared to traditional SMB solutions, Netatalk, as an open-source implementation of Apple Filing Protocol (AFP), offers the following advantages for Mac devices:

  • Seamless compatibility with Time Machine backups
  • Native-level file-sharing experience
  • Better support for Mac metadata
  • Print service integration

Project Repository

https://github.com/Netatalk/netatalk

Setup

The setup is straightforward—just a single Docker Compose file:

version: '3.8'
services:
  netatalk:
    image: netatalk/netatalk:4.2.4
    container_name: netatalk
    network_mode: host
    cap_add:
      - NET_ADMIN
    volumes:
      - "./share:/mnt/afpshare" # Regular shared directory  
      - "./backup:/mnt/afpbackup" # Time Machine dedicated directory  
      - "/var/run/dbus:/var/run/dbus"
      - "/etc/localtime:/etc/localtime"
    environment:
      - AFP_USER=bboysoul
      - AFP_PASS=xxxxxxxx # Cannot exceed 8 characters  
      - AFP_GROUP=afpusers
      #- ATALKD_INTERFACE=ens192
      - TZ=Asia/Shanghai
    restart: always

Then run:

docker-compose up -d

After that, simply use Command+K in Mac Finder, enter afp://your-server-IP, and input the credentials to access.

Feel free to follow my blog at www.bboy.app

Have Fun