Skip to content

Commit

Permalink
Merge pull request #9 from amnezia-vpn/new_registry
Browse files Browse the repository at this point in the history
New registry
  • Loading branch information
shipilovds authored Aug 12, 2024
2 parents a5f2d29 + bfff106 commit b31a996
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 5 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/docker-build-and-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ jobs:
make docker
env:
DOCKER_IMAGE: ghcr.io/${{ github.repository }}
DOCKER_USER: ${{ github.actor }}
DOCKER_PASSWORD: ${{ secrets.GITHUB_TOKEN }}
DOCKER_REGISTRY:
DOCKER_IMAGE: amneziavpn/amneziawg-exporter
DOCKER_USER: ${{ secrets.DOCKERHUB_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKERHUB_TOKEN }}
21 changes: 20 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,27 @@ The following environment variables can be used to configure amneziawg-exporter.
> [!NOTE]
> Every metric receives a `peer` label to identify the AmneziaWG peer, and `client_name` to identify the client if client table is enabled.
## Docker image

The Docker image is built using the [Dockerfile](Dockerfile) available in this repository. You can easily obtain it from [DockerHub](https://hub.docker.com/r/amneziavpn/amneziawg-exporter) by running the command `docker pull amneziavpn/amneziawg-exporter.`


## Example usage

### Build binary

```sh
make build
```

### Build docker image

```sh
make docker
```

### Run in docker

You can use example [docker-compose.yml](docker-compose.yml) with Docker Compose v2 to run AmneziaWG exporter:

```sh
Expand All @@ -56,5 +75,5 @@ You can use example [docker-compose.yml](docker-compose.yml) with Docker Compose
✔ Container amneziawg-exporter Started 0.2s
# docker compose ps
NAME IMAGE COMMAND SERVICE CREATED STATUS PORTS
amneziawg-exporter ghcr.io/amnezia-vpn/amneziawg-exporter:2.0.0 "/usr/bin/amneziawg-exporter" amneziawg-exporter 23 seconds ago Up 23 seconds
amneziawg-exporter amneziavpn/amneziawg-exporter:2.0.0 "/usr/bin/amneziawg-exporter" amneziawg-exporter 23 seconds ago Up 23 seconds
```
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
services:
amneziawg-exporter:
image: ghcr.io/shipilovds/amneziawg-exporter:1.0.0
image: amneziavpn/amneziawg-exporter:2.0.0
container_name: amneziawg-exporter
cap_add:
- NET_ADMIN
Expand Down

0 comments on commit b31a996

Please sign in to comment.