cloudfoundry / diego-windows-release

Apache License 2.0
9 stars 13 forks source link

NoAppDetectedError while pushing dot net app on windows cell #27

Closed cfmagnum closed 7 years ago

cfmagnum commented 7 years ago

We have upgraded cf to v254 and diego v1.10.1. The windows cell has been deployed using diego-windows-release 0.496 ,but while pushing any app on stack windows2012R2 we get the following error:

x.x.x.x:~/workspace/oscf-old/ci/aws/windows-cell/wats/assets/nora/NoraPublished$ cf push windows-test-app -s windows2012R2 -b https://github.com/ryandotsmith/null-buildpack.git -m 1G --no-start
Using stack windows2012R2...
OK
Updating app windows-test-app in org oscf-sys / space testing as admin...
OK

Uploading windows-test-app...
Uploading app files from: /workspace/.jewel/oscf-old/ci/aws/windows-cell/wats/assets/nora/NoraPublished
Uploading 21K, 20 files
Done uploading
OK

x.x.x.x:~/workspace/oscf-old/ci/aws/windows-cell/wats/assets/nora/NoraPublished$ cf start windows-test-app
Starting app windows-test-app in org oscf-sys / space testing as admin...
Creating container
Successfully created container
Downloading app package...
Downloaded app package (786.8K)
Staging...
None of the buildpacks detected a compatible application
Exit status 222
Staging failed: Exited with status 222
Destroying container
Successfully destroyed container

FAILED
NoAppDetectedError
cf-gitbot commented 7 years ago

We have created an issue in Pivotal Tracker to manage this:

https://www.pivotaltracker.com/story/show/143557517

The labels on this github issue will be updated when the story is started.

sunjayBhatia commented 7 years ago

@cfmagnum with that version of diego, the Windows App Lifecycle has changed to actually use buildpacks. As such, you need to use the hwc-buildpack and change your push command to:

cf push windows-test-app -s windows2012R2 -b https://github.com/cloudfoundry-incubator/hwc-buildpack/releases/download/v2.3.3/hwc_buildpack-cached-v2.3.3.zip -m 1G --no-start

The WAL also does not support git urls (there is a bug in libGit2) so your url does in fact also need to be to an actual buildpack artifact, not a git repository.

sunjayBhatia commented 7 years ago

also @cfmagnum please consider moving to BOSH deployed Windows cells, the MSI will be officially deprecated soon

cfmagnum commented 7 years ago

Thank you for the suggestion, we would try it. Also had a query as you stated that MSI would be deprecated what would be the migration strategy for the same. Would diego handle the migrations of existing apps to the new windows cell deployment(deployed via bosh).

sunjayBhatia commented 7 years ago

@cfmagnum Existing apps will have to be evacuated to the new BOSH deployed cells and the old DiegoWindows cells shut down.

Set-Service RepService -startuptype "Disabled"

Invoke-WebRequest -Uri -UseBasicParsing http://localhost:1800/evacuate -Method Post

while ($true) {
    try {
        Get-WebRequest "http://localhost:1800/ping"
    } catch {
        [system.exception]
        break;
    }
}

Apps should be evacuated and pushed onto running cells

cfmagnum commented 7 years ago

Thank you for your suggestions. The migration stratergy on windows cell we would try it. The other suggestion regarding pushing of apps on windows cell using different buildpack worked for us.

sunjayBhatia commented 7 years ago

Sweet! I will close this out then, glad you got it working