Is there a way to pass the desired MYSQL password to the prompts in the
apt-get install lamp-server^ package in a single command line?
Note: I tried finding the package repository to read up on it, but I can't find it.
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It only takes a minute to sign up.Sign up to join this community
You can preset the password:
sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password password your_password' sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password_again password your_password' sudo apt-get -y install lamp-server^
This is adapted from a SO Question which has a few variants on this idea.