Created
July 7, 2014 07:16
-
-
Save seak0503/2c6388edf78b00c30cc0 to your computer and use it in GitHub Desktop.
ユーザの作成とパスワード設定を行うシェルスクリプト
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# root権限と同じ権限を持つユーザの作成 | |
/usr/sbin/useradd -u 0 -o -g 0 new_superuser | |
echo "new_superuser:newpassword1" | /usr/sbin/chpasswd | |
# 一般ユーザの作成 | |
/usr/sbin/groupadd -g 50000 newuser | |
/usr/sbin/useradd -u 50000 -g 50000 newuser | |
echo "newuser:newpassword2" | /usr/sbin/chpasswd |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment