Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Build netatalk 3.1.10 on Ubuntu 16.04
#!/bin/bash
# Get system to updated state and install required packages
sudo apt update
sudo apt full-upgrade
sudo apt install clang make libdb-dev libgcrypt20-dev libavahi-client-dev libpam0g-dev
# Build and install
./configure --with-init-style=systemd --disable-static
make -j $(grep -c ^processor /proc/cpuinfo)
sudo make install-strip
# Add network users with home dirs, but without shell access
sudo adduser --home /mnt/storage/.shares/username1 --shell /bin/false username1
sudo adduser --home /mnt/storage/.shares/username2 --shell /bin/false username2
# Create separate dir for Time Machines
mkdir /mnt/storage/.backups
sudo chmod a+w /mnt/storage/.backups
# Add to /usr/local/etc/afp.conf
# [Homes]
# home name = "My files"
# basedir regex = /mnt/storage/.shares
#
# [Time Machine]
# valid users = username1 username2
# path = /path/to/storage/.backups
# time machine = yes
# Enable and start
sudo systemctl enable netatalk
sudo systemctl start netatalk
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment