Skip to content

Allow creating devices without build api credentials #101

Allow creating devices without build api credentials

Allow creating devices without build api credentials #101

name: Build and test
on: [pull_request, push]
jobs:
build-test:
runs-on: ubuntu-latest
strategy:
matrix:
go-version: ['1.19.0']
steps:
- name: Checkout repository
uses: actions/checkout@a81bbbf8298c0fa03ea29cdc473d45769f953675 # aka v2
- name: Install dependencies
uses: actions/setup-go@v3
with:
go-version: ${{ matrix.go-version }}
- run: go version
- name: Build
run: go build ./...
- name: Test
run: go test -v -coverprofile=coverage.out ./...
- name: Check format
run: if [ "$(gofmt -s -l . | wc -l)" -gt 0 ]; then exit 1; fi
build-test-debian-package:
runs-on: ubuntu-latest
strategy:
matrix:
go-version: ['1.19.0']
container:
image: debian@sha256:6a8bad8d20e1ca5ecbb7a314e51df6fca73fcce19af2778550671bdd1cbe7b43 # aka stable-20211011
steps:
- name: setup apt
run: apt update -y && apt upgrade -y
- name: Checkout repository
uses: actions/checkout@a81bbbf8298c0fa03ea29cdc473d45769f953675 # aka v2
- name: Install dependencies
uses: actions/setup-go@v3
with:
go-version: ${{ matrix.go-version }}
- name: install debuild dependencies
run: apt install -y git devscripts config-package-dev debhelper-compat golang
- name: Build
run: cd build/package && dpkg-buildpackage -i -uc -us -b
- name: Install cvdremote debian package
run: dpkg -i build/cvdremote_*_*64.deb || apt-get install -f -y