Skip to content

Commit

Permalink
Merge pull request #3 from Allram/master
Browse files Browse the repository at this point in the history
Update dashboard-immich.json and some translations/naming
  • Loading branch information
friendlyFriend4000 authored Aug 22, 2023
2 parents 3c6d7ef + f6d9520 commit c23ad91
Show file tree
Hide file tree
Showing 5 changed files with 353 additions and 139 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ RUN pip3 install .

ENV IMMICH_API_TOKEN=""
ENV IMMICH_HOST=""
ENV IMMICH_PORT=""
ENV IMMICH_PORT="8080"
#has to be EXPORT_PORT 8000 or else it does not work, same applies to the env file
ENV EXPORTER_PORT="8000"
ENV EXPORTER_LOG_LEVEL="INFO"
Expand Down
23 changes: 6 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,35 +5,24 @@ A prometheus exporter for Immich. Get metrics from a server and offers them in a

## How to use it

You can install this exporter with the following command:
Here is an example docker run command

```bash
pip3 install prometheus-qbittorrent-exporter
```

Then you can run it with

```
immich-exporter
```

Another option is to run it in a docker container. Here is an example docker run command

```
docker run -e IMMICH_PORT=8010 -e IMMICH_HOST=192.168.178.1 -p 8000:8000 friendlyfriend/prometheus-immich-exporter
docker run -e IMMICH_PORT=8080 -e IMMICH_HOST=192.168.178.1 -e IMMICH_API_TOKEN=TOKEN -p 8000:8000 friendlyfriend/prometheus-immich-exporter
```
Add this to your prometheus.yml
```
- job_name: "qbittorrent_exporter"
- job_name: "Immich_exporter"
static_configs:
- targets: ['yourimmichexporter:port']
```
The application reads configuration using environment variables:

| Environment variable | Default | Description |
|----------------------|----------|----------------------------------------------------|
| `IMMICH_HOST` | | immich server hostname |
| `IMMICH_PORT` | | immich server port |
| `IMMICH_HOST` | | Immich proxy url |
| `IMMICH_PORT` | `8080` | Immich proxy port |
| `IMMICH_API_TOKEN` | | Immich API token, created from Immich dashboard |
| `EXPORTER_PORT` | `8000` | Exporter listening port |
| `EXPORTER_LOG_LEVEL` | `INFO` | Log level. One of: `DEBUG`, `INFO`, `WARNING`, `ERROR`, `CRITICAL` |
| `METRICS_PREFIX` | `immich` | Prefix to add to all the metrics |
Expand Down
2 changes: 1 addition & 1 deletion grafana/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Import

To import the dashboard into your grafana, download the [dashboard.json](https://raw.githubusercontent.com/friendlyFriend/immich-qbittorrent-exporter/master/grafana/dashboard.json) file and import it into your server. Select your prometheus instance and that should be all.
To import the dashboard into your grafana, download the [dashboard.json](https://github.com/friendlyFriend4000/prometheus-immich-exporter/raw/master/grafana/dashboard-immich.json) file and import it into your server. Select your prometheus instance and that should be all.

The graphs can be customized in their relative time. Mind that it takes time to populate them if you set relative time to monthly or yearly

Expand Down
Loading

0 comments on commit c23ad91

Please sign in to comment.