在我运行任何其他任务 dist 文件夹之前,构建过程中生成的文件夹似乎已被删除。
trigger:
- master
pool: default
steps:
- task: NodeTool@0
inputs:
versionSpec: '10.x'
displayName: 'Install Node.js'
- script: |
npm install -g @angular/cli
npm install
ng build --prod
displayName: 'npm install and build'
#i added this task and it seems like the node_modules and the dist
#folder that was generated during the build are not getting copied to the (a)directory
#only the source code get copied. it seems like the folders are getting
#deleted even before the #PublishPipelineArtifact@1 …Run Code Online (Sandbox Code Playgroud) 我正在尝试授予应用程序访问数据库的权限。其中一个步骤要求必须在数据库上运行创建用户的脚本。我通过 azureSqlAzureDacpacDeployment@1 任务的管道执行此操作。
使用托管标识保护来自应用服务的 Azure SQL 数据库连接
- task: SqlAzureDacpacDeployment@1
inputs:
azureSubscription: 'xxxxxxxx (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)'
AuthenticationType: 'aadAuthenticationIntegrated'
ServerName: '$(SqlServerName)'
DatabaseName: '$(SqlDatabaseName)'
deployType: 'InlineSqlTask'
SqlInline: |
CREATE USER [$(AppName)] FROM EXTERNAL PROVIDER;
ALTER ROLE db_datareader ADD MEMBER [$(AppName)];
ALTER ROLE db_datawriter ADD MEMBER [$(AppName)];
GO
InlineAdditionalArguments: '-v $(ApiAppName)'
IpDetectionMethod: 'AutoDetect'
ApiAppName = 'AppName=MyApplication'
##[error]The format used to define the new variable for Invoke-Sqlcmd cmdlet is invalid.
Please use the 'var=value' format for defining a new variable.Check out how to troubleshoot
failures at …Run Code Online (Sandbox Code Playgroud) azure azure-sql-database azure-devops azure-pipelines azure-managed-identity