• Stars
    star
    253
  • Rank 160,776 (Top 4 %)
  • Language
    Go
  • License
    MIT License
  • Created almost 9 years ago
  • Updated about 4 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A tool to convert docker inspect to the opencontainers runc spec.

riddler

make-all make-image GoDoc Github All Releases

A tool to convert docker inspect to the opencontainers/specs and opencontainers/runc.

Table of Contents

NOTE

This project is no longer maintained. If you are using a version of docker greater than 1.11 then you can just copy the config from /var/run/docker/libcontainerd like so:

$ docker ps -a
CONTAINER ID    CREATED             STATUS              PORTS               NAMES
d4da95779a3c    3 minutes ago       Up 3 minutes        80/tcp              modest_meitner

$ sudo tree /var/run/docker/libcontainerd -L 1
/var/run/docker/libcontainerd
β”œβ”€β”€ containerd
β”œβ”€β”€ d4da95779a3c287b28b421194f04374b6330e6ff10f5ca1a99d03828d84f1635
β”œβ”€β”€ docker-containerd.pid
β”œβ”€β”€ docker-containerd.sock
└── event.ts

$ sudo tree /var/run/docker/libcontainerd/d4da95779a3c.../
/var/run/docker/libcontainerd/d4da95779a3c.../
β”œβ”€β”€ config.json
β”œβ”€β”€ init-stderr
β”œβ”€β”€ init-stdin
└── init-stdout

$ sudo file /var/run/docker/libcontainerd/d4da95779a3c.../config.json
/var/run/docker/libcontainerd/d4da95779a3c.../config.json: ASCII text, with very long lines

Installation

Binaries

For installation instructions from binaries please visit the Releases Page.

Via Go

$ go get github.com/genuinetools/riddler

Usage

$ riddler -h
riddler -  A tool to convert docker inspect to the opencontainers runc spec.

Usage: riddler <command>

Flags:

  --host       Docker Daemon socket(s) to connect to (default: unix:///var/run/docker.sock)
  --idlen      Length of UID/GID ID space ranges for user namespaces (default: 0)
  --idroot     Root UID/GID for user namespaces (default: 0)
  --bundle     Path to the root of the bundle directory (default: <none>)
  -d           enable debug logging (default: false)
  -f, --force  force overwrite existing files (default: false)
  --hook       Hooks to prefill into spec file. (ex. --hook prestart:netns) (default: [])

Commands:

  version  Show the version information.

Installation

For seccomp and apparmor support you will need:

  • sys/apparmor.h
  • seccomp.h

OR to compile without those run:

$ make build BUILDTAGS=""

example

# just pass the container name or id on run

$ riddler chrome
config.json has been saved.

TODO

  • fixup various todos (mostly runtime config parsing)
  • add more unit tests for each field

More Repositories

1

img

Standalone, daemon-less, unprivileged Dockerfile and OCI compatible container image builder.
Go
3,885
star
2

binctr

Fully static, unprivileged, self-contained, containers as executable binaries.
Go
2,512
star
3

reg

Docker registry v2 command line client and repo listing generator with security checks.
Go
1,648
star
4

bane

Custom & better AppArmor profile generator for Docker containers.
Go
1,149
star
5

amicontained

Container introspection tool. Find out what container runtime is being used as well as features available.
Go
979
star
6

weather

Weather via the command line.
Go
959
star
7

contained.af

A stupid game for learning about containers, capabilities, and syscalls.
JavaScript
893
star
8

bpfd

Framework for running BPF programs with rules on Linux as a daemon. Container aware.
Go
471
star
9

pepper

A tool for performing actions on GitHub repos or a single repo.
Go
362
star
10

audit

For auditing what collaborators, hooks, and deploy keys you have added on all your GitHub repositories.
Go
336
star
11

ghb0t

A GitHub Bot to automatically delete your fork's branches after a pull request has been merged.
Makefile
286
star
12

sshb0t

A bot for keeping your ssh authorized_keys up to date with user's GitHub keys, **only** use if you enable 2FA & keep your keys updates.
Makefile
280
star
13

netns

Runc hook (OCI compatible) for setting up default bridge networking for containers.
Go
223
star
14

certok

Command line tool to check the validity and expiration dates of SSL certificates.
Go
159
star
15

apk-file

Search apk package contents via the command line.
Makefile
107
star
16

udict

A command line urban dictionary.
Makefile
106
star
17

bpfps

A tool to list and diagnose bpf programs. (Who watches the watchers..? :)
Makefile
94
star
18

1up

A custom Gmail spam filter bot.
Go
78
star
19

releases

Server to show latest GitHub Releases for a set of repositories.
Go
64
star
20

upmail

Email notification hook for https://github.com/sourcegraph/checkup.
Makefile
61
star
21

magneto

Pipe runc (OCI compatible) events to a stats TUI (Text User Interface).
Go
46
star
22

pkg

A home for various Go packages to be imported by other projects.
Go
36
star
23

www

This is the public website for genuine tools.
HTML
21
star