问题
We have our sql project build built as dacpac
and has dependency on master.dacpac
, the dacpac
is included with the website content.
Both dacpac
's are included in the package through filePath
provider.
I can see the package contains the dacpac
's together.
On the target directory however, the master.dacpac
is sync'ed correctly, (deleted and then added from package). But the application dacpac
is not sync'ed (in fact, the package is added first and then deleted, effectively loosing the file from target).
All other files of website seems to be unpacking correctly.
回答1:
Based on the comments under the question above I believe your issue is you are syncing the DacPacs to the website root. The website doesn't have those files in its file list so it attempts to remove those files on each sync pass.
Try syncing the DacPacs to a different folder that's not part of the web app path.
This should also fix your other question - MsDeploy synchronization completed in XX pass(es)
来源:https://stackoverflow.com/questions/37751657/msdeploy-sync-not-working