Skip to content

Update stanza validation in resource_splunk_configs_conf.go #354

Update stanza validation in resource_splunk_configs_conf.go

Update stanza validation in resource_splunk_configs_conf.go #354

Workflow file for this run

name: test
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
workflow_dispatch:
jobs:
build:
name: Build and test
runs-on: ubuntu-latest
services:
splunk:
image: splunk/splunk:latest
env:
SPLUNK_START_ARGS: --accept-license
SPLUNK_PASSWORD: password
ports:
- 8000:8000
- 8089:8089
volumes:
- ${{ github.workspace }}:/workspace
steps:
- name: Set up Go 1.x
uses: actions/[email protected]
with:
go-version: ^1.22
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v3
- name: Get dependencies
run: |
go get -v -t -d ./...
if [ -f Gopkg.toml ]; then
curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
dep ensure
fi
- name: Build
run: go build -v .
- name: Set up Terraform 1.1.7
uses: hashicorp/setup-terraform@v3
with:
terraform_version: "1.1.7"
- name: Terraform init
run: terraform -chdir=terraform init
- name: Terraform apply
run: terraform -chdir=terraform apply --auto-approve
- name: Test
run: TF_ACC=1 SPLUNK_HOME=/opt/splunk SPLUNK_URL=localhost:8089 SPLUNK_USERNAME=admin SPLUNK_PASSWORD=password go test ./... -v