diff --git a/setup.py b/setup.py index 841e4f1f..6e03b3d9 100644 --- a/setup.py +++ b/setup.py @@ -6,7 +6,7 @@ import glob PACKAGE_NAME = "stimela" -__version__ = "1.7.9" +__version__ = "1.7.11" build_root = os.path.dirname(__file__) diff --git a/stimela/singularity.py b/stimela/singularity.py index d8ef0714..f90b636d 100644 --- a/stimela/singularity.py +++ b/stimela/singularity.py @@ -44,10 +44,9 @@ def pull(image, name, docker=True, directory=".", force=False): if os.path.exists(image_path) and not force: stimela.logger().info(f"Singularity image already exists at '{image_path}'. To replace it, please re-run with the 'force' option") else: - utils.xrun(f"cd {directory} && {BINARY}", ["pull", - "--force" if force else "", "--name", - name, fp]) - + utils.xrun(f"cd {directory} && {BINARY}", ["pull", + "--force" if force else "", "--name", + name, fp]) return 0 class Container(object): @@ -122,10 +121,9 @@ def run(self, *args, output_wrangler=None): raise SystemExit from None self.status = "running" - extras = "--userns" if BINARY_NAME == "singularity" else "--writable-tmpfs" self._print("Starting container [{0:s}]. Timeout set to {1:d}. The container ID is printed below.".format( self.name, self.time_out)) - utils.xrun(f"{BINARY} run --workdir {self.execdir} --containall {extras}", + utils.xrun(f"{BINARY} run --workdir {self.execdir} --contain", list(args) + [volumes, self.image, self.RUNSCRIPT], log=self.logger, timeout=self.time_out, output_wrangler=output_wrangler, env=self._env, logfile=self.logfile)