diff options
Diffstat (limited to 'aria2d.install')
-rw-r--r-- | aria2d.install | 30 |
1 files changed, 13 insertions, 17 deletions
diff --git a/aria2d.install b/aria2d.install index 9ecda7a9008d..3dc3441a2f5b 100644 --- a/aria2d.install +++ b/aria2d.install @@ -1,24 +1,20 @@ -post_install() { - echo -n "Adding aria2 user and group ..." - useradd aria2 -r -U -d /var/share/aria2/ -s /bin/nologin && echo " done." - passwd -l aria2 &>/dev/null - - install -d /var/share/aria2/ - touch /var/share/aria2/aria2.log +post_install(){ + useradd aria2 -r -U -d /var/share/aria2/ -s /bin/nologin + passwd -l aria2 &> /dev/null + install -d -o aria2 -g aria2 "${pkgdir}/var/share/aria2/" touch /var/share/aria2/aria2.session - chmod 600 /etc/conf.d/aria2.conf - chown aria2:aria2 /etc/conf.d/aria2.conf - chown -R aria2:aria2 /var/share/aria2/ +cat << EOF + +Now the aria2d is installed, you may want to ... + 1. check the config file for aria2 at /etc/conf.d/aria2.conf + 2. get the downloaded files at /var/share/aria2/ + +EOF - echo "Now the aria2d is installed, you may want to ..." - echo " 1. check the config file for aria2 at /etc/conf.d/aria2.conf" - echo " 2. get the downloaded files at /var/share/aria2/" } post_remove() { - echo -n -e "\nRemoving aria2 user/group..." - userdel aria2 && echo " done." - echo "Now the aria2d was removed from your system," - echo "you may need to check the directory /var/share/aria2/ by manual." + userdel aria2 + echo -n -e "Now the aria2d was removed from your system,\n you may need to check the directory /var/share/aria2/ by manual." } |