mirror of
https://github.com/yavook/kiwi-scp.git
synced 2024-11-22 04:43:00 +00:00
subcommand "push"
This commit is contained in:
parent
81b597cb58
commit
9617597257
4 changed files with 23 additions and 2 deletions
|
@ -7,6 +7,7 @@ from .init import InitCommand
|
||||||
from .logs import LogsCommand
|
from .logs import LogsCommand
|
||||||
from .net import NetUpCommand, NetDownCommand
|
from .net import NetUpCommand, NetDownCommand
|
||||||
from .pull import PullCommand
|
from .pull import PullCommand
|
||||||
|
from .push import PushCommand
|
||||||
from .sh import ShCommand
|
from .sh import ShCommand
|
||||||
from .show import ShowCommand
|
from .show import ShowCommand
|
||||||
from .up import UpCommand
|
from .up import UpCommand
|
||||||
|
@ -23,6 +24,7 @@ __all__ = [
|
||||||
'NetUpCommand',
|
'NetUpCommand',
|
||||||
'NetDownCommand',
|
'NetDownCommand',
|
||||||
'PullCommand',
|
'PullCommand',
|
||||||
|
'PushCommand',
|
||||||
'ShCommand',
|
'ShCommand',
|
||||||
'ShowCommand',
|
'ShowCommand',
|
||||||
'UpCommand',
|
'UpCommand',
|
||||||
|
|
|
@ -8,7 +8,7 @@ class BuildCommand(FlexCommand):
|
||||||
|
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
super().__init__(
|
super().__init__(
|
||||||
'build', "Building images",
|
'build', "Building images for",
|
||||||
description="Build images for the whole instance, a project or service(s) inside a project"
|
description="Build images for the whole instance, a project or service(s) inside a project"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ class PullCommand(FlexCommand):
|
||||||
|
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
super().__init__(
|
super().__init__(
|
||||||
'pull', "Pulling images",
|
'pull', "Pulling images for",
|
||||||
description="Pull images for the whole instance, a project or service(s) inside a project"
|
description="Pull images for the whole instance, a project or service(s) inside a project"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
19
src/kiwi/subcommands/push.py
Normal file
19
src/kiwi/subcommands/push.py
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
# local
|
||||||
|
from ._subcommand import FlexCommand
|
||||||
|
from .utils.dockercommand import DockerCommand
|
||||||
|
|
||||||
|
|
||||||
|
class PushCommand(FlexCommand):
|
||||||
|
"""kiwi push"""
|
||||||
|
|
||||||
|
def __init__(self):
|
||||||
|
super().__init__(
|
||||||
|
'push', "Pushing images for",
|
||||||
|
description="Push images for the whole instance, a project or service(s) inside a project"
|
||||||
|
)
|
||||||
|
|
||||||
|
def _run_services(self, runner, config, args, services):
|
||||||
|
DockerCommand('docker-compose').run(
|
||||||
|
config, args, ['push', *services]
|
||||||
|
)
|
||||||
|
return True
|
Loading…
Reference in a new issue