Update deployment details
This commit is contained in:
parent
dbe5cb2985
commit
f065300113
8
README
8
README
@ -33,7 +33,15 @@ own hardware.
|
|||||||
|
|
||||||
DEPLOYMENT
|
DEPLOYMENT
|
||||||
|
|
||||||
|
Only Nix build instructions targeting containers are provided below,
|
||||||
|
but this project can be built and run without containers or Nix using Cabal.
|
||||||
|
|
||||||
|
- Clone this repository
|
||||||
|
- Build the container image (with flakes enabled): `nix build .#purr-container`
|
||||||
|
- Load the container image
|
||||||
|
- podman load -i result
|
||||||
|
- Use the provided docker stack example to deploy the container if desired
|
||||||
|
- docker stack deploy -c docker-stack.yml purr
|
||||||
|
|
||||||
DEVELOPMENT & SUPPORT
|
DEVELOPMENT & SUPPORT
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
ENVIRONMENT="production"
|
ENVIRONMENT="production"
|
||||||
APPLICATIONHOST="localhost"
|
APPLICATIONHOST="localhost"
|
||||||
APPLICATIONPORT="3000"
|
APPLICATIONPORT="3000"
|
||||||
DATAPATH="./"
|
DATADIR="./"
|
||||||
DBFILE="data/Purr.sqlite"
|
DBFILE="data/Purr.sqlite"
|
||||||
LINKLENGTH="24"
|
LINKLENGTH="24"
|
||||||
ADMINEMAIL="admin@purr.example.com"
|
ADMINEMAIL="admin@purr.example.com"
|
||||||
|
@ -8,8 +8,8 @@ services:
|
|||||||
networks:
|
networks:
|
||||||
- webnet
|
- webnet
|
||||||
volumes:
|
volumes:
|
||||||
- ./data/Purr.sqlite:/app/data/Purr.sqlite
|
- ./data:/app/data
|
||||||
- ./config.dhall:/app/config.dhall
|
- ./.env:/app/.env
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
webnet:
|
webnet:
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
let
|
let
|
||||||
pkgs = nixpkgs.legacyPackages.${system};
|
pkgs = nixpkgs.legacyPackages.${system};
|
||||||
packageName = "purr";
|
packageName = "purr";
|
||||||
dockerPackageName = "${packageName}-docker";
|
containerPackageName = "${packageName}-container";
|
||||||
|
|
||||||
haskellPackages = pkgs.haskellPackages;
|
haskellPackages = pkgs.haskellPackages;
|
||||||
|
|
||||||
@ -37,7 +37,7 @@
|
|||||||
};
|
};
|
||||||
devShell = self.devShells.${system}.default;
|
devShell = self.devShells.${system}.default;
|
||||||
|
|
||||||
packages.${dockerPackageName} = pkgs.dockerTools.buildImage {
|
packages.${containerPackageName} = pkgs.dockerTools.buildImage {
|
||||||
name = "purr";
|
name = "purr";
|
||||||
|
|
||||||
copyToRoot = pkgs.buildEnv {
|
copyToRoot = pkgs.buildEnv {
|
||||||
@ -50,6 +50,7 @@
|
|||||||
Cmd = [
|
Cmd = [
|
||||||
"/bin/Purr"
|
"/bin/Purr"
|
||||||
];
|
];
|
||||||
|
WorkingDir = "/app";
|
||||||
ExposedPorts = {
|
ExposedPorts = {
|
||||||
"3000/tcp" = {};
|
"3000/tcp" = {};
|
||||||
};
|
};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user