Walkthru on downloading and installing ACS

ACS and a Database

ACS uses SQL database to store raw data. This requirement is not optional, and requires one of MySQL, MariaDB, or PostgreSQL. Further databases may be explored if needed. This manual is targeted towards unix flavors of installs. These database are available on Windows platforms, but this is more the exception than the rule.

These are general configuration instructions for handling mostly stock install. If you have advanced tweaking, security policies, or build from source, you are mostly on your own here, but can follow along.

Requirements

ACS requires one of:

  • MariaDB >= 10.3
  • MySQL >= 8.0
  • PostgreSQL >= 10.0

ACS configuration

ACS searches for configuration by starting with a built in known-working configuration set, and then proceeds to load configuration from a predefined set of folders that may contain any number of YAML files. Folders are searched in order, and the contents are loaded in ASCIIbetically ordered. To get an ordered list of folders searched in, you must run acs search-paths, but at the time of writing this document on a linux system uses the following

  • /etc/ACS
  • /usr/share/ACS
  • ${HOME}/.acs
  • ${HOME}/.share/ACS

If you have not already done so, make the directory: mkdir -p ${HOME}/.acs

Database Setup

This document attempts to give general guidance on setting up a database server for ACS to user. For sake of consistency, this document assumes the following.

Settings Value
Database username acs
Database password acs-password
Database acs

PostgreSQL

  • Install postgres via your package manager or similar

    • Redhat & Clones: yum install postgres or dnf install postgres
    • Ubuntu apt install postgresql postgresql-contrib
    • FreeBSD pkg install postgresql postgresql-contrib
  • Ensure the daemon is running via systemctl status postgresql or similar.
  • Create the needed database user, table, etc:
sudo -u postgres psql
postgres $ create database acs;
postgres $ create user acs with encrypted password 'acs-password';
postgres $ grant all privileges on database acs to acs;
  • Modify, or create ${HOME}/.acs/db.yaml to match the settings mentioned above:
---
Database:
  Driver: postgres
  Source: "host=localhost port=5432 user=acs dbname=acs sslmode=disable password=acs-password"
  • Verify that this is being loaded properly via acs db-show
Config located the following files in "${HOME}/.acs"
        - /home/avaps/.acs/db.yaml
        - /home/avaps/.acs/general.yaml
Driver                  : postgres
Max # Connections       : 5
Connection String       : host=localhost port=5432 user=acs dbname=acs sslmode=disable password=acs-password
Pragma                  : <None>
  • Attempt to create the needed database tables via acs db-create. If everything went as expected, you should see something like below printed on the terminal:
Config located the following files in "${HOME}/.acs"
        - /home/avaps/.acs/db.yaml
        - /home/avaps/.acs/general.yaml
Successfully connected and created needed tables

MySQL

MariaDB