Skip to content
This repository has been archived by the owner on Jun 10, 2020. It is now read-only.

Micro application that manages links and banners, rotate them, with a single public endpoint to see those banners

License

Notifications You must be signed in to change notification settings

Wolnosciowiec-Archive/banner-rotator

Repository files navigation

Banner Rotator

Docker Build Status MicroBadger Layers

Banner rotating service. Outputs a list of banners in HTML and JSON formats, has an API documentation.

Originally made for the Anarchist movement

The project was made on a request of Anarchist Federation. It is published on a free license to use for everyone.

Quick start

  1. Install required: PHP 7.2, GNU Make, php-sqlite
  2. Clone the repository
  3. Do the setup: make build setup_database_first_time
  4. Start the application: make start_dev

Endpoints documentation

Use /public/doc endpoint to access the documentation. Also, there is an exported list of routes for Postman in postman.json

Docker

There exists a Docker image named wolnosciowiec/news-feed-provider at the official Docker registry. To manually build an image use make build@x86_64

Please take a look at the ENV section of a Dockerfile to see the list of possible environment variables to pass to configure your application.

sudo docker run -e DATABASE_URL="sqlite:///%kernel.project_dir%/var/data.db" -e SITE_TITLE="List of grassroot, libertarian trade unions" -d --rm --name nfp wolnosciowiec/banner-rotator

You can also build a docker image by yourself that will be tagged the same as it is on docker hub.

# for regular x86_64 (amd64)
make build@x86_64

# for ARMv7 architecture
make build@arm7hf