forked from open-telemetry/opentelemetry-collector-contrib
-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add opentelemetry-collector-builder with Makefile and Github Action t…
…o build on PR (#1300)
- Loading branch information
1 parent
44bb259
commit cf09a91
Showing
4 changed files
with
86 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
name: OpenTelemetry Collector Builder | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
# otelcolbuilder_post_go1_16: | ||
# runs-on: ubuntu-20.04 | ||
# strategy: | ||
# matrix: | ||
# go: [ '1.16' ] | ||
# steps: | ||
# - uses: actions/checkout@v2 | ||
# - name: Setup go | ||
# uses: actions/setup-go@v2 | ||
# with: | ||
# go-version: ${{ matrix.go }} | ||
# - name: Print go version | ||
# run: go version | ||
# - name: Build OpenTelemetry distro | ||
# working-directory: ./otelcolbuilder/ | ||
# run: | | ||
# go install github.com/open-telemetry/opentelemetry-collector-builder@v0.24.0 | ||
# make build | ||
|
||
# Just build on 1.15 for now because of a weird issue: | ||
# https://github.com/actions/setup-go/issues/107 | ||
otelcolbuilder_pre_go1_16: | ||
runs-on: ubuntu-20.04 | ||
strategy: | ||
matrix: | ||
go: [ '1.15' ] | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Setup go | ||
uses: actions/setup-go@v2 | ||
with: | ||
go-version: ${{ matrix.go }} | ||
- name: Print go version | ||
run: go version | ||
- name: Print go env | ||
run: go env | ||
- name: Build OpenTelemetry distro | ||
working-directory: ./otelcolbuilder/ | ||
run: | | ||
make install-prego1.16 | ||
make build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
cmd/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
dist: | ||
name: otelcol-sumo | ||
description: Sumo Logic OpenTelemetry Collector distribution | ||
|
||
# the module name for the new distribution, following Go mod conventions. Optional, but recommended. | ||
module: github.com/SumoLogic/opentelemetry-collector-builder | ||
|
||
otelcol_version: 0.24.0 # the OpenTelemetry Collector version to use as base for the distribution. | ||
output_path: ./cmd/ # the path to write the output (sources and binary). | ||
|
||
processors: | ||
- gomod: "github.com/open-telemetry/opentelemetry-collector-contrib/processor/cascadingfilterprocessor v0.24.0" | ||
- gomod: "github.com/open-telemetry/opentelemetry-collector-contrib/processor/k8sprocessor v0.24.0" | ||
- gomod: "github.com/open-telemetry/opentelemetry-collector-contrib/processor/sourceprocessor v0.24.0" | ||
|
||
exporters: | ||
- gomod: "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/sumologicexporter v0.24.0" | ||
|
||
# Replacement paths are relative to the output_path (location of source files) | ||
replaces: | ||
- github.com/open-telemetry/opentelemetry-collector-contrib/processor/cascadingfilterprocessor => ./../../processor/cascadingfilterprocessor | ||
|
||
- github.com/open-telemetry/opentelemetry-collector-contrib/processor/k8sprocessor => ./../../processor/k8sprocessor | ||
- github.com/open-telemetry/opentelemetry-collector-contrib/internal/k8sconfig => ./../../internal/k8sconfig | ||
|
||
- github.com/open-telemetry/opentelemetry-collector-contrib/processor/sourceprocessor => ./../../processor/sourceprocessor | ||
|
||
- go.opentelemetry.io/collector => github.com/SumoLogic/opentelemetry-collector v0.24.0-sumo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
install: | ||
go install github.com/open-telemetry/opentelemetry-collector-builder@v0.24.0 | ||
|
||
install-prego1.16: | ||
GO111MODULE=on go get github.com/open-telemetry/opentelemetry-collector-builder@v0.24.0 | ||
|
||
build: | ||
opentelemetry-collector-builder --config .otelcol-builder.yaml |