Commit 7eee3fde authored by David Trattnig's avatar David Trattnig
Browse files

Merge branch 'develop' of gitlab.servus.at:aura/engine-api into develop

parents fbf675e8 8e3cb984
Pipeline #1175 passed with stages
in 4 minutes and 36 seconds
......@@ -3,35 +3,35 @@
<!-- TOC -->
1. [Engine API Server](#engine-api-server)
1. [Overview](#overview)
2. [Deployment Modes](#deployment-modes)
1. [Single Deployment](#single-deployment)
2. [Redundant Deployment](#redundant-deployment)
1. [Managing Active Engine State](#managing-active-engine-state)
2. [Playlog Synchronization for High Availability deployment scenarios](#playlog-synchronization-for-high-availability-deployment-scenarios)
1. [Active Sync](#active-sync)
2. [Passive Sync](#passive-sync)
3. [Getting started](#getting-started)
1. [Requirements](#requirements)
2. [Installation](#installation)
1. [Setting up the database](#setting-up-the-database)
3. [Configuration](#configuration)
1. [Engine 1 Node](#engine-1-node)
2. [Engine 2 Node](#engine-2-node)
3. [Synchronization Node](#synchronization-node)
4. [Running the Server](#running-the-server)
1. [Development](#development)
2. [Production](#production)
3. [Running with Systemd](#running-with-systemd)
4. [Running with Supervisor](#running-with-supervisor)
5. [Running with Docker](#running-with-docker)
5. [Development](#development-1)
1. [Using the API](#using-the-api)
2. [Extending the API](#extending-the-api)
3. [Creating a local image](#creating-a-local-image)
4. [Publish new image](#publish-new-image)
6. [Logging](#logging)
2. [About](#about)
1. [Overview](#overview)
2. [Deployment Modes](#deployment-modes)
1. [Single Deployment](#single-deployment)
2. [Redundant Deployment](#redundant-deployment)
1. [Managing Active Engine State](#managing-active-engine-state)
2. [Playlog Synchronization for High Availability deployment scenarios](#playlog-synchronization-for-high-availability-deployment-scenarios)
1. [Active Sync](#active-sync)
2. [Passive Sync](#passive-sync)
3. [Getting started](#getting-started)
1. [Requirements](#requirements)
2. [Installation](#installation)
1. [Setting up the database](#setting-up-the-database)
3. [Configuration](#configuration)
1. [Engine 1 Node](#engine-1-node)
2. [Engine 2 Node](#engine-2-node)
3. [Synchronization Node](#synchronization-node)
4. [Running the Server](#running-the-server)
1. [Development](#development)
2. [Production](#production)
3. [Running with Systemd](#running-with-systemd)
4. [Running with Supervisor](#running-with-supervisor)
5. [Running with Docker](#running-with-docker)
5. [Development](#development-1)
1. [Using the API](#using-the-api)
2. [Extending the API](#extending-the-api)
3. [Creating a local image](#creating-a-local-image)
4. [Publish new image](#publish-new-image)
6. [Logging](#logging)
7. [About](#about)
<!-- /TOC -->
......@@ -124,7 +124,7 @@ If you are not planning to go with Docker or just want to setup a local developm
For Production use you also need following:
- [Gunicorn](https://gunicorn.org/), or any other compatible WSGI server
### Installation
Create a virtual environment for your Python dependencies:
......@@ -173,7 +173,7 @@ engine-api$ cp config/sample/sample-docker.engine-api.ini config/docker/engine-a
Now edit the configuration file. If you trust all the defaults you'll only need to change the database password.
For some deployment like production you may want to change the default port too.
For some deployment like production you may want to change the default port too.
In this case also set the correct IP and port in `gunicorn.conf.py` file.
> You might also need to 'open' the chosen port in your `iptables` (Default is 8008)
......@@ -424,16 +424,13 @@ If you are developer and want to publish a new image to DockerHub, run
The Engine API logs can be found under `./logs`.
# About
Aura Engine API is the API interface for the play-out engine of the [Aura Radio Software Suite](https://gitlab.servus.at/aura/meta).
This project is based on a swagger-enabled Flask server using an *API First* approach. It also uses the [Connexion](https://github.com/zalando/connexion) library on top of Flask.
## About
[<img src="https://gitlab.servus.at/autoradio/meta/-/raw/master/assets/images/aura-logo.png" width="150" />](https://gitlab.servus.at/aura/meta)
AURA stands for Automated Radio and is a swiss army knife for community radio stations. Beside the Engine it provides Steering (Admin Interface for the radio station), Dashboard (Collaborative scheduling and programme coordination), Tank (Audio uploading, pre-processing and delivery). Read more in the [Aura Meta](https://gitlab.servus.at/aura/meta) repository or on the specific project pages.
Automated Radio (AURA) is a open source software suite for community radio stations. Learn more about AURA in the [Meta repository](https://gitlab.servus.at/aura/meta).
| [<img src="https://gitlab.servus.at/aura/meta/-/raw/master/assets/images/aura-steering.png" width="150" align="left" />](https://gitlab.servus.at/aura/steering) | [<img src="https://gitlab.servus.at/aura/meta/-/raw/master/assets/images/aura-dashboard.png" width="150" align="left" />](https://gitlab.servus.at/aura/dashboard) | [<img src="https://gitlab.servus.at/aura/meta/-/raw/master/assets/images/aura-tank.png" width="150" align="left" />](https://gitlab.servus.at/aura/tank) | [<img src="https://gitlab.servus.at/aura/meta/-/raw/master/assets/images/aura-engine.png" width="150" align="left" />](https://gitlab.servus.at/aura/engine) |
|---|---|---|---|
| [Steering](https://gitlab.servus.at/aura/steering) | [Dashboard](https://gitlab.servus.at/aura/dashboard)<br/>[Dashboard Clock](https://gitlab.servus.at/aura/dashboard-clock) | [Tank](https://gitlab.servus.at/aura/tank) | [Engine](https://gitlab.servus.at/aura/engine)<br/>[Engine API](https://gitlab.servus.at/aura/engine-api) |
\ No newline at end of file
| [Steering](https://gitlab.servus.at/aura/steering) | [Dashboard](https://gitlab.servus.at/aura/dashboard)<br/>[Dashboard Clock](https://gitlab.servus.at/aura/dashboard-clock) | [Tank](https://gitlab.servus.at/aura/tank) | [Engine](https://gitlab.servus.at/aura/engine)<br/>[Engine Core](https://gitlab.servus.at/aura/engine-core)<br/>[Engine API](https://gitlab.servus.at/aura/engine-api) |
......@@ -122,7 +122,7 @@ class PlayLog(db.Model):
if track:
# Station fallback may not provide a duration. Take this one, it's better than nothing.
if track.track_duration == 0:
if track.track_duration == 0 or not track.track_duration:
return track
# Preferably only get playlogs which are known for still being on air
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment