Skip to content

admarrs/module.sql

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

51 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Duct module.sql

A Duct module that adds a SQL database connection pool and Ragtime migrations to a configuration.

Installation

To install, add the following to your project :dependencies:

[duct/module.sql "0.4.2"]

Usage

To add this module to your configuration, add the :duct.module/sql key:

{:duct.module/sql {}}

By default the module looks for a database URL in the JDBC_DATABASE_URL and DATABASE_URL environment variables, but you can specify it directly by setting the :database-url key:

{:duct.module/sql {:database-url "jdbc:sqlite:db/example.sqlite"}}

To add migrations:

{:duct.migrator/ragtime {:migrations [#ig/ref :example.migration/create-foo]}}

See migrator.ragtime for more information.

License

Copyright © 2017 James Reeves

Distributed under the Eclipse Public License either version 1.0 or (at your option) any later version.

About

Duct module for working with a SQL database

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Clojure 100.0%