I need a simple unix script to mass add users w/ a password

Debian

Hey guys. Looking for help creating a simple shell script that’ll mass add users. I have maybe 10 users i want to add. I have the usernames and plain text password but moving forward and adding a bunch of people over and over is going to be a pain.

Any help?

username : password etc

the way ive been doing it is simply
/useradd username
/passwd password1
password1
password1

etc but takes real long especially doing multiple people on several servers. I’d also rather not get into anything fancy like mysql

Create a file with the following format:

user1:password
user2:password
etc... 
etc...
#!/bin/bash

for i in $(cat file | awk -F: '{print $1}')
do
useradd $i
done
chpasswd file

Where file is the name of the file you created.

Create a file with the following format:

user1:password
user2:password
etc... 
etc...
#!/bin/bash

for i in $(cat file | awk -F: '{print $1}')
do
useradd $i
done
chpasswd file

Where file is the name of the file you created.

I can’t code worth shit but i’m thankful for people like you.