

def ensure_conf(self, template, varnish_conf_path='/etc/default/varnish', options={
    
}, owner=None):
    "\n        Ensures that Varnish's configuration file at the specified path is up-to-date.\n\n        :param template: The name of the VCL template file.\n        :type template: :class:`str`\n        :param varnish_conf_path: The path that the configuration file will be in the remote server. Defaults to `/etc/default/varnish`.\n        :type varnish_conf_path: :class:`str`\n        :param options: Dictionary of options to pass to the configuration template file. Extends context.\n        :type options: :class:`dict`\n        :param owner: Owner of the configuration file at the remote server. Defaults to :data:`None`.\n        :type owner: :class:`str`\n\n        Example:\n        ::\n\n            from provy.core import Role\n            from provy.more.debian import VarnishRole\n\n            class MySampleRole(Role):\n                def provision(self):\n                    with self.using(VarnishRole) as role:\n                        role.ensure_conf('default_varnish', owner='user')\n        "
    result = self.update_file(template, varnish_conf_path, options=options, sudo=True, owner=owner)
    if result:
        self.log('varnish conf updated!')
        self.ensure_restart()

dataset/ETHPy150Open python-provy/provy/provy/more/debian/cache/varnish.py VarnishRole.ensure_conf/original