50% off 所有套餐限时优惠,起价 $2.48/mo
Ghost

Ghost

Ghost 是一个现代内容发布平台,提供 Headless CMS 功能,支持新闻邮件、博客和付费会员,原生集成 Stripe 支付,并提供类似 Substack 的邮件订阅体验。OpenAI、DuckDuckGo 和 Mozilla 均在使用。这是面向专业出版者的 WordPress 开源替代方案,采用 MIT 协议授权。

Version

6

Operating System

Ubuntu Server 24.04 LTS

Min. RAM

2 GB

IP Types

IPV4,IPV6

访问 Ghost 管理后台

URL: https://<server-ip>/ghost

完成初始配置:创建管理员账号并设置站点信息。

通过 Docker Compose 管理 Ghost

cd /root/ghost
docker compose ps        # View running containers
docker compose up -d     # Start Ghost
docker compose down      # Stop Ghost
docker compose restart   # Restart Ghost

Credentials & Configuration

配置文件存储于 /root/ghost/.env 和 /root/ghost/docker-compose.yml。

Email Setup

Uncomment mail section in /root/ghost/docker-compose.yml.

Restart containers:

cd /root/ghost; docker compose restart

请确保已开启 SMTP 访问权限。

以 Gmail 应用专用密码为例:

mail__transport: SMTP
mail__options__host: smtp.gmail.com
mail__options__port: 465
mail__options__secure: true
mail__options__auth__user: [email protected]
mail__options__auth__pass: your-app-password

Domain & SSL

将你的域名指向服务器 IP。

Update /root/ghost/docker-compose.yml 将 URL 更新为域名(url: https://your-domain)。

Restart containers:

cd /root/ghost; docker compose restart

关于 Certbot SSL:

apt install -y certbot python3-certbot-nginx
certbot certonly --nginx --non-interactive --agree-tos --email <your-email> -d <your-domain>

替换以下文件中的 SSL 路径 /etc/nginx/sites-enabled/ghost.

# Example
ssl_certificate /etc/letsencrypt/live/your-domain/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/your-domain/privkey.pem;

Reload Nginx:

nginx -t && systemctl reload nginx

 

立即部署 Ghost。 From $2.48/mo.