mirror of
https://github.com/juewuy/ShellCrash.git
synced 2026-09-08 05:36:33 +00:00
~修复 Docker 仅挂载 configs 时重建容器丢失内核配置的问题:补充 yamls/jsons 卷挂载
This commit is contained in:
+3
-1
@@ -89,6 +89,8 @@ mkdir -p /root/ShellCrash
|
|||||||
docker run -d \
|
docker run -d \
|
||||||
………………
|
………………
|
||||||
-v shellcrash_configs:/etc/ShellCrash/configs \
|
-v shellcrash_configs:/etc/ShellCrash/configs \
|
||||||
|
-v shellcrash_yamls:/etc/ShellCrash/yamls \
|
||||||
|
-v shellcrash_jsons:/etc/ShellCrash/jsons \
|
||||||
………………
|
………………
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -134,7 +136,7 @@ docker rm -f shellcrash
|
|||||||
### Docker删除卷
|
### Docker删除卷
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
docker volume rm shellcrash_configs
|
docker volume rm shellcrash_configs shellcrash_yamls shellcrash_jsons
|
||||||
```
|
```
|
||||||
|
|
||||||
### Compose删除容器&卷
|
### Compose删除容器&卷
|
||||||
|
|||||||
@@ -18,10 +18,14 @@ services:
|
|||||||
# - net.ipv6.conf.all.forwarding=1
|
# - net.ipv6.conf.all.forwarding=1
|
||||||
volumes:
|
volumes:
|
||||||
- shellcrash_configs:/etc/ShellCrash/configs:rw
|
- shellcrash_configs:/etc/ShellCrash/configs:rw
|
||||||
|
- shellcrash_yamls:/etc/ShellCrash/yamls:rw
|
||||||
|
- shellcrash_jsons:/etc/ShellCrash/jsons:rw
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
shellcrash_configs:
|
shellcrash_configs:
|
||||||
|
shellcrash_yamls:
|
||||||
|
shellcrash_jsons:
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
macvlan_lan:
|
macvlan_lan:
|
||||||
|
|||||||
Reference in New Issue
Block a user