Hi Kevin
For a variety of reasons, the recommended way is to use a CI/CD platform, like TeamCity or Azure DevOps. One reason is to avoid repeat manual deployment work.
But, if you are okay with manual deployment, you can do the same procedure as the CI/CD platform would do. Take a look at this documentation page. It sounds like you are already on step 3.
Hi Kevin
I believe all new DXP environments are provisioned with the Linux stack.
About deploying to DXP with a Docker image. Not possible, since DXP creates its own container image from your package on deployment.
But you can deploy to Docker or Kubernetes, if you have your own such environment. It is exciting times.
Yes, the infrastructure and setup is different as CMS 12 is .NET Core and runs on Linux infrastructure.
Here's a some guides on deploying in Azure DevOps
Push esentially it's
Hi Kevin,
Yes, If you are deploying to a DXP environment then the API is the only way to do it.
You can read more on how to deploy using the API here.
While this is all done from a local environment I would advise to use some form of CI/CD software to handle building and deploying the code for you there is a good write up here from the team at Epinova on how to do this using their tool.
Paul
Thank you all!
I've made some progress, but not full success. I want to eventually end up with a CI/CD solution, but first I wanted to try deploying just with Powershell.
First, I use Visual Studio's Publish to Folder.
Then I run the following script:
Compress-Archive -Path ".\bin\Release\net6.0\publish\*" -DestinationPath ".\bin\Release\cms.app.2023.1.zip" -Force
if (Test-Path ".\bin\Release\cms.app.2023.1.nukpg") {
Remove-Item ".\bin\Release\cms.app.2023.1.nukpg" -Force
}
Rename-Item -Path ".\bin\Release\cms.app.2023.1.zip" -NewName ".\bin\Release\cms.app.2023.1.nukpg" -Force
Connect-EpiCloud -ClientKey "<clientKey>" -ClientSecret "<clientSecret>" -ProjectId "<projectId>"
$saslink = Get-EpiDeploymentPackageLocation
Add-EpiDeploymentPackage -SasUrl $saslink -Path ".\bin\Release\cms.app.2023.1.nukpg"
Start-EpiDeployment -DeploymentPackage "cms.app.2023.1.nukpg" -TargetEnvironment Integration -DirectDeploy
Complete-EpiDeployment -Id "<projectId>"
All of these steps appear to complete successfully, except the last one; resulting in the error:
API call failed! The error was: The remote server returned an error: (404) Not Found. {"success":false,"errors":["The deployment: xxxxxx is not found."],"result":null}
At C:\Program Files\WindowsPowerShell\Modules\EpiCloud\1.2.0\EpiCloud.psm1:315 char:13
Based on what I've read, the -Id parameter is not looking for a projectId, but some other ID. What is this ID and where can I find it?
Otherwise, is my script complete and correct?
Hi Kevin
That parameter should refer to the specific deployment you have started.
As I recall you will get an object from Start-EpiDeployment which you can use in Complete-EpiDeployment. Something like:
$deployment = Start-EpiDeployment -DeploymentPackage "cms.app.2023.1.nukpg" -TargetEnvironment Integration -DirectDeploy
Complete-EpiDeployment -Id $deployment.id
Background:
For our current CMS-11 environment, deployment has always been done using Visual Studio + Web Deploy. For our new CMS-12 environment, Opti support stated:
The only supported deployment method is using the deployment API as outlined in the documentation https://docs.developers.optimizely.com/digital-experience-platform/docs/deployment-api
Questions:
Comments:
I have searched for and read a lot of documentation and I am not seeing or recognizing what to do. All Opti-based documents I have found presumes a base familiarity I am missing.
From the post: https://stefanolsen.com/posts/7-ways-to-deploy-optimizely-cms-12-.net-6 ... any comments on these deployment options?
Any help or discussion would be greatly appreciated!
Thanks, Kevin