[{"data":1,"prerenderedAt":326},["ShallowReactive",2],{"docs-nav":3,"docs:\u002Fdocs\u002Fconcepts\u002Fplans-and-apply":139},[4,7,10,13,16,19,22,25,28,31,34,37,40,43,46,49,52,55,58,61,64,67,70,73,76,79,82,85,88,91,94,97,100,103,106,109,112,115,118,121,124,127,130,133,136],{"path":5,"title":6},"\u002Fdocs\u002Faccess-gating","Protect a local route",{"path":8,"title":9},"\u002Fdocs\u002Farchitecture\u002Fsecurity-and-trust","Security and trust",{"path":11,"title":12},"\u002Fdocs\u002Fconcepts\u002Fbuilds-and-deployments","Build and deploy",{"path":14,"title":15},"\u002Fdocs\u002Fconcepts\u002Fconfiguration-ownership","Where configuration belongs",{"path":17,"title":18},"\u002Fdocs\u002Fconcepts\u002Fenvironments-and-secrets","Environment values and secrets",{"path":20,"title":21},"\u002Fdocs\u002Fconcepts\u002Fmental-model","How projects fit together",{"path":23,"title":24},"\u002Fdocs\u002Fconcepts\u002Fplans-and-apply","Plans and apply",{"path":26,"title":27},"\u002Fdocs\u002Fconcepts\u002Ftargets-and-runtimes","Choose a target and runtime",{"path":29,"title":30},"\u002Fdocs\u002Fcontribute\u002Freleases","Publish a release",{"path":32,"title":33},"\u002Fdocs\u002Fdevelopment-mounts","Development mounts",{"path":35,"title":36},"\u002Fdocs\u002Fgetting-started","Getting started",{"path":38,"title":39},"\u002Fdocs\u002Fhelp\u002Ffaq","FAQ",{"path":41,"title":42},"\u002Fdocs\u002Fhelp\u002Ftroubleshooting","Troubleshooting",{"path":44,"title":45},"\u002Fdocs\u002Fhow-to\u002Fdeploy-production","Prepare a deployment environment",{"path":47,"title":48},"\u002Fdocs\u002Fhow-to\u002Fswarm-cluster","Run on a multi-node Swarm",{"path":50,"title":51},"\u002Fdocs","mm documentation",{"path":53,"title":54},"\u002Fdocs\u002Fjobs-and-schedules","Jobs and schedules",{"path":56,"title":57},"\u002Fdocs\u002Flocal-dashboard","Local dashboard",{"path":59,"title":60},"\u002Fdocs\u002Flocal-https","Local HTTPS",{"path":62,"title":63},"\u002Fdocs\u002Flocal-services","Local services",{"path":65,"title":66},"\u002Fdocs\u002Fmcp","Let an AI agent work on your project",{"path":68,"title":69},"\u002Fdocs\u002Fmulti-project-hosts","Run multiple projects on one host",{"path":71,"title":72},"\u002Fdocs\u002Fonboarding","Set up a project",{"path":74,"title":75},"\u002Fdocs\u002Fopenbao","Use OpenBao",{"path":77,"title":78},"\u002Fdocs\u002Fproject\u002Fcontributing","Contributing",{"path":80,"title":81},"\u002Fdocs\u002Fproject\u002Flicense","License",{"path":83,"title":84},"\u002Fdocs\u002Fproject\u002Fsecurity","Security",{"path":86,"title":87},"\u002Fdocs\u002Freference\u002Fcapability-matrix","Supported features and platforms",{"path":89,"title":90},"\u002Fdocs\u002Freference\u002Fcli","CLI command reference",{"path":92,"title":93},"\u002Fdocs\u002Freference\u002Fconfiguration","Configuration",{"path":95,"title":96},"\u002Fdocs\u002Freference\u002Fenvironment-variables","Environment variables",{"path":98,"title":99},"\u002Fdocs\u002Freference\u002Ferrors-and-exit-codes","Errors and exit codes",{"path":101,"title":102},"\u002Fdocs\u002Freference\u002Fknown-issues","Known limitations",{"path":104,"title":105},"\u002Fdocs\u002Fremote-access","Manage remote access",{"path":107,"title":108},"\u002Fdocs\u002Fremote-daemon","Set up a remote host",{"path":110,"title":111},"\u002Fdocs\u002Fruntime-observability","Status, logs, and commands",{"path":113,"title":114},"\u002Fdocs\u002Fsecret-delivery","Pass secrets to your app",{"path":116,"title":117},"\u002Fdocs\u002Fsecret-providers","Choose a secret store",{"path":119,"title":120},"\u002Fdocs\u002Fstart\u002Finstall","Install mm",{"path":122,"title":123},"\u002Fdocs\u002Fterminal-ui","Terminal UI",{"path":125,"title":126},"\u002Fdocs\u002Ftutorials\u002Fdotnet-web-api",".NET web API example",{"path":128,"title":129},"\u002Fdocs\u002Ftutorials\u002Ffirst-local-app","First local app",{"path":131,"title":132},"\u002Fdocs\u002Ftutorials\u002Flaravel-rust","Laravel and Rust example",{"path":134,"title":135},"\u002Fdocs\u002Ftutorials\u002Fnode-fullstack","Node full stack example",{"path":137,"title":138},"\u002Fdocs\u002Fvault","Use HashiCorp Vault",{"id":140,"title":24,"body":141,"description":319,"extension":320,"meta":321,"navigation":322,"path":23,"seo":323,"stem":324,"__hash__":325},"docs\u002Fdocs\u002Fconcepts\u002Fplans-and-apply.md",{"type":142,"value":143,"toc":313},"minimark",[144,148,153,199,206,209,256,259,263,266,282,289,293,296,300,309],[145,146,147],"p",{},"A plan shows what mm will change before it makes the change. It prints a hash:\nthe value you pass back to confirm which plan you reviewed.",[149,150,152],"h2",{"id":151},"review-and-apply-a-deployment","Review and apply a deployment",[154,155,160],"pre",{"className":156,"code":157,"language":158,"meta":159,"style":159},"language-sh shiki shiki-themes mm","mm deploy plan\nmm deploy apply --plan PLAN_HASH --yes\n","sh","",[161,162,163,179],"code",{"__ignoreMap":159},[164,165,168,172,176],"span",{"class":166,"line":167},"line",1,[164,169,171],{"class":170},"svrjQ","mm",[164,173,175],{"class":174},"sv8ni"," deploy",[164,177,178],{"class":174}," plan\n",[164,180,182,184,186,189,193,196],{"class":166,"line":181},2,[164,183,171],{"class":170},[164,185,175],{"class":174},[164,187,188],{"class":174}," apply",[164,190,192],{"class":191},"sbRf1"," --plan",[164,194,195],{"class":174}," PLAN_HASH",[164,197,198],{"class":191}," --yes\n",[145,200,201,202,205],{},"Replace ",[161,203,204],{},"PLAN_HASH"," with the hash from the first command. Review the selected\nenvironment, target, images, and resources before applying.",[145,207,208],{},"Use the same flags for both commands. For example:",[154,210,212],{"className":156,"code":211,"language":158,"meta":159,"style":159},"mm --environment production --target prod deploy plan\nmm --environment production --target prod deploy apply --plan PLAN_HASH --yes\n",[161,213,214,234],{"__ignoreMap":159},[164,215,216,218,221,224,227,230,232],{"class":166,"line":167},[164,217,171],{"class":170},[164,219,220],{"class":191}," --environment",[164,222,223],{"class":174}," production",[164,225,226],{"class":191}," --target",[164,228,229],{"class":174}," prod",[164,231,175],{"class":174},[164,233,178],{"class":174},[164,235,236,238,240,242,244,246,248,250,252,254],{"class":166,"line":181},[164,237,171],{"class":170},[164,239,220],{"class":191},[164,241,223],{"class":174},[164,243,226],{"class":191},[164,245,229],{"class":174},[164,247,175],{"class":174},[164,249,188],{"class":174},[164,251,192],{"class":191},[164,253,195],{"class":174},[164,255,198],{"class":191},[145,257,258],{},"Builds and shared service changes follow the same pattern, but each operation\nhas its own plan. A build hash cannot approve a deployment.",[149,260,262],{"id":261},"when-a-plan-changes","When a plan changes",[145,264,265],{},"mm checks the inputs again before applying. A plan can become stale if you:",[267,268,269,273,276,279],"ul",{},[270,271,272],"li",{},"Edit project configuration, Compose files, or build inputs.",[270,274,275],{},"Change the environment, target, runtime, or build options.",[270,277,278],{},"Update a secret used by the operation.",[270,280,281],{},"Apply another deployment or change resources on the target.",[145,283,284,285,288],{},"If you see ",[161,286,287],{},"deployment plan changed",", run the original plan command again,\nreview the new result, and use its new hash. Do not edit stored plans.",[149,290,292],{"id":291},"what-a-plan-includes","What a plan includes",[145,294,295],{},"Plans include resource changes and secret references, but not secret values.\nAn unsupported feature, missing required value, or conflicting resource stops\nthe operation. mm will not take over another tool's resource merely because\nits name matches.",[149,297,299],{"id":298},"if-apply-fails","If apply fails",[145,301,302,303,308],{},"Deployment attempts to restore the last successful deployment when one is\navailable. Rollback can also fail, so read the error and check service status\nbefore trying again. See ",[304,305,307],"a",{"href":306},"..\u002Fhelp\u002Ftroubleshooting#interrupted-deployment-or-service-operation","recovery steps",".",[310,311,312],"style",{},"html pre.shiki code .svrjQ, html code.shiki .svrjQ{--shiki-default:var(--mm-code-function)}html pre.shiki code .sv8ni, html code.shiki .sv8ni{--shiki-default:var(--mm-code-string)}html pre.shiki code .sbRf1, html code.shiki .sbRf1{--shiki-default:var(--mm-code-option)}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}",{"title":159,"searchDepth":181,"depth":181,"links":314},[315,316,317,318],{"id":151,"depth":181,"text":152},{"id":261,"depth":181,"text":262},{"id":291,"depth":181,"text":292},{"id":298,"depth":181,"text":299},"Preview a change, approve it, and handle an out-of-date plan.","md",{},true,{"title":24,"description":319},"docs\u002Fconcepts\u002Fplans-and-apply","-45vCUk_URJWRH-fcGzlnioYo-XScJOczv-RRN9wFEU",1794512545911]