mcloud-deployments

โดย medusajs

ดำเนินการคำสั่ง mcloud deployments เพื่อแสดงรายการการปรับใช้ ดึงข้อมูลรายละเอียดการปรับใช้ และดึงบันทึกการสร้าง ใช้เมื่อแสดงรายการการปรับใช้ ตรวจสอบการปรับใช้…

npx skills add https://github.com/medusajs/medusa-agent-skills --skill mcloud-deployments

Cloud CLI: Deployments Commands

Execute mcloud deployments commands to inspect deployments and their build logs.

Constraints

  • Always pass --json when parsing output — plaintext format may change.
  • Always confirm context (mcloud whoami --json) before running commands if org/project are not already known.
  • Use --deployment IDs in the format depl_* or build IDs; build IDs resolve to their latest deployment automatically.

Commands

deployments list

List recent deployments for a project (default: 20 most recent across all environments).

mcloud deployments list --organization <org-id> --project <project-id-or-handle> --json

Options:

  • -o/--organization <id> — Organization ID (falls back to active context)
  • -p/--project <id-or-handle> — Project ID or handle (falls back to active context)
  • -e/--environment <handle> — Filter by environment handle
  • --environment-type <production|long-lived|preview> — Filter by environment type
  • --commit <sha> — Filter by Git commit SHA (full or prefix)
  • --limit <1-200> — Max results (default: 20)
  • --offset <number> — Pagination offset (default: 0)
  • --json — Output as JSON

deployments get

Retrieve a single deployment's details by ID.

mcloud deployments get <deployment-id> --organization <org-id> --project <project-id-or-handle> --json

Arguments:

  • deployment — Deployment ID (required)

Options:

  • -o/--organization <id>, -p/--project <id-or-handle>, --json

deployments build-logs

Fetch build logs for a deployment. Use this to debug build-failed status.

mcloud deployments build-logs <deployment-id> --organization <org-id> --project <project-id-or-handle>

Arguments:

  • deployment — Deployment ID (required)

Options:

  • -o/--organization <id>, -p/--project <id-or-handle>
  • --type <backend|storefront> — Which build log stream to read (default: backend)
  • --json — Output as JSON

Deployment Statuses

StatusMeaning
createdBuild not started yet
buildingBuild running
builtBuild succeeded, awaiting rollout
deployingRolling out to environment
deployedLive and serving traffic
build-failedBuild step failed — read build-logs
deployment-failedBuild succeeded, runtime crashed — read mcloud logs
timed-outExceeded time budget (backend only)
canceledSuperseded by a newer deployment
idleNo longer the active deployment

Examples

# List all deployments (with active context set)
mcloud deployments list --json

# Find most recent build-failed deployment
mcloud deployments list --json \
  | jq -r '[.[] | select(.backend_status == "build-failed")][0].id'

# Get deployment details
mcloud deployments get bld_01ABC123 --json

# Read backend build logs
mcloud deployments build-logs bld_01ABC123

# Read storefront build logs
mcloud deployments build-logs bld_01ABC123 --type storefront

# Filter deployments by commit SHA
mcloud deployments list --commit a1b2c3d --json | jq '.'

# Get deployments for a specific environment
mcloud deployments list --environment production --json

Skills เพิ่มเติมจาก medusajs

mcloud-variables
medusajs
ดำเนินการคำสั่ง mcloud variables เพื่อแสดงรายการและรับตัวแปรสภาพแวดล้อมสำหรับสภาพแวดล้อมคลาวด์ ใช้เมื่อตรวจสอบ อ่าน หรือส่งออกสภาพแวดล้อม…
official
building-storefronts
medusajs
การผสานรวมฟรอนต์เอนด์แบบ SDK-first สำหรับร้านค้า Medusa ด้วยรูปแบบ React Query และกฎการเรียก API ที่สำคัญ ใช้ Medusa JS SDK สำหรับคำขอ API ทั้งหมดเสมอ—ห้ามใช้ fetch() ปกติเด็ดขาด เนื่องจากขาดส่วนหัวที่จำเป็น (publishable API key สำหรับเส้นทางร้านค้า, auth สำหรับเส้นทางผู้ดูแลระบบ) ส่งออบเจกต์ JavaScript ธรรมดาไปยังเมธอดของ SDK ห้ามใช้ JSON.stringify() กับพารามิเตอร์ body เพราะ SDK จัดการการทำให้เป็นอนุกรมโดยอัตโนมัติ ใช้ useQuery สำหรับคำขอ GET และ useMutation สำหรับคำขอ POST/DELETE,...
official
building-admin-dashboard-customizations
medusajs
ส่วนขยาย UI แบบกำหนดเองสำหรับแดชบอร์ด Medusa Admin โดยใช้ Admin SDK และคอมโพเนนต์ Medusa UI โหลดสกิลนี้ก่อนสำหรับงาน UI ของแอดมิน (การวางแผน การนำไปใช้ การสำรวจ); เซิร์ฟเวอร์ MCP ให้เฉพาะการอ้างอิง API เท่านั้น ไม่ใช่รูปแบบการออกแบบหรือกลยุทธ์การโหลดข้อมูล สำคัญ: ใช้ Medusa JS SDK สำหรับคำขอ API ทั้งหมดเสมอ (ห้ามใช้ fetch ปกติ); แยกคิวรีการแสดงผลออกจากคิวรีโมดอล และล้างข้อมูลการแสดงผลหลังจากการกลายพันธุ์ นำวิดเจ็ตไปใช้บนหน้าที่มีอยู่หรือสร้างเส้นทาง UI แบบกำหนดเอง;...
official
learning-medusa
medusajs
ค่ายฝึกพัฒนา Medusa แบบโต้ตอบทีละขั้นตอน ที่คุณจะสร้างฟีเจอร์แบรนด์ไปพร้อมกับเรียนรู้รูปแบบสถาปัตยกรรม ประกอบด้วยสามบทเรียนแบบต่อเนื่อง (รวม 2–3 ชั่วโมง) ครอบคลุมโมดูล เวิร์กโฟลว์ เส้นทาง API การเชื่อมโยงโมดูล ฮุคของเวิร์กโฟลว์ และการปรับแต่ง UI ของแอดมิน มีการตรวจสอบจุดเช็คพอยต์หลังจากแต่ละองค์ประกอบหลัก เพื่อทดสอบความเข้าใจเชิงแนวคิด คุณภาพโค้ด และฟังก์ชันการทำงานก่อนดำเนินการต่อ ปฏิบัติต่อข้อผิดพลาดเป็นโอกาสในการสอน แก้ไขข้อบกพร่องร่วมกันด้วยคำถามวินิจฉัยและการวิเคราะห์สาเหตุที่แท้จริง...
official
db-migrate
medusajs
ดำเนินการย้ายฐานข้อมูล Medusa ที่รออยู่และรายงานผลลัพธ์ รัน npx medusa db:migrate ผ่าน Bash เพื่อใช้การย้ายข้อมูลที่รออยู่ทั้งหมดไปยังฐานข้อมูล Medusa ของคุณ รายงานผลลัพธ์การย้ายข้อมูล รวมถึงจำนวนการย้ายข้อมูลที่ถูกนำไปใช้ ข้อผิดพลาดที่พบ และการยืนยันความสำเร็จ ออกแบบมาสำหรับโปรเจกต์ Medusa ที่มีการตั้งค่า npm/npx มาตรฐาน
official
mcloud-environments
medusajs
ดำเนินการคำสั่ง mcloud environments เพื่อแสดงรายการ รับข้อมูล สร้าง ลบ ปรับใช้ใหม่ หรือเรียกใช้บิลด์สำหรับสภาพแวดล้อม Cloud ใช้เมื่อจัดการวงจรชีวิตของสภาพแวดล้อม...
official
db-generate
medusajs
สร้างการย้ายฐานข้อมูลสำหรับโมดูล Medusa ด้วยคำสั่งเดียว ครอบคลุมคำสั่ง CLI npx medusa db:generate เพื่อสร้างไฟล์การย้ายสำหรับโมดูล Medusa ที่ระบุ รับชื่อโมดูลเป็นอาร์กิวเมนต์และรายงานตำแหน่งไฟล์การย้าย ข้อผิดพลาด และขั้นตอนถัดไป แนะนำให้รัน npx medusa db:migrate หลังจากสร้างเพื่อใช้การย้ายโดยอัตโนมัติ
official
mcloud-deployments
medusajs
Execute คำสั่ง mcloud deployments เพื่อแสดงรายการ deployments ดึงรายละเอียด deployment และดึง build logs ใช้เมื่อต้องการแสดงรายการ deployments ตรวจสอบ deployment…
official