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

Add a Dockerfile that can build the binary too #236

Closed
anuraaga opened this issue May 15, 2020 · 2 comments · Fixed by #256
Closed

Add a Dockerfile that can build the binary too #236

anuraaga opened this issue May 15, 2020 · 2 comments · Fixed by #256
Assignees

Comments

@anuraaga
Copy link
Contributor

anuraaga commented May 15, 2020

Currently, it seems that there is a Dockerfile that can create an image from a binary built on the host machine. It would be nice to have a Dockerfile that can actually build the binary too, for example this one - https://github.com/anuraaga/opentelemetry-collector-contrib/blob/custom/Dockerfile

This way, it's easy to locally build a docker image for master without worrying about tooling using something like docker build -t opentelemetry-collector:test https://github.com/opentelemetry/opentelemetry-collector-contrib.git or similarly for local changes. This can work especially well with docker-compose which will always start up containers after building source without any other steps.

If this seems like a reasonable idea, I can send a PR with the Dockerfile I linked.

@anuraaga
Copy link
Contributor Author

@bogdandrutu @trask Sorry for bugging, wondering if you have any thoughts on this? I'm having to maintain a branch to keep the Dockerfile since it really helps me with integration work between many services and the collector, and think it could help others. Building / running the code from master is how I find bugs :)

In case it helps, here's where I'm using it, and wish it was just the upstream master repo https://github.com/aws-samples/aws-xray-sdk-with-opentelemetry-sample/blob/both-otel-and-xray/docker-compose.yml#L25

@flands
Copy link
Contributor

flands commented May 21, 2020

@anuraaga sounds good -- put up a PR for review

tigrannajaryan pushed a commit that referenced this issue May 28, 2020
…256)

This makes sure that go tooling isn't required to play with a binary built from master. It works particularly well with docker-compose, where you can set the build context to https://github.com/open-telemetry/opentelemetry-collector-contrib.git and always be testing integrations against master with a single command.

**Link to tracking Issue:** fixes #236 

**Testing:** 
docker build / docker run

**Documentation:** Added the docker build command to the README
wyTrivail referenced this issue in mxiamxia/opentelemetry-collector-contrib Jul 13, 2020
…256)

This makes sure that go tooling isn't required to play with a binary built from master. It works particularly well with docker-compose, where you can set the build context to https://github.com/open-telemetry/opentelemetry-collector-contrib.git and always be testing integrations against master with a single command.

**Link to tracking Issue:** fixes #236 

**Testing:** 
docker build / docker run

**Documentation:** Added the docker build command to the README
mxiamxia referenced this issue in mxiamxia/opentelemetry-collector-contrib Jul 22, 2020
ljmsc referenced this issue in ljmsc/opentelemetry-collector-contrib Feb 21, 2022
* init go modules for stackdriver exporter

* add replace rule

* add import to stackdriver example code

* update example/namedtracer/go.sum
jj22ee pushed a commit to jj22ee/opentelemetry-collector-contrib that referenced this issue Oct 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants