debian-armyknife/README.md

69 lines
1.3 KiB
Markdown
Raw Normal View History

2025-05-14 09:31:06 +02:00
# Dockerfile for creating a plugable debian for various troubleshooting-tasks
2025-05-14 09:24:01 +02:00
2025-05-14 09:29:17 +02:00
### Usage:
2025-05-14 09:24:01 +02:00
2025-05-14 09:42:34 +02:00
###### 1. Clone git-repo:
2025-05-14 09:24:01 +02:00
```
2025-05-14 09:36:44 +02:00
git clone https://forge.dmz.skyfritt.net/Symbiose/debian-armyknife
2025-05-14 09:29:17 +02:00
```
2025-05-16 11:03:23 +02:00
or (via Skyfritt-mirror):
2025-05-16 10:33:54 +02:00
```
git clone https://forge.dmz.skyfritt.net/Skyfritt/debian-armyknife
```
2025-05-14 09:36:44 +02:00
2025-05-14 09:42:34 +02:00
###### 2. Build image (from inside repo-folder, typically /opt/debian-armyknife)
2025-05-14 09:24:01 +02:00
2025-05-16 10:33:54 +02:00
docker:
2025-05-14 09:29:17 +02:00
```
docker build -t debian-armyknife:custom .
2025-05-14 09:24:01 +02:00
```
2025-05-16 10:33:54 +02:00
podman:
```
2025-05-23 10:41:15 +02:00
docker build -t debian-armyknife:custom . --network=host
2025-05-16 10:33:54 +02:00
```
2025-05-14 09:42:34 +02:00
###### 3. Verify that the new image is avaiable:
2025-05-16 10:39:33 +02:00
docker:
2025-05-14 09:29:17 +02:00
```
# docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
debian-armyknife custom ba509e499dda 11 hours ago 321MB
```
2025-05-16 10:39:33 +02:00
podman:
```
2025-05-23 10:41:15 +02:00
# podman images
REPOSITORY TAG IMAGE ID CREATED SIZE
localhost/debian-armyknife custom 08c635e4b6fa 9 seconds ago 620 MB
2025-05-16 10:39:33 +02:00
```
2025-05-14 09:24:01 +02:00
2025-05-14 09:42:34 +02:00
###### 4. Run image:
2025-05-16 10:39:33 +02:00
docker:
2025-05-14 09:29:17 +02:00
```
docker run -it debian-armyknife:custom bash
2025-05-14 09:24:01 +02:00
```
2025-05-16 10:33:54 +02:00
podman:
```
2025-05-23 10:41:15 +02:00
podman run -it debian-armyknife:custom bash
2025-05-16 10:33:54 +02:00
```
2025-05-14 09:24:01 +02:00
2025-05-14 09:46:53 +02:00
###### 5. Run and attach to specific network:
2025-05-16 10:39:33 +02:00
docker:
2025-05-14 09:31:06 +02:00
```
2025-05-14 09:46:53 +02:00
docker run --network [NETWORK NAME] -it debian-armyknife:custom bash
2025-05-14 09:31:06 +02:00
```
2025-05-16 10:33:54 +02:00
podman:
```
2025-05-23 10:41:15 +02:00
podman run -it --net skypodnet0 debian-armyknife:custom bash
2025-05-16 10:33:54 +02:00
```
2025-05-14 09:31:06 +02:00
2025-05-23 10:41:15 +02:00
###### Start with docker compose or as a quadlet with systemd:
2025-05-16 10:39:33 +02:00
docker:
2025-05-14 09:31:06 +02:00
```
missing
```
2025-05-16 10:33:54 +02:00
podman:
```
missing
2025-05-23 10:41:15 +02:00
```