Skip to content

Commit

Permalink
chore(release): update go, remove golint, update changelog (#77)
Browse files Browse the repository at this point in the history
* chore(release): update go, remove golint, update changelog
  • Loading branch information
alvarocabanas authored Jun 30, 2022
1 parent 27c858a commit 664f547
Show file tree
Hide file tree
Showing 10 changed files with 29 additions and 1,522 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/prerelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:

env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GO_VERSION: '1.16'
GO_VERSION: '1.18'
INTEGRATION: "haproxy"
ORIGINAL_REPO_NAME: ${{ github.event.repository.full_name }}
REPO_FULL_NAME: ${{ github.event.repository.full_name }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/push_pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ env:
TAG: "v0.0.0" # needed for goreleaser windows builds
REPO_FULL_NAME: ${{ github.event.repository.full_name }}
ORIGINAL_REPO_NAME: "newrelic/nri-haproxy"
GO_VERSION: '1.16'
GO_VERSION: '1.18'
DOCKER_LOGIN_AVAILABLE: ${{ secrets.OHAI_DOCKER_HUB_ID }}

jobs:
Expand Down
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,14 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).

## 2.3.3 (2022-06-29)
### Changed
- Bump dependencies
### Added
Added support for more distributions:
- RHEL(EL) 9
- Ubuntu 22.04

## 2.3.2 (2021-10-20)
### Added
Added support for more distributions:
Expand Down
11 changes: 0 additions & 11 deletions Dockerfile

This file was deleted.

14 changes: 2 additions & 12 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,25 +5,15 @@ INTEGRATION := haproxy
BINARY_NAME = nri-$(INTEGRATION)
GO_PKGS := $(shell go list ./... | grep -v "/vendor/")
GO_FILES := ./src/
GOFLAGS = -mod=readonly
GOLANGCI_LINT = github.com/golangci/golangci-lint/cmd/golangci-lint
GOCOV = github.com/axw/gocov/gocov
GOCOV_XML = github.com/AlekSi/gocov-xml

all: build

build: clean validate test compile
build: clean test compile

clean:
@echo "=== $(INTEGRATION) === [ clean ]: Removing binaries and coverage file..."
@rm -rfv bin coverage.xml

validate:
@printf "=== $(INTEGRATION) === [ validate ]: running golangci-lint & semgrep... "
@go run $(GOFLAGS) $(GOLANGCI_LINT) run --verbose
@[ -f .semgrep.yml ] && semgrep_config=".semgrep.yml" || semgrep_config="p/golang" ; \
docker run --rm -v "${PWD}:/src:ro" --workdir /src returntocorp/semgrep -c "$$semgrep_config"

compile:
@echo "=== $(INTEGRATION) === [ compile ]: Building $(BINARY_NAME)..."
@go build -o bin/$(BINARY_NAME) $(GO_FILES)
Expand All @@ -41,4 +31,4 @@ integration-test:
include $(CURDIR)/build/ci.mk
include $(CURDIR)/build/release.mk

.PHONY: all build clean validate compile test integration-test
.PHONY: all build clean compile test integration-test
8 changes: 0 additions & 8 deletions build/ci.mk
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,6 @@ ci/debug-container: ci/deps
-e GPG_PRIVATE_KEY_BASE64 \
$(BUILDER_TAG) bash

.PHONY : ci/validate
ci/validate: ci/deps
@docker run --rm -t \
--name "nri-$(INTEGRATION)-validate" \
-v $(CURDIR):/go/src/github.com/newrelic/nri-$(INTEGRATION) \
-w /go/src/github.com/newrelic/nri-$(INTEGRATION) \
$(BUILDER_TAG) make validate

.PHONY : ci/test
ci/test: ci/deps
@docker run --rm -t \
Expand Down
14 changes: 11 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,10 +1,18 @@
module github.com/newrelic/nri-haproxy

go 1.16
go 1.18

require (
github.com/golangci/golangci-lint v1.46.2
github.com/newrelic/infra-integrations-sdk v3.7.1+incompatible
github.com/newrelic/infra-integrations-sdk v3.7.3+incompatible
github.com/stretchr/testify v1.7.1
github.com/xeipuuv/gojsonschema v1.2.0
)

require (
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb // indirect
github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415 // indirect
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b // indirect
)
1,483 changes: 5 additions & 1,478 deletions go.sum

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion tests/integration/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.16 as builder
FROM golang:1.18 as builder
ARG CGO_ENABLED=0
WORKDIR /go/src/github.com/newrelic/nri-haproxy
COPY . .
Expand Down
7 changes: 0 additions & 7 deletions tools/tools.go

This file was deleted.

0 comments on commit 664f547

Please sign in to comment.