project-build-static-binary

Automate the creation of self-extracting static Netdata installers for diverse Linux architectures.

80.4k|6.6k|Updated Jun 17, 2013
One-click install
npx skills add https://github.com/netdata/netdata --skill project-build-static-binary
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: project-build-static-binary
Source: https://github.com/netdata/netdata/tree/main/.agents/skills/project-build-static-binary
Command: npx skills add https://github.com/netdata/netdata --skill project-build-static-binary

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill addresses the complexity of building portable, dependency-free Netdata binaries for environments lacking native build toolchains or specific system libraries, preventing failed deployments on restricted Linux hosts.

Core Features & Use Cases

  • Cross-Architecture Builds: Automates compilation for x86_64, aarch64, armv6l, and armv7l using Docker-based QEMU emulation.
  • Dependency Management: Handles static linking of essential libraries like OpenSSL, libunwind, and curl to ensure binary portability.
  • Use Case: Use this Skill to generate a custom static installer for a legacy RHEL server or an embedded ARM device where installing build dependencies is prohibited or impossible.

Quick Start

Run the build-static-binary skill for the x86_64 architecture to generate a self-extracting installer in the artifacts directory.

Frequently Asked Questions about project-build-static-binary

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I build a static Netdata binary for ARM64?▼

Execute the build script with the aarch64 argument to trigger the cross-compilation workflow. The process uses QEMU emulation to build the binary within a containerized environment, ensuring compatibility with ARM64 Linux targets.

What should I do if the build fails with a submodule error?▼

Initialize the repository submodules by running 'git submodule update --init --recursive' before starting the build. The build process requires these vendored sources to configure the Netdata build environment correctly.

Why does the build fail with sha256sum unrecognized option errors?▼

This error indicates a stale 'netdata/static-builder:v1' Docker image that lacks GNU coreutils. Run 'docker pull netdata/static-builder:v1' to refresh the image and resolve the compatibility issue with long-form command options.

Can I debug the build process if it fails mid-job?▼

Set the environment variable 'DEBUG_BUILD_INFRA=1' before running the build script. This prevents the container from exiting on failure, allowing you to inspect the in-progress install tree and troubleshoot the environment.

How do I verify the generated static binary?▼

Use the '--info' or '--list' flags with the generated .gz.run file to inspect the archive contents without executing the installer. You can also run the binary on a target host to verify runtime functionality.