跳到内容
SIAX
此语言版本是机器辅助翻译的草稿,尚未经过审核,不会被搜索引擎索引。 阅读经过审核的英文版本
安装未审核

Install Uptime Kuma with Docker

Run the open source uptime monitor Uptime Kuma in a Docker container, following the project's own README: Docker Compose or a single docker run command, the data volume and the file-system limitation to know about.

尚未翻译:以英文显示。

本指南尚未经人工审核。在依赖它之前,请对照所链接的文档检查每一步。它不会被搜索引擎收录。审核说明: Written by an agent from the project's README; the first-run steps are general practice and labelled as such. Needs a person to test and review before publication.

核实于

核对所依据的版本

  • Uptime Kuma Docker image: louislam/uptime-kuma:2 (major-version tag) [readme]

开始之前

  • A Linux server or VM with Docker and the Docker Compose plugin installed.
  • A local disk or Docker volume for the data directory (not a network file system, see below).

Option A: Docker Compose

The README offers a ready-made compose file. It defines one service using the image louislam/uptime-kuma:2, restarts it unless stopped, stores data in ./data mounted at /app/data and publishes port 3001.[readme][compose]

mkdir uptime-kuma
cd uptime-kuma
curl -o compose.yaml https://raw.githubusercontent.com/louislam/uptime-kuma/master/compose.yaml
docker compose up -d
From the project README. 来源:Uptime Kuma README (installation)

Option B: a single docker run command

docker run -d --restart=always -p 3001:3001 -v uptime-kuma:/app/data --name uptime-kuma louislam/uptime-kuma:2
From the project README. Data goes to the named volume uptime-kuma. 来源:Uptime Kuma README (installation)

Uptime Kuma then listens on port 3001 on all network interfaces. The README shows how to bind it to localhost only by publishing the port as 127.0.0.1:3001:3001, which is what you want when a reverse proxy on the same host is the only way in.[readme]

Storage: no network file systems

The README states that network file systems such as NFS are not supported. Map /app/data to a local directory or a Docker volume.[readme]

First run

  1. Open http://<server-ip>:3001 (or http://localhost:3001 on the host itself).
  2. Create the first account in the setup screen before anyone else can reach the port.
  3. Add your first monitor and check that data survives a container restart (docker restart uptime-kuma).

These first-run steps are general practice, not taken from the README.

本指南未涵盖

  • TLS and a reverse proxy in front of port 3001.
  • Backups of the data directory and upgrades between major versions.

来源

浏览完整网站 · Svenska