config: templateConfig default added, simplified, fixed for PHAR