Variablize and output to output directory

Add variables to the template for common things.

Also output artifacts to an "output/" directory.