Skip to content

Commit

Permalink
Convert to Kotlin
Browse files Browse the repository at this point in the history
  • Loading branch information
pambrose authored Dec 24, 2017
1 parent 9eb519a commit e4d8380
Show file tree
Hide file tree
Showing 98 changed files with 4,448 additions and 5,208 deletions.
94 changes: 3 additions & 91 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,94 +1,6 @@
.idea
prometheus-proxy.iml

.wercker

# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so

# Distribution / packaging
.Python
env/
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
*.egg-info/
.installed.cfg
*.egg

# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*,cover
.hypothesis/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
.idea/
.wercker/
target/

# IPython Notebook
.ipynb_checkpoints

# pyenv
.python-version

# celery beat schedule file
celerybeat-schedule

# dotenv
.env

# virtualenv
venv/
ENV/

# Spyder project settings
.spyderproject
*.iml

# Rope project settings
.ropeproject
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
VERSION=1.2.5
VERSION=1.3.0

default: build

Expand Down
18 changes: 13 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@ scrape_configs:
The docker images are available via:
```bash
$ docker pull pambrose/prometheus-proxy:1.2.5
$ docker pull pambrose/prometheus-agent:1.2.5
$ docker pull pambrose/prometheus-proxy:1.3.0
$ docker pull pambrose/prometheus-agent:1.3.0
```

Start the proxy and an agent in separate shells on your local machine:
Expand All @@ -94,14 +94,14 @@ Start the proxy and an agent in separate shells on your local machine:
$ docker run --rm -p 8082:8082 -p 8092:8092 -p 50051:50051 -p 8080:8080 \
-e HOSTNAME=${HOSTNAME} \
-e METRICS_ENABLED=true \
pambrose/prometheus-proxy:1.2.5
pambrose/prometheus-proxy:1.3.0
```

```bash
$ docker run --rm -p 8083:8083 -p 8093:8093 \
-e HOSTNAME=${HOSTNAME} \
-e AGENT_CONFIG='https://raw.githubusercontent.com/pambrose/prometheus-proxy/master/examples/simple.conf' \
pambrose/prometheus-agent:1.2.5
pambrose/prometheus-agent:1.3.0
```

Using the config file [simple.conf](https://raw.githubusercontent.com/pambrose/prometheus-proxy/master/examples/simple.conf),
Expand Down Expand Up @@ -180,4 +180,12 @@ The path names can be changed in the configuration file. To disable an admin ser

* [Prometheus.io](http://prometheus.io)
* [gRPC](http://grpc.io)
* [Typesafe Config](https://github.com/typesafehub/config)
* [Typesafe Config](https://github.com/typesafehub/config)
* [Zipkin]()

## Zipkin

* Run a Zipkin server with: `docker run -d -p 9411:9411 openzipkin/zipkin`
* View Zipkin info at http://localhost:9411

Details on the Zipkin container are [here](https://github.com/openzipkin/docker-zipkin).
2 changes: 1 addition & 1 deletion bin/docker-agent.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
docker run --rm -p 8083:8083 -p 8093:8093 \
-e HOSTNAME=${HOSTNAME} \
-e AGENT_CONFIG='https://raw.githubusercontent.com/pambrose/prometheus-proxy/master/examples/simple.conf' \
pambrose/prometheus-agent:1.2.5
pambrose/prometheus-agent:1.3.0
2 changes: 1 addition & 1 deletion bin/docker-proxy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
docker run --rm -p 8082:8082 -p 8092:8092 -p 50051:50051 -p 8080:8080 \
-e HOSTNAME=${HOSTNAME} \
-e PROXY_CONFIG='https://raw.githubusercontent.com/pambrose/prometheus-proxy/master/examples/simple.conf' \
pambrose/prometheus-proxy:1.2.5
pambrose/prometheus-proxy:1.3.0
5 changes: 2 additions & 3 deletions etc/compose/proxy.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
prometheus-proxy:
autoredeploy: true
image: 'pambrose/prometheus-proxy:1.2.5'
image: 'pambrose/prometheus-proxy:1.3.0'
ports:
- '8080:8080'
- '8082:8082'
- '8092:8092'
- '50051:50051'
environment:
- PROXY_CONFIG=https://dl.dropboxusercontent.com/u/481551/prometheus/cloud-proxy.conf

- PROXY_CONFIG=https://raw.githubusercontent.com/pambrose/config-data/master/prometheus-proxy/cloud-proxy.conf

prometheus-test:
autoredeploy: true
Expand Down
4 changes: 2 additions & 2 deletions etc/config/config.conf
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ proxy {
enabled = false
hostname = "localhost"
port = 9411
path = "api/v1/spans"
path = "api/v2/spans"
serviceName = "prometheus-proxy"
grpcReportingEnabled = false
}
Expand Down Expand Up @@ -124,7 +124,7 @@ agent {
enabled = false
hostname = "localhost"
port = 9411
path = "api/v1/spans"
path = "api/v2/spans"
serviceName = "prometheus-agent"
grpcReportingEnabled = false
}
Expand Down
2 changes: 1 addition & 1 deletion etc/docker/agent.df
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@ RUN ./mvnw -DskipTests=true clean package && \
rm -rf /root/.m2 .mvn etc src target/*.jar target/protoc* target/maven* target/generated* target/archive* target/test-classes

EXPOSE 8083
expose 8093
EXPOSE 8093

ENTRYPOINT ["/prometheus-proxy/target/bin/agent.sh"]
Loading

0 comments on commit e4d8380

Please sign in to comment.