Skip to content

Implement setting bandwidth_limit on a servers network interface #604

Implement setting bandwidth_limit on a servers network interface

Implement setting bandwidth_limit on a servers network interface #604

Workflow file for this run

name: Code quality
on:
push:
branches:
- main
pull_request:
branches:
- main
types:
- opened
- synchronize
- reopened
- ready_for_review
workflow_dispatch: {}
env:
GO_VERSION: 1.21
jobs:
docs-lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: ${{env.GO_VERSION}}
- name: Check for spelling errors
run: make misspell
- name: Check HCL format
run: make terrafmt
code-lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: ${{env.GO_VERSION}}
- name: Check code format
run: make fmtcheck
- name: Lint code
run: make go-lint
dependencies:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: ${{env.GO_VERSION}}
- name: run depscheck
run: make depscheck
unit-tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: ${{env.GO_VERSION}}
- name: run unit tests
run: make test
integration-tests:
if: ${{ ! github.event.pull_request.draft && github.actor != 'dependabot[bot]' }}
runs-on: ubuntu-latest
needs: unit-tests
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: ${{env.GO_VERSION}}
- name: run integration tests and post coverage to codeclimate
uses: paambaati/[email protected]
env:
ANEXIA_LOCATION_ID: 52b5f6b2fd3a4a7eaaedf1a7c019e9ea
ANEXIA_VLAN_ID: 00a239d617504e4ab49122efe0d27657
ANEXIA_TOKEN: ${{ secrets.ANEXIA_TOKEN }}
CC_TEST_REPORTER_ID: ${{ secrets.CODECLIMATE_COVERAGE_ID }}
# poor girls ternary operator
TESTARGS: ${{ (github.ref_type != 'tag' && github.ref_name != 'main') && '-short' || '' }}
with:
prefix: github.com/anexia-it/terraform-provider-anxcloud
coverageCommand: make testacc
coverageLocations: coverage.out:gocov