def from_map(map_key): 'use resolved map as image' image_id = subprocess.check_output(['plash-map', map_key]).decode().strip('\n') if not image_id: raise MapDoesNotExist('map {} not found'.format(repr(map_key))) return hint('image', image_id)
def wrapper(*args): cache_key = cache_key_templ.format(':'.join(args)).replace( '/', '%') container_id = utils.plash_map(cache_key) if not container_id: container_id = func(*args) utils.plash_map(cache_key, container_id) return hint('image', container_id)
def wrapper(*args): cache_key = cache_key_templ.format(":".join(args)).replace( "/", "%") container_id = utils.plash_call("map", cache_key) if not container_id: container_id = func(*args) utils.plash_call("map", cache_key, container_id) return hint("image", container_id)
def from_map(map_key): 'use resolved map as image' image_id = utils.plash_call('map', map_key) if not image_id: raise MapDoesNotExist('map {} not found'.format(repr(map_key))) return hint('image', image_id)
def from_id(image): 'specify the image from an image id' return hint('image', image)
def entrypoint(exec_path): "hint default command for this build" return hint("exec", exec_path)
def entrypoint(exec_path): 'hint default command for this build' return hint('exec', exec_path)
def from_map(map_key): "use resolved map as image" image_id = utils.plash_call("map", map_key) if not image_id: raise MapDoesNotExist("map {} not found".format(repr(map_key))) return hint("image", image_id)
def from_id(image): "specify the image from an image id" return hint("image", image)