Add custom build script support

Add extra configurations when starting daemon
Propagate token to docker in case credentials are not available
This commit is contained in:
allegroai
2022-03-15 10:04:25 +02:00
parent 2cd9e706c8
commit 531e514003
13 changed files with 504 additions and 178 deletions

View File

@@ -12,7 +12,7 @@ from ..requirements import RequirementsManager
class VirtualenvPip(SystemPip, PackageManager):
def __init__(self, session, python, requirements_manager, path, interpreter=None, execution_info=None, **kwargs):
# type: (Session, float, RequirementsManager, PathLike, PathLike, ExecutionInfo, Any) -> ()
# type: (Session, str, RequirementsManager, PathLike, PathLike, ExecutionInfo, Any) -> ()
"""
Program interface to virtualenv pip.
Must be given either path to virtualenv or source command.
@@ -48,7 +48,7 @@ class VirtualenvPip(SystemPip, PackageManager):
return Argv.conditional_flag(
self.session.config["agent.package_manager.system_site_packages"],
"--system-site-packages",
) + ("--python", self._bin)
)
def install_flags(self):
"""
@@ -64,10 +64,6 @@ class VirtualenvPip(SystemPip, PackageManager):
Only valid if instantiated with path.
Use self.python as self.bin does not exist.
"""
# Log virtualenv information to stdout
self.session.command(
self.python, "-m", "virtualenv", "--version"
)
self.session.command(
self.python, "-m", "virtualenv", self.path, *self.create_flags()
).check_call()