Skip to content

Commit

Permalink
Merge pull request #4 from whimsical-c4lic0/feature/update-docker
Browse files Browse the repository at this point in the history
Feature/update docker
  • Loading branch information
whimsical-c4lic0 authored Apr 30, 2024
2 parents f90ac52 + ce85ce4 commit f79a862
Show file tree
Hide file tree
Showing 4 changed files with 43 additions and 7 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Publish Docker image

on:
push:
branches:
- 'master'
schedule:
- cron: 0 0 * * 0 # Weekly
workflow_dispatch:

jobs:
push_to_registry:
name: Push docker image to registry
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Login to ghcr
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: .
push: true
tags: ghcr.io/${{ github.actor }}/streamonitor:latest

9 changes: 3 additions & 6 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
# syntax=docker/dockerfile:1

FROM python:3.10-slim-buster
FROM python:3.12-alpine3.19

RUN \
# Install additional dependencies
apt update && \
apt install -y ffmpeg && \
rm -rf /var/cache/apt/lists ;
# Install dependencies
RUN apk add --no-cache ffmpeg

WORKDIR /app

Expand Down
1 change: 1 addition & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@ services:
- ./parameters.py:/app/parameters.py
ports:
- '6969:6969'
- '5000:5000'
2 changes: 1 addition & 1 deletion streamonitor/managers/httpmanager.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,4 +60,4 @@ def recordings():
output += "<p>No recordings</p>"
return output

app.run(host='127.0.0.1', port=5000)
app.run(host='0.0.0.0', port=5000)

0 comments on commit f79a862

Please sign in to comment.