Resetting litespeed with single command

#1
Hi,

I tried to search one and single command that will change the password for the litespeed web panel.

I am aware that /usr/local/lsws/admin/misc/admpass.sh can be used, but this need to prese ENTER , key in the password and retype the password.

Is there any way to generate password with single command for example : /usr/local/lsws/admin/misc/admpass.sh --username=admin --password=mypassword11$ ?

This is for the cloudinit purposes and testing.

Please help.

Thanks
 

Pong

Administrator
Staff member
#2
Code:
TEMP=`/usr/local/lsws/admin/fcgi-bin/admin_php5 /usr/local/lsws/admin/misc/htpasswd.php yourpassword` && echo "yourusername:$TEMP" >> /usr/local/lsws/admin/conf/htpasswd
 
Top