Skip to content

Festivals-App/festivals-server

Repository files navigation



Festivals App Server

A lightweight service providing a RESTful API, called FestivalsAPI. The FestivalsAPI exposes all data functions needed by the FestivalsApp.

Figure 1: Architecture Overview Highlighted


DevelopmentDeploymentEngage


Development

The developement of the FestivalsAPI (see documentation) and the festivals-server is heavily dependend on the festivals-api-ios and the festivals-database which provides the persistent storage to the FestivalsAPI. In my regular development workflow i first mock the needed behaviour in the API client library and then start implementing the changes in the festivals-server and after that in the festivals-database. To test whether the festivals-server is working correctly i'm currently relying on downstream tests of the festivals-api-ios framework.

To find out more about the architecture and technical information see the ARCHITECTURE document. The general documentation for the Festivals App is in the festivals-documentation repository. The documentation repository contains architecture information, general deployment documentation, templates and other helpful documents.

Requirements

Deployment

The Go binaries are able to run without system dependencies so there are not many requirements for the system to run the festivals-server binary. The config file needs to be placed at /etc/festivals-server.conf or the template config file needs to be present in the directory the binary runs in.

You also need to provide certificates in the right format and location:

  • The default path to the root CA certificate is /usr/local/festivals-server/ca.crt
  • The default path to the server certificate is /usr/local/festivals-server/server.crt
  • The default path to the corresponding key is /usr/local/festivals-server/server.key
  • The default path to the database client certificate is /usr/local/festivals-server/database-client.crt
  • The default path to the corresponding key is /usr/local/festivals-server/database-client.key

Where the root CA certificate is required to validate incoming requests, the server certificate and key is required to make outgoing connections and the database client certificate and key is required to make connections to the festivals-database service. For instructions on how to manage and create the certificates see the festivals-pki repository.

VM

The install, update and uninstall scripts should work with any system that uses systemd and firewalld. Additionally the scripts will somewhat work under macOS but won't configure the firewall or launch service.

#Installing
curl -o install.sh https://raw.githubusercontent.com/Festivals-App/festivals-server/main/operation/install.sh
chmod +x install.sh
sudo ./install.sh

#Updating
curl -o update.sh https://raw.githubusercontent.com/Festivals-App/festivals-server/main/operation/update.sh
chmod +x update.sh
sudo ./update.sh

#To see if the server is running use:
sudo systemctl status festivals-server

Build and run using make

make build
make run
# Default API Endpoint : http://localhost:10439

Engage

I welcome every contribution, whether it is a pull request or a fixed typo. The best place to discuss questions and suggestions regarding the festivals-server is the issues section. More general information and a good starting point if you want to get involved is the festival-documentation repository.

The following channels are available for discussions, feedback, and support requests:

Type Channel
General Discussion
Other Requests

Licensing

Copyright (c) 2017-2024 Simon Gaus. Licensed under the GNU Lesser General Public License v3.0