Created
April 21, 2020 11:25
-
-
Save cesarvr/0f06317b5ae906b8b66ae43b7a40a1f0 to your computer and use it in GitHub Desktop.
Tagging images on Openshift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
oc create dc $1 --image=$(oc get is $1 -o=jsonpath='{.status.dockerImageRepository}'):prod || true && | |
oc expose dc $1 --port=8080 -l app=$1 || true && | |
oc expose svc $1 -l app=$1 || true && | |
oc label dc $1 app=$1 production=true --overwrite=true || true | |
oc label svc $1 app=$1 production=true --overwrite=true || true | |
oc label route $1 app=$1 production=true --overwrite=true || true | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment