Merge pull request #3 from hutte-recipes/test-migration-1710700566 #2
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
# Flxbl CI/CD Template for GitHub | |
#---------------------------------------------------------------------------------------------------- | |
# Follows reference pipeline available at docs.dxatscale.io | |
# | |
#----------------------------------------------------------------------------------------------------- | |
# To know more about Flxbl, visit https://docs.dxatscale.io | |
# To know more on sfp, visit https://docs.flxbl.io/sfp | |
# This pipeline builds on a release branch. | |
# Note: Assumes you've cherry-picked a fix from master (thats been tested in DEV etc). Makes the change available for release. | |
name: Release Build & Publish | |
on: | |
push: | |
branches: | |
- release/** | |
workflow_dispatch: | |
# Set the environment variables for tracking metrics | |
#env: | |
# SFPOWERSCRIPTS_NEWRELIC: 'true' | |
# SFPOWERSCRIPTS_NEWRELIC_API_KEY: '${{ secrets.NEWRELIC_INSIGHT_INSERT_KEYS }}' | |
# SFPOWERSCRIPTS_DATADOG: 'true' | |
# SFPOWERSCRIPTS_DATADOG_HOST: '${{ secrets.DATADOG_HOST }}' | |
# SFPOWERSCRIPTS_DATADOG_API_KEY: '${{ secrets.DATADOG_API_KEY }}' | |
# SFPOWERSCRIPTS_SPLUNK: 'true' | |
# SFPOWERSCRIPTS_SPLUNK_HOST: '${{ secrets.SPLUNK_HOST }}' | |
# SFPOWERSCRIPTS_SPLUNK_API_KEY: '${{ secrets.SPLUNK_API_KEY }}' | |
jobs: | |
buildAndPublish: | |
name: Build and Publish | |
runs-on: ubuntu-latest | |
container: ghcr.io/flxbl-io/sfp | |
concurrency: build | |
if: contains(github.ref,'release') || github.ref == 'refs/heads/release/**' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Authenticate Dev Hub | |
run: | | |
echo "${{ secrets.DEVHUB_SFDX_AUTH_URL }}" > ./authfile | |
sf org login sfdx-url -f authfile -a devhub | |
- name: Create packages | |
id: sfpowerscripts-build | |
run: | | |
# Note: Temporarily disabling --diffcheck for debugging | |
sfp quickbuild --devhubalias devhub --branch ${GITHUB_REF#refs/heads/} --buildnumber ${GITHUB_RUN_ID} --waittime 180 | |
# Publish artifacts | |
- uses: actions/upload-artifact@v2 | |
with: | |
node-version: "16.x" | |
name: build-artifacts | |
path: artifacts | |
- uses: actions/setup-node@v3 | |
with: | |
registry-url: "https://npm.pkg.github.com" | |
scope: "@${{ github.repository_owner }}" | |
- name: Publish | |
run: | | |
sfp publish --artifactdir artifacts --npm --scope @${{ github.repository_owner }} --gittag --pushgittag | |
env: | |
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |