Skip to content

Instantly share code, notes, and snippets.

@Marusyk

Marusyk/pipeline.yml

Created Nov 27, 2018
Embed
What would you like to do?
Build definiton for run tests of your containers in Azure DevOps (VSTS)
resources:
- repo: self
queue:
name: Default
steps:
- task: DockerCompose@0
displayName: 'Build images'
inputs:
dockerComposeFile: 'docker-compose.yml'
action: 'Build services'
additionalImageTags: '$(Build.BuildId)'
includeLatestTag: true
- task: DockerCompose@0
displayName: 'Run unit tests'
inputs:
dockerComposeFile: 'docker-compose.yml'
additionalDockerComposeFiles: 'docker-compose.override.yml'
action: 'Run a specific service'
serviceName: 'webapplication-tests'
detached: false
- task: PublishTestResults@2
displayName: 'Publish Test Results'
inputs:
testResultsFormat: VSTest
testResultsFiles: '*.trx'
searchFolder: '$(Build.ArtifactStagingDirectory)'
condition: succeededOrFailed()
- task: DockerCompose@0
displayName: 'Push images'
inputs:
additionalDockerComposeFiles: '**/docker-compose.override.yml'
action: 'Push services'
additionalImageTags: '$(Build.BuildId)'
enabled: false
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.