diff --git a/packer.py b/packer.py index b49d109..cc17dc2 100644 --- a/packer.py +++ b/packer.py @@ -38,15 +38,16 @@ def __init__(self, template, exc=None, only=None, vars=None, self.packer = sh.Command(exec_path) self.packer = self.packer.bake(**kwargs) - def init(self, upgrade=False): + def init(self, config_file, upgrade=False): """Executes a `packer init` + :param str config_file: Path to the configuration file :param bool upgrade: Updates plugins to the latest version """ self.packer_cmd = self.packer.init self._add_opt('-upgrade' if upgrade else None) - self._add_opt(self.template) + self._add_opt(config_file) return self.packer_cmd() diff --git a/setup.py b/setup.py index 15405b4..10e29ea 100644 --- a/setup.py +++ b/setup.py @@ -13,7 +13,7 @@ def read(*parts): setup( name='python-packer', - version='1.0.2', + version='1.0.3', url='https://github.com/abhi1693/python-packer', author='abhi1693', author_email='desk.abhimanyu@gmail.com',