发布1.0.3版本

This commit is contained in:
ilovintit
2025-06-15 20:40:36 +08:00
parent db242ffe66
commit b03c3383d5
3 changed files with 16 additions and 2 deletions
+8
View File
@@ -3,6 +3,7 @@ import * as k8s from '@kubernetes/client-node'
import * as fs from 'fs'
import * as path from 'path'
import { filter, clone } from 'lodash'
import { Agent } from 'https'
interface Config {
branch: string
@@ -11,6 +12,10 @@ interface Config {
deployment: string
}
const insecureAgent = new Agent({
rejectUnauthorized: false
})
/**
* The main function for the action.
*
@@ -45,6 +50,9 @@ export async function run(): Promise<void> {
kc.loadFromFile(
path.join(workspace, clusterPath + deployConfig.cluster + '.yaml')
)
await kc.applyToHTTPSOptions({
httpsAgent: insecureAgent
})
const k8sApi = kc.makeApiClient(k8s.AppsV1Api)
const nowDeployment = await k8sApi.readNamespacedDeployment({
name: deployConfig.deployment,