Created
January 2, 2020 14:00
-
-
Save zloeber/777c345d69998f054a78e076860e5d02 to your computer and use it in GitHub Desktop.
hugo multi-provider publish with azure devops
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: $(BuildDefinitionName).$(DayOfYear)$(Rev:.r) | |
trigger: | |
batch: true | |
branches: | |
include: | |
- master | |
- develop | |
# Don't trigger on PRs | |
pr: none | |
resources: | |
repositories: | |
- repository: pipelines | |
type: github | |
endpoint: github_services | |
name: zloeber/azure-pipeline-library | |
stages: | |
## Build Hugo site (DEV) | |
- ${{ if eq(variables['Build.SourceBranch'], 'refs/heads/develop') }}: | |
- template: build/hugo-generate.yml@pipelines | |
parameters: | |
initialize: true | |
baseurl: 'https://zacharyloeber-dev.onrender.com/' | |
testhtml: 'false' | |
staticpath: './docs' | |
contentpath: './content' | |
drafts: 'true' | |
- template: deploy/git-folder.yml@pipelines | |
parameters: | |
repo: 'https://github.com/zloeber/dev.zacharyloeber.com-content.git' | |
branch: 'master' | |
path: 'docs' | |
environment: 'dev' | |
## Build Hugo site (PROD) | |
- ${{ if eq(variables['Build.SourceBranch'], 'refs/heads/master') }}: | |
- template: build/hugo-generate.yml@pipelines | |
parameters: | |
initialize: true | |
site: 'zacharyloeber.com' | |
baseurl: 'https://zacharyloeber.com/' | |
staticpath: 'docs' | |
contentpath: './content' | |
testhtml: 'false' | |
- template: deploy/git-folder.yml@pipelines | |
parameters: | |
repo: 'https://github.com/zloeber/zacharyloeber.com-content.git' | |
branch: 'master' | |
path: 'docs' | |
environment: 'production' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment