Skip to content

Instantly share code, notes, and snippets.

@JoeM-RP
Last active January 8, 2020 19:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save JoeM-RP/72786b8effc1f86f366105514ce1c866 to your computer and use it in GitHub Desktop.
Save JoeM-RP/72786b8effc1f86f366105514ce1c866 to your computer and use it in GitHub Desktop.
Sample yml file for Gatsby + contentful webpage using Azure Build Pipelines
# Node.js with React
# Build a Node.js project that uses React.
# Add steps that analyze code, save build artifacts, deploy, and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/javascript
trigger:
- master
pool:
vmImage: 'ubuntu-latest'
steps:
- task: NodeTool@0
inputs:
versionSpec: '10.x'
displayName: 'Install Node.js'
- script: |
npm install
CI=true npm run build
displayName: 'gatsby build'
- task: PublishBuildArtifacts@1
inputs:
PathtoPublish: 'public' # public is the name of the default build output folder
ArtifactName: 'src/public' # this can be called anything you like
publishLocation: 'Container'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment