Adapt order dependency impl to python types impl
This commit is contained in:
parent
b7af305636
commit
595cfec572
3 changed files with 7 additions and 8 deletions
|
@ -47,6 +47,9 @@ REMOTE_COPY = "scp -o User=root -q"
|
|||
REMOTE_EXEC = "ssh -o User=root"
|
||||
REMOTE_CMDS_CLEANUP_PATTERN = "ssh -o User=root -O exit -S {}"
|
||||
|
||||
ORDER_DEP_STATE_NAME = 'order_dep_state'
|
||||
TYPEORDER_DEP_NAME = 'typeorder_dep'
|
||||
|
||||
|
||||
class Error(Exception):
|
||||
"""Base exception class for this project"""
|
||||
|
|
|
@ -100,9 +100,6 @@ class Manifest(object):
|
|||
|
||||
"""
|
||||
|
||||
ORDER_DEP_STATE_NAME = 'order_dep_state'
|
||||
TYPEORDER_DEP_NAME = 'typeorder_dep'
|
||||
|
||||
def __init__(self, target_host, local, dry_run=False):
|
||||
self.target_host = target_host
|
||||
self.local = local
|
||||
|
@ -227,8 +224,8 @@ class Manifest(object):
|
|||
os.remove(os.path.join(self.local.base_path, fname))
|
||||
except FileNotFoundError:
|
||||
pass
|
||||
_rm_file(Manifest.ORDER_DEP_STATE_NAME)
|
||||
_rm_file(Manifest.TYPEORDER_DEP_NAME)
|
||||
_rm_file(cdist.ORDER_DEP_STATE_NAME)
|
||||
_rm_file(cdist.TYPEORDER_DEP_NAME)
|
||||
|
||||
def env_py_type_manifest(self, cdist_object):
|
||||
env = os.environ.copy()
|
||||
|
|
|
@ -29,7 +29,6 @@ import sys
|
|||
import cdist
|
||||
from cdist import core
|
||||
from cdist import flock
|
||||
from cdist.core.manifest import Manifest
|
||||
import cdist.util.python_type_util as pytype_util
|
||||
from cdist.core.pytypes import get_pytype_class
|
||||
import inspect
|
||||
|
@ -87,9 +86,9 @@ class Emulator(object):
|
|||
self.typeorder_path = os.path.join(self.global_path, "typeorder")
|
||||
|
||||
self.typeorder_dep_path = os.path.join(self.global_path,
|
||||
Manifest.TYPEORDER_DEP_NAME)
|
||||
cdist.TYPEORDER_DEP_NAME)
|
||||
self.order_dep_state_path = os.path.join(self.global_path,
|
||||
Manifest.ORDER_DEP_STATE_NAME)
|
||||
cdist.ORDER_DEP_STATE_NAME)
|
||||
|
||||
self.type_name = os.path.basename(argv[0])
|
||||
self.cdist_type = core.CdistType(self.type_base_path, self.type_name)
|
||||
|
|
Loading…
Reference in a new issue