diff --git a/Makefile b/Makefile index 5411cec7..a794d43d 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -VERSION=1.9.2 +VERSION=1.10.0 default: compile @@ -64,4 +64,4 @@ refresh: ./gradlew --refresh-dependencies upgrade-wrapper: - ./gradlew wrapper --gradle-version=7.1 --distribution-type=bin \ No newline at end of file + ./gradlew wrapper --gradle-version=6.8.3 --distribution-type=bin \ No newline at end of file diff --git a/README.md b/README.md index d27b3a60..6009ba5a 100644 --- a/README.md +++ b/README.md @@ -108,8 +108,8 @@ scrape_configs: The docker images are available via: ```bash -docker pull pambrose/prometheus-proxy:1.9.2 -docker pull pambrose/prometheus-agent:1.9.2 +docker pull pambrose/prometheus-proxy:1.10.0 +docker pull pambrose/prometheus-agent:1.10.0 ``` Start a proxy container with: @@ -118,7 +118,7 @@ Start a proxy container with: docker run --rm -p 8082:8082 -p 8092:8092 -p 50051:50051 -p 8080:8080 \ --env ADMIN_ENABLED=true \ --env METRICS_ENABLED=true \ - pambrose/prometheus-proxy:1.9.2 + pambrose/prometheus-proxy:1.10.0 ``` Start an agent container with: @@ -126,7 +126,7 @@ Start an agent container with: ```bash docker run --rm -p 8083:8083 -p 8093:8093 \ --env AGENT_CONFIG='https://raw.githubusercontent.com/pambrose/prometheus-proxy/master/examples/simple.conf' \ - pambrose/prometheus-agent:1.9.2 + pambrose/prometheus-agent:1.10.0 ``` Using the config @@ -144,7 +144,7 @@ is in your current directory, run an agent container with: docker run --rm -p 8083:8083 -p 8093:8093 \ --mount type=bind,source="$(pwd)"/prom-agent.conf,target=/app/prom-agent.conf \ --env AGENT_CONFIG=prom-agent.conf \ - pambrose/prometheus-agent:1.9.2 + pambrose/prometheus-agent:1.10.0 ``` **Note:** The `WORKDIR` of the proxy and agent images is `/app`, so make sure to use `/app` as the base directory in the @@ -283,7 +283,7 @@ docker run --rm -p 8082:8082 -p 8092:8092 -p 50440:50440 -p 8080:8080 \ --env PROXY_CONFIG=tls-no-mutual-auth.conf \ --env ADMIN_ENABLED=true \ --env METRICS_ENABLED=true \ - pambrose/prometheus-proxy:1.9.2 + pambrose/prometheus-proxy:1.10.0 docker run --rm -p 8083:8083 -p 8093:8093 \ --mount type=bind,source="$(pwd)"/testing/certs,target=/app/testing/certs \ @@ -291,7 +291,7 @@ docker run --rm -p 8083:8083 -p 8093:8093 \ --env AGENT_CONFIG=tls-no-mutual-auth.conf \ --env PROXY_HOSTNAME=mymachine.lan:50440 \ --name docker-agent \ - pambrose/prometheus-agent:1.9.2 + pambrose/prometheus-agent:1.10.0 ``` **Note:** The `WORKDIR` of the proxy and agent images is `/app`, so make sure to use `/app` as the base directory in the diff --git a/bin/docker-agent.sh b/bin/docker-agent.sh index 54ff7974..b89e38ec 100755 --- a/bin/docker-agent.sh +++ b/bin/docker-agent.sh @@ -3,4 +3,4 @@ docker run --rm -p 8083:8083 -p 8093:8093 \ --env AGENT_CONFIG='https://raw.githubusercontent.com/pambrose/prometheus-proxy/master/examples/simple.conf' \ --env PROXY_HOSTNAME=mymachine.lan \ - pambrose/prometheus-agent:1.9.2 + pambrose/prometheus-agent:1.10.0 diff --git a/bin/docker-proxy.sh b/bin/docker-proxy.sh index 9474b64e..07cbb0de 100755 --- a/bin/docker-proxy.sh +++ b/bin/docker-proxy.sh @@ -2,4 +2,4 @@ docker run --rm -p 8082:8082 -p 8092:8092 -p 50051:50051 -p 8080:8080 \ --env PROXY_CONFIG='https://raw.githubusercontent.com/pambrose/prometheus-proxy/master/examples/simple.conf' \ - pambrose/prometheus-proxy:1.9.2 + pambrose/prometheus-proxy:1.10.0 diff --git a/build.gradle b/build.gradle index cf6a1c79..03af728e 100644 --- a/build.gradle +++ b/build.gradle @@ -1,13 +1,14 @@ plugins { id 'idea' id 'java' - id 'java-library' - id 'maven-publish' + //id 'java-library' + //id 'maven-publish' + id 'maven' id 'org.jmailen.kotlinter' version "3.4.5" id 'org.jetbrains.kotlin.jvm' version '1.5.20' id 'com.google.protobuf' version '0.8.16' id "com.github.ben-manes.versions" version '0.39.0' - id 'com.github.johnrengelman.shadow' version '7.0.0' + id 'com.github.johnrengelman.shadow' version '6.1.0' id 'com.github.gmazzo.buildconfig' version '3.0.1' // Turn these off until jacoco fixes their kotlin 1.5.0 SMAP issue // id 'jacoco' @@ -15,7 +16,7 @@ plugins { } group = 'io.prometheus' -version = '1.9.2' +version = '1.10.0' sourceCompatibility = 1.8 targetCompatibility = 1.8 @@ -120,7 +121,7 @@ configurations.all { //startScripts.enabled = false -task sourcesJar(type: Jar) { +task sourcesJar(type: Jar, dependsOn: classes) { from sourceSets.main.allJava archiveClassifier.set("sources") } @@ -130,16 +131,25 @@ task javadocJar(type: Jar, dependsOn: javadoc) { from javadoc.destinationDir } -publishing { - publications { - mavenAar(MavenPublication) { - from components.java - afterEvaluate { - artifact javadocJar - artifact sourcesJar - } - } - } +//publishing { +// publications { +// mavenAar(MavenPublication) { +// from components.java +// afterEvaluate { +// artifact javadocJar +// artifact sourcesJar +// } +// } +// } +//} + +//java { +// withSourcesJar() +//} + +artifacts { + archives sourcesJar + //archives javadocJar } //jacocoTestReport { diff --git a/etc/compose/proxy.yml b/etc/compose/proxy.yml index aaa84877..b2f90b81 100644 --- a/etc/compose/proxy.yml +++ b/etc/compose/proxy.yml @@ -1,6 +1,6 @@ prometheus-proxy: autoredeploy: true - image: 'pambrose/prometheus-proxy:1.9.2' + image: 'pambrose/prometheus-proxy:1.10.0' ports: - '8080:8080' - '8082:8082' diff --git a/etc/docker/agent.df b/etc/docker/agent.df index 96faf237..438df21d 100644 --- a/etc/docker/agent.df +++ b/etc/docker/agent.df @@ -24,4 +24,4 @@ EXPOSE 8093 CMD [] -ENTRYPOINT ["java", "-server", "-XX:+UnlockExperimentalVMOptions", "-XX:+UseG1GC", "-XX:MaxGCPauseMillis=100", "-XX:+UseStringDeduplication", "-jar", "/app/prometheus-agent.jar"] +ENTRYPOINT ["java", "-server", "-XX:+UnlockExperimentalVMOptions", "-XX:+UseG1GC", "-XX:MaxGCPauseMillis=100", "-XX:+UseStringDeduplication", "-jar", "/app/prometheus-agent.jar"] \ No newline at end of file diff --git a/etc/docker/proxy.df b/etc/docker/proxy.df index b843d257..432aad6c 100644 --- a/etc/docker/proxy.df +++ b/etc/docker/proxy.df @@ -1,6 +1,6 @@ - FROM alpine - MAINTAINER Paul Ambrose "pambrose@mac.com" - RUN apk add openjdk11-jre +FROM alpine +MAINTAINER Paul Ambrose "pambrose@mac.com" +RUN apk add openjdk11-jre # Define the user to use in this instance to prevent using root that even in a container, can be a security risk. ENV APPLICATION_USER prometheus @@ -27,4 +27,4 @@ EXPOSE 50440 CMD [] -ENTRYPOINT ["java", "-server", "-XX:+UnlockExperimentalVMOptions", "-XX:+UseG1GC", "-XX:MaxGCPauseMillis=100", "-XX:+UseStringDeduplication", "-jar", "/app/prometheus-proxy.jar"] +ENTRYPOINT ["java", "-server", "-XX:+UnlockExperimentalVMOptions", "-XX:+UseG1GC", "-XX:MaxGCPauseMillis=100", "-XX:+UseStringDeduplication", "-jar", "/app/prometheus-proxy.jar"] \ No newline at end of file diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 69a97150..442d9132 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-6.8.3-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists