(cluster_name, type, namespace, name)
| 95 | } |
| 96 | |
| 97 | export function forceDeleteWorkLoad (cluster_name, type, namespace, name) { |
| 98 | switch (type) { |
| 99 | case "deployments": |
| 100 | case "statefulsets": |
| 101 | case "daemonsets": |
| 102 | return delWithData( |
| 103 | `${appsV1UrlWithNsUrl(cluster_name, type, namespace)}/${name}`,{ |
| 104 | gracePeriodSeconds: 0 |
| 105 | } |
| 106 | ) |
| 107 | case "cronjobs": |
| 108 | return delWithData( |
| 109 | `${batchV1WithNsUrl(cluster_name, type, namespace)}/${name}`,{ |
| 110 | gracePeriodSeconds: 0 |
| 111 | } |
| 112 | ) |
| 113 | case "pods": |
| 114 | return delWithData(`${apiV1UrlWithNsUrl(cluster_name, type, namespace)}/${name}`,{ |
| 115 | gracePeriodSeconds: 0 |
| 116 | }) |
| 117 | case "jobs": |
| 118 | return delWithData(`${batchV1WithNsUrl(cluster_name, type, namespace)}/${name}`,{ |
| 119 | gracePeriodSeconds: 0 |
| 120 | }) |
| 121 | } |
| 122 | } |
| 123 | |
| 124 | export function createWorkLoad (cluster_name, type, namespace, data) { |
| 125 | switch (type) { |
nothing calls this directly
no test coverage detected