Skip to content

Commit

Permalink
Merge pull request #2 from BudgetSmartHome/feature/build_arm_images
Browse files Browse the repository at this point in the history
Build images for amd64, armv6, armv7, and arm64
  • Loading branch information
proffalken authored Feb 24, 2021
2 parents f311578 + 66bb1b5 commit e4ce053
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
6 changes: 6 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,11 @@ jobs:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}

- name: Set up QEMU
uses: docker/setup-qemu-action@master
with:
platforms: all

- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v1
Expand All @@ -48,6 +53,7 @@ jobs:
context: ./
file: ./Dockerfile
push: true
platforms: linux/amd64, linux/arm/v7, linux/arm/v6, linux/arm64
tags: ${{ steps.docker_meta.outputs.tags }}
labels: ${{ steps.docker_meta.outputs.labels }}

Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ COPY templates /app/templates

WORKDIR /app

RUN pip install -r requirements.txt
RUN /usr/bin/python3 -m pip install -r requirements.txt

EXPOSE 5000

Expand Down
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ in the MakerAPI settings on your Hubitat device.

Next, run the following command to start the container:

`docker run -v "$(pwd)"/config:/app/config -p 5000:5000 proffalken/hubitat2prom:latest`
`docker run --privileged -v "$(pwd)"/config:/app/config -p 5000:5000 proffalken/hubitat2prom:latest`

**NOTE: THE CONTAINER REQUIRES PRIVILEGED ACCESS WHEN RUNNING ON ARM ARCHITECTURE DUE TO [THIS ISSUE](https://github.com/BudgetSmartHome/hubitat2prom/issues/4).**

This will start the container listening on your local machine on port 5000, and you can visit
[http://localhost:5000/metrics](http://localhost:5000/metrics) to confirm that the metrics are coming through.
Expand Down

0 comments on commit e4ce053

Please sign in to comment.