aboutsummaryrefslogtreecommitdiff
path: root/cluster/prod/app/cryptpad/build/docker.nix
blob: 16bb1342d36793688c3cdea00daf2cc13f10393d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
{ pkgs ? import <nixpkgs> {}

, name ? "cryptpad"
, tag ? "nix-latest"

, withOnlyOffice ? true

, cryptpad ? pkgs.callPackage ./default.nix { inherit withOnlyOffice; }
}: let
  cryptpad' = cryptpad.overrideAttrs {
    postInstall = ''
      ln -sf /cryptpad/customize $out/customize
    '';
  };
in pkgs.dockerTools.buildImage {
  inherit name tag;

  config = {
    Cmd = [
      (pkgs.lib.getExe cryptpad')
    ];

    Volumes = {
      "/cryptpad/customize" = {};
    };
  };
}