prometheus

(★ 65,773)

Prometheus 모니터링 시스템 및 시계열 데이터베이스.

파일 탐색기

  • .dockerignore
  • .gitattributes
  • .gitignore
  • .golangci.yml
  • .promu.yml
  • .yamllint
  • AGENTS.md
  • CHANGELOG.md
  • CLAUDE.md
  • CODE_OF_CONDUCT.md
  • CODEOWNERS
  • CONTRIBUTING.md
  • Dockerfile
  • Dockerfile.distroless
  • go.mod
  • go.sum
  • go.work
  • LICENSE
  • MAINTAINERS.md
  • Makefile
  • Makefile.common
  • NOTICE
  • README.md
  • RELEASE.md
  • renovate.json
  • SECURITY-INSIGHTS.yml
  • SECURITY.md
  • VERSION

# 설치 가이드

go
사전 준비물
  • Go Version specified in go.mod or greater
  • NodeJS Version specified in web/ui/.nvmrc or greater
  • npm 10 or greater

설치 및 실행 절차

git clone https://github.com/prometheus/prometheus.git

프로젝트 소스 코드를 복제합니다.

cd prometheus

프로젝트 디렉토리로 이동합니다.

make build

프로젝트를 빌드하고 웹 자산을 컴파일합니다.

./prometheus --config.file=your_config.yml

설정 파일을 지정하여 프로메테우스를 실행합니다.

핵심 명령어

make build

prometheus 및 promtool 바이너리를 빌드하고 웹 자산을 포함시킵니다.

make test

프로젝트의 전체 테스트를 실행합니다.

make assets

React UI 자산을 빌드합니다.

go install github.com/prometheus/prometheus/cmd/...

GOPATH에 바이너리를 설치합니다.

go install을 사용할 경우 web/ui/static 디렉토리의 로컬 자산을 읽기 위해 저장소 루트에서 실행해야 합니다.

# CDN으로 사용하기

jsDelivr

jsDelivr는 공개 GitHub 리포지토리를 별도 설정 없이 CDN으로 즉시 서빙합니다. 버전과 파일을 고르면 웹페이지에 바로 붙일 수 있는 링크와 예시 코드가 만들어집니다.

릴리즈 타임라인

활발히 관리 중

명령어 용어집

이 문서에서 사용된 명령어를 모아봤습니다. 낯선 명령어가 있다면 펼쳐서 확인해보세요.

🔍

docker run

설명 보기 ▼

This command is an alias of `docker container run`.

tldr docker container run

View documentation for the original command:

🔍

git clone

설명 보기 ▼

Clone an existing repository.

git clone {{remote_repository_location}} {{path/to/directory}}

Clone an existing repository into a new directory (the default directory is the repository name):

git clone --recursive {{remote_repository_location}}

Clone an existing repository and its submodules:

git clone {{[-n|--no-checkout]}} {{remote_repository_location}}

Clone only the `.git` directory of an existing repository:

🔍

go build

설명 보기 ▼

Compile Go sources.

go build {{path/to/main.go}}

Compile a 'package main' file (output will be the filename without extension):

go build -o {{path/to/binary}} {{path/to/source.go}}

Compile, specifying the output filename:

go build -o {{path/to/binary}} {{path/to/package}}

Compile a package:

🔍

go get

설명 보기 ▼

Add a dependency package, or download packages in legacy GOPATH mode.
Note: `./...` is a Go package pattern understood by Go tooling. It matches the current package and all packages recursively under the current directory.

go get {{example.com/pkg}}

Add a specified package to `go.mod` in module-mode or install the package in GOPATH-mode:

go get {{example.com/pkg}}@{{v1.2.3}}

Modify the package with a given version in module-aware mode:

go get {{example.com/pkg}}@{{none}}

Remove a specified package:

🔍

go install

설명 보기 ▼

Compile and install packages named by the import paths.

go install

Compile and install the current package:

go install {{path/to/package}}

Compile and install a specific local package:

go install {{golang.org/x/tools/gopls}}@{{latest}}

Install the latest version of a program, ignoring `go.mod` in the current directory:

🔍

npm

설명 보기 ▼

JavaScript 및 Node.js 패키지 관리자.
Node.js 프로젝트 및 모듈 의존성을 관리합니다.
더 많은 정보: <https://docs.npmjs.com/cli/npm/>.

npm init {{[-y|--yes]}}

기본값으로 `package.json` 파일 생성 (`--yes`를 생략하면 대화식으로 진행):

npm {{[i|install]}}

package.json에 의존성으로 나열된 모든 패키지를 다운로드:

npm {{[i|install]}} {{package_name}}@{{version}}

특정 버전의 패키지를 다운로드하고 `package.json`의 의존성 목록에 추가:

🔍

promtool

설명 보기 ▼

Prometheus 모니터링 시스템을 위한 도구.
더 많은 정보: <https://prometheus.io/docs/prometheus/latest/getting_started/>.

promtool check config {{config_file.yml}}

구성 파일이 유효한지 여부 확인 (오류가 있을 경우 보고):

promtool check rules {{rules_file.yml}}

규칙 파일이 유효한지 여부 확인 (오류가 있을 경우 보고):

curl --silent {{http://example.com:9090/metrics/}} | promtool check metrics

`stdin`을 통해 Prometheus 메트릭을 전달하여 일관성과 정확성을 확인:

// repository documentation