locked
how can i manually edit a web deploy package? RRS feed

  • Question

  • User16290778 posted

    I generate a package like this: 

    msbuild myapp.csproj /T:Package

    I want to transform the package after it has been created.

    I dont want to use parameters.xml because i already have a bunch of xdt transforms and using another totally difference transform tool for the same thing is really stupid.

    I tried scripting applying my xdt transforms, opening the zip, adding in the transformed configs, and deploying that modified package

    Web deploy deleted the entire site directory and failed.

    Why? Does webdeploy hash the files or something making it impossible to manually edit a package after it has been created (outside of the parameters.xml thing)?

    The error was: 

    ERROR: msdeploy failed : SetParameters from:
    "C:\...\...\package.SetParameters.xml"
    Wednesday, April 25, 2018 11:07 PM

All replies

  • User283571144 posted

    Hi red888,

    I dont want to use parameters.xml because i already have a bunch of xdt transforms and using another totally difference transform tool for the same thing is really stupid.

    I tried scripting applying my xdt transforms, opening the zip, adding in the transformed configs, and deploying that modified package

    Web deploy deleted the entire site directory and failed.

     

    According to your description, I couldn't understand clearly about your requirement.

    Do you mean you don't want to add the Packages.SetParameters.xml?

    As far as I know, the Packages.deploy cmd file contains the codes to deploy the package to IIS.

    The codes as below:

    call :CheckParameterFile
    echo. Start executing msdeploy.exe
    echo -------------------------------------------------------
    if  not exist "%_DeploySetParametersFile%" (
    set _MSDeployCommandline="%MSDeployPath%msdeploy.exe" -source:package='%RootPath%MVCNormallIssue.zip' -dest:%_Destination% -verb:sync -disableLink:AppPoolExtension -disableLink:ContentExtension -disableLink:CertificateExtension
    ) else (
    set _MSDeployCommandline="%MSDeployPath%msdeploy.exe" -source:package='%RootPath%MVCNormallIssue.zip' -dest:%_Destination% -verb:sync -disableLink:AppPoolExtension -disableLink:ContentExtension -disableLink:CertificateExtension -setParamFile:"%_DeploySetParametersFile%"
    )

    If the SetParametersFile is not exists, it will not execute the parameter file.

    I couldn't find the reason why show the error about the "SetParameters.xml" file.

    I suggest you could post the details codes about the  "SetParameters.xml" file.

    If you could post more details information, it will be more easily for us to find the solution.

    Best Regards,

    Brando

     

    Thursday, April 26, 2018 3:00 AM
  • User16290778 posted

    I compiled a webdeploy package and now I want to transform it.

    msdeploy has a mechanism for transforming an already complied package using setparameters.

    I don't want to use that. I want to manually modify the package, then deploy it.

    msdeploy is not letting me do this and is throwing an error

    Thursday, April 26, 2018 4:22 PM