注意:这是https://hub.docker.com/_/ghost%E7%9A%84%60s390x%60%E6%9E%B6%E6%9E%84%E6%9E%84%E5%BB%BA%E7%9A%84%22per-architecture%22%E4%BB%93%E5%BA%93%E2%80%94%E2%80%94%E6%9B%B4%E5%A4%9A%E4%BF%A1%E6%81%AF%EF%BC%8C%E8%AF%B7%E5%8F%82%E8%A7%81%E5%AE%98%E6%96%B9%E9%95%9C%E5%83%8F%E6%96%87%E6%A1%A3%E4%B8%AD%E7%9A%84%22%E9%99%A4amd64%E4%B9%8B%E5%A4%96%E7%9A%84%E6%9E%B6%E6%9E%84%EF%BC%9F%22https://github.com/docker-library/official-images#architectures-other-than-amd64%E5%92%8C%E5%AE%98%E6%96%B9%E9%95%9C%E5%83%8FFAQ%E4%B8%AD%E7%9A%84%22%E9%95%9C%E5%83%8F%E7%9A%84%E6%BA%90%E4%BB%A3%E7%A0%81%E5%9C%A8Git%E4%B8%AD%E6%9B%B4%E6%94%B9%E4%BA%86%EF%BC%8C%E7%8E%B0%E5%9C%A8%E8%AF%A5%E6%80%8E%E4%B9%88%E5%8A%9E%EF%BC%9F%22https://github.com/docker-library/faq#an-images-source-changed-in-git-now-what%E3%80%82
维护者:
https://github.com/docker-library/ghost
获取帮助的途径:
Docker社区Slack、Server Fault、Unix & Linux或Stack Overflow
Dockerfile链接https://github.com/docker-library/ghost/blob/e092f980a4b38a***f42b7eceb7b80d441e202/6/debian/Dockerfile
https://github.com/docker-library/ghost/blob/fdba3d80f50da610007165f5fe46f9b8af69764b/5/debian/Dockerfile
提交issue的位置:
https://github.com/docker-library/ghost/issues?q=
支持的架构:(https://github.com/docker-library/official-images#architectures-other-than-amd64)
https://hub.docker.com/r/amd64/ghost/%E3%80%81https://hub.docker.com/r/arm32v6/ghost/%E3%80%81https://hub.docker.com/r/arm32v7/ghost/%E3%80%81https://hub.docker.com/r/arm64v8/ghost/%E3%80%81https://hub.docker.com/r/ppc64le/ghost/%E3%80%81https://hub.docker.com/r/s390x/ghost/
已发布镜像工件详情:
https://github.com/docker-library/repo-info/blob/master/repos/ghost%EF%BC%88https://github.com/docker-library/repo-info/commits/master/repos/ghost%EF%BC%89
(镜像元数据、传输大小等)
镜像更新:
https://github.com/docker-library/official-images/issues?q=label%3Alibrary%2Fghost
https://github.com/docker-library/official-images/blob/master/library/ghost%EF%BC%88https://github.com/docker-library/official-images/commits/master/library/ghost%EF%BC%89
本描述的来源:
https://github.com/docker-library/docs/tree/master/ghost%EF%BC%88https://github.com/docker-library/docs/commits/master/ghost%EF%BC%89
Ghost是一个独立的在线发布平台,支持通过网络和电子邮件通讯发布内容。它内置用户注册、访问控制和订阅支付功能(通过Stripe),让你能够与受众建立直接关系。其基于Node.js和MySQL8构建,具有快速、用户友好的特点。
Ghost.org
!https://raw.githubusercontent.com/docker-library/docs/c88522f95bebcab2322f3020f2f735210286939b/ghost/logo.png
以下命令将启动一个Ghost开发实例,监听Ghost的默认端口2368。
console$ docker run -d --name some-ghost -e NODE_ENV=development s390x/ghost
如果希望从主机直接访问实例而无需使用容器IP,可以使用标准端口映射:
console$ docker run -d --name some-ghost -e NODE_ENV=development -e url=http://localhost:3001 -p 3001:2368 s390x/ghost
如果一切正常,你可以通过http://localhost:3001访问新站点,并通过http://localhost:3001/ghost访问Ghost管理界面(或分别通过http://host-ip:3001和http://host-ip:3001/ghost)。
升级主版本前,需确保当前运行的是最新的次版本,否则可能会遇到数据库错误。
要升级Ghost容器,需将数据挂载到旧版本容器的相应路径(见下文):从管理面板导入内容,停止容器,然后将内容重新挂载到要升级到的新版本容器中;之后可从管理面板导出内容。
挂载现有内容。以下示例同时使用基于Alpine Linux的镜像:
console$ docker run -d \ --name some-ghost \ -e NODE_ENV=development \ -e database__connection__filename='/var/lib/ghost/content/data/ghost.db' \ -p 3001:2368 \ -v /path/to/ghost/blog:/var/lib/ghost/content \ s390x/ghost:alpine
注意:database__connection__filename仅在开发模式下有效,用于指定SQLite数据库文件的位置。如果使用开发模式,应将其设置为持久化文件夹(绑定挂载或卷)中的可写路径。生产模式下不可用,因为需要外部MySQL服务器(见下文的Docker Compose示例)。
也可使用命名docker卷代替/var/lib/ghost/content的直接主机路径:
console$ docker run -d \ --name some-ghost \ -e NODE_ENV=development \ -e database__connection__filename='/var/lib/ghost/content/data/ghost.db' \ -p 3001:2368 \ -v some-ghost-data:/var/lib/ghost/content \ s390x/ghost
所有Ghost配置参数(如url)都可通过环境变量指定。有关允许的配置项以及如何将嵌套配置键转换为相应环境变量名称的详细信息,请参见Ghost文档:
console$ docker run -d --name some-ghost -e NODE_ENV=development -e url=http://some-ghost.example.com s390x/ghost
(下文的compose.yaml中有更多配置示例。)
当在https://github.com/TryGhost/Ghost/issues%E6%8F%90%E4%BA%A4%E5%B7%A5%E5%8D%95%E6%97%B6%EF%BC%8C%E9%9C%80%E8%A6%81%E7%9F%A5%E9%81%93%E6%89%80%E4%BD%BF%E7%94%A8%E7%9A%84Node.js%E7%89%88%E6%9C%AC%EF%BC%9A
console$ docker exec <container-id> node --version [node版本输出]
虽然Docker镜像中包含Ghost-CLI并使用其部分命令设置基础Ghost镜像,但许多其他Ghost-CLI命令可能无法正常工作,并且并非设计用于此场景。更多信息参见https://github.com/docker-library/ghost/issues/156#issuecomment-428159861%E3%80%82
要在生产环境运行Ghost,还需要运行MySQL 8、配置https,并设置带有适当X-Forwarded-For、X-Forwarded-Host和X-Forwarded-Proto(https)头的反向代理。
以下示例展示了使用MySQL运行的部分必要配置。有关更多详细信息,请参见Ghost的“配置选项”文档。
ghost的compose.yaml示例:
yamlservices: ghost: image: ghost:5-alpine restart: always ports: - 8080:2368 environment: # 参见 https://ghost.org/docs/config/#configuration-options database__client: mysql database__connection__host: db database__connection__user: root database__connection__password: example database__connection__database: ghost # 这个url值只是示例,可能不适合你的环境! url: http://localhost:8080 # 与链接文档中提到的默认值相反,本镜像默认为NODE_ENV=production(因此如需开发模式需显式指定) #NODE_ENV: development volumes: - ghost:/var/lib/ghost/content db: image: mysql:8.0 restart: always environment: MYSQL_ROOT_PASSWORD: example volumes: - db:/var/lib/mysql volumes: ghost: db:
运行docker compose up,等待完全初始化后,访问http://localhost:8080或http://host-ip:8080(根据实际情况)。
查看本镜像中包含的软件的许可证信息。
与所有Docker镜像一样,本镜像可能还包含其他软件,这些软件可能采用其他许可证(如基础发行版中的Bash等,以及主要软件的任何直接或间接依赖项)。
一些能够自动检测到的额外许可证信息可能位于https://github.com/docker-library/repo-info/tree/master/repos/ghost%E4%B8%AD%E3%80%82
对于任何预构建镜像的使用,镜像用户有责任确保对本镜像的任何使用都符合其中包含的所有软件的相关许可证。

探索更多轩辕镜像的使用方法,找到最适合您系统的配置方式
通过 Docker 登录认证访问私有仓库
无需登录使用专属域名
Kubernetes 集群配置 Containerd
K3s 轻量级 Kubernetes 镜像加速
VS Code Dev Containers 配置
Podman 容器引擎配置
HPC 科学计算容器配置
ghcr、Quay、nvcr 等镜像仓库
Harbor Proxy Repository 对接专属域名
Portainer Registries 加速拉取
Nexus3 Docker Proxy 内网缓存
需要其他帮助?请查看我们的 常见问题Docker 镜像访问常见问题解答 或 提交工单
manifest unknown
no matching manifest(架构)
invalid tar header(解压)
TLS 证书失败
DNS 超时
410 Gone 排查
402 与流量用尽
401 认证失败
429 限流
D-Bus 凭证提示
413 与超大单层
来自真实用户的反馈,见证轩辕镜像的优质服务