Giter VIP home page Giter VIP logo

caddyprom's Introduction

Hi there 👋

caddyprom's People

Contributors

aldevar avatar dependabot-preview[bot] avatar hairyhenderson avatar jopereira avatar mexhigh avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

caddyprom's Issues

Add Metrics by URL

I really need metrics by URL in order to verify which endpoint is causing some bottlenecks and eventual problems.

What do you think about implementing this on this project? I could work on this...

Dockerfile

Hi,

I tried to create a dockerfile with caddyprom.

FROM caddy:builder AS builder

RUN caddy-builder \
    github.com/hairyhenderson/caddyprom

FROM caddy:latest

COPY --from=builder /usr/bin/caddy /usr/bin/caddy

and my caddyfile:

{
    order prometheus first
}

{{ domain }} {
        reverse_proxy {{ service }}:{{ port }}
        log {
                output file /var/log/caddy/{{ domain }}.log
        }
                {
                debug
        }
}

prometheus

After that I use ansible with docker-compose module to build and deploy caddy. It's work for caddy.

But I don't find any metrics.

/ # curl localhost:9180/metrics
curl: (7) Failed to connect to localhost port 9180: Connection refused

Where is my mistake?

Thanks

Stats per Host

Please, would there be a possibility to add metrics per host like it was done in https://github.com/miekg/caddy-prometheus?

caddy_http_request_count_total{host, family, proto}
caddy_http_request_duration_seconds{host, family, proto}
caddy_http_response_latency_seconds{host, family, proto, status}
caddy_http_response_size_bytes{host, family, proto, status}
caddy_http_response_status_count_total{host, family, proto, status}

Dependabot can't resolve your Go dependency files

Dependabot can't resolve your Go dependency files.

As a result, Dependabot couldn't update your dependencies.

The error Dependabot encountered was:

dmitri.shuralyov.com/gpu/[email protected]: unrecognized import path "dmitri.shuralyov.com/gpu/mtl" (https fetch: Get https://dmitri.shuralyov.com/gpu/mtl?go-get=1: EOF)

If you think the above is an error on Dependabot's side please don't hesitate to get in touch - we'll do whatever we can to fix it.

View the update logs.

Question : Metrics for reverse-proxy

Hi,
Here is my caddy configuration in json format

{
    "storage":{
            "module": "consul"
    },
    "apps": {
        "http": {
            "servers": {
                "srv0": {
                    "listen": [
                        ":443"
                    ],
                    "routes": [
                        {
                            "handle": [
                                {
                                    "handler": "reverse_proxy",
                                    "upstreams": [
                                        {
                                            "dial": "10.0.0.1:80"
                                        },
                                        {
                                            "dial": "10.0.0.2:80"
                                        }
                                    ],
                                    "health_checks": {
                                        "active": {
                                            "path": "/",
                                            "port": 80,
                                            "interval": "0.5s",
                                            "timeout": "2s",
                                            "expect_status": 200
                                         }}
                                }
                            ],
                            "match": [
                                {
                                    "host": ["redacted.mycompany.com"]
                                }]
                        },
                    {
                            "handle": [
                                {
                                    "handler": "prometheus"
                                }
                            ],
                            "match": [
                                {
                                    "host": ["localhost"]
                                }
                            ]
                        }

                    ]
                }
            }
        }
    }
}

prometheux loads correctly and I'm able to view metrics. But metrics seems to be shown only when requesting localhost. If I generate some traffic on redacted.mycompany.com, the localhost:9180/metrics page does not change. No metric is added.

My question is, does this module works with reverse-proxy handler?

How to configure listen address

Is there any possibility to set the listen address in the caddyfile? I'm using caddy inside docker, which makes the prometheus module unusable for me as it only listens on localhost by default.
Thanks for the help.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.