Skip to content

Commit

Permalink
docker install on almalinux
Browse files Browse the repository at this point in the history
  • Loading branch information
usmannasir committed Jan 5, 2024
1 parent 7bd5630 commit 8fed57b
Showing 1 changed file with 22 additions and 8 deletions.
30 changes: 22 additions & 8 deletions plogical/DockerSites.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,20 +47,34 @@ def run(self):
def InstallDocker(self):

if ProcessUtilities.decideDistro() == ProcessUtilities.centos or ProcessUtilities.decideDistro() == ProcessUtilities.cent8:
command = 'sudo curl -L "https://github.com/docker/compose/releases/download/v2.17.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose'
ProcessUtilities.executioner(command)
#command = 'sudo curl -L "https://github.com/docker/compose/releases/download/v2.17.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose'

command = 'dnf config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo'

ReturnCode = ProcessUtilities.executioner(command)

if ReturnCode:
pass
else:
return 0, ReturnCode

command = 'chmod +x /usr/local/bin/docker-compose'
command = 'dnf install docker-ce docker-ce-cli containerd.io docker-compose-plugin -y'
ReturnCode = ProcessUtilities.executioner(command)

if ReturnCode:
return 1, None
else:
return 0, ReturnCode

else:
command = 'apt install docker-compose -y'

ReturnCode = ProcessUtilities.executioner(command)
ReturnCode = ProcessUtilities.executioner(command)

if ReturnCode:
return 1, None
else:
return 0, ReturnCode
if ReturnCode:
return 1, None
else:
return 0, ReturnCode

@staticmethod
def SetupProxy(port):
Expand Down

0 comments on commit 8fed57b

Please sign in to comment.