Deploy dacpac as nuget - nuget

I'm trying figuring out how to handle dacpac files as nuget for our solution.
We have a huge database created and handled by a SSDT project that produces a dacpac.
We would like to create a pipeline in DevOps for creating a nuget package from that with a certain version, publishing it to Artifact. So everyone can download it and recreate the database locally.
is that possible?

Related

Deploy SSIS Changes Only through Azure DevOps Pipeline

Recently I created a pipe line in Azure DevOps to deploy the SSIS Package automatically. I was able to complete it successfully but I'm worried weather the complete solution will be deployed every time or just the package which was modified lately. (The way we do through Visual Studio)
Or else we have any option to deploy the changes or deploy the whole.
When I say changes that means only modified object.
My Solution has multiple package but mostly I change only one package at once.

Pipeline on Azure Devops is failing

a month ago we had a solution (big one) in .net framework 4.7.2. This was building fine on azure devops pipeline.
Now we ported our solution to net5.
Everything is working in visual studio but on azure devops, the pipeline is failing.
We had to change our Microsoft.Interop.Word (and excel, and outlook) to a com reference. Because net5 is multiplatform and interop is not.
Because we removed the nuget packages and changed to com reference the pipeline is failing.
Does anyone know how to handle this specific problem?
We can't remove the interop.excel and etc from our projects because they are dependent on it.
Beneath you see the result we have.
It feels like we have tried everything to make it work again on azure devops.
have you consider self-hosted agent since you have requirement to stay the external library in this case Microsoft.Office.Interops and I don't think Microsoft Azure DevOps Pipeline agent support that currently.
With self-hosted agent, you install the PIAs and link your library/com references to the paths.
There is problem with assembly in the code, your code may be building on local environment as it is getting references for all assemblies however when you checking in the code pipelines could not fetch the assemblies through nuget package restore, if you are referencing assembly from local machine, make sure you add its nuget package reference package.config file, so nuget restore will restore the package
can you try below
Link

Azure DevOps Pipeline not downloading reference

I'm relatively new to Azure DevOps, but I've already created 4 other pipelines that are working. I'm running into trouble with a build pipeline that is not pulling in NuGet references. I added the Task NuGet restore, but it's only getting some of the packages.
It works when I build in Visual Studio 2017. If I do a nuget restore from the command line, some of the packages are fetched. When I build, Visual Studio fetches the additional packages at the beginning of the build. Why is the NuGet restore task not fetching all of the packages? Why are the remaining packages fetched during the Visual Studio build, but not during the Azure DevOps build?
My project is old legacy ASP.NET that my boss wants automated. I'm talking the version of ASP.NET with .ASPX files that preceded MVC.
This is the error from the Azure DevOps build:
[error]WebApp\web.config(95,0): Error ASPCONFIG: Could not load file or assembly 'Microsoft.ReportViewer.Common, Version=12.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91' or one of its dependencies. The system cannot find the file specified.
For this issue , first, make sure to select vs2017-win2016 agent when running the pipeline.
Secondly you can try to install the latest nuget.
Another possibility for your issue could be that some packages used by your project is not hosted in nuget.org. If part of the packages used locally are hosted in private server or local package source, the online Nuget Restore Task can't download the mssing packages. Please check your packages.config and project file to make sure all your packages are hosted in nuget.org.

Cake nuget addin problem with Azure Artifacts

We are started migration from TeamCity+Proget to Azure Pipelines and Azure Artifacts. For builds we use cake scripts and it's a part of problem.
In our cake scripts a lot of #addin nuget:?package=My.Private.Package
Unfortunately cake nuget cannot authenticate on Azure Artifacts, which is required by it. #addin is run before other code inside cake scripts, so i cant add any internal authentication.
Also problem is that we are using Hosted Agents.
So my idea is for resolving it, is download nuget packages from Azure Artifacts (with Download Package steps), unzip them (cause its downloaded as zip files), pack again to nupkg files and somehow add to local cache.
So i got few questions:
1. Maybe somebody know better way to resolve authentication problem between cake addin nuget and Azure Artifacts?
2. If not, how to add to local cache nuget packages from .nupkg files on Hosted Agents without adding it to csproj/sln files. (Dev team is totally against it, cause those packages needed for build and not a part of application).
Will be appreciate for any ideas. Thanks

Create NuGet package from folder

I need to package an Azure function app that we've built in TeamCity as a Nuget package for deployment via Octopus Deploy. Standard practice would be to use MSBuild and OctoPack but with Azure Functions this will not work as the function.json files are created after the build is complete and they would therefore not be included in any package that OctoPack creates.
So I need to build first and then create a package from the \bin\Release\net471 folder. Would be grateful to hear peoples opinions on the best way to acheive this?
In the end I went with octo.exe using a start directory of \bin\Release\net471 which saved me having to create a nuspec file as I would have had to if using the NuGet CLI or dotnet pack