Respect docker setting on repo sync
@@ -250,7 +250,11 @@ class SyncRepositoryTaskStep(SyncRepositoryMixin):
self.version = self.get_version(version_pk)
self.project = self.version.project
- environment = LocalBuildEnvironment(
+ if settings.DOCKER_ENABLE:
+ env_cls = DockerBuildEnvironment
+ else:
+ env_cls = LocalBuildEnvironment
+ environment = env_cls(
project=self.project,
version=self.version,
record=False,
