Skip to content

Instantly share code, notes, and snippets.

@rtacconi
Last active February 8, 2017 10:56
Show Gist options
  • Save rtacconi/e0b0bce7d83bc73191137856e03efe06 to your computer and use it in GitHub Desktop.
Save rtacconi/e0b0bce7d83bc73191137856e03efe06 to your computer and use it in GitHub Desktop.
REPORT=/tmp/ssh_acl.txt
for user in $(knife data bag show users)
do
knife data bag show users $user | grep -v ssh_keys | grep -v ssh-rsa | grep -v htpasswd | grep -v shell >> $REPORT
echo "---------------------" >> $REPORT
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment