Add labels
This commit is contained in:
parent
f37264d7cf
commit
bb0fe1ee9f
|
@ -8,7 +8,8 @@ def deploy_go(name, src, image, sync_folders = []):
|
||||||
"{name}-compile".format(name=name),
|
"{name}-compile".format(name=name),
|
||||||
compile_cmd,
|
compile_cmd,
|
||||||
ignore="build/".format(src=src),
|
ignore="build/".format(src=src),
|
||||||
deps=[src])
|
deps=[src],
|
||||||
|
labels=[name])
|
||||||
|
|
||||||
i = 0
|
i = 0
|
||||||
resource_deps=["{name}-compile".format(name=name)]
|
resource_deps=["{name}-compile".format(name=name)]
|
||||||
|
@ -17,7 +18,8 @@ def deploy_go(name, src, image, sync_folders = []):
|
||||||
local_resource(
|
local_resource(
|
||||||
new_resource_dep,
|
new_resource_dep,
|
||||||
"mkdir -p build/{name}/{targetPath} && rsync -av {localPath}/ build/{name}/{targetPath}/".format(localPath=f[0], targetPath=f[1], name=name),
|
"mkdir -p build/{name}/{targetPath} && rsync -av {localPath}/ build/{name}/{targetPath}/".format(localPath=f[0], targetPath=f[1], name=name),
|
||||||
deps=[f[0]]
|
deps=[f[0]],
|
||||||
|
labels=[name]
|
||||||
)
|
)
|
||||||
resource_deps.append(new_resource_dep)
|
resource_deps.append(new_resource_dep)
|
||||||
i = i+1
|
i = i+1
|
||||||
|
@ -34,7 +36,7 @@ ENTRYPOINT /server""".format(name = name)
|
||||||
entrypoint=['/server'],
|
entrypoint=['/server'],
|
||||||
dockerfile_contents=dockerfile_contents,
|
dockerfile_contents=dockerfile_contents,
|
||||||
only=["build/{name}/".format(name = name)],
|
only=["build/{name}/".format(name = name)],
|
||||||
live_update=[sync("build/{name}".format(name=name), '/')],
|
live_update=[sync("build/{name}".format(name=name), '/')]
|
||||||
)
|
)
|
||||||
|
|
||||||
k8s_resource(name, resource_deps=resource_deps)
|
k8s_resource(name, resource_deps=resource_deps, labels=[name])
|
||||||
|
|
Loading…
Reference in New Issue