Skip to content

feat: initial setup

feat: initial setup #8

Workflow file for this run

name: Preview
on:
pull_request:
branches:
- main
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Update apt index
run: sudo apt-get update
- name: Install cloud-init
run: sudo apt-get install -y cloud-init
- name: Lint cloud-init file
run: |
if ! cloud-init schema -c cloud-init.yaml 2> >(tee stderr.log) >> $GITHUB_STEP_SUMMARY
then
# Print errors as such in GitHub logs.
cat stderr.log | grep "in.*line.*column" -A1 --no-group-separator | sed -z 's/in "\([^"]*\)", line \([[:digit:]]\+\), column \([[:digit:]]\+\):\s*/::error file=cloud-init.yaml,title=\1,line=\2,col=\3::/g'
exit 1
fi
preview:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
- name: Install dependencies
run: go get .
- name: Build
run: go build -v ./...
- uses: pulumi/actions@v6
with:
command: preview
stack-name: holochain/nomad-server
comment-on-pr: true
diff: true
github-token: ${{ secrets.HRA2_GITHUB_TOKEN }}
env:
PULUMI_ACCESS_TOKEN: ${{ secrets.HRA2_PULUMI_ACCESS_TOKEN }}
ci_pass:
if: always()
needs:
- lint
- preview
runs-on: Ubuntu-latest
steps:
- name: Decide whether the required jobs succeeded or failed
uses: re-actors/alls-green@release/v1
with:
jobs: ${{ toJSON(needs) }}