docs(calculate-version): 重整 action 與 workflow 文件
This commit is contained in:
+9
-2
@@ -1,15 +1,22 @@
|
||||
# --------------------------------------------------
|
||||
# 用途:定義 calculate-version action 的 Docker 執行環境。
|
||||
# 更新日期:2026/07/11 17:44:33(Asia/Taipei)
|
||||
# 用途:定義 calculate-version action 的 Docker 執行環境與啟動入口。
|
||||
# 更新日期:2026/07/11 21:08:44(Asia/Taipei)
|
||||
# --------------------------------------------------
|
||||
|
||||
# 使用 Node LTS Alpine 映像,兼顧 Node 執行環境與較小的映像體積。
|
||||
FROM node:lts-alpine
|
||||
|
||||
# 將工作目錄切換到 /action,後續複製與執行都以此為基準。
|
||||
WORKDIR /action
|
||||
|
||||
# 複製 action 的主程式來源到容器內,供 entrypoint 執行。
|
||||
COPY src/ /action/src/
|
||||
|
||||
# 複製 entrypoint 腳本到容器內,作為啟動入口。
|
||||
COPY entrypoint.sh /action/entrypoint.sh
|
||||
|
||||
# 賦予 entrypoint 可執行權限,否則容器啟動時無法直接執行。
|
||||
RUN chmod +x /action/entrypoint.sh
|
||||
|
||||
# 指定容器啟動時直接執行 entrypoint 腳本。
|
||||
ENTRYPOINT ["/action/entrypoint.sh"]
|
||||
|
||||
Reference in New Issue
Block a user