mirror of
https://github.com/whyour/qinglong.git
synced 2026-09-20 16:07:11 +08:00
fix(ql3): install alpha finalizer dependencies
This commit is contained in:
@@ -559,6 +559,9 @@ function auditAlphaStageIndexWorkflow(root = DEFAULT_ROOT) {
|
||||
`if: ${condition}`,
|
||||
' - local-alpha-milestone\n',
|
||||
' - cluster-alpha-milestone\n',
|
||||
'pnpm/action-setup@v6',
|
||||
'cache-dependency-path: pnpm-lock.yaml',
|
||||
'pnpm install --frozen-lockfile --ignore-scripts',
|
||||
`name: ql3-alpha-${'${{ github.sha }}'}-local-${'${{ inputs.local_alpha_variant }}'}-milestone`,
|
||||
`name: ql3-alpha-${'${{ github.sha }}'}-cluster-milestone`,
|
||||
'scripts/ql3-alpha-stage-index.cjs',
|
||||
@@ -571,11 +574,15 @@ function auditAlphaStageIndexWorkflow(root = DEFAULT_ROOT) {
|
||||
if (!stage || tokens.some((token) => !stage.includes(token))) {
|
||||
findings.push('ALPHA_STAGE_INDEX_FINALIZER_CONTRACT_DRIFT');
|
||||
}
|
||||
const dependencyInstallIndex = stage.indexOf(
|
||||
'pnpm install --frozen-lockfile --ignore-scripts',
|
||||
);
|
||||
const finalizeIndex = stage.indexOf('--mode=finalize');
|
||||
const auditIndex = stage.indexOf('--mode=audit');
|
||||
const uploadIndex = stage.indexOf('actions/upload-artifact@');
|
||||
if (
|
||||
finalizeIndex < 0 ||
|
||||
dependencyInstallIndex < 0 ||
|
||||
finalizeIndex <= dependencyInstallIndex ||
|
||||
auditIndex <= finalizeIndex ||
|
||||
uploadIndex <= auditIndex
|
||||
) {
|
||||
|
||||
@@ -494,6 +494,9 @@ function auditClusterAlphaMilestoneWorkflow(root = DEFAULT_ROOT) {
|
||||
const milestone = jobBlock(workflow, 'cluster-alpha-milestone');
|
||||
const tokens = [
|
||||
'name: Finalize the Cluster Alpha integration milestone',
|
||||
'pnpm/action-setup@v6',
|
||||
'cache-dependency-path: pnpm-lock.yaml',
|
||||
'pnpm install --frozen-lockfile --ignore-scripts',
|
||||
'actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c',
|
||||
'scripts/ql3-cluster-alpha-milestone.cjs',
|
||||
'--mode=finalize',
|
||||
@@ -517,11 +520,15 @@ function auditClusterAlphaMilestoneWorkflow(root = DEFAULT_ROOT) {
|
||||
) {
|
||||
findings.push('CLUSTER_MILESTONE_FINALIZER_CONTRACT_DRIFT');
|
||||
}
|
||||
const dependencyInstallIndex = milestone.indexOf(
|
||||
'pnpm install --frozen-lockfile --ignore-scripts',
|
||||
);
|
||||
const finalizerIndex = milestone.indexOf('--mode=finalize');
|
||||
const auditIndex = milestone.indexOf('--mode=audit');
|
||||
const uploadIndex = milestone.indexOf('actions/upload-artifact@');
|
||||
if (
|
||||
finalizerIndex < 0 ||
|
||||
dependencyInstallIndex < 0 ||
|
||||
finalizerIndex <= dependencyInstallIndex ||
|
||||
auditIndex <= finalizerIndex ||
|
||||
uploadIndex <= auditIndex
|
||||
) {
|
||||
|
||||
@@ -527,6 +527,9 @@ function auditLocalAlphaMilestoneWorkflow(root = DEFAULT_ROOT) {
|
||||
const milestoneTokens = [
|
||||
' name: Finalize the Local Alpha milestone',
|
||||
' needs:',
|
||||
'pnpm/action-setup@v6',
|
||||
'cache-dependency-path: pnpm-lock.yaml',
|
||||
'pnpm install --frozen-lockfile --ignore-scripts',
|
||||
'actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c',
|
||||
`name: ql3-alpha-${'${{ github.sha }}'}-local-${'${{ inputs.local_alpha_variant }}'}-amd64`,
|
||||
`name: ql3-alpha-${'${{ github.sha }}'}-local-${'${{ inputs.local_alpha_variant }}'}-arm64`,
|
||||
@@ -547,11 +550,15 @@ function auditLocalAlphaMilestoneWorkflow(root = DEFAULT_ROOT) {
|
||||
) {
|
||||
findings.push('MILESTONE_FINALIZER_CONTRACT_DRIFT');
|
||||
}
|
||||
const dependencyInstallIndex = milestone.indexOf(
|
||||
'pnpm install --frozen-lockfile --ignore-scripts',
|
||||
);
|
||||
const finalizerIndex = milestone.indexOf('--mode=finalize');
|
||||
const auditIndex = milestone.indexOf('--mode=audit');
|
||||
const uploadIndex = milestone.lastIndexOf('actions/upload-artifact@');
|
||||
if (
|
||||
finalizerIndex < 0 ||
|
||||
dependencyInstallIndex < 0 ||
|
||||
finalizerIndex <= dependencyInstallIndex ||
|
||||
auditIndex <= finalizerIndex ||
|
||||
uploadIndex <= auditIndex
|
||||
) {
|
||||
|
||||
Reference in New Issue
Block a user