iNecas / fsharp-sqlite

An example project using F# and SQLite

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

FSharpSqlite

An example project using F# and SQLite, that involves:

  • defining and running DB in F# using fluentmigrator
  • setup of SqlProvider with SQLite (involving copying the files to right place)
  • using SqlProvider to work with the data
  • running on top of dotnet core v3.0 using Linux containers

Usage

The simplest way to get the reproducible setup is to use Linux containers. This instructions prefer Buildah and Podman over docker, as they don't need any additional daemon to be running on the system. Corresponding docker commands should still work though.

Building app container

To build the sample application image, run:

buildah bud -t inecas/fsharp-sqlite .

This will download the dotnet core v3 SDK image and will prepare the setup for running the application.

Usage

podman run --rm -ti --name inecas-fsharp-sqlite inecas/fsharp-sqlite
dotnet run -p src/FSharpSqlite.Use
# outputs: John's id is 1

About

An example project using F# and SQLite


Languages

Language:F# 90.8%Language:Dockerfile 9.2%