前段时间,docker被墙了,想通过群晖直接升级或安装应用已经不行了,那么今天抄袭了一篇很方便的免翻墙便捷升级群晖docker应用的方法
-
用到的工具是NxShell,通过SSH连接NAS
换成Xshell了,NxShell不能复制,不好玩!
-
输入
sudo -i
切换到root
用户权限 -
查看已安装的应用
docker images
root@NAS:~# docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
neosmemo/memos latest 7f4bea21310f 3 weeks ago 38.6MB
nextcloud latest 68294f5fded5 8 weeks ago 1GB
linuxserver/nextcloud latest 6c494fe01e99 8 weeks ago 436MB
kodcloud/kodbox latest 70c3adf323c8 2 months ago 483MB
jitesoft/tesseract-ocr latest d55342cfc11b 3 months ago 216MB
containrrr/watchtower latest f847e1adb570 4 months ago 14.6MB
altran1502/immich-server latest 271392023569 4 months ago 506MB
vaultwarden/server latest 241447ae76e9 5 months ago 200MB
photoprism/photoprism latest e6f531bbf1b0 7 months ago 1.5GB
viktorstrate/photoview latest acd3733a486e 10 months ago 1.28GB
bitwardenrs/server latest 9e3bf5918c28 16 months ago 187MB
mmmz/trwebocr latest 41baab05273a 17 months ago 1.29GB
- 打开memos然后在右侧复制下载地址,得到
docker pull neosmemo/memos
- 输入上面命令拉取镜像
root@NAS:~# docker pull neosmemo/memos
Using default tag: latest
latest: Pulling from neosmemo/memos
91d30c5bc195: Already exists
43fa02c6b626: Pull complete
58cd5a794880: Pull complete
6eaa1a2422bd: Pull complete
b93974286559: Pull complete
Digest: sha256:875d028759b330c8df10a49eb8cce3d55725f34c2ffd95dca304081976805ccc
Status: Downloaded newer image for neosmemo/memos:latest
docker.io/neosmemo/memos:latest
docker images
后我们可能会看到出现2个Memos镜像,其原因是拉取Docker镜像没有指定版本号的话,默认会拉取版本号(tag)为“latest”的镜像,老的镜像和新的镜像版本号都是latest,就会把老镜像版本号挤掉,变成none。我们只需要保留tag为latest的即可。
:~# docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
neosmemo/memos latest f930acc56434 3 weeks ago 38.7MB
neosmemo/memos <none> 7f4bea21310f 3 weeks ago 38.6MB
nextcloud latest 68294f5fded5 8 weeks ago 1GB
linuxserver/nextcloud latest 6c494fe01e99 8 weeks ago 436MB
kodcloud/kodbox latest 70c3adf323c8 2 months ago 483MB
jitesoft/tesseract-ocr latest d55342cfc11b 3 months ago 216MB
containrrr/watchtower latest f847e1adb570 4 months ago 14.6MB
altran1502/immich-server latest 271392023569 4 months ago 506MB
vaultwarden/server latest 241447ae76e9 5 months ago 200MB
photoprism/photoprism latest e6f531bbf1b0 7 months ago 1.5GB
viktorstrate/photoview latest acd3733a486e 10 months ago 1.28GB
bitwardenrs/server latest 9e3bf5918c28 16 months ago 187MB
mmmz/trwebocr latest 41baab05273a 17 months ago 1.29GB
-
群晖面板将memos镜像重命名为memos-backup618为新的容器腾出命名空间
-
选中memos-backup618,点击
设置
复制设置
,名称重新改为memos
,应用后,会自动复制一个新的容器并且复制所有数据过去。 -
群晖面板删掉memos-backup618容器,删除旧的镜像文件即可
:~# docker rmi 7f4bea21310f
Untagged: neosmemo/memos@sha256:f9026edce05dfb65f95bfc0f5b9755d78868825264bf7cfb7832f70607d3c1ca
Deleted: sha256:7f4bea21310f28fd46581df818ec09975ad2d461bbaa8d4f73aa988a8d71d66e
Deleted: sha256:85b6f5f90e63337963d665ec67a7af3ccdaea40c280b47427148e49c86d08d52
Deleted: sha256:7cc93b8e3b1b77110990547119d1a2328e2a144d61ed2d84e6620cf09ef435ea
Deleted: sha256:e6c32109e9a50758ff7f38de074ba42743457b61e9fcf11e00764f5063768f1e
Deleted: sha256:62d22efbc1ec5e7de486acfb8efee8d82dfa4b2504869c3596baedc2a5dbbefd