about summary refs log tree commit diff
path: root/nixpkgs/doc/builders/images/snap/example-hello.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/doc/builders/images/snap/example-hello.nix')
-rw-r--r--nixpkgs/doc/builders/images/snap/example-hello.nix12
1 files changed, 12 insertions, 0 deletions
diff --git a/nixpkgs/doc/builders/images/snap/example-hello.nix b/nixpkgs/doc/builders/images/snap/example-hello.nix
new file mode 100644
index 000000000000..123da80c5477
--- /dev/null
+++ b/nixpkgs/doc/builders/images/snap/example-hello.nix
@@ -0,0 +1,12 @@
+let
+  inherit (import <nixpkgs> { }) snapTools hello;
+in snapTools.makeSnap {
+  meta = {
+    name = "hello";
+    summary = hello.meta.description;
+    description = hello.meta.longDescription;
+    architectures = [ "amd64" ];
+    confinement = "strict";
+    apps.hello.command = "${hello}/bin/hello";
+  };
+}