#!/usr/bin/env bash

username=$1
home_dir={{component.home}}/$username

mkdir -p $home_dir
ftpasswd --passwd \
    --file={{component.passwd_file.path}} \
    --name=$username \
    --uid={{component.service_user_uid}} \
    --home=$home_dir \
    --shell=/bin/false
