как какать:
digraph {
rankdir=LR
registry -> image [label=pull]
image -> container [label=run]
}
# Recorded with the doitlive recorder
#doitlive shell: /bin/bash
#doitlive prompt: default
rm app.py Containerfile compose.yml ; podman system prune --all
podman run hello-world
podman run --interactive --tty debian
echo "# let's get something from host!"
echo 'print("fart")' > app.py
podman run --rm -itv "$PWD":/v:z debian
podman run --rm -itv "$PWD":/v:z --entrypoint sh python
echo "# let's build our own image!"
echo 'FROM python' > Containerfile
echo 'WORKDIR /app' >> Containerfile
echo 'COPY app.py .' >> Containerfile
echo 'ENTRYPOINT ["python", "-u", "app.py"]' >> Containerfile
cat Containerfile
podman build .
podman build --tag crap .
podman run crap
echo "# let's run a web service!"
echo 'import http.server' >> app.py
echo 'http.server.HTTPServer(("", 80), http.server.SimpleHTTPRequestHandler).serve_forever()' >> app.py
podman build -t crap .
podman run --name poo --publish 8000:80 crap
echo 'services:' > compose.yml
echo ' shit:' >> compose.yml
echo ' build: .' >> compose.yml
echo ' image: crap' >> compose.yml
echo ' container_name: poo' >> compose.yml
echo ' ports:' >> compose.yml
echo ' - "8000:80"' >> compose.yml
cat compose.yml
podman compose up --detach
podman ps
podman compose down
digraph {
rankdir=LR
registry -> image [label=pull]
image -> container [label=run]
}
Модифицировать окружение контейнера мимо образа!
(не надо так)
Годный реестр:
or
or
By clicking below, you agree to our terms of service.
New to HackMD? Sign up
Syntax | Example | Reference | |
---|---|---|---|
# Header | Header | 基本排版 | |
- Unordered List |
|
||
1. Ordered List |
|
||
- [ ] Todo List |
|
||
> Blockquote | Blockquote |
||
**Bold font** | Bold font | ||
*Italics font* | Italics font | ||
~~Strikethrough~~ | |||
19^th^ | 19th | ||
H~2~O | H2O | ||
++Inserted text++ | Inserted text | ||
==Marked text== | Marked text | ||
[link text](https:// "title") | Link | ||
 | Image | ||
`Code` | Code |
在筆記中貼入程式碼 | |
```javascript var i = 0; ``` |
|
||
:smile: | ![]() |
Emoji list | |
{%youtube youtube_id %} | Externals | ||
$L^aT_eX$ | LaTeX | ||
:::info This is a alert area. ::: |
This is a alert area. |
On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?
Please give us some advice and help us improve HackMD.
Do you want to remove this version name and description?
Syncing