Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move opentelemetry-collector-builder to core #4286

Merged
merged 42 commits into from
Oct 28, 2021
Merged
Show file tree
Hide file tree
Changes from 41 commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
d402d9a
Initial commit
Jan 27, 2021
3c1dd9e
Add CODEOWNERS file (#2)
bogdandrutu Jan 29, 2021
fb510a9
Moved from github.com/observatorium/opentelemetry-collector-builder (#3)
jpkrohling Feb 2, 2021
fdf9416
fixed panics (#6)
joe-elliott Feb 11, 2021
40a858e
Replace master with main in CI and mergify files (#8)
jpkrohling Feb 11, 2021
1da8f73
Bump to OpenTelemetry Collector 0.20.0 (#10)
jpkrohling Feb 11, 2021
f29b566
Explicitly enable Go modules in quickstart instructions (#13)
jiwen624 Mar 3, 2021
409ad94
Update to collector v0.21.0 (#17)
jpkrohling Mar 9, 2021
c9fe696
Update to collector v0.22.0 (#19)
Mar 11, 2021
7c67d1e
Download go modules before building (#20)
Mar 15, 2021
a6b22d3
Add version command (#25)
Ashmita152 Mar 22, 2021
5b9df7b
Pass errors from cobra Execute back to main for correct exit code (#28)
Mar 30, 2021
3d80039
Update to collector v0.23.0 (#27)
Mar 30, 2021
8ad7683
Generate a warning if the builder and collector base version mismatch…
fangyi-zhou Apr 6, 2021
35f8b0d
Update to OpenTelemetry Collector 0.24.0
crearys Apr 13, 2021
bd48b7d
Don't use %w formatting with log.Fatal (#35)
pmalek-sumo Apr 15, 2021
4056de9
Update to OpenTelemetry Collector 0.25.0 (#36)
secat Apr 21, 2021
fe3af5d
Update to 0.26.0 and update BuildInfo (#39)
crearys May 10, 2021
4f061ca
Sync build and CI Go versions at latest 1.16 (#34)
sodabrew May 11, 2021
5b5d3fb
Add option to generate go code only (no compile) (#40)
May 12, 2021
d8500e6
Don't reuse exec.Cmd (#42)
pmalek May 18, 2021
7e4aa7f
Update to OpenTelemetry Collector 0.27.0 (#43)
sodabrew May 19, 2021
78e8560
Add CI Badge (#47)
KKelvinLo May 26, 2021
16563b6
Update to Collector v0.28.0 (#49)
fangyi-zhou Jun 24, 2021
a468961
Account for go mod download in go1.17 not updating go.sum (#50)
pmalek Jun 24, 2021
9225b86
Update to collector v0.29.0 (#54)
himanshu007-creator Jun 25, 2021
4afd918
Update to collector v0.30.0 (#57)
u5surf Jul 15, 2021
c50c477
cmd: fix module flag default value to github.com/open-telemetry (#58)
zchee Jul 19, 2021
f6a5144
Update to collector v0.31.0 (#60)
crearys Aug 3, 2021
10e9c07
Update to v0.33.0 (#62)
Aneurysm9 Aug 25, 2021
6689c36
Add excludes support to generated go.mod (#63)
Aneurysm9 Aug 25, 2021
08d2c20
Small cleanup for the builder files (#64)
bogdandrutu Sep 1, 2021
5bb4137
Support building with Go 1.17 (#66)
jpkrohling Sep 1, 2021
5ada61a
Update to OpenTelemetry core 0.34.0 (#68)
jpkrohling Sep 2, 2021
eb82ae4
Upgrade to OpenTelemetry Collector 0.35.0 (#70)
fangyi-zhou Sep 14, 2021
0e65d95
Upgrade to OpenTelemetry Collector 0.36.0 (#76)
pmalek Oct 1, 2021
9a77f1b
Generate custom service code for Windows (#75)
loomis-relativity Oct 13, 2021
a9f8085
Remove Core from Module type (#77)
u5surf Oct 14, 2021
e3470e7
release 0.37.0 (#78)
Oct 15, 2021
075d83a
Move builder to subdirectory
jpkrohling Oct 28, 2021
c7b2497
Merge remote-tracking branch 'builder/jpkrohling/move-to-subdirectory…
jpkrohling Oct 28, 2021
f2e9137
Merge branch 'main' into jpkrohling/move-builder
bogdandrutu Oct 28, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions builder/.github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#####################################################
#
# List of approvers for OpenTelemetry Collector Builder
#
#####################################################
#
# Learn about membership in OpenTelemetry community:
# https://github.com/open-telemetry/community/blob/master/community-membership.md
#
#
# Learn about CODEOWNERS file format:
# https://help.github.com/en/articles/about-code-owners
#

* @open-telemetry/collector-approvers @open-telemetry/collector-builder-approvers
19 changes: 19 additions & 0 deletions builder/.github/mergify.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
pull_request_rules:
- name: remove outdated reviews
conditions:
- base=main
actions:
dismiss_reviews: {}

- name: Automatic merge when all checks pass and the PR is approved
conditions:
- "#approved-reviews-by>=1"
- "-draft"
- "status-success=Unit tests"
- "status-success=Code standards (linting)"
- "status-success=Security"
- "status-success=Integration test"
actions:
merge:
method: squash
commit_message: title+body
56 changes: 56 additions & 0 deletions builder/.github/workflows/go.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: "Continuous Integration"

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

jobs:
unit-tests:
name: Unit tests
runs-on: ubuntu-20.04
steps:

- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.17

- name: Check out code into the Go module directory
uses: actions/checkout@v2

- name: Test
run: go test -v ./...

lint:
name: Code standards (linting)
runs-on: ubuntu-20.04
steps:
- name: Check out code into the Go module directory
uses: actions/checkout@v2

- name: Lint
uses: golangci/golangci-lint-action@v2
with:
version: v1.29
args: --enable=gosec,maligned,misspell
only-new-issues: true

security:
name: Security
runs-on: ubuntu-20.04
steps:
- name: Check out code into the Go module directory
uses: actions/checkout@v2

- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: go

- name: Autobuild
uses: github/codeql-action/autobuild@v1

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
24 changes: 24 additions & 0 deletions builder/.github/workflows/integration-test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Integration tests

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

jobs:
integration-test:
name: Integration test
runs-on: ubuntu-20.04
steps:

- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.17

- name: Check out code into the Go module directory
uses: actions/checkout@v2

- name: Test
run: ./test/test.sh
29 changes: 29 additions & 0 deletions builder/.github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: goreleaser

on:
push:
tags:
- 'v*'

jobs:
goreleaser:
runs-on: ubuntu-20.04
steps:
-
name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
-
name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.17
-
name: Run GoReleaser
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: release --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
40 changes: 40 additions & 0 deletions builder/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@

# Created by https://www.toptal.com/developers/gitignore/api/go,vscode
# Edit at https://www.toptal.com/developers/gitignore?templates=go,vscode

### Go ###
# Binaries for programs and plugins
*.exe
*.exe~
*.dll
*.so
*.dylib

# Test binary, built with `go test -c`
*.test

# Output of the go coverage tool, specifically when used with LiteIDE
*.out

# Dependency directories (remove the comment below to include it)
# vendor/

### Go Patch ###
/vendor/
/Godeps/

### vscode ###
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
*.code-workspace

### goland ###
.idea

# End of https://www.toptal.com/developers/gitignore/api/go,vscode

/dist/
opentelemetry-collector-builder
18 changes: 18 additions & 0 deletions builder/.golangci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# all available settings of specific linters
linters-settings:
goheader:
template-path: header.txt
goimports:
local-prefixes: github.com/open-telemetry/opentelemetry-collector-builder
maligned:
suggest-new: true
misspell:
locale: US

linters:
enable:
- goheader
- goimports
- maligned
- misspell
- gosec
33 changes: 33 additions & 0 deletions builder/.goreleaser.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
before:
hooks:
- go mod download
builds:
- flags:
- -trimpath
ldflags:
- -s -w -X github.com/open-telemetry/opentelemetry-collector-builder/cmd.version={{.Version}} -X github.com/open-telemetry/opentelemetry-collector-builder/cmd.date={{.Date}}
env:
- CGO_ENABLED=0
goos:
- linux
- windows
- darwin
goarch:
- amd64
- arm
- arm64
goarm:
- 6
- 7
archives:
- format: binary
checksum:
name_template: "checksums.txt"
snapshot:
name_template: "{{ .Tag }}-next"
changelog:
sort: asc
filters:
exclude:
- "^docs:"
- "^test:"
Loading