Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to prevent removing old files #27

Open
alessioGit83 opened this issue May 28, 2024 · 10 comments
Open

Unable to prevent removing old files #27

alessioGit83 opened this issue May 28, 2024 · 10 comments

Comments

@alessioGit83
Copy link

Hello,
I'm trying to use the tool to deploy code into Azure App Service.
The deploy process works but even if I not declare the /d parameter, the deploy process remove all old files not present in the new deployment.

Any suggestions?

Thanks
Alessio

@davidebbo
Copy link
Owner

davidebbo commented May 28, 2024

I just tried and was not able to repro. Steps I used:

  • Create new Azure Web App, which comes with a hostingstart.html
  • Download the publish profile
  • Use WAWSdeploy to publish a folder with one test file (just a foo.txt at the root), without passing any flags

Result: the new file gets published, and the existing hostingstart.html is still there

Please try these exact steps.

@alessioGit83
Copy link
Author

alessioGit83 commented May 28, 2024 via email

@davidebbo
Copy link
Owner

It does not happen for me. After redeploying with a different file, I still have all the original files.

To help isolate, please try again with a fresh site as per my steps above.

@alessioGit83
Copy link
Author

alessioGit83 commented May 28, 2024 via email

@alessioGit83
Copy link
Author

alessioGit83 commented May 28, 2024 via email

@davidebbo
Copy link
Owner

I used the publishSetting file provided by azure portal. Do you use the same approach?

Yes, I just downloaded it from the portal.

Have you tried with a fresh new app, just to make sure that there is nothing unusual about yours?

@alessioGit83
Copy link
Author

alessioGit83 commented May 28, 2024 via email

@davidebbo
Copy link
Owner

Why can't you test on a new app? I just created a free app, and it's ready in a minute at no cost.

Usage wise, all I did is run wawsdeploy c:\testfolder testsite.PublishSettings.

@alessioGit83
Copy link
Author

alessioGit83 commented May 29, 2024 via email

@davidebbo
Copy link
Owner

Strange, I cannot explain it. Note that WAWSDeploy is just a thin wrapper on top of msdeploy.exe. See https://blog.davidebbo.com/2014/03/WAWSDeploy.html for details (and also look at the WAWSDeploy code to see how it calls it).

It would be interesting to see if you get the same results when using msdeploy.exe directly. If so, that takes WAWSDeploy out of the equation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants