-
Notifications
You must be signed in to change notification settings - Fork 36
09. Examples
- Retrieve metadata by running
mcdev retrieve <BU>
(where the BU corresponds to a credential-Business Unit combo in the .mcdevrc.json) - Create a directory called
deploy/
in the root directory - Create a directory called
dataExtension/
in thedeploy/
directory - Copy a single dataExtension directory from the
retrieve/<credential>/<BU-Name>/dataExtension/
directory intodeploy/<credential>/<BU-Name>/dataExtension/
- Run
mcdev deploy <BU>
to deploy everything in the deploy folder to the specified Business Unit
Metadata of a Business Unit can be retrieved by running the following command:
mcdev retrieve <BU>
where <BU>
needs to be replaced with credentialName/businessUnit-Name
that is defined in .mcdevrc.json.
Run this command for each of your defined Business Units and this will result in a retrieve directory with a sub-directory for each Business Unit. Each sub-directory contains the metadata from this Business Unit that is currently supported to retrieve.
This folder structure can be committed into a git repository and used as a backup.
Now we want to deploy an Automation with its related metadata. Select a retrieved Automation and copy it into the deploy folder. (deploy/<credential>/<BU-Name>/automation/myAutomation.meta-automation.json
)
Copy all related activity metadata of this automation into the deploy folder. (Example: deploy/<credential>/<BU-Name>/query/myquery.meta-query.json
and deploy/<credential>/<BU-Name>/query/myquery.meta-query.sql
)
To start the deployment run the following command:
mcdev deploy <BU>
Copyright (c) 2020-2024 Accenture. MIT licensed. Main contributors: Jörn Berkefeld, Doug Midgley