From: | "Bo Ørsted Andresen" <bo.andresen@××××.dk> | ||
---|---|---|---|
To: | gentoo-user@l.g.o | ||
Subject: | Re: [gentoo-user] Problem: unprivileged user cannot use /usr/bin/crontab | ||
Date: | Wed, 21 Jun 2006 14:53:21 | ||
Message-Id: | 200606211642.49257.bo.andresen@zlin.dk | ||
In Reply to: | Re: [gentoo-user] Problem: unprivileged user cannot use /usr/bin/crontab by Neil Bothwick |
1 | On Wednesday 21 June 2006 16:20, Neil Bothwick wrote: |
2 | > egrep ^.*?:.*?:.*?:100: /etc/passwd | cut -d: -f1 | while read u do gpasswd |
3 | > -a $u cron; done |
4 | > |
5 | > will add all users from group GID 100 (users on this system) to the cron |
6 | > group. |
7 | |
8 | Well... |
9 | |
10 | awk -F: "\$4~/^\ |
11 | `awk -F: '$1~/^users$/{print $3}' < /etc/group`\ |
12 | \$/{print \$1}" < /etc/passwd | \ |
13 | while read user; do |
14 | gpasswd -a "$user" cron |
15 | done |
16 | |
17 | ;) |
18 | |
19 | -- |
20 | Bo Andresen |