mirror of
https://github.com/Azure/k8s-deploy.git
synced 2026-04-08 06:12:15 +08:00
Sending a warning instead of throwing error when KUBECONFIG is missing. (#145)
This commit is contained in:
parent
bba73cd11a
commit
2f25f49dce
@ -53,7 +53,7 @@ function installKubectl(version) {
|
||||
}
|
||||
function checkClusterContext() {
|
||||
if (!process.env["KUBECONFIG"]) {
|
||||
throw new Error('Cluster context not set. Use k8ssetcontext action to set cluster context');
|
||||
core.warning('KUBECONFIG env is not explicitly set. Ensure cluster context is set by using k8s-set-context / aks-set-context action.');
|
||||
}
|
||||
}
|
||||
function run() {
|
||||
|
||||
@ -42,7 +42,7 @@ async function installKubectl(version: string) {
|
||||
|
||||
function checkClusterContext() {
|
||||
if (!process.env["KUBECONFIG"]) {
|
||||
throw new Error('Cluster context not set. Use k8ssetcontext action to set cluster context');
|
||||
core.warning('KUBECONFIG env is not explicitly set. Ensure cluster context is set by using k8s-set-context / aks-set-context action.');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user