# Start a prometheus server

use follow command, to run a prometheus server by docker container

    docker run --name prometheus  -p 9090:9090  -v /etc/prometheus/prometheus.yml:/etc/prometheus/prometheus.yml prom/prometheus

edit the config to find your nodeExporter

    scrape_configs:
      - job_name: 'prometheus'
        static_configs:
          - targets: ['localhost:9090']
      # 采集node exporter监控数据
      - job_name: 'node'
        static_configs:
          - targets: ['host.docker.internal:9300']
