existing function to write the dockerfile using .format, enhance it with jinja2 templates #hacktoberfest