From fcb0baede206acf1c56262c7523a3bc310f6c7d8 Mon Sep 17 00:00:00 2001
From: fortandh <fortandh@qq.com>
Date: Thu, 14 Mar 2024 22:01:44 +0800
Subject: [PATCH] =?UTF-8?q?Mod:=20=E5=9C=A8=20artifact=20=E5=90=8D?=
 =?UTF-8?q?=E7=A7=B0=E4=B8=8A=E6=B7=BB=E5=8A=A0=E6=97=B6=E9=97=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 .gitlab-ci.yml | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 21853be..c35b12e 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -13,7 +13,7 @@ build:
     - yarn build
   allow_failure: false
   rules:
-    - if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
+    - if: $CI_PIPELINE_SOURCE == "merge_request_event"
       changes:
         compare_to: 'refs/head/main'
         paths:
@@ -30,11 +30,12 @@ webpack:
     - yarn build
     - cp -r public .next/standalone/
     - cp -r .next/static .next/standalone/.next/
+    - mv .next/standalone .
   artifacts:
     paths:
-      - .next/standalone
+      - standalone
     expire_in: 1 week
-    name: start-navigator-$CI_COMMIT_SHORT_SHA
+    name: start-navigator-$CI_COMMIT_SHORT_SHA-${CI_PIPELINE_CREATED_AT:0:19}
   allow_failure: false
-  rules:
-    - if: $CI_PIPELINE_SOURCE == "merge_request_event" && $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "main"
+  only:
+    - main
-- 
GitLab