tvl-depot/nix_gcr/cloud_run.nix
William Carroll 8562bf5b5a Rename //deploy -> //nix_gcr
I create //deploy when I first deployed a few applications that I
packaged with Nix. This was before I setup socrates as my "cloud". Now I
deploy all of my services using NixOS. The name "deploy" is a bit stale.
I'm renaming it //nix_gcr because it documents how I can deploy
Nix-packaged projects on Google Cloud Run.
2020-04-05 15:40:47 +01:00

18 lines
322 B
Nix

{
pkgs ? import <nixpkgs> {},
depot ? import <depot> {},
...
}:
pkgs.dockerTools.buildLayeredImage {
name = "gemma";
tag = "latest";
config.ExposedPorts = {
"4242" = {};
};
config.Env = [
"GEMMA_CONFIG=${./config.lisp}"
];
config.Cmd = [ "${depot.fun.gemma}/bin/gemma" ];
maxLayers = 120;
}