Skip to content
Merged
Show file tree
Hide file tree
Changes from 24 commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
b208eaa
mount /var/lib/better-stack
paweljw Nov 4, 2025
4cde3f3
adjust paths, build images without most files
paweljw Nov 4, 2025
f185c0a
bootstrap script
paweljw Nov 4, 2025
26d0ea1
bootstrapping container
paweljw Nov 4, 2025
0838fef
reload supervisorctl config on bootstrap
paweljw Nov 5, 2025
9db2e18
solve manifest processor managing beyla supervisor
paweljw Nov 5, 2025
373b293
add manifest processor (in-band first for testing)
paweljw Nov 5, 2025
a2fe878
solve issues with bootstrapper
paweljw Nov 5, 2025
da706e0
fixes
paweljw Nov 5, 2025
bde5acb
order of operations
paweljw Nov 5, 2025
3634b12
move files from beyla/
paweljw Nov 5, 2025
0e43751
move files from dockerprobe/
paweljw Nov 5, 2025
97ab13c
move files from engine/
paweljw Nov 5, 2025
b64c09f
move mdprobe, vector.sh, default enrichment tables
paweljw Nov 5, 2025
0f95434
move certbot
paweljw Nov 5, 2025
2754365
final removals
paweljw Nov 5, 2025
5bb15cb
drop mdprobe
paweljw Nov 5, 2025
3c50dbd
bump COLLECTOR_VERSION to 1.1.0
paweljw Nov 5, 2025
e4aee50
move healthcheck.sh
paweljw Nov 5, 2025
7b1edc2
remove ruby tests GH action
paweljw Nov 5, 2025
3768f8c
adjust seccomp docker-compose file
paweljw Nov 5, 2025
a167eb1
adjust seccomp docker-compose file
paweljw Nov 5, 2025
5140f01
remote beyla config
paweljw Nov 5, 2025
c23a44f
remove last of beyla's config from container
paweljw Nov 5, 2025
9fa2986
reorganize
paweljw Nov 6, 2025
aca33bf
fix
paweljw Nov 6, 2025
722f5ad
fix GHA
paweljw Nov 6, 2025
6ccb3dd
fix GHA
paweljw Nov 6, 2025
1b8a3db
fix GHA
paweljw Nov 6, 2025
da6d4b7
fix bootstrap
paweljw Nov 6, 2025
e4c1ea0
use coroot node agent 1.27.0 (fixes uretprobe crashes)
paweljw Nov 7, 2025
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
Original file line number Diff line number Diff line change
Expand Up @@ -8,27 +8,6 @@ on:
workflow_dispatch:

jobs:
test:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '3.2'
bundler-cache: true # runs 'bundle install' and caches installed gems automatically

- name: Install dependencies
run: bundle install

- name: Run tests
run: bundle exec rake test

- name: Validate Docker compose build
run: docker compose build --no-cache

# The diff is expected to be:
# 8a9,10
# > security_opt:
Expand Down
29 changes: 6 additions & 23 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,6 @@ RUN apt-get update && apt-get install -y \
COPY --from=vector --chmod=755 /usr/bin/vector /usr/local/bin/vector
COPY --from=vector /etc/vector /etc/vector

# Copy mdprobe
COPY mdprobe /mdprobe

# Create necessary directories
RUN mkdir -p /versions/0-default \
&& mkdir -p /etc/supervisor/conf.d \
Expand All @@ -36,7 +33,7 @@ RUN mkdir -p /versions/0-default \
# Set environment variables
ENV BASE_URL=https://telemetry.betterstack.com
ENV CLUSTER_COLLECTOR=false
ENV COLLECTOR_VERSION=1.0.40
ENV COLLECTOR_VERSION=1.1.0
ENV VECTOR_VERSION=0.47.0
ENV BEYLA_VERSION=2.7.5
ENV CLUSTER_AGENT_VERSION=1.2.4
Expand All @@ -54,28 +51,14 @@ ENV CLUSTER_AGENT_VERSION=1.2.4
# This is considered a best practice when running multi-process containers with Tini as the init system.
ENV TINI_SUBREAPER=true

# Copy supervisor configuration
COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf
# Copy bootstrap supervisor configuration and necessary initialization scripts
COPY bootstrap_supervisord.conf /bootstrap/supervisord.conf
COPY --chmod=755 bootstrap.sh /bootstrap.sh
COPY --chmod=755 run_supervisord.sh /run_supervisord.sh

# Copy Ruby scripts
COPY --chmod=755 updater.rb /updater.rb
COPY --chmod=755 proxy.rb /proxy.rb
COPY --chmod=755 vector.sh /vector.sh
COPY --chmod=755 healthcheck.sh /healthcheck.sh
COPY --chmod=755 certbot-runner.sh /certbot-runner.sh
COPY --chmod=755 certbot-deploy-hook.sh /certbot-deploy-hook.sh
COPY versions/0-default/vector.yaml /versions/0-default/vector.yaml
COPY versions/0-default/databases.json /versions/0-default/databases.json
COPY kubernetes-discovery/0-default/discovered_pods.yaml /kubernetes-discovery/0-default/discovered_pods.yaml
COPY engine /engine
COPY --chmod=755 ebpf.sh /ebpf.sh
# Copy default enrichment files to both locations
# /enrichment-defaults is the source for copying at runtime
# /enrichment is for Kubernetes compatibility, since it's volume mounts work differently from compose/swarm
COPY dockerprobe/docker-mappings.default.csv /enrichment-defaults/docker-mappings.csv
COPY dockerprobe/databases.default.csv /enrichment-defaults/databases.csv
COPY dockerprobe/docker-mappings.default.csv /enrichment/docker-mappings.csv
COPY dockerprobe/databases.default.csv /enrichment/databases.csv

# Create initial vector-config with symlinks to defaults
RUN mkdir -p /vector-config/0-default \
Expand All @@ -90,4 +73,4 @@ RUN mkdir -p /vector-config/0-default \
ENTRYPOINT ["/usr/bin/tini", "-s", "--"]

# Start supervisor
CMD ["/usr/bin/supervisord", "-c", "/etc/supervisor/conf.d/supervisord.conf"]
CMD ["/run_supervisord.sh"]
16 changes: 4 additions & 12 deletions Dockerfile.beyla
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ RUN apt-get update && \
rm -rf /var/lib/apt/lists/*

# Create necessary directories
RUN mkdir -p /etc/supervisor/conf.d /var/log/supervisor /enrichment
RUN mkdir -p /etc/supervisor/conf.d /var/log/supervisor /enrichment /bootstrap

# Copy Beyla files from official image and set permissions
COPY --from=beyla-source --chmod=755 /beyla /usr/local/bin/beyla
Expand All @@ -37,16 +37,8 @@ COPY --from=node-agent --chmod=755 /usr/bin/coroot-node-agent /usr/local/bin/nod
# Copy Cluster Agent
COPY --from=cluster-agent --chmod=755 /usr/bin/coroot-cluster-agent /usr/local/bin/cluster-agent

# Copy Ruby dockerprobe implementation to working directory
COPY dockerprobe /dockerprobe

# Copy configuration files
COPY beyla/supervisord.conf /etc/supervisor/conf.d/supervisord.conf
COPY --chmod=755 beyla/entrypoint.sh /entrypoint.sh
COPY --chmod=755 beyla/cluster-collector.sh /cluster-collector.sh

# Copy Beyla configuration
COPY beyla.yaml /etc/beyla/beyla.yaml
COPY beyla/bootstrap_supervisord.conf /bootstrap/supervisord.conf
COPY --chmod=755 beyla/run_supervisord.sh /run_supervisord.sh

# Default command
CMD ["/entrypoint.sh"]
CMD ["/run_supervisord.sh"]
10 changes: 0 additions & 10 deletions Gemfile

This file was deleted.

44 changes: 0 additions & 44 deletions Gemfile.lock

This file was deleted.

9 changes: 0 additions & 9 deletions Rakefile

This file was deleted.

55 changes: 0 additions & 55 deletions beyla.yaml

This file was deleted.

13 changes: 13 additions & 0 deletions beyla/bootstrap_supervisord.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[supervisord]
nodaemon=true
logfile=/var/log/supervisor/supervisord.log
loglevel=info

[unix_http_server]
file=/beyla_supervisor_socket/supervisor.sock

[supervisorctl]
serverurl=unix:///beyla_supervisor_socket/supervisor.sock

[rpcinterface:supervisor]
supervisor.rpcinterface_factory=supervisor.rpcinterface:make_main_rpcinterface
47 changes: 0 additions & 47 deletions beyla/cluster-collector.sh

This file was deleted.

11 changes: 0 additions & 11 deletions beyla/entrypoint.sh

This file was deleted.

17 changes: 17 additions & 0 deletions beyla/run_supervisord.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/bin/bash

set -e

# Ensure the supervisord.conf exists in the expected location
SUPERVISORD_CONF="/var/lib/better-stack/beyla/supervisord.conf"
BOOTSTRAP_CONF="/bootstrap/supervisord.conf"

if [ ! -f "$SUPERVISORD_CONF" ]; then
echo "Supervisord config not found at $SUPERVISORD_CONF, copying from bootstrap..."
mkdir -p "$(dirname "$SUPERVISORD_CONF")"
cp "$BOOTSTRAP_CONF" "$SUPERVISORD_CONF"
echo "Copied bootstrap supervisord config to $SUPERVISORD_CONF"
fi

# Start supervisord
exec /usr/bin/supervisord -c "$SUPERVISORD_CONF"
50 changes: 0 additions & 50 deletions beyla/supervisord.conf

This file was deleted.

Loading