Skip to content

Latest commit

 

History

History
57 lines (47 loc) · 1.26 KB

ptrace.mdx

File metadata and controls

57 lines (47 loc) · 1.26 KB
title sidebarTitle description icon
Troubleshoot: missing SYS_PTRACE capability
SYS_PTRACE
circle-exclamation

Subtrace requires the SYS_PTRACE Linux capability in order to work correctly.

Docker

If you're using Subtrace in a Docker container using docker run, you can enable that by adding the --cap-add=SYS_PTRACE command line flag when starting your container. For example:

docker run -it --rm --cap-add=SYS_PTRACE debian:12

Docker Compose

If you're using Subtrace with Docker Compose, add the following line to your service definition in the compose.yml file:

services:
  my-app:
    image: ghcr.io/NAMESPACE/IMAGE_NAME:latest
    command: "subtrace run -- ./start.sh"
    cap_add:
      - SYS_PTRACE

Kubernetes

If you're deploying on Kubernetes, add the following line to your deployment:

apiVersion: apps/v1
kind: Deployment
metadata:
  name: my-deployment
spec:
  replicas: 1
  selector:
    matchLabels:
      app: my-app
  template:
    metadata:
      labels:
        app: my-app
    spec:
      containers:
      - name: my-container
        image: ghcr.io/NAMESPACE/IMAGE_NAME:latest
        securityContext:
          capabilities:
            add:
              - SYS_PTRACE