Splunk AppDynamics

Golang inside of docker

David_Boardman
Explorer

I'm working through how to build a golang program instrumented with AppDynamics running inside a docker container.

Anyone done this?  I'm encountering problems when the final build is complete - so I'm curious what distro you used to build from.

Labels (1)
Tags (1)
0 Karma
1 Solution

David_Boardman
Explorer

I got this working, although my "solution" was quite a bit contorted.  The thing I had to do was to manually copy some of the shared-libraries into the docker image.  See the following two lines referencing "shared libraries".  Specifically in my './lib/' directory I have libgcc_s.so.1 and libstdc++.so.6.  These I got from a stock Ubuntu:14.04 version and copied them into my build directory.

On top of this I had to manually copy the AppDynamics shared-library inside the container also (see Dockerfile below).

---------------------

Here's my Dockerfile:

FROM busybox:ubuntu-14.04

 

# Add the binary

COPY src/app/bubbagump /app/bubbagump

 

# Copy in supporting shared libraries (ripped from Ubuntu (vagrant) )

COPY lib/ /lib

 

# Copy AppDynamics shared library

COPY src/appdynamics/sdk_lib/lib/libappdynamics.so /lib/

 

# Copy in the certificate file

 

COPY src/appdynamics/ca-bundle.crt /app/

 

WORKDIR /app

  

CMD ["/app/bubbagump"]

View solution in original post

0 Karma

Kyle_Furlong
Contributor

Hi David,

Could you share your build process and the errors you're encountering?

Thanks,

Kyle

0 Karma

David_Boardman
Explorer

I got this working, although my "solution" was quite a bit contorted.  The thing I had to do was to manually copy some of the shared-libraries into the docker image.  See the following two lines referencing "shared libraries".  Specifically in my './lib/' directory I have libgcc_s.so.1 and libstdc++.so.6.  These I got from a stock Ubuntu:14.04 version and copied them into my build directory.

On top of this I had to manually copy the AppDynamics shared-library inside the container also (see Dockerfile below).

---------------------

Here's my Dockerfile:

FROM busybox:ubuntu-14.04

 

# Add the binary

COPY src/app/bubbagump /app/bubbagump

 

# Copy in supporting shared libraries (ripped from Ubuntu (vagrant) )

COPY lib/ /lib

 

# Copy AppDynamics shared library

COPY src/appdynamics/sdk_lib/lib/libappdynamics.so /lib/

 

# Copy in the certificate file

 

COPY src/appdynamics/ca-bundle.crt /app/

 

WORKDIR /app

  

CMD ["/app/bubbagump"]

0 Karma
Get Updates on the Splunk Community!

Splunk Observability Synthetic Monitoring - Resolved Incident on Detector Alerts

We’ve discovered a bug that affected the auto-clear of Synthetic Detectors in the Splunk Synthetic Monitoring ...

Video | Tom’s Smartness Journey Continues

Remember Splunk Community member Tom Kopchak? If you caught the first episode of our Smartness interview ...

3-2-1 Go! How Fast Can You Debug Microservices with Observability Cloud?

3-2-1 Go! How Fast Can You Debug Microservices with Observability Cloud? Learn how unique features like ...