Skip to content

Commit 58721b9

Browse files
committed
docker install function
1 parent 3f0d1e3 commit 58721b9

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

plogical/DockerSites.py

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
import sys
55
import time
66

7+
8+
79
sys.path.append('/usr/local/CyberCP')
810
import django
911

@@ -12,6 +14,7 @@
1214
from plogical.acl import ACLManager
1315
except:
1416
pass
17+
from dockerManager.dockerInstall import DockerInstall
1518
from plogical.processUtilities import ProcessUtilities
1619
from plogical.CyberCPLogFileWriter import CyberCPLogFileWriter as logging
1720
import argparse
@@ -174,10 +177,7 @@ def DeployWPContainer(self):
174177
result = ProcessUtilities.outputExecutioner(command)
175178
print(f'return code of docker install {result}')
176179
if result.find("not found") > -1:
177-
status, message = self.InstallDocker()
178-
if status == 0:
179-
logging.statusWriter(self.JobID, 'Failed to installed docker. [404]')
180-
return 0, message
180+
DockerInstall.submitInstallDocker()
181181

182182
logging.statusWriter(self.JobID, 'Docker is ready to use..,10')
183183

@@ -662,10 +662,7 @@ def DeployN8NContainer(self):
662662
result = ProcessUtilities.outputExecutioner(command)
663663
print(f'return code of docker install {result}')
664664
if result.find("not found") > -1:
665-
status, message = self.InstallDocker()
666-
if status == 0:
667-
logging.statusWriter(self.JobID, 'Failed to installed docker. [404]')
668-
return 0, message
665+
DockerInstall.submitInstallDocker()
669666

670667
logging.statusWriter(self.JobID, 'Docker is ready to use..,10')
671668

0 commit comments

Comments
 (0)