I'd like to install a LAMP stack on my laptop in order to be able to locally develop PHP websites. However, since my computer is a laptop, and since I don't always need having apache and MySQL server running, I'd like to setup a simple way to start and stop the LAMP stack when I need it. What method do you suggest to achieve that?
- Disable apache and mysql daemons and start / stop them when needed?
- Install LAMP stack on a virtual machine and share the network with the host to access the developed websites?
- Other suggestions?