<p>Yes. AWS CodeDeploy bundletype is specified separately from the revision location, so you could upload a .nupkg to Amazon S3, set the bundle type to 'zip', and since a nupkg is simply an archive CodeDeploy will treat it as such and upload it to your EC2 instance.</p>

<p>In your nuspec, make sure your appspec.yml gets placed in the root of your .nupkg. My project contains the appspec.yml and powershell scripts to manage windows services in a directory structure like this:</p>

<pre><code>deploy/appspec.yml
deploy/lib/get.ps1
deploy/lib/start.ps1
deploy/lib/stop.ps1
...
</code></pre>

<p>You can include this structure at the root by simply recursively retrieving this directory structure (via double wildcards <code>**</code>) in the nuspec files element:</p>

<pre><code>&lt;files&gt;
  &lt;file src="deploy\**" target="" /&gt;
&lt;/files&gt;  
</code></pre>

<p>And then after packing and outputting the nupkg, you can create the application revision as below:</p>

<p><a href="https://i.sstatic.net/ZjJoI.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/ZjJoI.png" alt="enter image description here"></a></p>

CC BY-SA 3.0
2017-02-28T17:21:13.990Z
2017-02-28T17:34:37.370Z
2017-02-28T17:34:37.370Z
Anthony Neace
<p>My build process packages my application in a <code>.nupkg</code> instead of a <code>.zip</code>. </p>

<p>Assuming my .nupkg contains a <a href="http://docs.aws.amazon.com/codedeploy/latest/userguide/app-spec-ref.html" rel="nofollow noreferrer">correctly-implemented</a> <code>appspec.yml</code> and is otherwise appropriately bundled, can my deployment revision use it?</p>

<amazon-web-services><aws-codedeploy><nuget>
Is it possible to package an application in a .nupkg when creating an application revision in AWS CodeDeploy?
Anthony Neace
# Is it possible to package an application in a .nupkg when creating an application revision in AWS CodeDeploy?

(Asked by: username_0 on 2017-02-28)

My build process packages my application in a `.nupkg` instead of a `.zip`.

Assuming my .nupkg contains a [correctly-implemented](http://docs.aws.amazon.com/codedeploy/latest/userguide/app-spec-ref.html) `appspec.yml` and is otherwise appropriately bundled, can my deployment revision use it?

**Tags:** amazon-web-services, aws-codedeploy, nuget


---

## 1 answers

### Answer by username_0 on 2017-02-28. Score: 2 | Accepted answer

Yes. AWS CodeDeploy bundletype is specified separately from the revision location, so you could upload a .nupkg to Amazon S3, set the bundle type to 'zip', and since a nupkg is simply an archive CodeDeploy will treat it as such and upload it to your EC2 instance.
In your nuspec, make sure your appspec.yml gets placed in the root of your .nupkg. My project contains the appspec.yml and powershell scripts to manage windows services in a directory structure like this:
deploy/appspec.yml
deploy/lib/get.ps1
deploy/lib/start.ps1
deploy/lib/stop.ps1
...

You can include this structure at the root by simply recursively retrieving this directory structure (via double wildcards **) in the nuspec files element:

  
  

And then after packing and outputting the nupkg, you can create the application revision as below:


---

