NPanday
  1. NPanday
  2. NPANDAY-488

Packaging for Web Applications (also Azure Web Roles)

    Details

      Description

      MSDeploy is an extensible tool for creating deployment packages, which then can be deployed to IIS (or Windows Services, e.g.)

      This is also a prerequisite for Azure Web Roles.

      High-level Requirements

      • Must support Package creation
      • Must support full MSDeploy feature set (through -source:manifest?)
      • Must choose reasonable defaults for file inclusion
      • Must be configurable from the VS Add-in
      • Should support XDT transformations
      • Should support filtering (Maven-Properties)
      • Should support Parametrization (through -declareParamFile)
      • Should make it hard to let default connection strings and passwords "leak" into the package

      Implementation Details

      • instead of reinventing the wheel, we could utilize maven-assembly-plugin:single with package-type "dir"
        • or: Syntax should be similar to maven-assembly-plugin; maybe code reuse is possible?
        • Externalized descriptors for file-inclusions should be possible (NPanday then provides reasonable defaults)
      • Package type is named msdeploy-package with extension msdeploy.zip (must end with .zip)
      • XDT should be delegated to MSBuild (partially depends on NPANDAY-486)

      Flow

      To test how this could work out, I used default Maven/NPanday tools + registration of msdeploy-package as msdeploy.zip. Then, as soon as we know how this should exactly work, we can start creating the needed plugins.

      prepare-package

      • assembly:single -> target/prepare-package/01-source-raw
        • includes dotnet-library dependencies in bin
        • includes *.as?x + config + css + js + graphics
      • exec:exec: msbuild copy-transformed.xml -> XDT-Transforms using *.package.config -> target/prepare-package/03-transformed
      • (Optional) exec:exec -> msdeploy - apply parameter configuration
        • This would avoid leaking developer default values into the package

      package

      • exec:exec: msdeploy -verb:sync -source:dirPath=target/prepare-package/03-transformed -dest:package=target/${artifactId}.msdeploy.zip
      • build-helper:attach artifact target/${artifactId}.msdeploy.zip as msdeploy-package

      Build runs locally:

      [INFO] Installing target\HelloWorld_WebRole.dll to .m2\...\HelloWorld_WebRole\1.0.0-SNAPSHOT\HelloWorld_WebRole-1.0.0-SNAPSHOT.dll
      [INFO] Installing target\HelloWorld_WebRole.msdeploy.zip to .m2\...\HelloWorld_WebRole\1.0.0-SNAPSHOT\HelloWorld_WebRole-1.0.0-SNAPSHOT.msdeploy.zip
      

        Issue Links

          Activity

          Hide
          Lars Corneliussen added a comment -

          We need NPANDAY-486 to include components, that make it easy to generate a MSBuild file and then run it (also from other plugins)

          Show
          Lars Corneliussen added a comment - We need NPANDAY-486 to include components, that make it easy to generate a MSBuild file and then run it (also from other plugins)

            People

            • Assignee:
              Lars Corneliussen
              Reporter:
              Lars Corneliussen
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development