add server-side option for kubectl apply commands (#424)

This commit is contained in:
benjamin
2025-07-03 11:15:06 -04:00
committed by GitHub
parent b9529f8427
commit cc1e193d23
8 changed files with 88 additions and 8 deletions
+9 -2
View File
@@ -84,16 +84,23 @@ export async function deployManifests(
)
const forceDeployment = core.getInput('force').toLowerCase() === 'true'
const serverSideApply =
core.getInput('server-side').toLowerCase() === 'true'
if (trafficSplitMethod === TrafficSplitMethod.SMI) {
const updatedManifests = appendStableVersionLabelToResource(files)
const result = await kubectl.apply(
updatedManifests,
forceDeployment
forceDeployment,
serverSideApply
)
checkForErrors([result])
} else {
const result = await kubectl.apply(files, forceDeployment)
const result = await kubectl.apply(
files,
forceDeployment,
serverSideApply
)
checkForErrors([result])
}