What are some optimized LAMP or LEMP stack scripts with email?

There are installer scripts that exist for web applications and supporting services, but most of them to my knowledge are focused on the web hosting world. For example Scriptaculous and Fantastico, to name just two.

There are also pre-baked virtual appliances made by places like JumpBox, BitNami, CloudZoom, and Turnkey Linux. Those can be variously deployed to cloud providers and be up and running in mere minutes.

Perhaps you could start with some of those projects and move forward, developing something more to your own tastes.

...but, wait...

If after reading all of the above you're left thinking "But wait, that's not exactly what I want" that's because what you want doesn't exactly exist yet. It appears that you want something that's more specific than a generic install script (Fantastico, etc.) but not quite as heavy a a drop-in virtual appliance.

I'm sure that something closer to what you want exists. For myself, there was a time when I was working on Wordpress installations a lot and had a fancy idea to create a spectacular installation script that went an extra mile or five to lock down permissions, edit directory structures and generally clean up after the installation to make things smarter, tidier and much more secure for the Linux OS, the MySQL database server, Apache and any caching / proxies involved.

I'm sure I'm not the only one that had an idea like that, so there was likely someone who had a custom Wordpress install script that I could have used or at least learned from and mutated to my own desires. I could have turned it into quite the github project, I think.

What I'm saying is that you'll really need to get down to the grass roots level of some kind of LAMP community that focuses on the needs of those who rapidly deploy multiple servers in the use-cases that you focus on. More than likely you'll be laying down a lot of your own pipe. You'll probably want to get some core group of contributors to help you. Make it a full on FOSS project.

Then you'll be known as That Amazing FOSS Guy and you'll never lack for roses at your feet! Or, something like that...