database

Databases

Sparky keeps it's data in database, by default it uses sqlite, following databases are supported:

  • SQLite

  • MySQL/MariaDB

  • PostgreSQL

Configuring database

Following is an example for MySQL database, the same rules are applied for other database, like PostgreSQL, etc.

Create Sparky configuration file

You should defined database engine and connection parameters, say we want to use MySQL:

$ nano ~/sparky.yaml

With content:

database:
  engine: mysql
  host: $dbhost
  port: $dbport
  name: $dbname
  user: $dbuser
  pass: $dbpassword

For example:

database:
  engine: mysql
  host: "127.0.0.1"
  port: 3306
  name: sparky
  user: sparky
  pass: "123"

Installs dependencies

Depending on platform it should be client needed for your database API, for example for Debian we have to:

$ sudo yum install mysql-client

Creating database user, password and schema

DB init script will generate database schema, provided that user defined and sparky configuration file has access to the database:

$ raku db-init.raku

That is it, now Sparky runs under MySQL!

Sparky v0.2.32

Sparky is a flexible and minimalist continuous integration server and distribute tasks runner written in Raku

Authors

  • Alexey Melezhik

License

Artistic-2.0

Dependencies

YAMLishDBIishDBIish::PoolJSON::FastHTTP::TinySparrow6:ver<0.0.90+>Sparrowdo:ver<0.1.54+>Sparky-Job-Api:ver<0.0.12+>Time::CrontabFile::Directory::TreecroCro::HTTP:ver<0.8.9+>Cro::HTTP::ServerCro::HTTP::RouterCro::WebApp::TemplateData::Dump:ver<0.0.12+>Text::Markdown

Test Dependencies

Provides

  • Sparky
  • Sparky::HTML
  • Sparky::Job
  • Sparky::Security
  • Sparky::Utils

The Camelia image is copyright 2009 by Larry Wall. "Raku" is trademark of the Yet Another Society. All rights reserved.

Built with Podlite — the markup and publishing tools behind this site.