From 9c5874ae14299a6f8c5f118b4cbed18a67061ba2 Mon Sep 17 00:00:00 2001 From: Cedric Verstraeten Date: Wed, 22 Apr 2020 22:17:24 +0200 Subject: [PATCH] add docker info --- .docz/.cache/async-requires.js | 3 +- .docz/.cache/babelState.json | 16 +- ...tore-0aba6c9a0ad3957e6773e032a84a2399.json | 2 +- ...tore-0ca793490a7bb4791f7c46ebaa6e0c8d.json | 2 +- ...tore-0d7f3f51699847bb4680d4d6678f8741.json | 1 + ...tore-0e0eb9e157331fb6122e7ab392cb3c8b.json | 2 +- ...tore-0f356c72f12f755bb1a43a120418c5ce.json | 2 +- ...tore-121c1de76a52ca34d1b049cd4f1606bf.json | 1 + ...tore-159f3a9ffbd7b0bfc9e3a064fc896e42.json | 2 +- ...tore-1d35799b0fd4a99ff0dbdd3b2f81aebf.json | 2 +- ...tore-25dd5b29c7f2c5a385f80ef779c21981.json | 1 + ...tore-2700cbe0fa446f181450db29e00f8f7f.json | 1 + ...tore-2be2590779b804ede018a8925fff1146.json | 2 +- ...tore-2d803be35bbfb2321ee72a233c028b37.json | 1 + ...tore-30153aa59279e74ec5bb4c16c59bfd3f.json | 1 + ...tore-3116a5c30580652aa7fed0ac6e1075d8.json | 1 + ...tore-32b2afad1d87d362789a8512873828bb.json | 2 +- ...tore-390c49abb652dc1d2fbce6848089e625.json | 2 +- ...tore-4145ced9d2b83f44f4a82c4861822fdb.json | 1 + ...tore-41b16d38bc61c17499eedf3de99373a4.json | 1 + ...tore-41e3f0e02f3884e0729d517829b6ddf0.json | 1 + ...tore-4caca5b4ef3dce40e34bf5769d6e80f8.json | 2 +- ...tore-539aed0f4600e6bb4755356ea1f96e11.json | 1 + ...tore-587ebbe6b511a59a683e298dd2fcbdff.json | 1 + ...tore-5a2db5ceca4a34135dfe60553b644651.json | 1 + ...tore-5d712ae2876bdd0cb73a797f6724f8d4.json | 1 + ...tore-5e5fc51818b1c919d294dfe9e2e6ea4c.json | 1 + ...tore-6115286b5fc0e2f7dc8d6a8998860d99.json | 1 + ...tore-646cb4d61844566a08621a365fbacccd.json | 2 +- ...tore-65439ff883bcb2669dd4fcb155646686.json | 2 +- ...tore-66f83e093accc4831e0aea1e3a1af16b.json | 1 + ...tore-708d54cc04f36632d6530d30f6b9e4d2.json | 1 + ...tore-94847925d58c4478a42fd8efb20158a8.json | 1 + ...tore-9a7c34ea4af7641209130611e67a9961.json | 1 + ...tore-9c0f902ec1f902379deebc0934cd225c.json | 1 + ...tore-9f4c0c5af3244082021f4985f686a308.json | 1 + ...tore-a07cf4b43fe03cb970799ca6225b026d.json | 1 + ...tore-a89b84451932065903e6bf25d9b03550.json | 2 +- ...tore-bb82aa854932c622ccbfd9f435edcc09.json | 2 +- ...tore-bf88f10bc76df564c81248fad75cc3c5.json | 1 + ...tore-c7806681374e300d3ec3b0d9c62563c5.json | 1 + ...tore-c8089618502ab2cbaca6c5ef0928b237.json | 1 + ...tore-d0b9eeeaa92d675686b9c7817a3167a8.json | 2 +- ...tore-d819a3072abd47de3d1d539ee0a87a44.json | 2 +- ...tore-da466c249906f950dfe169c53e70109c.json | 1 + ...tore-dffd70628d0005fccd26c6a05f8c2b37.json | 1 + ...tore-e84cb24fa982c1f2afd788562ec84293.json | 1 + ...tore-e8aa2a80b6d8b25efef29267ee82ea19.json | 2 +- ...tore-eac50b06b920771ba28638c45c44daed.json | 1 + ...tore-edd4f3646d51b29f3e3eea1608fd9493.json | 1 + .docz/.cache/dev-404-page.js | 145 ++++++++++++++++++ .docz/.cache/redux/redux.node.state_0 | Bin 607617 -> 651856 bytes .docz/.cache/redux/redux.rest.state | Bin 7972 -> 8446 bytes .docz/.cache/sync-requires.js | 3 +- .docz/app/db.json | 79 ++++++---- .docz/gatsby-node.js | 144 +++++++++++++++++ .docz/public/index.html | 3 +- .../opensource/installation/page-data.json | 2 +- .docz/public/static/d/1803957048.json | 2 +- src/open-source/installation.mdx | 142 +++++++++++------ 60 files changed, 495 insertions(+), 109 deletions(-) create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-0d7f3f51699847bb4680d4d6678f8741.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-121c1de76a52ca34d1b049cd4f1606bf.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-25dd5b29c7f2c5a385f80ef779c21981.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-2700cbe0fa446f181450db29e00f8f7f.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-2d803be35bbfb2321ee72a233c028b37.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-30153aa59279e74ec5bb4c16c59bfd3f.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-3116a5c30580652aa7fed0ac6e1075d8.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-4145ced9d2b83f44f4a82c4861822fdb.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-41b16d38bc61c17499eedf3de99373a4.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-41e3f0e02f3884e0729d517829b6ddf0.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-539aed0f4600e6bb4755356ea1f96e11.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-587ebbe6b511a59a683e298dd2fcbdff.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-5a2db5ceca4a34135dfe60553b644651.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-5d712ae2876bdd0cb73a797f6724f8d4.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-5e5fc51818b1c919d294dfe9e2e6ea4c.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-6115286b5fc0e2f7dc8d6a8998860d99.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-66f83e093accc4831e0aea1e3a1af16b.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-708d54cc04f36632d6530d30f6b9e4d2.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-94847925d58c4478a42fd8efb20158a8.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-9a7c34ea4af7641209130611e67a9961.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-9c0f902ec1f902379deebc0934cd225c.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-9f4c0c5af3244082021f4985f686a308.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-a07cf4b43fe03cb970799ca6225b026d.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-bf88f10bc76df564c81248fad75cc3c5.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-c7806681374e300d3ec3b0d9c62563c5.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-c8089618502ab2cbaca6c5ef0928b237.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-da466c249906f950dfe169c53e70109c.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-dffd70628d0005fccd26c6a05f8c2b37.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-e84cb24fa982c1f2afd788562ec84293.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-eac50b06b920771ba28638c45c44daed.json create mode 100644 .docz/.cache/caches/gatsby-plugin-mdx/diskstore-edd4f3646d51b29f3e3eea1608fd9493.json create mode 100755 .docz/.cache/dev-404-page.js create mode 100644 .docz/gatsby-node.js diff --git a/.docz/.cache/async-requires.js b/.docz/.cache/async-requires.js index a3d19b3..78ea7bb 100644 --- a/.docz/.cache/async-requires.js +++ b/.docz/.cache/async-requires.js @@ -2,11 +2,12 @@ const preferDefault = m => m && m.default || m exports.components = { + "component---cache-dev-404-page-js": () => import("./dev-404-page.js" /* webpackChunkName: "component---cache-dev-404-page-js" */), "component---src-architectures-mdx": () => import("./../../src/architectures.mdx" /* webpackChunkName: "component---src-architectures-mdx" */), "component---src-index-mdx": () => import("./../../src/index.mdx" /* webpackChunkName: "component---src-index-mdx" */), "component---src-enterprise-get-started-mdx": () => import("./../../src/enterprise/get-started.mdx" /* webpackChunkName: "component---src-enterprise-get-started-mdx" */), - "component---src-enterprise-installation-mdx": () => import("./../../src/enterprise/installation.mdx" /* webpackChunkName: "component---src-enterprise-installation-mdx" */), "component---src-enterprise-index-mdx": () => import("./../../src/enterprise/index.mdx" /* webpackChunkName: "component---src-enterprise-index-mdx" */), + "component---src-enterprise-installation-mdx": () => import("./../../src/enterprise/installation.mdx" /* webpackChunkName: "component---src-enterprise-installation-mdx" */), "component---src-enterprise-releases-mdx": () => import("./../../src/enterprise/releases.mdx" /* webpackChunkName: "component---src-enterprise-releases-mdx" */), "component---src-open-source-get-started-mdx": () => import("./../../src/open-source/get-started.mdx" /* webpackChunkName: "component---src-open-source-get-started-mdx" */), "component---src-open-source-index-mdx": () => import("./../../src/open-source/index.mdx" /* webpackChunkName: "component---src-open-source-index-mdx" */), diff --git a/.docz/.cache/babelState.json b/.docz/.cache/babelState.json index 4c286d2..c6b7b2b 100644 --- a/.docz/.cache/babelState.json +++ b/.docz/.cache/babelState.json @@ -17,8 +17,8 @@ { "name": "/Users/i353408/Vagrant/www/repos/documentation/node_modules/@emotion/babel-preset-css-prop/dist/babel-preset-css-prop.cjs.js", "options": { - "sourceMap": false, - "autoLabel": false, + "sourceMap": true, + "autoLabel": true, "plugins": [] } } @@ -45,8 +45,8 @@ { "name": "/Users/i353408/Vagrant/www/repos/documentation/node_modules/@emotion/babel-preset-css-prop/dist/babel-preset-css-prop.cjs.js", "options": { - "sourceMap": false, - "autoLabel": false, + "sourceMap": true, + "autoLabel": true, "plugins": [] } } @@ -73,8 +73,8 @@ { "name": "/Users/i353408/Vagrant/www/repos/documentation/node_modules/@emotion/babel-preset-css-prop/dist/babel-preset-css-prop.cjs.js", "options": { - "sourceMap": false, - "autoLabel": false, + "sourceMap": true, + "autoLabel": true, "plugins": [] } } @@ -101,8 +101,8 @@ { "name": "/Users/i353408/Vagrant/www/repos/documentation/node_modules/@emotion/babel-preset-css-prop/dist/babel-preset-css-prop.cjs.js", "options": { - "sourceMap": false, - "autoLabel": false, + "sourceMap": true, + "autoLabel": true, "plugins": [] } } diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0aba6c9a0ad3957e6773e032a84a2399.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0aba6c9a0ad3957e6773e032a84a2399.json index f75c9f9..bdb4a27 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0aba6c9a0ad3957e6773e032a84a2399.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0aba6c9a0ad3957e6773e032a84a2399.json @@ -1 +1 @@ -{"expireTime":9007200841014164000,"key":"gatsby-plugin-mdx-entire-payload-e2342ab6842f8987168b840f99e28360-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Web interface","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":16,"offset":174},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":16,"offset":174},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The web is responsible for the visualization. It's a GUI which helps the user to find activity at a specific period, configure the machinery, view a live stream, see system information and much more.","position":{"start":{"line":10,"column":1,"offset":176},"end":{"line":10,"column":200,"offset":375},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":176},"end":{"line":10,"column":200,"offset":375},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It's written in PHP using the extremely popular PHP Framework Laravel, and Javascript using the client-side framework BackboneJS. We will discuss the different pages and functionality briefly. Please check out ","position":{"start":{"line":12,"column":1,"offset":377},"end":{"line":12,"column":211,"offset":587},"indent":[]}},{"type":"link","title":null,"url":"https://demo.kerberos.io","children":[{"type":"text","value":"the demo environment","position":{"start":{"line":12,"column":212,"offset":588},"end":{"line":12,"column":232,"offset":608},"indent":[]}}],"position":{"start":{"line":12,"column":211,"offset":587},"end":{"line":12,"column":259,"offset":635},"indent":[]}},{"type":"text","value":" if you want to see a real life example.","position":{"start":{"line":12,"column":259,"offset":635},"end":{"line":12,"column":299,"offset":675},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":377},"end":{"line":12,"column":299,"offset":675},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Overview","position":{"start":{"line":14,"column":4,"offset":680},"end":{"line":14,"column":12,"offset":688},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":677},"end":{"line":14,"column":12,"offset":688},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"We will shortly discuss the different pages that make up the web interface of Kerberos Open Source.","position":{"start":{"line":16,"column":1,"offset":690},"end":{"line":16,"column":100,"offset":789},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":690},"end":{"line":16,"column":100,"offset":789},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Dashboard","position":{"start":{"line":18,"column":5,"offset":795},"end":{"line":18,"column":14,"offset":804},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":791},"end":{"line":18,"column":14,"offset":804},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The landing page of the web is the dashboard. On the dashboard a user will see some statistics: activity per hour, activity per day, a live stream, the latest activity and a heatmap.","position":{"start":{"line":20,"column":1,"offset":806},"end":{"line":20,"column":183,"offset":988},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":806},"end":{"line":20,"column":183,"offset":988},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/web/dashboard.png","alt":"web dashboard","position":{"start":{"line":22,"column":1,"offset":990},"end":{"line":22,"column":56,"offset":1045},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":990},"end":{"line":22,"column":56,"offset":1045},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Overview","position":{"start":{"line":24,"column":5,"offset":1051},"end":{"line":24,"column":13,"offset":1059},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1047},"end":{"line":24,"column":13,"offset":1059},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When selecting a specific day, you'll will get a timeline and overview. By using the timeline you can navigate through a day; the timeline highlights the amount of activity, from gray to red.","position":{"start":{"line":26,"column":1,"offset":1061},"end":{"line":26,"column":192,"offset":1252},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1061},"end":{"line":26,"column":192,"offset":1252},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/web/overview.png","alt":"web overview","position":{"start":{"line":28,"column":1,"offset":1254},"end":{"line":28,"column":54,"offset":1307},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":1254},"end":{"line":28,"column":54,"offset":1307},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Settings","position":{"start":{"line":30,"column":5,"offset":1313},"end":{"line":30,"column":13,"offset":1321},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":1309},"end":{"line":30,"column":13,"offset":1321},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The settings page allows you to configure the machinery. You can define the type of camera, post-processes, conditions and much more; it's highly configurable.","position":{"start":{"line":32,"column":1,"offset":1323},"end":{"line":32,"column":160,"offset":1482},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":1323},"end":{"line":32,"column":160,"offset":1482},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/web/settings.png","alt":"web settings","position":{"start":{"line":36,"column":1,"offset":1486},"end":{"line":36,"column":54,"offset":1539},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":1486},"end":{"line":36,"column":54,"offset":1539},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"System","position":{"start":{"line":38,"column":5,"offset":1545},"end":{"line":38,"column":11,"offset":1551},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":1541},"end":{"line":38,"column":11,"offset":1551},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The system page allows you to monitor the system. On this page you'll get an overview of the system specifications (CPU, Memory, Network, etc). Several actions are available: you can download system information (for debugging purposes) and download or remove your images.","position":{"start":{"line":40,"column":1,"offset":1553},"end":{"line":40,"column":272,"offset":1824},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":1553},"end":{"line":40,"column":272,"offset":1824},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/web/system.png","alt":"web system","position":{"start":{"line":42,"column":1,"offset":1826},"end":{"line":42,"column":50,"offset":1875},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":1826},"end":{"line":42,"column":50,"offset":1875},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Project structure","position":{"start":{"line":44,"column":4,"offset":1880},"end":{"line":44,"column":21,"offset":1897},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":1877},"end":{"line":44,"column":21,"offset":1897},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The web interface is using the Laravel framework (version 5.4). There is a lot of documentation related to Laravel, please review ","position":{"start":{"line":46,"column":1,"offset":1899},"end":{"line":46,"column":131,"offset":2029},"indent":[]}},{"type":"link","title":null,"url":"https://laravel.com/docs/5.4","children":[{"type":"text","value":"their documentation website here","position":{"start":{"line":46,"column":132,"offset":2030},"end":{"line":46,"column":164,"offset":2062},"indent":[]}}],"position":{"start":{"line":46,"column":131,"offset":2029},"end":{"line":46,"column":195,"offset":2093},"indent":[]}},{"type":"text","value":". In a nutshell this is how the web is organised.","position":{"start":{"line":46,"column":195,"offset":2093},"end":{"line":46,"column":244,"offset":2142},"indent":[]}}],"position":{"start":{"line":46,"column":1,"offset":1899},"end":{"line":46,"column":244,"offset":2142},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Back-end","position":{"start":{"line":48,"column":5,"offset":2148},"end":{"line":48,"column":13,"offset":2156},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2144},"end":{"line":48,"column":13,"offset":2156},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"config/app.php - general application settings.","position":{"start":{"line":50,"column":3,"offset":2160},"end":{"line":50,"column":49,"offset":2206},"indent":[]}}],"position":{"start":{"line":50,"column":3,"offset":2160},"end":{"line":50,"column":49,"offset":2206},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":2158},"end":{"line":50,"column":49,"offset":2206},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"config/kerberos.php - this file contains web specific parameters; the user credentials to sign in, etc.","position":{"start":{"line":51,"column":3,"offset":2209},"end":{"line":51,"column":106,"offset":2312},"indent":[]}}],"position":{"start":{"line":51,"column":3,"offset":2209},"end":{"line":51,"column":106,"offset":2312},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2207},"end":{"line":51,"column":106,"offset":2312},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"app/Http/Controllers - MVC controllers","position":{"start":{"line":52,"column":3,"offset":2315},"end":{"line":52,"column":41,"offset":2353},"indent":[]}}],"position":{"start":{"line":52,"column":3,"offset":2315},"end":{"line":52,"column":41,"offset":2353},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2313},"end":{"line":52,"column":41,"offset":2353},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"app/Http/Repositories -repositories are injected into the controller.","position":{"start":{"line":53,"column":3,"offset":2356},"end":{"line":53,"column":72,"offset":2425},"indent":[]}}],"position":{"start":{"line":53,"column":3,"offset":2356},"end":{"line":53,"column":72,"offset":2425},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2354},"end":{"line":53,"column":72,"offset":2425},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"app/Providers/AppServiceProvider.php - bind repositories to a specific interface - dependency injection.","position":{"start":{"line":54,"column":3,"offset":2428},"end":{"line":54,"column":107,"offset":2532},"indent":[]}}],"position":{"start":{"line":54,"column":3,"offset":2428},"end":{"line":54,"column":107,"offset":2532},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2426},"end":{"line":54,"column":107,"offset":2532},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"routes/api.php - contains all the URI endpoints for Ajax calls.","position":{"start":{"line":55,"column":3,"offset":2535},"end":{"line":55,"column":66,"offset":2598},"indent":[]}}],"position":{"start":{"line":55,"column":3,"offset":2535},"end":{"line":55,"column":66,"offset":2598},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2533},"end":{"line":55,"column":66,"offset":2598},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"routes/web.php - url routing for pages.","position":{"start":{"line":56,"column":3,"offset":2601},"end":{"line":56,"column":42,"offset":2640},"indent":[]}}],"position":{"start":{"line":56,"column":3,"offset":2601},"end":{"line":56,"column":42,"offset":2640},"indent":[]}}],"position":{"start":{"line":56,"column":1,"offset":2599},"end":{"line":56,"column":42,"offset":2640},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":2158},"end":{"line":56,"column":42,"offset":2640},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Front-end","position":{"start":{"line":58,"column":5,"offset":2646},"end":{"line":58,"column":14,"offset":2655},"indent":[]}}],"position":{"start":{"line":58,"column":1,"offset":2642},"end":{"line":58,"column":14,"offset":2655},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"public/css/less - LESS is used for the CSS.","position":{"start":{"line":60,"column":3,"offset":2659},"end":{"line":60,"column":46,"offset":2702},"indent":[]}}],"position":{"start":{"line":60,"column":3,"offset":2659},"end":{"line":60,"column":46,"offset":2702},"indent":[]}}],"position":{"start":{"line":60,"column":1,"offset":2657},"end":{"line":60,"column":46,"offset":2702},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"public/js/app - BackboneJS and RequireJS is used for building modular JS classes.","position":{"start":{"line":61,"column":3,"offset":2705},"end":{"line":61,"column":84,"offset":2786},"indent":[]}}],"position":{"start":{"line":61,"column":3,"offset":2705},"end":{"line":61,"column":84,"offset":2786},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2703},"end":{"line":61,"column":84,"offset":2786},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"public/js/mustache - Mustache is used for the client-side view rendering.","position":{"start":{"line":62,"column":3,"offset":2789},"end":{"line":62,"column":76,"offset":2862},"indent":[]}}],"position":{"start":{"line":62,"column":3,"offset":2789},"end":{"line":62,"column":76,"offset":2862},"indent":[]}}],"position":{"start":{"line":62,"column":1,"offset":2787},"end":{"line":62,"column":76,"offset":2862},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"public/js/vendor - This is where the bower extensions are installed.","position":{"start":{"line":63,"column":3,"offset":2865},"end":{"line":63,"column":71,"offset":2933},"indent":[]}}],"position":{"start":{"line":63,"column":3,"offset":2865},"end":{"line":63,"column":71,"offset":2933},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2863},"end":{"line":63,"column":71,"offset":2933},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"public/capture - A directory where images are written to by default.","position":{"start":{"line":64,"column":3,"offset":2936},"end":{"line":64,"column":71,"offset":3004},"indent":[]}}],"position":{"start":{"line":64,"column":3,"offset":2936},"end":{"line":64,"column":71,"offset":3004},"indent":[]}}],"position":{"start":{"line":64,"column":1,"offset":2934},"end":{"line":64,"column":71,"offset":3004},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"public/bower.json - The bower extensions used in the web repository.","position":{"start":{"line":65,"column":3,"offset":3007},"end":{"line":65,"column":71,"offset":3075},"indent":[]}}],"position":{"start":{"line":65,"column":3,"offset":3007},"end":{"line":65,"column":71,"offset":3075},"indent":[]}}],"position":{"start":{"line":65,"column":1,"offset":3005},"end":{"line":65,"column":71,"offset":3075},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"public/Gruntfile.js - We are using Grunt for our task manager.","position":{"start":{"line":66,"column":3,"offset":3078},"end":{"line":66,"column":65,"offset":3140},"indent":[]}}],"position":{"start":{"line":66,"column":3,"offset":3078},"end":{"line":66,"column":65,"offset":3140},"indent":[]}}],"position":{"start":{"line":66,"column":1,"offset":3076},"end":{"line":66,"column":65,"offset":3140},"indent":[]}}],"position":{"start":{"line":60,"column":1,"offset":2657},"end":{"line":66,"column":65,"offset":3140},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"API","position":{"start":{"line":68,"column":4,"offset":3145},"end":{"line":68,"column":7,"offset":3148},"indent":[]}}],"position":{"start":{"line":68,"column":1,"offset":3142},"end":{"line":68,"column":7,"offset":3148},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to integrate the Kerberos agent with your own application, you're at the right place! The web interface comes with a RESTfull API, that allows you to retrieve and modify information from the Kerberos agent.","position":{"start":{"line":70,"column":1,"offset":3150},"end":{"line":70,"column":219,"offset":3368},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":3150},"end":{"line":70,"column":219,"offset":3368},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Disable the machinery","position":{"start":{"line":72,"column":3,"offset":3372},"end":{"line":72,"column":24,"offset":3393},"indent":[]}}],"position":{"start":{"line":72,"column":3,"offset":3372},"end":{"line":72,"column":24,"offset":3393},"indent":[]}}],"position":{"start":{"line":72,"column":1,"offset":3370},"end":{"line":72,"column":24,"offset":3393},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Health check","position":{"start":{"line":73,"column":3,"offset":3396},"end":{"line":73,"column":15,"offset":3408},"indent":[]}}],"position":{"start":{"line":73,"column":3,"offset":3396},"end":{"line":73,"column":15,"offset":3408},"indent":[]}}],"position":{"start":{"line":73,"column":1,"offset":3394},"end":{"line":73,"column":15,"offset":3408},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Enable or disable output devices","position":{"start":{"line":74,"column":3,"offset":3411},"end":{"line":74,"column":35,"offset":3443},"indent":[]}}],"position":{"start":{"line":74,"column":3,"offset":3411},"end":{"line":74,"column":35,"offset":3443},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":3409},"end":{"line":74,"column":35,"offset":3443},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"etc.","position":{"start":{"line":75,"column":3,"offset":3446},"end":{"line":75,"column":7,"offset":3450},"indent":[]}}],"position":{"start":{"line":75,"column":3,"offset":3446},"end":{"line":75,"column":7,"offset":3450},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3444},"end":{"line":75,"column":7,"offset":3450},"indent":[]}}],"position":{"start":{"line":72,"column":1,"offset":3370},"end":{"line":75,"column":7,"offset":3450},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Authentication","position":{"start":{"line":77,"column":5,"offset":3456},"end":{"line":77,"column":19,"offset":3470},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3452},"end":{"line":77,"column":19,"offset":3470},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To use the RESTfull API of your Kerberos agent you need to define an Authorization header with each request. We use Basic Authentication to secure the different endpoints.","position":{"start":{"line":79,"column":1,"offset":3472},"end":{"line":79,"column":172,"offset":3643},"indent":[]}}],"position":{"start":{"line":79,"column":1,"offset":3472},"end":{"line":79,"column":172,"offset":3643},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"\"Authorization\": \"Basic root:root\"","position":{"start":{"line":81,"column":1,"offset":3645},"end":{"line":83,"column":4,"offset":3691},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"An example with Python looks like this.","position":{"start":{"line":85,"column":1,"offset":3693},"end":{"line":85,"column":40,"offset":3732},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":3693},"end":{"line":85,"column":40,"offset":3732},"indent":[]}},{"type":"code","lang":"python","meta":null,"value":"import requests\nimport json\nimport base64\nurl = \"http://ip-of-pi/api/v1/condition/enabled\"\nusername = \"user\"\npassword = \"passw\"\nbasicAuth = base64.b64encode('%s:%s' % (username, password))\nheaders = {\"Authorization\": \"Basic \" + basicAuth, \"Content-Type\": \"application/json\"}\ndata = '{\"active\": \"true\"}'\n#Call REST API\nresponse = requests.put(url, data=data, headers=headers)\nprint(response.text)","position":{"start":{"line":87,"column":1,"offset":3734},"end":{"line":100,"column":4,"offset":4143},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you're using the wrong credentials, the web will return following error message.","position":{"start":{"line":102,"column":1,"offset":4145},"end":{"line":102,"column":84,"offset":4228},"indent":[]}}],"position":{"start":{"line":102,"column":1,"offset":4145},"end":{"line":102,"column":84,"offset":4228},"indent":[]}},{"type":"code","lang":"text","meta":null,"value":"Invalid credentials.","position":{"start":{"line":104,"column":1,"offset":4230},"end":{"line":106,"column":4,"offset":4262},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Endpoints","position":{"start":{"line":108,"column":5,"offset":4268},"end":{"line":108,"column":14,"offset":4277},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":4264},"end":{"line":108,"column":14,"offset":4277},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All endpoints are prefixed with api/v","position":{"start":{"line":110,"column":1,"offset":4279},"end":{"line":110,"column":38,"offset":4316},"indent":[]}},{"type":"linkReference","identifier":"version","label":"version","referenceType":"shortcut","children":[{"type":"text","value":"version","position":{"start":{"line":110,"column":39,"offset":4317},"end":{"line":110,"column":46,"offset":4324},"indent":[]}}],"position":{"start":{"line":110,"column":38,"offset":4316},"end":{"line":110,"column":47,"offset":4325},"indent":[]}},{"type":"text","value":"/, in which the last part defines the API version number. Below you will find all the available endpoints with there signature and response. Note that when you call an endpoint which doesn't exists, the web will throw an 404.","position":{"start":{"line":110,"column":47,"offset":4325},"end":{"line":110,"column":272,"offset":4550},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4279},"end":{"line":110,"column":272,"offset":4550},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n\t\"error\": \"API method does not exists\"\n}","position":{"start":{"line":112,"column":1,"offset":4552},"end":{"line":116,"column":4,"offset":4606},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Version 1","position":{"start":{"line":118,"column":5,"offset":4612},"end":{"line":118,"column":14,"offset":4621},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":4608},"end":{"line":118,"column":14,"offset":4621},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Below you'll find a list of all API methods which are available for version 1.","position":{"start":{"line":120,"column":1,"offset":4623},"end":{"line":120,"column":79,"offset":4701},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":4623},"end":{"line":120,"column":79,"offset":4701},"indent":[]}},{"type":"paragraph","children":[{"type":"inlineCode","value":"GET api/v1/name","position":{"start":{"line":122,"column":1,"offset":4703},"end":{"line":122,"column":18,"offset":4720},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":4703},"end":{"line":122,"column":18,"offset":4720},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Description","position":{"start":{"line":124,"column":3,"offset":4724},"end":{"line":124,"column":14,"offset":4735},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":4722},"end":{"line":124,"column":16,"offset":4737},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":4722},"end":{"line":124,"column":16,"offset":4737},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Retrieve the name of your instance.","position":{"start":{"line":126,"column":1,"offset":4739},"end":{"line":126,"column":36,"offset":4774},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":4739},"end":{"line":126,"column":36,"offset":4774},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Response","position":{"start":{"line":128,"column":3,"offset":4778},"end":{"line":128,"column":11,"offset":4786},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":4776},"end":{"line":128,"column":13,"offset":4788},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":4776},"end":{"line":128,"column":13,"offset":4788},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n\t\"name\": \"frontdoor\"\n}","position":{"start":{"line":129,"column":1,"offset":4789},"end":{"line":133,"column":4,"offset":4825},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"inlineCode","value":"PUT api/v1/name","position":{"start":{"line":135,"column":1,"offset":4827},"end":{"line":135,"column":18,"offset":4844},"indent":[]}}],"position":{"start":{"line":135,"column":1,"offset":4827},"end":{"line":135,"column":18,"offset":4844},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Description","position":{"start":{"line":137,"column":3,"offset":4848},"end":{"line":137,"column":14,"offset":4859},"indent":[]}}],"position":{"start":{"line":137,"column":1,"offset":4846},"end":{"line":137,"column":16,"offset":4861},"indent":[]}}],"position":{"start":{"line":137,"column":1,"offset":4846},"end":{"line":137,"column":16,"offset":4861},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Change the name of your instance.","position":{"start":{"line":139,"column":1,"offset":4863},"end":{"line":139,"column":34,"offset":4896},"indent":[]}}],"position":{"start":{"line":139,"column":1,"offset":4863},"end":{"line":139,"column":34,"offset":4896},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Payload","position":{"start":{"line":141,"column":3,"offset":4900},"end":{"line":141,"column":10,"offset":4907},"indent":[]}}],"position":{"start":{"line":141,"column":1,"offset":4898},"end":{"line":141,"column":12,"offset":4909},"indent":[]}}],"position":{"start":{"line":141,"column":1,"offset":4898},"end":{"line":141,"column":12,"offset":4909},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n\t\"name\": \"frontdoor-changed\"\n}","position":{"start":{"line":142,"column":1,"offset":4910},"end":{"line":146,"column":4,"offset":4954},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Response","position":{"start":{"line":148,"column":3,"offset":4958},"end":{"line":148,"column":11,"offset":4966},"indent":[]}}],"position":{"start":{"line":148,"column":1,"offset":4956},"end":{"line":148,"column":13,"offset":4968},"indent":[]}}],"position":{"start":{"line":148,"column":1,"offset":4956},"end":{"line":148,"column":13,"offset":4968},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n\t\"name\": \"frontdoor-changed\"\n}","position":{"start":{"line":149,"column":1,"offset":4969},"end":{"line":153,"column":4,"offset":5013},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"inlineCode","value":"GET api/v1/images/latest_sequence","position":{"start":{"line":155,"column":1,"offset":5015},"end":{"line":155,"column":36,"offset":5050},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":5015},"end":{"line":155,"column":36,"offset":5050},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Description","position":{"start":{"line":157,"column":3,"offset":5054},"end":{"line":157,"column":14,"offset":5065},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":5052},"end":{"line":157,"column":16,"offset":5067},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":5052},"end":{"line":157,"column":16,"offset":5067},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Retrieve the latest sequence detected.","position":{"start":{"line":159,"column":1,"offset":5069},"end":{"line":159,"column":39,"offset":5107},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":5069},"end":{"line":159,"column":39,"offset":5107},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Response","position":{"start":{"line":161,"column":3,"offset":5111},"end":{"line":161,"column":11,"offset":5119},"indent":[]}}],"position":{"start":{"line":161,"column":1,"offset":5109},"end":{"line":161,"column":13,"offset":5121},"indent":[]}}],"position":{"start":{"line":161,"column":1,"offset":5109},"end":{"line":161,"column":13,"offset":5121},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"[\n {\n time: \"10:59:57\",\n src: \"https://demo.kerberos.io/capture/1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\",\n local_src: \"/var/www/web/public/capture/1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\",\n metadata: {\n key: \"1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\",\n user: \"1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\",\n timestamp: 1501491597,\n microseconds: \"6-310145\",\n instanceName: \"frontdoor\",\n regionCoordinates: \"722-691-873-926\",\n numberOfChanges: \"703\",\n token: \"511\"\n },\n type: \"video\"\n }\n]","position":{"start":{"line":162,"column":1,"offset":5122},"end":{"line":181,"column":4,"offset":5823},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"inlineCode","value":"GET api/v1/condition/enabled","position":{"start":{"line":183,"column":1,"offset":5825},"end":{"line":183,"column":31,"offset":5855},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":5825},"end":{"line":183,"column":31,"offset":5855},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Description","position":{"start":{"line":185,"column":3,"offset":5859},"end":{"line":185,"column":14,"offset":5870},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":5857},"end":{"line":185,"column":16,"offset":5872},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":5857},"end":{"line":185,"column":16,"offset":5872},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Check if enabled or disabled.","position":{"start":{"line":187,"column":1,"offset":5874},"end":{"line":187,"column":30,"offset":5903},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":5874},"end":{"line":187,"column":30,"offset":5903},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Response","position":{"start":{"line":189,"column":3,"offset":5907},"end":{"line":189,"column":11,"offset":5915},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":5905},"end":{"line":189,"column":13,"offset":5917},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":5905},"end":{"line":189,"column":13,"offset":5917},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n \t\"active\": \"true\",\n \t\"delay\": \"5000\"\n}","position":{"start":{"line":190,"column":1,"offset":5918},"end":{"line":195,"column":4,"offset":5971},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"inlineCode","value":"PUT api/v1/condition/enabled","position":{"start":{"line":197,"column":1,"offset":5973},"end":{"line":197,"column":31,"offset":6003},"indent":[]}}],"position":{"start":{"line":197,"column":1,"offset":5973},"end":{"line":197,"column":31,"offset":6003},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Description","position":{"start":{"line":199,"column":3,"offset":6007},"end":{"line":199,"column":14,"offset":6018},"indent":[]}}],"position":{"start":{"line":199,"column":1,"offset":6005},"end":{"line":199,"column":16,"offset":6020},"indent":[]}}],"position":{"start":{"line":199,"column":1,"offset":6005},"end":{"line":199,"column":16,"offset":6020},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Activate or disable the system.","position":{"start":{"line":201,"column":1,"offset":6022},"end":{"line":201,"column":32,"offset":6053},"indent":[]}}],"position":{"start":{"line":201,"column":1,"offset":6022},"end":{"line":201,"column":32,"offset":6053},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Payload","position":{"start":{"line":203,"column":3,"offset":6057},"end":{"line":203,"column":10,"offset":6064},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":6055},"end":{"line":203,"column":12,"offset":6066},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":6055},"end":{"line":203,"column":12,"offset":6066},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n \t\"active\": \"false\"\n}","position":{"start":{"line":204,"column":1,"offset":6067},"end":{"line":208,"column":4,"offset":6102},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Response","position":{"start":{"line":210,"column":3,"offset":6106},"end":{"line":210,"column":11,"offset":6114},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":6104},"end":{"line":210,"column":13,"offset":6116},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":6104},"end":{"line":210,"column":13,"offset":6116},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n \t\"active\": \"false\",\n \t\"delay\": \"5000\"\n}","position":{"start":{"line":211,"column":1,"offset":6117},"end":{"line":216,"column":4,"offset":6171},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"inlineCode","value":"GET api/v1/system/health","position":{"start":{"line":218,"column":1,"offset":6173},"end":{"line":218,"column":27,"offset":6199},"indent":[]}}],"position":{"start":{"line":218,"column":1,"offset":6173},"end":{"line":218,"column":27,"offset":6199},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Description","position":{"start":{"line":220,"column":3,"offset":6203},"end":{"line":220,"column":14,"offset":6214},"indent":[]}}],"position":{"start":{"line":220,"column":1,"offset":6201},"end":{"line":220,"column":16,"offset":6216},"indent":[]}}],"position":{"start":{"line":220,"column":1,"offset":6201},"end":{"line":220,"column":16,"offset":6216},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Check if the machinery is running (the stream is connected).","position":{"start":{"line":222,"column":1,"offset":6218},"end":{"line":222,"column":61,"offset":6278},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":6218},"end":{"line":222,"column":61,"offset":6278},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Response","position":{"start":{"line":224,"column":3,"offset":6282},"end":{"line":224,"column":11,"offset":6290},"indent":[]}}],"position":{"start":{"line":224,"column":1,"offset":6280},"end":{"line":224,"column":13,"offset":6292},"indent":[]}}],"position":{"start":{"line":224,"column":1,"offset":6280},"end":{"line":224,"column":13,"offset":6292},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n \t\"status\": \"false\"\n}","position":{"start":{"line":225,"column":1,"offset":6293},"end":{"line":229,"column":4,"offset":6328},"indent":[1,1,1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":232,"column":1,"offset":6331},"end":{"line":232,"column":31,"offset":6361},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":232,"column":31,"offset":6361}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Web interface`}

\n

{`The web is responsible for the visualization. It's a GUI which helps the user to find activity at a specific period, configure the machinery, view a live stream, see system information and much more.`}

\n

{`It's written in PHP using the extremely popular PHP Framework Laravel, and Javascript using the client-side framework BackboneJS. We will discuss the different pages and functionality briefly. Please check out `}{`the demo environment`}{` if you want to see a real life example.`}

\n

{`Overview`}

\n

{`We will shortly discuss the different pages that make up the web interface of Kerberos Open Source.`}

\n

{`Dashboard`}

\n

{`The landing page of the web is the dashboard. On the dashboard a user will see some statistics: activity per hour, activity per day, a live stream, the latest activity and a heatmap.`}

\n

\"web

\n

{`Overview`}

\n

{`When selecting a specific day, you'll will get a timeline and overview. By using the timeline you can navigate through a day; the timeline highlights the amount of activity, from gray to red.`}

\n

\"web

\n

{`Settings`}

\n

{`The settings page allows you to configure the machinery. You can define the type of camera, post-processes, conditions and much more; it's highly configurable.`}

\n

\"web

\n

{`System`}

\n

{`The system page allows you to monitor the system. On this page you'll get an overview of the system specifications (CPU, Memory, Network, etc). Several actions are available: you can download system information (for debugging purposes) and download or remove your images.`}

\n

\"web

\n

{`Project structure`}

\n

{`The web interface is using the Laravel framework (version 5.4). There is a lot of documentation related to Laravel, please review `}{`their documentation website here`}{`. In a nutshell this is how the web is organised.`}

\n

{`Back-end`}

\n
    \n
  • {`config/app.php - general application settings.`}
  • \n
  • {`config/kerberos.php - this file contains web specific parameters; the user credentials to sign in, etc.`}
  • \n
  • {`app/Http/Controllers - MVC controllers`}
  • \n
  • {`app/Http/Repositories -repositories are injected into the controller.`}
  • \n
  • {`app/Providers/AppServiceProvider.php - bind repositories to a specific interface - dependency injection.`}
  • \n
  • {`routes/api.php - contains all the URI endpoints for Ajax calls.`}
  • \n
  • {`routes/web.php - url routing for pages.`}
  • \n
\n

{`Front-end`}

\n
    \n
  • {`public/css/less - LESS is used for the CSS.`}
  • \n
  • {`public/js/app - BackboneJS and RequireJS is used for building modular JS classes.`}
  • \n
  • {`public/js/mustache - Mustache is used for the client-side view rendering.`}
  • \n
  • {`public/js/vendor - This is where the bower extensions are installed.`}
  • \n
  • {`public/capture - A directory where images are written to by default.`}
  • \n
  • {`public/bower.json - The bower extensions used in the web repository.`}
  • \n
  • {`public/Gruntfile.js - We are using Grunt for our task manager.`}
  • \n
\n

{`API`}

\n

{`If you want to integrate the Kerberos agent with your own application, you're at the right place! The web interface comes with a RESTfull API, that allows you to retrieve and modify information from the Kerberos agent.`}

\n
    \n
  • {`Disable the machinery`}
  • \n
  • {`Health check`}
  • \n
  • {`Enable or disable output devices`}
  • \n
  • {`etc.`}
  • \n
\n

{`Authentication`}

\n

{`To use the RESTfull API of your Kerberos agent you need to define an Authorization header with each request. We use Basic Authentication to secure the different endpoints.`}

\n
{`\"Authorization\"`}{`: `}{`\"Basic root:root\"`}
\n

{`An example with Python looks like this.`}

\n
{`import`}{` requests`}{`\n`}{`import`}{` json`}{`\n`}{`import`}{` base64`}{`\n`}{`url = `}{`\"http://ip-of-pi/api/v1/condition/enabled\"`}{`\n`}{`username = `}{`\"user\"`}{`\n`}{`password = `}{`\"passw\"`}{`\n`}{`basicAuth = base64.b64encode(`}{`'`}{`%s`}{`:`}{`%s`}{`'`}{` % (username, password))`}{`\n`}{`headers = {`}{`\"Authorization\"`}{`: `}{`\"Basic \"`}{` + basicAuth, `}{`\"Content-Type\"`}{`: `}{`\"application/json\"`}{`}`}{`\n`}{`data = `}{`'{\"active\": \"true\"}'`}{`\n`}{`#Call REST API`}{`\n`}{`response = requests.put(url, `}{`data`}{`=data, `}{`headers`}{`=headers)`}{`\n`}{`print`}{`(response.text)`}
\n

{`If you're using the wrong credentials, the web will return following error message.`}

\n
{`Invalid credentials.`}
\n

{`Endpoints`}

\n

{`All endpoints are prefixed with api/v`}{`[version]`}{`/, in which the last part defines the API version number. Below you will find all the available endpoints with there signature and response. Note that when you call an endpoint which doesn't exists, the web will throw an 404.`}

\n
{`{`}{`\n`}{`\t`}{`\"error\"`}{`: `}{`\"API method does not exists\"`}{`\n`}{`}`}
\n

{`Version 1`}

\n

{`Below you'll find a list of all API methods which are available for version 1.`}

\n

{`GET api/v1/name`}

\n

{`Description`}

\n

{`Retrieve the name of your instance.`}

\n

{`Response`}

\n
{`{`}{`\n`}{`\t`}{`\"name\"`}{`: `}{`\"frontdoor\"`}{`\n`}{`}`}
\n

{`PUT api/v1/name`}

\n

{`Description`}

\n

{`Change the name of your instance.`}

\n

{`Payload`}

\n
{`{`}{`\n`}{`\t`}{`\"name\"`}{`: `}{`\"frontdoor-changed\"`}{`\n`}{`}`}
\n

{`Response`}

\n
{`{`}{`\n`}{`\t`}{`\"name\"`}{`: `}{`\"frontdoor-changed\"`}{`\n`}{`}`}
\n

{`GET api/v1/images/latest_sequence`}

\n

{`Description`}

\n

{`Retrieve the latest sequence detected.`}

\n

{`Response`}

\n
{`[`}{`\n`}{`    {`}{`\n`}{`        `}{`time`}{`: `}{`\"10:59:57\"`}{`,`}{`\n`}{`        `}{`src`}{`: `}{`\"https://demo.kerberos.io/capture/1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\"`}{`,`}{`\n`}{`        `}{`local_src`}{`: `}{`\"/var/www/web/public/capture/1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\"`}{`,`}{`\n`}{`        `}{`metadata`}{`: {`}{`\n`}{`            `}{`key`}{`: `}{`\"1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\"`}{`,`}{`\n`}{`            `}{`user`}{`: `}{`\"1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\"`}{`,`}{`\n`}{`            `}{`timestamp`}{`: `}{`1501491597`}{`,`}{`\n`}{`            `}{`microseconds`}{`: `}{`\"6-310145\"`}{`,`}{`\n`}{`            `}{`instanceName`}{`: `}{`\"frontdoor\"`}{`,`}{`\n`}{`            `}{`regionCoordinates`}{`: `}{`\"722-691-873-926\"`}{`,`}{`\n`}{`            `}{`numberOfChanges`}{`: `}{`\"703\"`}{`,`}{`\n`}{`            `}{`token`}{`: `}{`\"511\"`}{`\n`}{`        },`}{`\n`}{`        `}{`type`}{`: `}{`\"video\"`}{`\n`}{`    }`}{`\n`}{`]`}
\n

{`GET api/v1/condition/enabled`}

\n

{`Description`}

\n

{`Check if enabled or disabled.`}

\n

{`Response`}

\n
{`{`}{`\n`}{` \t`}{`\"active\"`}{`: `}{`\"true\"`}{`,`}{`\n`}{` \t`}{`\"delay\"`}{`: `}{`\"5000\"`}{`\n`}{`}`}
\n

{`PUT api/v1/condition/enabled`}

\n

{`Description`}

\n

{`Activate or disable the system.`}

\n

{`Payload`}

\n
{`{`}{`\n`}{` \t`}{`\"active\"`}{`: `}{`\"false\"`}{`\n`}{`}`}
\n

{`Response`}

\n
{`{`}{`\n`}{` \t`}{`\"active\"`}{`: `}{`\"false\"`}{`,`}{`\n`}{` \t`}{`\"delay\"`}{`: `}{`\"5000\"`}{`\n`}{`}`}
\n

{`GET api/v1/system/health`}

\n

{`Description`}

\n

{`Check if the machinery is running (the stream is connected).`}

\n

{`Response`}

\n
{`{`}{`\n`}{` \t`}{`\"status\"`}{`: `}{`\"false\"`}{`\n`}{`}`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974265000,"key":"gatsby-plugin-mdx-entire-payload-e2342ab6842f8987168b840f99e28360-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Web interface","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":16,"offset":174},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":16,"offset":174},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The web is responsible for the visualization. It's a GUI which helps the user to find activity at a specific period, configure the machinery, view a live stream, see system information and much more.","position":{"start":{"line":10,"column":1,"offset":176},"end":{"line":10,"column":200,"offset":375},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":176},"end":{"line":10,"column":200,"offset":375},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It's written in PHP using the extremely popular PHP Framework Laravel, and Javascript using the client-side framework BackboneJS. We will discuss the different pages and functionality briefly. Please check out ","position":{"start":{"line":12,"column":1,"offset":377},"end":{"line":12,"column":211,"offset":587},"indent":[]}},{"type":"link","title":null,"url":"https://demo.kerberos.io","children":[{"type":"text","value":"the demo environment","position":{"start":{"line":12,"column":212,"offset":588},"end":{"line":12,"column":232,"offset":608},"indent":[]}}],"position":{"start":{"line":12,"column":211,"offset":587},"end":{"line":12,"column":259,"offset":635},"indent":[]}},{"type":"text","value":" if you want to see a real life example.","position":{"start":{"line":12,"column":259,"offset":635},"end":{"line":12,"column":299,"offset":675},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":377},"end":{"line":12,"column":299,"offset":675},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Overview","position":{"start":{"line":14,"column":4,"offset":680},"end":{"line":14,"column":12,"offset":688},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":677},"end":{"line":14,"column":12,"offset":688},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"We will shortly discuss the different pages that make up the web interface of Kerberos Open Source.","position":{"start":{"line":16,"column":1,"offset":690},"end":{"line":16,"column":100,"offset":789},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":690},"end":{"line":16,"column":100,"offset":789},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Dashboard","position":{"start":{"line":18,"column":5,"offset":795},"end":{"line":18,"column":14,"offset":804},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":791},"end":{"line":18,"column":14,"offset":804},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The landing page of the web is the dashboard. On the dashboard a user will see some statistics: activity per hour, activity per day, a live stream, the latest activity and a heatmap.","position":{"start":{"line":20,"column":1,"offset":806},"end":{"line":20,"column":183,"offset":988},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":806},"end":{"line":20,"column":183,"offset":988},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/web/dashboard.png","alt":"web dashboard","position":{"start":{"line":22,"column":1,"offset":990},"end":{"line":22,"column":56,"offset":1045},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":990},"end":{"line":22,"column":56,"offset":1045},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Overview","position":{"start":{"line":24,"column":5,"offset":1051},"end":{"line":24,"column":13,"offset":1059},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1047},"end":{"line":24,"column":13,"offset":1059},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When selecting a specific day, you'll will get a timeline and overview. By using the timeline you can navigate through a day; the timeline highlights the amount of activity, from gray to red.","position":{"start":{"line":26,"column":1,"offset":1061},"end":{"line":26,"column":192,"offset":1252},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1061},"end":{"line":26,"column":192,"offset":1252},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/web/overview.png","alt":"web overview","position":{"start":{"line":28,"column":1,"offset":1254},"end":{"line":28,"column":54,"offset":1307},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":1254},"end":{"line":28,"column":54,"offset":1307},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Settings","position":{"start":{"line":30,"column":5,"offset":1313},"end":{"line":30,"column":13,"offset":1321},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":1309},"end":{"line":30,"column":13,"offset":1321},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The settings page allows you to configure the machinery. You can define the type of camera, post-processes, conditions and much more; it's highly configurable.","position":{"start":{"line":32,"column":1,"offset":1323},"end":{"line":32,"column":160,"offset":1482},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":1323},"end":{"line":32,"column":160,"offset":1482},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/web/settings.png","alt":"web settings","position":{"start":{"line":36,"column":1,"offset":1486},"end":{"line":36,"column":54,"offset":1539},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":1486},"end":{"line":36,"column":54,"offset":1539},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"System","position":{"start":{"line":38,"column":5,"offset":1545},"end":{"line":38,"column":11,"offset":1551},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":1541},"end":{"line":38,"column":11,"offset":1551},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The system page allows you to monitor the system. On this page you'll get an overview of the system specifications (CPU, Memory, Network, etc). Several actions are available: you can download system information (for debugging purposes) and download or remove your images.","position":{"start":{"line":40,"column":1,"offset":1553},"end":{"line":40,"column":272,"offset":1824},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":1553},"end":{"line":40,"column":272,"offset":1824},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/web/system.png","alt":"web system","position":{"start":{"line":42,"column":1,"offset":1826},"end":{"line":42,"column":50,"offset":1875},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":1826},"end":{"line":42,"column":50,"offset":1875},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Project structure","position":{"start":{"line":44,"column":4,"offset":1880},"end":{"line":44,"column":21,"offset":1897},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":1877},"end":{"line":44,"column":21,"offset":1897},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The web interface is using the Laravel framework (version 5.4). There is a lot of documentation related to Laravel, please review ","position":{"start":{"line":46,"column":1,"offset":1899},"end":{"line":46,"column":131,"offset":2029},"indent":[]}},{"type":"link","title":null,"url":"https://laravel.com/docs/5.4","children":[{"type":"text","value":"their documentation website here","position":{"start":{"line":46,"column":132,"offset":2030},"end":{"line":46,"column":164,"offset":2062},"indent":[]}}],"position":{"start":{"line":46,"column":131,"offset":2029},"end":{"line":46,"column":195,"offset":2093},"indent":[]}},{"type":"text","value":". In a nutshell this is how the web is organised.","position":{"start":{"line":46,"column":195,"offset":2093},"end":{"line":46,"column":244,"offset":2142},"indent":[]}}],"position":{"start":{"line":46,"column":1,"offset":1899},"end":{"line":46,"column":244,"offset":2142},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Back-end","position":{"start":{"line":48,"column":5,"offset":2148},"end":{"line":48,"column":13,"offset":2156},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2144},"end":{"line":48,"column":13,"offset":2156},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"config/app.php - general application settings.","position":{"start":{"line":50,"column":3,"offset":2160},"end":{"line":50,"column":49,"offset":2206},"indent":[]}}],"position":{"start":{"line":50,"column":3,"offset":2160},"end":{"line":50,"column":49,"offset":2206},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":2158},"end":{"line":50,"column":49,"offset":2206},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"config/kerberos.php - this file contains web specific parameters; the user credentials to sign in, etc.","position":{"start":{"line":51,"column":3,"offset":2209},"end":{"line":51,"column":106,"offset":2312},"indent":[]}}],"position":{"start":{"line":51,"column":3,"offset":2209},"end":{"line":51,"column":106,"offset":2312},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2207},"end":{"line":51,"column":106,"offset":2312},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"app/Http/Controllers - MVC controllers","position":{"start":{"line":52,"column":3,"offset":2315},"end":{"line":52,"column":41,"offset":2353},"indent":[]}}],"position":{"start":{"line":52,"column":3,"offset":2315},"end":{"line":52,"column":41,"offset":2353},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2313},"end":{"line":52,"column":41,"offset":2353},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"app/Http/Repositories -repositories are injected into the controller.","position":{"start":{"line":53,"column":3,"offset":2356},"end":{"line":53,"column":72,"offset":2425},"indent":[]}}],"position":{"start":{"line":53,"column":3,"offset":2356},"end":{"line":53,"column":72,"offset":2425},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2354},"end":{"line":53,"column":72,"offset":2425},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"app/Providers/AppServiceProvider.php - bind repositories to a specific interface - dependency injection.","position":{"start":{"line":54,"column":3,"offset":2428},"end":{"line":54,"column":107,"offset":2532},"indent":[]}}],"position":{"start":{"line":54,"column":3,"offset":2428},"end":{"line":54,"column":107,"offset":2532},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2426},"end":{"line":54,"column":107,"offset":2532},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"routes/api.php - contains all the URI endpoints for Ajax calls.","position":{"start":{"line":55,"column":3,"offset":2535},"end":{"line":55,"column":66,"offset":2598},"indent":[]}}],"position":{"start":{"line":55,"column":3,"offset":2535},"end":{"line":55,"column":66,"offset":2598},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2533},"end":{"line":55,"column":66,"offset":2598},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"routes/web.php - url routing for pages.","position":{"start":{"line":56,"column":3,"offset":2601},"end":{"line":56,"column":42,"offset":2640},"indent":[]}}],"position":{"start":{"line":56,"column":3,"offset":2601},"end":{"line":56,"column":42,"offset":2640},"indent":[]}}],"position":{"start":{"line":56,"column":1,"offset":2599},"end":{"line":56,"column":42,"offset":2640},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":2158},"end":{"line":56,"column":42,"offset":2640},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Front-end","position":{"start":{"line":58,"column":5,"offset":2646},"end":{"line":58,"column":14,"offset":2655},"indent":[]}}],"position":{"start":{"line":58,"column":1,"offset":2642},"end":{"line":58,"column":14,"offset":2655},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"public/css/less - LESS is used for the CSS.","position":{"start":{"line":60,"column":3,"offset":2659},"end":{"line":60,"column":46,"offset":2702},"indent":[]}}],"position":{"start":{"line":60,"column":3,"offset":2659},"end":{"line":60,"column":46,"offset":2702},"indent":[]}}],"position":{"start":{"line":60,"column":1,"offset":2657},"end":{"line":60,"column":46,"offset":2702},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"public/js/app - BackboneJS and RequireJS is used for building modular JS classes.","position":{"start":{"line":61,"column":3,"offset":2705},"end":{"line":61,"column":84,"offset":2786},"indent":[]}}],"position":{"start":{"line":61,"column":3,"offset":2705},"end":{"line":61,"column":84,"offset":2786},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2703},"end":{"line":61,"column":84,"offset":2786},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"public/js/mustache - Mustache is used for the client-side view rendering.","position":{"start":{"line":62,"column":3,"offset":2789},"end":{"line":62,"column":76,"offset":2862},"indent":[]}}],"position":{"start":{"line":62,"column":3,"offset":2789},"end":{"line":62,"column":76,"offset":2862},"indent":[]}}],"position":{"start":{"line":62,"column":1,"offset":2787},"end":{"line":62,"column":76,"offset":2862},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"public/js/vendor - This is where the bower extensions are installed.","position":{"start":{"line":63,"column":3,"offset":2865},"end":{"line":63,"column":71,"offset":2933},"indent":[]}}],"position":{"start":{"line":63,"column":3,"offset":2865},"end":{"line":63,"column":71,"offset":2933},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2863},"end":{"line":63,"column":71,"offset":2933},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"public/capture - A directory where images are written to by default.","position":{"start":{"line":64,"column":3,"offset":2936},"end":{"line":64,"column":71,"offset":3004},"indent":[]}}],"position":{"start":{"line":64,"column":3,"offset":2936},"end":{"line":64,"column":71,"offset":3004},"indent":[]}}],"position":{"start":{"line":64,"column":1,"offset":2934},"end":{"line":64,"column":71,"offset":3004},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"public/bower.json - The bower extensions used in the web repository.","position":{"start":{"line":65,"column":3,"offset":3007},"end":{"line":65,"column":71,"offset":3075},"indent":[]}}],"position":{"start":{"line":65,"column":3,"offset":3007},"end":{"line":65,"column":71,"offset":3075},"indent":[]}}],"position":{"start":{"line":65,"column":1,"offset":3005},"end":{"line":65,"column":71,"offset":3075},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"public/Gruntfile.js - We are using Grunt for our task manager.","position":{"start":{"line":66,"column":3,"offset":3078},"end":{"line":66,"column":65,"offset":3140},"indent":[]}}],"position":{"start":{"line":66,"column":3,"offset":3078},"end":{"line":66,"column":65,"offset":3140},"indent":[]}}],"position":{"start":{"line":66,"column":1,"offset":3076},"end":{"line":66,"column":65,"offset":3140},"indent":[]}}],"position":{"start":{"line":60,"column":1,"offset":2657},"end":{"line":66,"column":65,"offset":3140},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"API","position":{"start":{"line":68,"column":4,"offset":3145},"end":{"line":68,"column":7,"offset":3148},"indent":[]}}],"position":{"start":{"line":68,"column":1,"offset":3142},"end":{"line":68,"column":7,"offset":3148},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to integrate the Kerberos agent with your own application, you're at the right place! The web interface comes with a RESTfull API, that allows you to retrieve and modify information from the Kerberos agent.","position":{"start":{"line":70,"column":1,"offset":3150},"end":{"line":70,"column":219,"offset":3368},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":3150},"end":{"line":70,"column":219,"offset":3368},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Disable the machinery","position":{"start":{"line":72,"column":3,"offset":3372},"end":{"line":72,"column":24,"offset":3393},"indent":[]}}],"position":{"start":{"line":72,"column":3,"offset":3372},"end":{"line":72,"column":24,"offset":3393},"indent":[]}}],"position":{"start":{"line":72,"column":1,"offset":3370},"end":{"line":72,"column":24,"offset":3393},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Health check","position":{"start":{"line":73,"column":3,"offset":3396},"end":{"line":73,"column":15,"offset":3408},"indent":[]}}],"position":{"start":{"line":73,"column":3,"offset":3396},"end":{"line":73,"column":15,"offset":3408},"indent":[]}}],"position":{"start":{"line":73,"column":1,"offset":3394},"end":{"line":73,"column":15,"offset":3408},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Enable or disable output devices","position":{"start":{"line":74,"column":3,"offset":3411},"end":{"line":74,"column":35,"offset":3443},"indent":[]}}],"position":{"start":{"line":74,"column":3,"offset":3411},"end":{"line":74,"column":35,"offset":3443},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":3409},"end":{"line":74,"column":35,"offset":3443},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"etc.","position":{"start":{"line":75,"column":3,"offset":3446},"end":{"line":75,"column":7,"offset":3450},"indent":[]}}],"position":{"start":{"line":75,"column":3,"offset":3446},"end":{"line":75,"column":7,"offset":3450},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3444},"end":{"line":75,"column":7,"offset":3450},"indent":[]}}],"position":{"start":{"line":72,"column":1,"offset":3370},"end":{"line":75,"column":7,"offset":3450},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Authentication","position":{"start":{"line":77,"column":5,"offset":3456},"end":{"line":77,"column":19,"offset":3470},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3452},"end":{"line":77,"column":19,"offset":3470},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To use the RESTfull API of your Kerberos agent you need to define an Authorization header with each request. We use Basic Authentication to secure the different endpoints.","position":{"start":{"line":79,"column":1,"offset":3472},"end":{"line":79,"column":172,"offset":3643},"indent":[]}}],"position":{"start":{"line":79,"column":1,"offset":3472},"end":{"line":79,"column":172,"offset":3643},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"\"Authorization\": \"Basic root:root\"","position":{"start":{"line":81,"column":1,"offset":3645},"end":{"line":83,"column":4,"offset":3691},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"An example with Python looks like this.","position":{"start":{"line":85,"column":1,"offset":3693},"end":{"line":85,"column":40,"offset":3732},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":3693},"end":{"line":85,"column":40,"offset":3732},"indent":[]}},{"type":"code","lang":"python","meta":null,"value":"import requests\nimport json\nimport base64\nurl = \"http://ip-of-pi/api/v1/condition/enabled\"\nusername = \"user\"\npassword = \"passw\"\nbasicAuth = base64.b64encode('%s:%s' % (username, password))\nheaders = {\"Authorization\": \"Basic \" + basicAuth, \"Content-Type\": \"application/json\"}\ndata = '{\"active\": \"true\"}'\n#Call REST API\nresponse = requests.put(url, data=data, headers=headers)\nprint(response.text)","position":{"start":{"line":87,"column":1,"offset":3734},"end":{"line":100,"column":4,"offset":4143},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you're using the wrong credentials, the web will return following error message.","position":{"start":{"line":102,"column":1,"offset":4145},"end":{"line":102,"column":84,"offset":4228},"indent":[]}}],"position":{"start":{"line":102,"column":1,"offset":4145},"end":{"line":102,"column":84,"offset":4228},"indent":[]}},{"type":"code","lang":"text","meta":null,"value":"Invalid credentials.","position":{"start":{"line":104,"column":1,"offset":4230},"end":{"line":106,"column":4,"offset":4262},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Endpoints","position":{"start":{"line":108,"column":5,"offset":4268},"end":{"line":108,"column":14,"offset":4277},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":4264},"end":{"line":108,"column":14,"offset":4277},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All endpoints are prefixed with api/v","position":{"start":{"line":110,"column":1,"offset":4279},"end":{"line":110,"column":38,"offset":4316},"indent":[]}},{"type":"linkReference","identifier":"version","label":"version","referenceType":"shortcut","children":[{"type":"text","value":"version","position":{"start":{"line":110,"column":39,"offset":4317},"end":{"line":110,"column":46,"offset":4324},"indent":[]}}],"position":{"start":{"line":110,"column":38,"offset":4316},"end":{"line":110,"column":47,"offset":4325},"indent":[]}},{"type":"text","value":"/, in which the last part defines the API version number. Below you will find all the available endpoints with there signature and response. Note that when you call an endpoint which doesn't exists, the web will throw an 404.","position":{"start":{"line":110,"column":47,"offset":4325},"end":{"line":110,"column":272,"offset":4550},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4279},"end":{"line":110,"column":272,"offset":4550},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n\t\"error\": \"API method does not exists\"\n}","position":{"start":{"line":112,"column":1,"offset":4552},"end":{"line":116,"column":4,"offset":4606},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Version 1","position":{"start":{"line":118,"column":5,"offset":4612},"end":{"line":118,"column":14,"offset":4621},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":4608},"end":{"line":118,"column":14,"offset":4621},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Below you'll find a list of all API methods which are available for version 1.","position":{"start":{"line":120,"column":1,"offset":4623},"end":{"line":120,"column":79,"offset":4701},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":4623},"end":{"line":120,"column":79,"offset":4701},"indent":[]}},{"type":"paragraph","children":[{"type":"inlineCode","value":"GET api/v1/name","position":{"start":{"line":122,"column":1,"offset":4703},"end":{"line":122,"column":18,"offset":4720},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":4703},"end":{"line":122,"column":18,"offset":4720},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Description","position":{"start":{"line":124,"column":3,"offset":4724},"end":{"line":124,"column":14,"offset":4735},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":4722},"end":{"line":124,"column":16,"offset":4737},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":4722},"end":{"line":124,"column":16,"offset":4737},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Retrieve the name of your instance.","position":{"start":{"line":126,"column":1,"offset":4739},"end":{"line":126,"column":36,"offset":4774},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":4739},"end":{"line":126,"column":36,"offset":4774},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Response","position":{"start":{"line":128,"column":3,"offset":4778},"end":{"line":128,"column":11,"offset":4786},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":4776},"end":{"line":128,"column":13,"offset":4788},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":4776},"end":{"line":128,"column":13,"offset":4788},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n\t\"name\": \"frontdoor\"\n}","position":{"start":{"line":129,"column":1,"offset":4789},"end":{"line":133,"column":4,"offset":4825},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"inlineCode","value":"PUT api/v1/name","position":{"start":{"line":135,"column":1,"offset":4827},"end":{"line":135,"column":18,"offset":4844},"indent":[]}}],"position":{"start":{"line":135,"column":1,"offset":4827},"end":{"line":135,"column":18,"offset":4844},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Description","position":{"start":{"line":137,"column":3,"offset":4848},"end":{"line":137,"column":14,"offset":4859},"indent":[]}}],"position":{"start":{"line":137,"column":1,"offset":4846},"end":{"line":137,"column":16,"offset":4861},"indent":[]}}],"position":{"start":{"line":137,"column":1,"offset":4846},"end":{"line":137,"column":16,"offset":4861},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Change the name of your instance.","position":{"start":{"line":139,"column":1,"offset":4863},"end":{"line":139,"column":34,"offset":4896},"indent":[]}}],"position":{"start":{"line":139,"column":1,"offset":4863},"end":{"line":139,"column":34,"offset":4896},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Payload","position":{"start":{"line":141,"column":3,"offset":4900},"end":{"line":141,"column":10,"offset":4907},"indent":[]}}],"position":{"start":{"line":141,"column":1,"offset":4898},"end":{"line":141,"column":12,"offset":4909},"indent":[]}}],"position":{"start":{"line":141,"column":1,"offset":4898},"end":{"line":141,"column":12,"offset":4909},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n\t\"name\": \"frontdoor-changed\"\n}","position":{"start":{"line":142,"column":1,"offset":4910},"end":{"line":146,"column":4,"offset":4954},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Response","position":{"start":{"line":148,"column":3,"offset":4958},"end":{"line":148,"column":11,"offset":4966},"indent":[]}}],"position":{"start":{"line":148,"column":1,"offset":4956},"end":{"line":148,"column":13,"offset":4968},"indent":[]}}],"position":{"start":{"line":148,"column":1,"offset":4956},"end":{"line":148,"column":13,"offset":4968},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n\t\"name\": \"frontdoor-changed\"\n}","position":{"start":{"line":149,"column":1,"offset":4969},"end":{"line":153,"column":4,"offset":5013},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"inlineCode","value":"GET api/v1/images/latest_sequence","position":{"start":{"line":155,"column":1,"offset":5015},"end":{"line":155,"column":36,"offset":5050},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":5015},"end":{"line":155,"column":36,"offset":5050},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Description","position":{"start":{"line":157,"column":3,"offset":5054},"end":{"line":157,"column":14,"offset":5065},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":5052},"end":{"line":157,"column":16,"offset":5067},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":5052},"end":{"line":157,"column":16,"offset":5067},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Retrieve the latest sequence detected.","position":{"start":{"line":159,"column":1,"offset":5069},"end":{"line":159,"column":39,"offset":5107},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":5069},"end":{"line":159,"column":39,"offset":5107},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Response","position":{"start":{"line":161,"column":3,"offset":5111},"end":{"line":161,"column":11,"offset":5119},"indent":[]}}],"position":{"start":{"line":161,"column":1,"offset":5109},"end":{"line":161,"column":13,"offset":5121},"indent":[]}}],"position":{"start":{"line":161,"column":1,"offset":5109},"end":{"line":161,"column":13,"offset":5121},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"[\n {\n time: \"10:59:57\",\n src: \"https://demo.kerberos.io/capture/1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\",\n local_src: \"/var/www/web/public/capture/1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\",\n metadata: {\n key: \"1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\",\n user: \"1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\",\n timestamp: 1501491597,\n microseconds: \"6-310145\",\n instanceName: \"frontdoor\",\n regionCoordinates: \"722-691-873-926\",\n numberOfChanges: \"703\",\n token: \"511\"\n },\n type: \"video\"\n }\n]","position":{"start":{"line":162,"column":1,"offset":5122},"end":{"line":181,"column":4,"offset":5823},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"inlineCode","value":"GET api/v1/condition/enabled","position":{"start":{"line":183,"column":1,"offset":5825},"end":{"line":183,"column":31,"offset":5855},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":5825},"end":{"line":183,"column":31,"offset":5855},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Description","position":{"start":{"line":185,"column":3,"offset":5859},"end":{"line":185,"column":14,"offset":5870},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":5857},"end":{"line":185,"column":16,"offset":5872},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":5857},"end":{"line":185,"column":16,"offset":5872},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Check if enabled or disabled.","position":{"start":{"line":187,"column":1,"offset":5874},"end":{"line":187,"column":30,"offset":5903},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":5874},"end":{"line":187,"column":30,"offset":5903},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Response","position":{"start":{"line":189,"column":3,"offset":5907},"end":{"line":189,"column":11,"offset":5915},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":5905},"end":{"line":189,"column":13,"offset":5917},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":5905},"end":{"line":189,"column":13,"offset":5917},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n \t\"active\": \"true\",\n \t\"delay\": \"5000\"\n}","position":{"start":{"line":190,"column":1,"offset":5918},"end":{"line":195,"column":4,"offset":5971},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"inlineCode","value":"PUT api/v1/condition/enabled","position":{"start":{"line":197,"column":1,"offset":5973},"end":{"line":197,"column":31,"offset":6003},"indent":[]}}],"position":{"start":{"line":197,"column":1,"offset":5973},"end":{"line":197,"column":31,"offset":6003},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Description","position":{"start":{"line":199,"column":3,"offset":6007},"end":{"line":199,"column":14,"offset":6018},"indent":[]}}],"position":{"start":{"line":199,"column":1,"offset":6005},"end":{"line":199,"column":16,"offset":6020},"indent":[]}}],"position":{"start":{"line":199,"column":1,"offset":6005},"end":{"line":199,"column":16,"offset":6020},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Activate or disable the system.","position":{"start":{"line":201,"column":1,"offset":6022},"end":{"line":201,"column":32,"offset":6053},"indent":[]}}],"position":{"start":{"line":201,"column":1,"offset":6022},"end":{"line":201,"column":32,"offset":6053},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Payload","position":{"start":{"line":203,"column":3,"offset":6057},"end":{"line":203,"column":10,"offset":6064},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":6055},"end":{"line":203,"column":12,"offset":6066},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":6055},"end":{"line":203,"column":12,"offset":6066},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n \t\"active\": \"false\"\n}","position":{"start":{"line":204,"column":1,"offset":6067},"end":{"line":208,"column":4,"offset":6102},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Response","position":{"start":{"line":210,"column":3,"offset":6106},"end":{"line":210,"column":11,"offset":6114},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":6104},"end":{"line":210,"column":13,"offset":6116},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":6104},"end":{"line":210,"column":13,"offset":6116},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n \t\"active\": \"false\",\n \t\"delay\": \"5000\"\n}","position":{"start":{"line":211,"column":1,"offset":6117},"end":{"line":216,"column":4,"offset":6171},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"inlineCode","value":"GET api/v1/system/health","position":{"start":{"line":218,"column":1,"offset":6173},"end":{"line":218,"column":27,"offset":6199},"indent":[]}}],"position":{"start":{"line":218,"column":1,"offset":6173},"end":{"line":218,"column":27,"offset":6199},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Description","position":{"start":{"line":220,"column":3,"offset":6203},"end":{"line":220,"column":14,"offset":6214},"indent":[]}}],"position":{"start":{"line":220,"column":1,"offset":6201},"end":{"line":220,"column":16,"offset":6216},"indent":[]}}],"position":{"start":{"line":220,"column":1,"offset":6201},"end":{"line":220,"column":16,"offset":6216},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Check if the machinery is running (the stream is connected).","position":{"start":{"line":222,"column":1,"offset":6218},"end":{"line":222,"column":61,"offset":6278},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":6218},"end":{"line":222,"column":61,"offset":6278},"indent":[]}},{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Response","position":{"start":{"line":224,"column":3,"offset":6282},"end":{"line":224,"column":11,"offset":6290},"indent":[]}}],"position":{"start":{"line":224,"column":1,"offset":6280},"end":{"line":224,"column":13,"offset":6292},"indent":[]}}],"position":{"start":{"line":224,"column":1,"offset":6280},"end":{"line":224,"column":13,"offset":6292},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"{\n \t\"status\": \"false\"\n}","position":{"start":{"line":225,"column":1,"offset":6293},"end":{"line":229,"column":4,"offset":6328},"indent":[1,1,1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":232,"column":1,"offset":6331},"end":{"line":232,"column":31,"offset":6361},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":232,"column":31,"offset":6361}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Web interface`}

\n

{`The web is responsible for the visualization. It's a GUI which helps the user to find activity at a specific period, configure the machinery, view a live stream, see system information and much more.`}

\n

{`It's written in PHP using the extremely popular PHP Framework Laravel, and Javascript using the client-side framework BackboneJS. We will discuss the different pages and functionality briefly. Please check out `}{`the demo environment`}{` if you want to see a real life example.`}

\n

{`Overview`}

\n

{`We will shortly discuss the different pages that make up the web interface of Kerberos Open Source.`}

\n

{`Dashboard`}

\n

{`The landing page of the web is the dashboard. On the dashboard a user will see some statistics: activity per hour, activity per day, a live stream, the latest activity and a heatmap.`}

\n

\"web

\n

{`Overview`}

\n

{`When selecting a specific day, you'll will get a timeline and overview. By using the timeline you can navigate through a day; the timeline highlights the amount of activity, from gray to red.`}

\n

\"web

\n

{`Settings`}

\n

{`The settings page allows you to configure the machinery. You can define the type of camera, post-processes, conditions and much more; it's highly configurable.`}

\n

\"web

\n

{`System`}

\n

{`The system page allows you to monitor the system. On this page you'll get an overview of the system specifications (CPU, Memory, Network, etc). Several actions are available: you can download system information (for debugging purposes) and download or remove your images.`}

\n

\"web

\n

{`Project structure`}

\n

{`The web interface is using the Laravel framework (version 5.4). There is a lot of documentation related to Laravel, please review `}{`their documentation website here`}{`. In a nutshell this is how the web is organised.`}

\n

{`Back-end`}

\n
    \n
  • {`config/app.php - general application settings.`}
  • \n
  • {`config/kerberos.php - this file contains web specific parameters; the user credentials to sign in, etc.`}
  • \n
  • {`app/Http/Controllers - MVC controllers`}
  • \n
  • {`app/Http/Repositories -repositories are injected into the controller.`}
  • \n
  • {`app/Providers/AppServiceProvider.php - bind repositories to a specific interface - dependency injection.`}
  • \n
  • {`routes/api.php - contains all the URI endpoints for Ajax calls.`}
  • \n
  • {`routes/web.php - url routing for pages.`}
  • \n
\n

{`Front-end`}

\n
    \n
  • {`public/css/less - LESS is used for the CSS.`}
  • \n
  • {`public/js/app - BackboneJS and RequireJS is used for building modular JS classes.`}
  • \n
  • {`public/js/mustache - Mustache is used for the client-side view rendering.`}
  • \n
  • {`public/js/vendor - This is where the bower extensions are installed.`}
  • \n
  • {`public/capture - A directory where images are written to by default.`}
  • \n
  • {`public/bower.json - The bower extensions used in the web repository.`}
  • \n
  • {`public/Gruntfile.js - We are using Grunt for our task manager.`}
  • \n
\n

{`API`}

\n

{`If you want to integrate the Kerberos agent with your own application, you're at the right place! The web interface comes with a RESTfull API, that allows you to retrieve and modify information from the Kerberos agent.`}

\n
    \n
  • {`Disable the machinery`}
  • \n
  • {`Health check`}
  • \n
  • {`Enable or disable output devices`}
  • \n
  • {`etc.`}
  • \n
\n

{`Authentication`}

\n

{`To use the RESTfull API of your Kerberos agent you need to define an Authorization header with each request. We use Basic Authentication to secure the different endpoints.`}

\n
{`\"Authorization\"`}{`: `}{`\"Basic root:root\"`}
\n

{`An example with Python looks like this.`}

\n
{`import`}{` requests`}{`\n`}{`import`}{` json`}{`\n`}{`import`}{` base64`}{`\n`}{`url = `}{`\"http://ip-of-pi/api/v1/condition/enabled\"`}{`\n`}{`username = `}{`\"user\"`}{`\n`}{`password = `}{`\"passw\"`}{`\n`}{`basicAuth = base64.b64encode(`}{`'`}{`%s`}{`:`}{`%s`}{`'`}{` % (username, password))`}{`\n`}{`headers = {`}{`\"Authorization\"`}{`: `}{`\"Basic \"`}{` + basicAuth, `}{`\"Content-Type\"`}{`: `}{`\"application/json\"`}{`}`}{`\n`}{`data = `}{`'{\"active\": \"true\"}'`}{`\n`}{`#Call REST API`}{`\n`}{`response = requests.put(url, `}{`data`}{`=data, `}{`headers`}{`=headers)`}{`\n`}{`print`}{`(response.text)`}
\n

{`If you're using the wrong credentials, the web will return following error message.`}

\n
{`Invalid credentials.`}
\n

{`Endpoints`}

\n

{`All endpoints are prefixed with api/v`}{`[version]`}{`/, in which the last part defines the API version number. Below you will find all the available endpoints with there signature and response. Note that when you call an endpoint which doesn't exists, the web will throw an 404.`}

\n
{`{`}{`\n`}{`\t`}{`\"error\"`}{`: `}{`\"API method does not exists\"`}{`\n`}{`}`}
\n

{`Version 1`}

\n

{`Below you'll find a list of all API methods which are available for version 1.`}

\n

{`GET api/v1/name`}

\n

{`Description`}

\n

{`Retrieve the name of your instance.`}

\n

{`Response`}

\n
{`{`}{`\n`}{`\t`}{`\"name\"`}{`: `}{`\"frontdoor\"`}{`\n`}{`}`}
\n

{`PUT api/v1/name`}

\n

{`Description`}

\n

{`Change the name of your instance.`}

\n

{`Payload`}

\n
{`{`}{`\n`}{`\t`}{`\"name\"`}{`: `}{`\"frontdoor-changed\"`}{`\n`}{`}`}
\n

{`Response`}

\n
{`{`}{`\n`}{`\t`}{`\"name\"`}{`: `}{`\"frontdoor-changed\"`}{`\n`}{`}`}
\n

{`GET api/v1/images/latest_sequence`}

\n

{`Description`}

\n

{`Retrieve the latest sequence detected.`}

\n

{`Response`}

\n
{`[`}{`\n`}{`    {`}{`\n`}{`        `}{`time`}{`: `}{`\"10:59:57\"`}{`,`}{`\n`}{`        `}{`src`}{`: `}{`\"https://demo.kerberos.io/capture/1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\"`}{`,`}{`\n`}{`        `}{`local_src`}{`: `}{`\"/var/www/web/public/capture/1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\"`}{`,`}{`\n`}{`        `}{`metadata`}{`: {`}{`\n`}{`            `}{`key`}{`: `}{`\"1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\"`}{`,`}{`\n`}{`            `}{`user`}{`: `}{`\"1501491597_6-310145_frontdoor_722-691-873-926_703_511.mp4\"`}{`,`}{`\n`}{`            `}{`timestamp`}{`: `}{`1501491597`}{`,`}{`\n`}{`            `}{`microseconds`}{`: `}{`\"6-310145\"`}{`,`}{`\n`}{`            `}{`instanceName`}{`: `}{`\"frontdoor\"`}{`,`}{`\n`}{`            `}{`regionCoordinates`}{`: `}{`\"722-691-873-926\"`}{`,`}{`\n`}{`            `}{`numberOfChanges`}{`: `}{`\"703\"`}{`,`}{`\n`}{`            `}{`token`}{`: `}{`\"511\"`}{`\n`}{`        },`}{`\n`}{`        `}{`type`}{`: `}{`\"video\"`}{`\n`}{`    }`}{`\n`}{`]`}
\n

{`GET api/v1/condition/enabled`}

\n

{`Description`}

\n

{`Check if enabled or disabled.`}

\n

{`Response`}

\n
{`{`}{`\n`}{` \t`}{`\"active\"`}{`: `}{`\"true\"`}{`,`}{`\n`}{` \t`}{`\"delay\"`}{`: `}{`\"5000\"`}{`\n`}{`}`}
\n

{`PUT api/v1/condition/enabled`}

\n

{`Description`}

\n

{`Activate or disable the system.`}

\n

{`Payload`}

\n
{`{`}{`\n`}{` \t`}{`\"active\"`}{`: `}{`\"false\"`}{`\n`}{`}`}
\n

{`Response`}

\n
{`{`}{`\n`}{` \t`}{`\"active\"`}{`: `}{`\"false\"`}{`,`}{`\n`}{` \t`}{`\"delay\"`}{`: `}{`\"5000\"`}{`\n`}{`}`}
\n

{`GET api/v1/system/health`}

\n

{`Description`}

\n

{`Check if the machinery is running (the stream is connected).`}

\n

{`Response`}

\n
{`{`}{`\n`}{` \t`}{`\"status\"`}{`: `}{`\"false\"`}{`\n`}{`}`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0ca793490a7bb4791f7c46ebaa6e0c8d.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0ca793490a7bb4791f7c46ebaa6e0c8d.json index d41da84..1b768e2 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0ca793490a7bb4791f7c46ebaa6e0c8d.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0ca793490a7bb4791f7c46ebaa6e0c8d.json @@ -1 +1 @@ -{"expireTime":9007200841014157000,"key":"gatsby-plugin-mdx-entire-payload-a35b58ded27e947810985d1c31281232-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import SettingsIcon from '@material-ui/icons/Settings';","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":56,"offset":214},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Get Started","position":{"start":{"line":10,"column":3,"offset":218},"end":{"line":10,"column":14,"offset":229},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":216},"end":{"line":10,"column":14,"offset":229},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've installed Kerberos Enterprise, you will have the Factory service running inside your cluster, and you will have access to the Factory web application. This web application allows you to administrate your Machinery deployments/pods.","position":{"start":{"line":12,"column":1,"offset":231},"end":{"line":12,"column":244,"offset":474},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":231},"end":{"line":12,"column":244,"offset":474},"indent":[]}},{"type":"jsx","value":"
\n
\n

","position":{"start":{"line":14,"column":1,"offset":476},"end":{"line":16,"column":11,"offset":678},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Login page","position":{"start":{"line":18,"column":4,"offset":683},"end":{"line":18,"column":14,"offset":693},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":680},"end":{"line":18,"column":14,"offset":693},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you open a browser, and navigate to the Factory web application (see installation for the url), you will land on the login page.","position":{"start":{"line":20,"column":1,"offset":695},"end":{"line":20,"column":134,"offset":828},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":695},"end":{"line":20,"column":134,"offset":828},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-loginpage-small.png","alt":"Factory","position":{"start":{"line":22,"column":1,"offset":830},"end":{"line":22,"column":77,"offset":906},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":830},"end":{"line":22,"column":77,"offset":906},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The default username password of the Factory web applications is:","position":{"start":{"line":24,"column":1,"offset":908},"end":{"line":24,"column":66,"offset":973},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":908},"end":{"line":24,"column":66,"offset":973},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"username: ","position":{"start":{"line":26,"column":3,"offset":977},"end":{"line":26,"column":13,"offset":987},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"root","position":{"start":{"line":26,"column":15,"offset":989},"end":{"line":26,"column":19,"offset":993},"indent":[]}}],"position":{"start":{"line":26,"column":13,"offset":987},"end":{"line":26,"column":21,"offset":995},"indent":[]}}],"position":{"start":{"line":26,"column":3,"offset":977},"end":{"line":26,"column":21,"offset":995},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":975},"end":{"line":26,"column":21,"offset":995},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"password: ","position":{"start":{"line":27,"column":3,"offset":998},"end":{"line":27,"column":13,"offset":1008},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"kerberos","position":{"start":{"line":27,"column":15,"offset":1010},"end":{"line":27,"column":23,"offset":1018},"indent":[]}}],"position":{"start":{"line":27,"column":13,"offset":1008},"end":{"line":27,"column":25,"offset":1020},"indent":[]}}],"position":{"start":{"line":27,"column":3,"offset":998},"end":{"line":27,"column":25,"offset":1020},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":996},"end":{"line":27,"column":25,"offset":1020},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":975},"end":{"line":27,"column":25,"offset":1020},"indent":[1]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"The username and password can be changed in the MongoDB database.","position":{"start":{"line":29,"column":3,"offset":1024},"end":{"line":29,"column":68,"offset":1089},"indent":[]}}],"position":{"start":{"line":29,"column":3,"offset":1024},"end":{"line":29,"column":68,"offset":1089},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1022},"end":{"line":29,"column":68,"offset":1089},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"License key","position":{"start":{"line":31,"column":4,"offset":1094},"end":{"line":31,"column":15,"offset":1105},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1091},"end":{"line":31,"column":15,"offset":1105},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The first time you login you are asked for a license key, this can be obtained by sending a request to cedric@verstraeten.io. An example license key looks like this:","position":{"start":{"line":33,"column":1,"offset":1107},"end":{"line":33,"column":166,"offset":1272},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1107},"end":{"line":33,"column":166,"offset":1272},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"-----BEGIN LICENSE KEY-----\nL/+DAwEBB2xpY2Vuc2UB/4QAAQIBB1BheWxvYWQBCgABCVNpZ25hdHVyZQEKAAAA\n/9z/hAFUPBAADG1haW4uTGljZW5zZf+BAwEBB0xpY2Vuc2UB/4IAAQIBB0NvbXBh\nbnkBDAABB0V4cFRpbWUBBAAAABb/ghMBCmtlcmJlcm9zaW8B/MC7ZzIAAf+AOaJ+\n8eU3OlZCphr4uJyH/PzfuDkMrqyfIsutc5kSz3rjsRtU4e6vETpHre8CPvFyx5w2\n0O8PKCIR4z1q28qJK2cvHQTK0/zf+KfYLilEcmNczLXgg+bnPvtA/bU/K8ZEwbnw\nRta3+8zId+xtYQApdmHwo/Ih/vCN579iDeunwVQA\n-----END LICENSE KEY-----","position":{"start":{"line":35,"column":3,"offset":1276},"end":{"line":42,"column":26,"offset":1695},"indent":[1,1,1,1,1,1,1]}}],"position":{"start":{"line":35,"column":3,"offset":1276},"end":{"line":42,"column":26,"offset":1695},"indent":[1,1,1,1,1,1,1]}}],"position":{"start":{"line":35,"column":1,"offset":1274},"end":{"line":42,"column":26,"offset":1695},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-licensekey.png","alt":"Factory","position":{"start":{"line":44,"column":1,"offset":1697},"end":{"line":44,"column":72,"offset":1768},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":1697},"end":{"line":44,"column":72,"offset":1768},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you received a license key, and entered it into the web application you will be redirected to the login screen. Enter your credentials again, and you will be guided into the dashboard.","position":{"start":{"line":46,"column":1,"offset":1770},"end":{"line":46,"column":190,"offset":1959},"indent":[]}}],"position":{"start":{"line":46,"column":1,"offset":1770},"end":{"line":46,"column":190,"offset":1959},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Overview","position":{"start":{"line":48,"column":4,"offset":1964},"end":{"line":48,"column":12,"offset":1972},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":1961},"end":{"line":48,"column":12,"offset":1972},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On the overview page you will find an intuitive overview of the different pages and functionalities. On the left menu you will see two sections: ","position":{"start":{"line":50,"column":1,"offset":1974},"end":{"line":50,"column":146,"offset":2119},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Docker","position":{"start":{"line":50,"column":148,"offset":2121},"end":{"line":50,"column":154,"offset":2127},"indent":[]}}],"position":{"start":{"line":50,"column":146,"offset":2119},"end":{"line":50,"column":156,"offset":2129},"indent":[]}},{"type":"text","value":" and ","position":{"start":{"line":50,"column":156,"offset":2129},"end":{"line":50,"column":161,"offset":2134},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Kubernetes","position":{"start":{"line":50,"column":163,"offset":2136},"end":{"line":50,"column":173,"offset":2146},"indent":[]}}],"position":{"start":{"line":50,"column":161,"offset":2134},"end":{"line":50,"column":175,"offset":2148},"indent":[]}},{"type":"text","value":". Kerberos Enterprise can both run in Docker (single-host) and Kubernetes (cluster) mode, however the recommended way is Kubernetes.","position":{"start":{"line":50,"column":175,"offset":2148},"end":{"line":50,"column":307,"offset":2280},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":1974},"end":{"line":50,"column":307,"offset":2280},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-dashboard.png","alt":"Factory","position":{"start":{"line":52,"column":1,"offset":2282},"end":{"line":52,"column":71,"offset":2352},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2282},"end":{"line":52,"column":71,"offset":2352},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Kubernetes","position":{"start":{"line":54,"column":4,"offset":2357},"end":{"line":54,"column":14,"offset":2367},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2354},"end":{"line":54,"column":14,"offset":2367},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On the left menu you will find the Kubernetes section. In this section 3 sub menu's are available:","position":{"start":{"line":56,"column":1,"offset":2369},"end":{"line":56,"column":99,"offset":2467},"indent":[]}}],"position":{"start":{"line":56,"column":1,"offset":2369},"end":{"line":56,"column":99,"offset":2467},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Nodes","position":{"start":{"line":58,"column":3,"offset":2471},"end":{"line":58,"column":8,"offset":2476},"indent":[]}}],"position":{"start":{"line":58,"column":3,"offset":2471},"end":{"line":58,"column":8,"offset":2476},"indent":[]}}],"position":{"start":{"line":58,"column":1,"offset":2469},"end":{"line":58,"column":8,"offset":2476},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Deployments","position":{"start":{"line":59,"column":3,"offset":2479},"end":{"line":59,"column":14,"offset":2490},"indent":[]}}],"position":{"start":{"line":59,"column":3,"offset":2479},"end":{"line":59,"column":14,"offset":2490},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2477},"end":{"line":59,"column":14,"offset":2490},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Pods","position":{"start":{"line":60,"column":3,"offset":2493},"end":{"line":60,"column":7,"offset":2497},"indent":[]}}],"position":{"start":{"line":60,"column":3,"offset":2493},"end":{"line":60,"column":7,"offset":2497},"indent":[]}}],"position":{"start":{"line":60,"column":1,"offset":2491},"end":{"line":60,"column":7,"offset":2497},"indent":[]}}],"position":{"start":{"line":58,"column":1,"offset":2469},"end":{"line":60,"column":7,"offset":2497},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Nodes","position":{"start":{"line":62,"column":4,"offset":2502},"end":{"line":62,"column":9,"offset":2507},"indent":[]}}],"position":{"start":{"line":62,"column":1,"offset":2499},"end":{"line":62,"column":9,"offset":2507},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The nodes section lists all the available nodes inside your Kubernetes cluster.","position":{"start":{"line":64,"column":1,"offset":2509},"end":{"line":64,"column":80,"offset":2588},"indent":[]}}],"position":{"start":{"line":64,"column":1,"offset":2509},"end":{"line":64,"column":80,"offset":2588},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-nodes.png","alt":"Factory","position":{"start":{"line":66,"column":1,"offset":2590},"end":{"line":66,"column":67,"offset":2656},"indent":[]}}],"position":{"start":{"line":66,"column":1,"offset":2590},"end":{"line":66,"column":67,"offset":2656},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Deployments","position":{"start":{"line":68,"column":4,"offset":2661},"end":{"line":68,"column":15,"offset":2672},"indent":[]}}],"position":{"start":{"line":68,"column":1,"offset":2658},"end":{"line":68,"column":15,"offset":2672},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The deployments section will list all the machinery deployments (agents) that you have deployed inside your cluster. It gives you access to deploy new deploments one by one or in bulk.","position":{"start":{"line":70,"column":1,"offset":2674},"end":{"line":70,"column":185,"offset":2858},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":2674},"end":{"line":70,"column":185,"offset":2858},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-deployments.png","alt":"Factory","position":{"start":{"line":72,"column":1,"offset":2860},"end":{"line":72,"column":73,"offset":2932},"indent":[]}}],"position":{"start":{"line":72,"column":1,"offset":2860},"end":{"line":72,"column":73,"offset":2932},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Adding a new deployment","position":{"start":{"line":74,"column":5,"offset":2938},"end":{"line":74,"column":28,"offset":2961},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":2934},"end":{"line":74,"column":28,"offset":2961},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"There are two options to add a new deployment:","position":{"start":{"line":76,"column":1,"offset":2963},"end":{"line":76,"column":47,"offset":3009},"indent":[]}}],"position":{"start":{"line":76,"column":1,"offset":2963},"end":{"line":76,"column":47,"offset":3009},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"single deployment","position":{"start":{"line":77,"column":3,"offset":3012},"end":{"line":77,"column":20,"offset":3029},"indent":[]}}],"position":{"start":{"line":77,"column":3,"offset":3012},"end":{"line":77,"column":20,"offset":3029},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3010},"end":{"line":77,"column":20,"offset":3029},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3010},"end":{"line":77,"column":20,"offset":3029},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By specifying a name for your deployment and it's corresponding RTSP url, a new deployment will be created for you, and deployed to one of your installed nodes.","position":{"start":{"line":79,"column":1,"offset":3031},"end":{"line":79,"column":161,"offset":3191},"indent":[]}}],"position":{"start":{"line":79,"column":1,"offset":3031},"end":{"line":79,"column":161,"offset":3191},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-add-single-deployment.png","alt":"Factory","position":{"start":{"line":81,"column":1,"offset":3193},"end":{"line":81,"column":83,"offset":3275},"indent":[]}}],"position":{"start":{"line":81,"column":1,"offset":3193},"end":{"line":81,"column":83,"offset":3275},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"in bulk deployment.","position":{"start":{"line":83,"column":3,"offset":3279},"end":{"line":83,"column":22,"offset":3298},"indent":[]}}],"position":{"start":{"line":83,"column":3,"offset":3279},"end":{"line":83,"column":22,"offset":3298},"indent":[]}}],"position":{"start":{"line":83,"column":1,"offset":3277},"end":{"line":83,"column":22,"offset":3298},"indent":[]}}],"position":{"start":{"line":83,"column":1,"offset":3277},"end":{"line":83,"column":22,"offset":3298},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By importing an Excel file, deployments can be created in bulk.","position":{"start":{"line":85,"column":1,"offset":3300},"end":{"line":85,"column":64,"offset":3363},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":3300},"end":{"line":85,"column":64,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-add-bulk-deployment.png","alt":"Factory","position":{"start":{"line":87,"column":1,"offset":3365},"end":{"line":87,"column":81,"offset":3445},"indent":[]}}],"position":{"start":{"line":87,"column":1,"offset":3365},"end":{"line":87,"column":81,"offset":3445},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By specifying the name and corresponding RTSP url in multiple rows, you can deploy your deployments in bulk.","position":{"start":{"line":89,"column":1,"offset":3447},"end":{"line":89,"column":109,"offset":3555},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":3447},"end":{"line":89,"column":109,"offset":3555},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-add-bulk-deployment-excel.png","alt":"Factory","position":{"start":{"line":91,"column":1,"offset":3557},"end":{"line":91,"column":87,"offset":3643},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3557},"end":{"line":91,"column":87,"offset":3643},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Configuring a deployment","position":{"start":{"line":93,"column":5,"offset":3649},"end":{"line":93,"column":29,"offset":3673},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3645},"end":{"line":93,"column":29,"offset":3673},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have a running deployment, you should see a green circle next to the deployment, indicating that it is succesfully running. At any time you can configure your deployments by clicking on the ","position":{"start":{"line":95,"column":1,"offset":3675},"end":{"line":95,"column":200,"offset":3874},"indent":[]}},{"type":"jsx","value":"","position":{"start":{"line":95,"column":200,"offset":3874},"end":{"line":95,"column":235,"offset":3909},"indent":[]}},{"type":"text","value":" icon. This will open a popup, allowing you to change some settings.","position":{"start":{"line":95,"column":235,"offset":3909},"end":{"line":95,"column":303,"offset":3977},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":3675},"end":{"line":95,"column":303,"offset":3977},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-config-region.png","alt":"Factory","position":{"start":{"line":97,"column":1,"offset":3979},"end":{"line":97,"column":75,"offset":4053},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":3979},"end":{"line":97,"column":75,"offset":4053},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following settings can be changed:","position":{"start":{"line":99,"column":1,"offset":4055},"end":{"line":99,"column":35,"offset":4089},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4055},"end":{"line":99,"column":35,"offset":4089},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"One or more regions of interest,","position":{"start":{"line":101,"column":3,"offset":4093},"end":{"line":101,"column":35,"offset":4125},"indent":[]}}],"position":{"start":{"line":101,"column":3,"offset":4093},"end":{"line":101,"column":35,"offset":4125},"indent":[]}}],"position":{"start":{"line":101,"column":1,"offset":4091},"end":{"line":101,"column":35,"offset":4125},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Time based conditions,","position":{"start":{"line":102,"column":3,"offset":4128},"end":{"line":102,"column":25,"offset":4150},"indent":[]}}],"position":{"start":{"line":102,"column":3,"offset":4128},"end":{"line":102,"column":25,"offset":4150},"indent":[]}}],"position":{"start":{"line":102,"column":1,"offset":4126},"end":{"line":102,"column":25,"offset":4150},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Pre- and postrecording","position":{"start":{"line":103,"column":3,"offset":4153},"end":{"line":103,"column":25,"offset":4175},"indent":[]}}],"position":{"start":{"line":103,"column":3,"offset":4153},"end":{"line":103,"column":25,"offset":4175},"indent":[]}}],"position":{"start":{"line":103,"column":1,"offset":4151},"end":{"line":103,"column":25,"offset":4175},"indent":[]}}],"position":{"start":{"line":101,"column":1,"offset":4091},"end":{"line":103,"column":25,"offset":4175},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Pods","position":{"start":{"line":105,"column":4,"offset":4180},"end":{"line":105,"column":8,"offset":4184},"indent":[]}}],"position":{"start":{"line":105,"column":1,"offset":4177},"end":{"line":105,"column":8,"offset":4184},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When creating a deployment, Kubernetes will create a Pod. This Pod will be deployed to one of your available nodes.\nOnce a Pod dies, or crashes, the deployment will make sure it is deployed again to a different (or the same) node.","position":{"start":{"line":107,"column":1,"offset":4186},"end":{"line":108,"column":115,"offset":4416},"indent":[1]}}],"position":{"start":{"line":107,"column":1,"offset":4186},"end":{"line":108,"column":115,"offset":4416},"indent":[1]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-pods.png","alt":"Factory","position":{"start":{"line":110,"column":1,"offset":4418},"end":{"line":110,"column":66,"offset":4483},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4418},"end":{"line":110,"column":66,"offset":4483},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Storage and video management","position":{"start":{"line":113,"column":4,"offset":4489},"end":{"line":113,"column":32,"offset":4517},"indent":[]}}],"position":{"start":{"line":113,"column":1,"offset":4486},"end":{"line":113,"column":32,"offset":4517},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Enterprise allows you to scale your video landscape horizontally, it stores its recordings locally for a short amount of time. The idea of Kerberos Enterprise is ","position":{"start":{"line":115,"column":1,"offset":4519},"end":{"line":115,"column":172,"offset":4690},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"not","position":{"start":{"line":115,"column":174,"offset":4692},"end":{"line":115,"column":177,"offset":4695},"indent":[]}}],"position":{"start":{"line":115,"column":172,"offset":4690},"end":{"line":115,"column":179,"offset":4697},"indent":[]}},{"type":"text","value":" to have a visual component, for example to browse through recordings, and search for specific events.","position":{"start":{"line":115,"column":179,"offset":4697},"end":{"line":115,"column":281,"offset":4799},"indent":[]}}],"position":{"start":{"line":115,"column":1,"offset":4519},"end":{"line":115,"column":281,"offset":4799},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To make this functionality possible we have integrated (similar to the open source version), Kerberos Enterprise, to ","position":{"start":{"line":117,"column":1,"offset":4801},"end":{"line":117,"column":118,"offset":4918},"indent":[]}},{"type":"link","title":null,"url":"/cloud","children":[{"type":"text","value":"Kerberos Cloud","position":{"start":{"line":117,"column":119,"offset":4919},"end":{"line":117,"column":133,"offset":4933},"indent":[]}}],"position":{"start":{"line":117,"column":118,"offset":4918},"end":{"line":117,"column":142,"offset":4942},"indent":[]}},{"type":"text","value":". A full featured, and extensive, platform for managing your video surveillance systems.","position":{"start":{"line":117,"column":142,"offset":4942},"end":{"line":117,"column":230,"offset":5030},"indent":[]}}],"position":{"start":{"line":117,"column":1,"offset":4801},"end":{"line":117,"column":230,"offset":5030},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":120,"column":1,"offset":5033},"end":{"line":120,"column":31,"offset":5063},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":120,"column":31,"offset":5063}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport SettingsIcon from '@material-ui/icons/Settings';\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Get Started`}

\n

{`Once you've installed Kerberos Enterprise, you will have the Factory service running inside your cluster, and you will have access to the Factory web application. This web application allows you to administrate your Machinery deployments/pods.`}

\n
\n
\n

\n

{`Login page`}

\n

{`Once you open a browser, and navigate to the Factory web application (see installation for the url), you will land on the login page.`}

\n

\"Factory\"

\n

{`The default username password of the Factory web applications is:`}

\n
    \n
  • {`username: `}{`root`}
  • \n
  • {`password: `}{`kerberos`}
  • \n
\n
\n

{`The username and password can be changed in the MongoDB database.`}

\n
\n

{`License key`}

\n

{`The first time you login you are asked for a license key, this can be obtained by sending a request to cedric@verstraeten.io. An example license key looks like this:`}

\n
\n

{`-----BEGIN LICENSE KEY-----\nL/+DAwEBB2xpY2Vuc2UB/4QAAQIBB1BheWxvYWQBCgABCVNpZ25hdHVyZQEKAAAA\n/9z/hAFUPBAADG1haW4uTGljZW5zZf+BAwEBB0xpY2Vuc2UB/4IAAQIBB0NvbXBh\nbnkBDAABB0V4cFRpbWUBBAAAABb/ghMBCmtlcmJlcm9zaW8B/MC7ZzIAAf+AOaJ+\n8eU3OlZCphr4uJyH/PzfuDkMrqyfIsutc5kSz3rjsRtU4e6vETpHre8CPvFyx5w2\n0O8PKCIR4z1q28qJK2cvHQTK0/zf+KfYLilEcmNczLXgg+bnPvtA/bU/K8ZEwbnw\nRta3+8zId+xtYQApdmHwo/Ih/vCN579iDeunwVQA\n-----END LICENSE KEY-----`}

\n
\n

\"Factory\"

\n

{`Once you received a license key, and entered it into the web application you will be redirected to the login screen. Enter your credentials again, and you will be guided into the dashboard.`}

\n

{`Overview`}

\n

{`On the overview page you will find an intuitive overview of the different pages and functionalities. On the left menu you will see two sections: `}{`Docker`}{` and `}{`Kubernetes`}{`. Kerberos Enterprise can both run in Docker (single-host) and Kubernetes (cluster) mode, however the recommended way is Kubernetes.`}

\n

\"Factory\"

\n

{`Kubernetes`}

\n

{`On the left menu you will find the Kubernetes section. In this section 3 sub menu's are available:`}

\n
    \n
  • {`Nodes`}
  • \n
  • {`Deployments`}
  • \n
  • {`Pods`}
  • \n
\n

{`Nodes`}

\n

{`The nodes section lists all the available nodes inside your Kubernetes cluster.`}

\n

\"Factory\"

\n

{`Deployments`}

\n

{`The deployments section will list all the machinery deployments (agents) that you have deployed inside your cluster. It gives you access to deploy new deploments one by one or in bulk.`}

\n

\"Factory\"

\n

{`Adding a new deployment`}

\n

{`There are two options to add a new deployment:`}

\n
    \n
  • {`single deployment`}
  • \n
\n

{`By specifying a name for your deployment and it's corresponding RTSP url, a new deployment will be created for you, and deployed to one of your installed nodes.`}

\n

\"Factory\"

\n
    \n
  • {`in bulk deployment.`}
  • \n
\n

{`By importing an Excel file, deployments can be created in bulk.`}

\n

\"Factory\"

\n

{`By specifying the name and corresponding RTSP url in multiple rows, you can deploy your deployments in bulk.`}

\n

\"Factory\"

\n

{`Configuring a deployment`}

\n

{`Once you have a running deployment, you should see a green circle next to the deployment, indicating that it is succesfully running. At any time you can configure your deployments by clicking on the `}{` icon. This will open a popup, allowing you to change some settings.`}

\n

\"Factory\"

\n

{`Following settings can be changed:`}

\n
    \n
  • {`One or more regions of interest,`}
  • \n
  • {`Time based conditions,`}
  • \n
  • {`Pre- and postrecording`}
  • \n
\n

{`Pods`}

\n

{`When creating a deployment, Kubernetes will create a Pod. This Pod will be deployed to one of your available nodes.\nOnce a Pod dies, or crashes, the deployment will make sure it is deployed again to a different (or the same) node.`}

\n

\"Factory\"

\n

{`Storage and video management`}

\n

{`Kerberos Enterprise allows you to scale your video landscape horizontally, it stores its recordings locally for a short amount of time. The idea of Kerberos Enterprise is `}{`not`}{` to have a visual component, for example to browse through recordings, and search for specific events.`}

\n

{`To make this functionality possible we have integrated (similar to the open source version), Kerberos Enterprise, to `}{`Kerberos Cloud`}{`. A full featured, and extensive, platform for managing your video surveillance systems.`}

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974263000,"key":"gatsby-plugin-mdx-entire-payload-a35b58ded27e947810985d1c31281232-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import SettingsIcon from '@material-ui/icons/Settings';","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":56,"offset":214},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Get Started","position":{"start":{"line":10,"column":3,"offset":218},"end":{"line":10,"column":14,"offset":229},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":216},"end":{"line":10,"column":14,"offset":229},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've installed Kerberos Enterprise, you will have the Factory service running inside your cluster, and you will have access to the Factory web application. This web application allows you to administrate your Machinery deployments/pods.","position":{"start":{"line":12,"column":1,"offset":231},"end":{"line":12,"column":244,"offset":474},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":231},"end":{"line":12,"column":244,"offset":474},"indent":[]}},{"type":"jsx","value":"
\n
\n

","position":{"start":{"line":14,"column":1,"offset":476},"end":{"line":16,"column":11,"offset":678},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Login page","position":{"start":{"line":18,"column":4,"offset":683},"end":{"line":18,"column":14,"offset":693},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":680},"end":{"line":18,"column":14,"offset":693},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you open a browser, and navigate to the Factory web application (see installation for the url), you will land on the login page.","position":{"start":{"line":20,"column":1,"offset":695},"end":{"line":20,"column":134,"offset":828},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":695},"end":{"line":20,"column":134,"offset":828},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-loginpage-small.png","alt":"Factory","position":{"start":{"line":22,"column":1,"offset":830},"end":{"line":22,"column":77,"offset":906},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":830},"end":{"line":22,"column":77,"offset":906},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The default username password of the Factory web applications is:","position":{"start":{"line":24,"column":1,"offset":908},"end":{"line":24,"column":66,"offset":973},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":908},"end":{"line":24,"column":66,"offset":973},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"username: ","position":{"start":{"line":26,"column":3,"offset":977},"end":{"line":26,"column":13,"offset":987},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"root","position":{"start":{"line":26,"column":15,"offset":989},"end":{"line":26,"column":19,"offset":993},"indent":[]}}],"position":{"start":{"line":26,"column":13,"offset":987},"end":{"line":26,"column":21,"offset":995},"indent":[]}}],"position":{"start":{"line":26,"column":3,"offset":977},"end":{"line":26,"column":21,"offset":995},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":975},"end":{"line":26,"column":21,"offset":995},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"password: ","position":{"start":{"line":27,"column":3,"offset":998},"end":{"line":27,"column":13,"offset":1008},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"kerberos","position":{"start":{"line":27,"column":15,"offset":1010},"end":{"line":27,"column":23,"offset":1018},"indent":[]}}],"position":{"start":{"line":27,"column":13,"offset":1008},"end":{"line":27,"column":25,"offset":1020},"indent":[]}}],"position":{"start":{"line":27,"column":3,"offset":998},"end":{"line":27,"column":25,"offset":1020},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":996},"end":{"line":27,"column":25,"offset":1020},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":975},"end":{"line":27,"column":25,"offset":1020},"indent":[1]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"The username and password can be changed in the MongoDB database.","position":{"start":{"line":29,"column":3,"offset":1024},"end":{"line":29,"column":68,"offset":1089},"indent":[]}}],"position":{"start":{"line":29,"column":3,"offset":1024},"end":{"line":29,"column":68,"offset":1089},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1022},"end":{"line":29,"column":68,"offset":1089},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"License key","position":{"start":{"line":31,"column":4,"offset":1094},"end":{"line":31,"column":15,"offset":1105},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1091},"end":{"line":31,"column":15,"offset":1105},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The first time you login you are asked for a license key, this can be obtained by sending a request to cedric@verstraeten.io. An example license key looks like this:","position":{"start":{"line":33,"column":1,"offset":1107},"end":{"line":33,"column":166,"offset":1272},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1107},"end":{"line":33,"column":166,"offset":1272},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"-----BEGIN LICENSE KEY-----\nL/+DAwEBB2xpY2Vuc2UB/4QAAQIBB1BheWxvYWQBCgABCVNpZ25hdHVyZQEKAAAA\n/9z/hAFUPBAADG1haW4uTGljZW5zZf+BAwEBB0xpY2Vuc2UB/4IAAQIBB0NvbXBh\nbnkBDAABB0V4cFRpbWUBBAAAABb/ghMBCmtlcmJlcm9zaW8B/MC7ZzIAAf+AOaJ+\n8eU3OlZCphr4uJyH/PzfuDkMrqyfIsutc5kSz3rjsRtU4e6vETpHre8CPvFyx5w2\n0O8PKCIR4z1q28qJK2cvHQTK0/zf+KfYLilEcmNczLXgg+bnPvtA/bU/K8ZEwbnw\nRta3+8zId+xtYQApdmHwo/Ih/vCN579iDeunwVQA\n-----END LICENSE KEY-----","position":{"start":{"line":35,"column":3,"offset":1276},"end":{"line":42,"column":26,"offset":1695},"indent":[1,1,1,1,1,1,1]}}],"position":{"start":{"line":35,"column":3,"offset":1276},"end":{"line":42,"column":26,"offset":1695},"indent":[1,1,1,1,1,1,1]}}],"position":{"start":{"line":35,"column":1,"offset":1274},"end":{"line":42,"column":26,"offset":1695},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-licensekey.png","alt":"Factory","position":{"start":{"line":44,"column":1,"offset":1697},"end":{"line":44,"column":72,"offset":1768},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":1697},"end":{"line":44,"column":72,"offset":1768},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you received a license key, and entered it into the web application you will be redirected to the login screen. Enter your credentials again, and you will be guided into the dashboard.","position":{"start":{"line":46,"column":1,"offset":1770},"end":{"line":46,"column":190,"offset":1959},"indent":[]}}],"position":{"start":{"line":46,"column":1,"offset":1770},"end":{"line":46,"column":190,"offset":1959},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Overview","position":{"start":{"line":48,"column":4,"offset":1964},"end":{"line":48,"column":12,"offset":1972},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":1961},"end":{"line":48,"column":12,"offset":1972},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On the overview page you will find an intuitive overview of the different pages and functionalities. On the left menu you will see two sections: ","position":{"start":{"line":50,"column":1,"offset":1974},"end":{"line":50,"column":146,"offset":2119},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Docker","position":{"start":{"line":50,"column":148,"offset":2121},"end":{"line":50,"column":154,"offset":2127},"indent":[]}}],"position":{"start":{"line":50,"column":146,"offset":2119},"end":{"line":50,"column":156,"offset":2129},"indent":[]}},{"type":"text","value":" and ","position":{"start":{"line":50,"column":156,"offset":2129},"end":{"line":50,"column":161,"offset":2134},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Kubernetes","position":{"start":{"line":50,"column":163,"offset":2136},"end":{"line":50,"column":173,"offset":2146},"indent":[]}}],"position":{"start":{"line":50,"column":161,"offset":2134},"end":{"line":50,"column":175,"offset":2148},"indent":[]}},{"type":"text","value":". Kerberos Enterprise can both run in Docker (single-host) and Kubernetes (cluster) mode, however the recommended way is Kubernetes.","position":{"start":{"line":50,"column":175,"offset":2148},"end":{"line":50,"column":307,"offset":2280},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":1974},"end":{"line":50,"column":307,"offset":2280},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-dashboard.png","alt":"Factory","position":{"start":{"line":52,"column":1,"offset":2282},"end":{"line":52,"column":71,"offset":2352},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2282},"end":{"line":52,"column":71,"offset":2352},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Kubernetes","position":{"start":{"line":54,"column":4,"offset":2357},"end":{"line":54,"column":14,"offset":2367},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2354},"end":{"line":54,"column":14,"offset":2367},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On the left menu you will find the Kubernetes section. In this section 3 sub menu's are available:","position":{"start":{"line":56,"column":1,"offset":2369},"end":{"line":56,"column":99,"offset":2467},"indent":[]}}],"position":{"start":{"line":56,"column":1,"offset":2369},"end":{"line":56,"column":99,"offset":2467},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Nodes","position":{"start":{"line":58,"column":3,"offset":2471},"end":{"line":58,"column":8,"offset":2476},"indent":[]}}],"position":{"start":{"line":58,"column":3,"offset":2471},"end":{"line":58,"column":8,"offset":2476},"indent":[]}}],"position":{"start":{"line":58,"column":1,"offset":2469},"end":{"line":58,"column":8,"offset":2476},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Deployments","position":{"start":{"line":59,"column":3,"offset":2479},"end":{"line":59,"column":14,"offset":2490},"indent":[]}}],"position":{"start":{"line":59,"column":3,"offset":2479},"end":{"line":59,"column":14,"offset":2490},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2477},"end":{"line":59,"column":14,"offset":2490},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Pods","position":{"start":{"line":60,"column":3,"offset":2493},"end":{"line":60,"column":7,"offset":2497},"indent":[]}}],"position":{"start":{"line":60,"column":3,"offset":2493},"end":{"line":60,"column":7,"offset":2497},"indent":[]}}],"position":{"start":{"line":60,"column":1,"offset":2491},"end":{"line":60,"column":7,"offset":2497},"indent":[]}}],"position":{"start":{"line":58,"column":1,"offset":2469},"end":{"line":60,"column":7,"offset":2497},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Nodes","position":{"start":{"line":62,"column":4,"offset":2502},"end":{"line":62,"column":9,"offset":2507},"indent":[]}}],"position":{"start":{"line":62,"column":1,"offset":2499},"end":{"line":62,"column":9,"offset":2507},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The nodes section lists all the available nodes inside your Kubernetes cluster.","position":{"start":{"line":64,"column":1,"offset":2509},"end":{"line":64,"column":80,"offset":2588},"indent":[]}}],"position":{"start":{"line":64,"column":1,"offset":2509},"end":{"line":64,"column":80,"offset":2588},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-nodes.png","alt":"Factory","position":{"start":{"line":66,"column":1,"offset":2590},"end":{"line":66,"column":67,"offset":2656},"indent":[]}}],"position":{"start":{"line":66,"column":1,"offset":2590},"end":{"line":66,"column":67,"offset":2656},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Deployments","position":{"start":{"line":68,"column":4,"offset":2661},"end":{"line":68,"column":15,"offset":2672},"indent":[]}}],"position":{"start":{"line":68,"column":1,"offset":2658},"end":{"line":68,"column":15,"offset":2672},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The deployments section will list all the machinery deployments (agents) that you have deployed inside your cluster. It gives you access to deploy new deploments one by one or in bulk.","position":{"start":{"line":70,"column":1,"offset":2674},"end":{"line":70,"column":185,"offset":2858},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":2674},"end":{"line":70,"column":185,"offset":2858},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-deployments.png","alt":"Factory","position":{"start":{"line":72,"column":1,"offset":2860},"end":{"line":72,"column":73,"offset":2932},"indent":[]}}],"position":{"start":{"line":72,"column":1,"offset":2860},"end":{"line":72,"column":73,"offset":2932},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Adding a new deployment","position":{"start":{"line":74,"column":5,"offset":2938},"end":{"line":74,"column":28,"offset":2961},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":2934},"end":{"line":74,"column":28,"offset":2961},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"There are two options to add a new deployment:","position":{"start":{"line":76,"column":1,"offset":2963},"end":{"line":76,"column":47,"offset":3009},"indent":[]}}],"position":{"start":{"line":76,"column":1,"offset":2963},"end":{"line":76,"column":47,"offset":3009},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"single deployment","position":{"start":{"line":77,"column":3,"offset":3012},"end":{"line":77,"column":20,"offset":3029},"indent":[]}}],"position":{"start":{"line":77,"column":3,"offset":3012},"end":{"line":77,"column":20,"offset":3029},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3010},"end":{"line":77,"column":20,"offset":3029},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3010},"end":{"line":77,"column":20,"offset":3029},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By specifying a name for your deployment and it's corresponding RTSP url, a new deployment will be created for you, and deployed to one of your installed nodes.","position":{"start":{"line":79,"column":1,"offset":3031},"end":{"line":79,"column":161,"offset":3191},"indent":[]}}],"position":{"start":{"line":79,"column":1,"offset":3031},"end":{"line":79,"column":161,"offset":3191},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-add-single-deployment.png","alt":"Factory","position":{"start":{"line":81,"column":1,"offset":3193},"end":{"line":81,"column":83,"offset":3275},"indent":[]}}],"position":{"start":{"line":81,"column":1,"offset":3193},"end":{"line":81,"column":83,"offset":3275},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"in bulk deployment.","position":{"start":{"line":83,"column":3,"offset":3279},"end":{"line":83,"column":22,"offset":3298},"indent":[]}}],"position":{"start":{"line":83,"column":3,"offset":3279},"end":{"line":83,"column":22,"offset":3298},"indent":[]}}],"position":{"start":{"line":83,"column":1,"offset":3277},"end":{"line":83,"column":22,"offset":3298},"indent":[]}}],"position":{"start":{"line":83,"column":1,"offset":3277},"end":{"line":83,"column":22,"offset":3298},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By importing an Excel file, deployments can be created in bulk.","position":{"start":{"line":85,"column":1,"offset":3300},"end":{"line":85,"column":64,"offset":3363},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":3300},"end":{"line":85,"column":64,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-add-bulk-deployment.png","alt":"Factory","position":{"start":{"line":87,"column":1,"offset":3365},"end":{"line":87,"column":81,"offset":3445},"indent":[]}}],"position":{"start":{"line":87,"column":1,"offset":3365},"end":{"line":87,"column":81,"offset":3445},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By specifying the name and corresponding RTSP url in multiple rows, you can deploy your deployments in bulk.","position":{"start":{"line":89,"column":1,"offset":3447},"end":{"line":89,"column":109,"offset":3555},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":3447},"end":{"line":89,"column":109,"offset":3555},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-add-bulk-deployment-excel.png","alt":"Factory","position":{"start":{"line":91,"column":1,"offset":3557},"end":{"line":91,"column":87,"offset":3643},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3557},"end":{"line":91,"column":87,"offset":3643},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Configuring a deployment","position":{"start":{"line":93,"column":5,"offset":3649},"end":{"line":93,"column":29,"offset":3673},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3645},"end":{"line":93,"column":29,"offset":3673},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have a running deployment, you should see a green circle next to the deployment, indicating that it is succesfully running. At any time you can configure your deployments by clicking on the ","position":{"start":{"line":95,"column":1,"offset":3675},"end":{"line":95,"column":200,"offset":3874},"indent":[]}},{"type":"jsx","value":"","position":{"start":{"line":95,"column":200,"offset":3874},"end":{"line":95,"column":235,"offset":3909},"indent":[]}},{"type":"text","value":" icon. This will open a popup, allowing you to change some settings.","position":{"start":{"line":95,"column":235,"offset":3909},"end":{"line":95,"column":303,"offset":3977},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":3675},"end":{"line":95,"column":303,"offset":3977},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-config-region.png","alt":"Factory","position":{"start":{"line":97,"column":1,"offset":3979},"end":{"line":97,"column":75,"offset":4053},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":3979},"end":{"line":97,"column":75,"offset":4053},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following settings can be changed:","position":{"start":{"line":99,"column":1,"offset":4055},"end":{"line":99,"column":35,"offset":4089},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4055},"end":{"line":99,"column":35,"offset":4089},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"One or more regions of interest,","position":{"start":{"line":101,"column":3,"offset":4093},"end":{"line":101,"column":35,"offset":4125},"indent":[]}}],"position":{"start":{"line":101,"column":3,"offset":4093},"end":{"line":101,"column":35,"offset":4125},"indent":[]}}],"position":{"start":{"line":101,"column":1,"offset":4091},"end":{"line":101,"column":35,"offset":4125},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Time based conditions,","position":{"start":{"line":102,"column":3,"offset":4128},"end":{"line":102,"column":25,"offset":4150},"indent":[]}}],"position":{"start":{"line":102,"column":3,"offset":4128},"end":{"line":102,"column":25,"offset":4150},"indent":[]}}],"position":{"start":{"line":102,"column":1,"offset":4126},"end":{"line":102,"column":25,"offset":4150},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Pre- and postrecording","position":{"start":{"line":103,"column":3,"offset":4153},"end":{"line":103,"column":25,"offset":4175},"indent":[]}}],"position":{"start":{"line":103,"column":3,"offset":4153},"end":{"line":103,"column":25,"offset":4175},"indent":[]}}],"position":{"start":{"line":103,"column":1,"offset":4151},"end":{"line":103,"column":25,"offset":4175},"indent":[]}}],"position":{"start":{"line":101,"column":1,"offset":4091},"end":{"line":103,"column":25,"offset":4175},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Pods","position":{"start":{"line":105,"column":4,"offset":4180},"end":{"line":105,"column":8,"offset":4184},"indent":[]}}],"position":{"start":{"line":105,"column":1,"offset":4177},"end":{"line":105,"column":8,"offset":4184},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When creating a deployment, Kubernetes will create a Pod. This Pod will be deployed to one of your available nodes.\nOnce a Pod dies, or crashes, the deployment will make sure it is deployed again to a different (or the same) node.","position":{"start":{"line":107,"column":1,"offset":4186},"end":{"line":108,"column":115,"offset":4416},"indent":[1]}}],"position":{"start":{"line":107,"column":1,"offset":4186},"end":{"line":108,"column":115,"offset":4416},"indent":[1]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-pods.png","alt":"Factory","position":{"start":{"line":110,"column":1,"offset":4418},"end":{"line":110,"column":66,"offset":4483},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4418},"end":{"line":110,"column":66,"offset":4483},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Storage and video management","position":{"start":{"line":113,"column":4,"offset":4489},"end":{"line":113,"column":32,"offset":4517},"indent":[]}}],"position":{"start":{"line":113,"column":1,"offset":4486},"end":{"line":113,"column":32,"offset":4517},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Enterprise allows you to scale your video landscape horizontally, it stores its recordings locally for a short amount of time. The idea of Kerberos Enterprise is ","position":{"start":{"line":115,"column":1,"offset":4519},"end":{"line":115,"column":172,"offset":4690},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"not","position":{"start":{"line":115,"column":174,"offset":4692},"end":{"line":115,"column":177,"offset":4695},"indent":[]}}],"position":{"start":{"line":115,"column":172,"offset":4690},"end":{"line":115,"column":179,"offset":4697},"indent":[]}},{"type":"text","value":" to have a visual component, for example to browse through recordings, and search for specific events.","position":{"start":{"line":115,"column":179,"offset":4697},"end":{"line":115,"column":281,"offset":4799},"indent":[]}}],"position":{"start":{"line":115,"column":1,"offset":4519},"end":{"line":115,"column":281,"offset":4799},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To make this functionality possible we have integrated (similar to the open source version), Kerberos Enterprise, to ","position":{"start":{"line":117,"column":1,"offset":4801},"end":{"line":117,"column":118,"offset":4918},"indent":[]}},{"type":"link","title":null,"url":"/cloud","children":[{"type":"text","value":"Kerberos Cloud","position":{"start":{"line":117,"column":119,"offset":4919},"end":{"line":117,"column":133,"offset":4933},"indent":[]}}],"position":{"start":{"line":117,"column":118,"offset":4918},"end":{"line":117,"column":142,"offset":4942},"indent":[]}},{"type":"text","value":". A full featured, and extensive, platform for managing your video surveillance systems.","position":{"start":{"line":117,"column":142,"offset":4942},"end":{"line":117,"column":230,"offset":5030},"indent":[]}}],"position":{"start":{"line":117,"column":1,"offset":4801},"end":{"line":117,"column":230,"offset":5030},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":120,"column":1,"offset":5033},"end":{"line":120,"column":31,"offset":5063},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":120,"column":31,"offset":5063}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport SettingsIcon from '@material-ui/icons/Settings';\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Get Started`}

\n

{`Once you've installed Kerberos Enterprise, you will have the Factory service running inside your cluster, and you will have access to the Factory web application. This web application allows you to administrate your Machinery deployments/pods.`}

\n
\n
\n

\n

{`Login page`}

\n

{`Once you open a browser, and navigate to the Factory web application (see installation for the url), you will land on the login page.`}

\n

\"Factory\"

\n

{`The default username password of the Factory web applications is:`}

\n
    \n
  • {`username: `}{`root`}
  • \n
  • {`password: `}{`kerberos`}
  • \n
\n
\n

{`The username and password can be changed in the MongoDB database.`}

\n
\n

{`License key`}

\n

{`The first time you login you are asked for a license key, this can be obtained by sending a request to cedric@verstraeten.io. An example license key looks like this:`}

\n
\n

{`-----BEGIN LICENSE KEY-----\nL/+DAwEBB2xpY2Vuc2UB/4QAAQIBB1BheWxvYWQBCgABCVNpZ25hdHVyZQEKAAAA\n/9z/hAFUPBAADG1haW4uTGljZW5zZf+BAwEBB0xpY2Vuc2UB/4IAAQIBB0NvbXBh\nbnkBDAABB0V4cFRpbWUBBAAAABb/ghMBCmtlcmJlcm9zaW8B/MC7ZzIAAf+AOaJ+\n8eU3OlZCphr4uJyH/PzfuDkMrqyfIsutc5kSz3rjsRtU4e6vETpHre8CPvFyx5w2\n0O8PKCIR4z1q28qJK2cvHQTK0/zf+KfYLilEcmNczLXgg+bnPvtA/bU/K8ZEwbnw\nRta3+8zId+xtYQApdmHwo/Ih/vCN579iDeunwVQA\n-----END LICENSE KEY-----`}

\n
\n

\"Factory\"

\n

{`Once you received a license key, and entered it into the web application you will be redirected to the login screen. Enter your credentials again, and you will be guided into the dashboard.`}

\n

{`Overview`}

\n

{`On the overview page you will find an intuitive overview of the different pages and functionalities. On the left menu you will see two sections: `}{`Docker`}{` and `}{`Kubernetes`}{`. Kerberos Enterprise can both run in Docker (single-host) and Kubernetes (cluster) mode, however the recommended way is Kubernetes.`}

\n

\"Factory\"

\n

{`Kubernetes`}

\n

{`On the left menu you will find the Kubernetes section. In this section 3 sub menu's are available:`}

\n
    \n
  • {`Nodes`}
  • \n
  • {`Deployments`}
  • \n
  • {`Pods`}
  • \n
\n

{`Nodes`}

\n

{`The nodes section lists all the available nodes inside your Kubernetes cluster.`}

\n

\"Factory\"

\n

{`Deployments`}

\n

{`The deployments section will list all the machinery deployments (agents) that you have deployed inside your cluster. It gives you access to deploy new deploments one by one or in bulk.`}

\n

\"Factory\"

\n

{`Adding a new deployment`}

\n

{`There are two options to add a new deployment:`}

\n
    \n
  • {`single deployment`}
  • \n
\n

{`By specifying a name for your deployment and it's corresponding RTSP url, a new deployment will be created for you, and deployed to one of your installed nodes.`}

\n

\"Factory\"

\n
    \n
  • {`in bulk deployment.`}
  • \n
\n

{`By importing an Excel file, deployments can be created in bulk.`}

\n

\"Factory\"

\n

{`By specifying the name and corresponding RTSP url in multiple rows, you can deploy your deployments in bulk.`}

\n

\"Factory\"

\n

{`Configuring a deployment`}

\n

{`Once you have a running deployment, you should see a green circle next to the deployment, indicating that it is succesfully running. At any time you can configure your deployments by clicking on the `}{` icon. This will open a popup, allowing you to change some settings.`}

\n

\"Factory\"

\n

{`Following settings can be changed:`}

\n
    \n
  • {`One or more regions of interest,`}
  • \n
  • {`Time based conditions,`}
  • \n
  • {`Pre- and postrecording`}
  • \n
\n

{`Pods`}

\n

{`When creating a deployment, Kubernetes will create a Pod. This Pod will be deployed to one of your available nodes.\nOnce a Pod dies, or crashes, the deployment will make sure it is deployed again to a different (or the same) node.`}

\n

\"Factory\"

\n

{`Storage and video management`}

\n

{`Kerberos Enterprise allows you to scale your video landscape horizontally, it stores its recordings locally for a short amount of time. The idea of Kerberos Enterprise is `}{`not`}{` to have a visual component, for example to browse through recordings, and search for specific events.`}

\n

{`To make this functionality possible we have integrated (similar to the open source version), Kerberos Enterprise, to `}{`Kerberos Cloud`}{`. A full featured, and extensive, platform for managing your video surveillance systems.`}

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0d7f3f51699847bb4680d4d6678f8741.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0d7f3f51699847bb4680d4d6678f8741.json new file mode 100644 index 0000000..5f4e38c --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0d7f3f51699847bb4680d4d6678f8741.json @@ -0,0 +1 @@ +{"expireTime":9007200842069003000,"key":"gatsby-plugin-mdx-entire-payload-43c9217a90c8cedbcf42bccecf5af7de-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4679},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":80,"offset":4760},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4760},"end":{"line":107,"column":101,"offset":4781},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4781},"end":{"line":107,"column":162,"offset":4842},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":162,"offset":4842},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4844},"end":{"line":112,"column":4,"offset":4933},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4938},"end":{"line":114,"column":10,"offset":4944},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4935},"end":{"line":114,"column":10,"offset":4944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":339,"offset":5284},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":340,"offset":5285},"end":{"line":116,"column":354,"offset":5299},"indent":[]}}],"position":{"start":{"line":116,"column":339,"offset":5284},"end":{"line":116,"column":390,"offset":5335},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":390,"offset":5335},"end":{"line":116,"column":391,"offset":5336},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":391,"offset":5336},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5342},"end":{"line":118,"column":18,"offset":5355},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5338},"end":{"line":118,"column":18,"offset":5355},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5357},"end":{"line":120,"column":50,"offset":5406},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5412},"end":{"line":122,"column":11,"offset":5418},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5408},"end":{"line":122,"column":11,"offset":5418},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":64,"offset":5483},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5484},"end":{"line":124,"column":86,"offset":5505},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5483},"end":{"line":124,"column":126,"offset":5545},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5545},"end":{"line":124,"column":127,"offset":5546},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":127,"offset":5546},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5552},"end":{"line":126,"column":26,"offset":5573},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5548},"end":{"line":126,"column":26,"offset":5573},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5702},"end":{"line":132,"column":4,"offset":5741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5931},"end":{"line":138,"column":4,"offset":6009},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6165},"end":{"line":145,"column":4,"offset":6312},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6414},"end":{"line":152,"column":4,"offset":6483},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6489},"end":{"line":154,"column":12,"offset":6496},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6485},"end":{"line":154,"column":12,"offset":6496},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":157,"column":25,"offset":6586},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6587},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":158,"column":59,"offset":6645},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":160,"column":4,"offset":6650},"end":{"line":160,"column":10,"offset":6656},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":6647},"end":{"line":160,"column":10,"offset":6656},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.","position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":310,"offset":6967},"indent":[]}}],"position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":310,"offset":6967},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To fill the gap, regarding the latter, we can rely on another solution called ","position":{"start":{"line":164,"column":1,"offset":6969},"end":{"line":164,"column":79,"offset":7047},"indent":[]}},{"type":"link","title":null,"url":"https://balena.io","children":[{"type":"text","value":"Balena.io","position":{"start":{"line":164,"column":80,"offset":7048},"end":{"line":164,"column":89,"offset":7057},"indent":[]}}],"position":{"start":{"line":164,"column":79,"offset":7047},"end":{"line":164,"column":109,"offset":7077},"indent":[]}},{"type":"text","value":". Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can ship our Kerberos Docker image to the Balena OS.","position":{"start":{"line":164,"column":109,"offset":7077},"end":{"line":164,"column":367,"offset":7335},"indent":[]}}],"position":{"start":{"line":164,"column":1,"offset":6969},"end":{"line":164,"column":367,"offset":7335},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On top of supporting a lot of boars,","position":{"start":{"line":166,"column":1,"offset":7337},"end":{"line":166,"column":37,"offset":7373},"indent":[]}}],"position":{"start":{"line":166,"column":1,"offset":7337},"end":{"line":166,"column":37,"offset":7373},"indent":[]}},{"type":"thematicBreak","position":{"start":{"line":168,"column":1,"offset":7375},"end":{"line":168,"column":4,"offset":7378},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":170,"column":3,"offset":7382},"end":{"line":170,"column":11,"offset":7390},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7380},"end":{"line":170,"column":11,"offset":7390},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":172,"column":1,"offset":7392},"end":{"line":172,"column":133,"offset":7524},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7392},"end":{"line":172,"column":133,"offset":7524},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":174,"column":4,"offset":7529},"end":{"line":174,"column":12,"offset":7537},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7526},"end":{"line":174,"column":12,"offset":7537},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":176,"column":1,"offset":7539},"end":{"line":176,"column":193,"offset":7731},"indent":[]}}],"position":{"start":{"line":176,"column":1,"offset":7539},"end":{"line":176,"column":193,"offset":7731},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":178,"column":4,"offset":7736},"end":{"line":178,"column":62,"offset":7794},"indent":[]}}],"position":{"start":{"line":178,"column":4,"offset":7736},"end":{"line":178,"column":62,"offset":7794},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7733},"end":{"line":178,"column":62,"offset":7794},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":179,"column":4,"offset":7798},"end":{"line":179,"column":69,"offset":7863},"indent":[]}}],"position":{"start":{"line":179,"column":4,"offset":7798},"end":{"line":179,"column":69,"offset":7863},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7795},"end":{"line":179,"column":69,"offset":7863},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7733},"end":{"line":179,"column":69,"offset":7863},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":181,"column":1,"offset":7865},"end":{"line":181,"column":99,"offset":7963},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":7865},"end":{"line":181,"column":99,"offset":7963},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":183,"column":5,"offset":7969},"end":{"line":183,"column":14,"offset":7978},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":7965},"end":{"line":183,"column":14,"offset":7978},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":185,"column":1,"offset":7980},"end":{"line":185,"column":71,"offset":8050},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":7980},"end":{"line":185,"column":71,"offset":8050},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":187,"column":3,"offset":8054},"end":{"line":187,"column":47,"offset":8098},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":187,"column":47,"offset":8098},"end":{"line":187,"column":79,"offset":8130},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":187,"column":79,"offset":8130},"end":{"line":187,"column":198,"offset":8249},"indent":[]}}],"position":{"start":{"line":187,"column":3,"offset":8054},"end":{"line":187,"column":198,"offset":8249},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":8052},"end":{"line":187,"column":198,"offset":8249},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":189,"column":1,"offset":8251},"end":{"line":191,"column":4,"offset":8314},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":193,"column":5,"offset":8320},"end":{"line":193,"column":14,"offset":8329},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8316},"end":{"line":193,"column":14,"offset":8329},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":195,"column":1,"offset":8331},"end":{"line":195,"column":56,"offset":8386},"indent":[]}}],"position":{"start":{"line":195,"column":1,"offset":8331},"end":{"line":195,"column":56,"offset":8386},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":196,"column":3,"offset":8389},"end":{"line":196,"column":52,"offset":8438},"indent":[]}}],"position":{"start":{"line":196,"column":3,"offset":8389},"end":{"line":196,"column":52,"offset":8438},"indent":[]}}],"position":{"start":{"line":196,"column":3,"offset":8389},"end":{"line":196,"column":52,"offset":8438},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8387},"end":{"line":196,"column":52,"offset":8438},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":198,"column":1,"offset":8440},"end":{"line":198,"column":3,"offset":8442},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":198,"column":3,"offset":8442},"end":{"line":198,"column":9,"offset":8448},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":198,"column":9,"offset":8448},"end":{"line":198,"column":223,"offset":8662},"indent":[]}}],"position":{"start":{"line":198,"column":1,"offset":8440},"end":{"line":198,"column":223,"offset":8662},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":200,"column":3,"offset":8666},"end":{"line":200,"column":159,"offset":8822},"indent":[]}}],"position":{"start":{"line":200,"column":3,"offset":8666},"end":{"line":200,"column":159,"offset":8822},"indent":[]}}],"position":{"start":{"line":200,"column":1,"offset":8664},"end":{"line":200,"column":159,"offset":8822},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":202,"column":1,"offset":8824},"end":{"line":205,"column":4,"offset":9001},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":207,"column":1,"offset":9003},"end":{"line":207,"column":160,"offset":9162},"indent":[]}}],"position":{"start":{"line":207,"column":1,"offset":9003},"end":{"line":207,"column":160,"offset":9162},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":209,"column":3,"offset":9166},"end":{"line":209,"column":31,"offset":9194},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":209,"column":31,"offset":9194},"end":{"line":209,"column":101,"offset":9264},"indent":[]}}],"position":{"start":{"line":209,"column":3,"offset":9166},"end":{"line":209,"column":101,"offset":9264},"indent":[]}}],"position":{"start":{"line":209,"column":1,"offset":9164},"end":{"line":209,"column":101,"offset":9264},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":211,"column":1,"offset":9266},"end":{"line":214,"column":4,"offset":9438},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":216,"column":1,"offset":9440},"end":{"line":216,"column":73,"offset":9512},"indent":[]}}],"position":{"start":{"line":216,"column":1,"offset":9440},"end":{"line":216,"column":73,"offset":9512},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":219,"column":3,"offset":9517},"end":{"line":219,"column":31,"offset":9545},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":219,"column":31,"offset":9545},"end":{"line":219,"column":101,"offset":9615},"indent":[]}}],"position":{"start":{"line":219,"column":3,"offset":9517},"end":{"line":219,"column":101,"offset":9615},"indent":[]}}],"position":{"start":{"line":219,"column":1,"offset":9515},"end":{"line":219,"column":101,"offset":9615},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":221,"column":1,"offset":9617},"end":{"line":224,"column":4,"offset":9789},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":226,"column":1,"offset":9791},"end":{"line":226,"column":62,"offset":9852},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":226,"column":63,"offset":9853},"end":{"line":226,"column":75,"offset":9865},"indent":[]}}],"position":{"start":{"line":226,"column":62,"offset":9852},"end":{"line":226,"column":143,"offset":9933},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":226,"column":143,"offset":9933},"end":{"line":226,"column":150,"offset":9940},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":226,"column":150,"offset":9940},"end":{"line":226,"column":169,"offset":9959},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":226,"column":169,"offset":9959},"end":{"line":226,"column":170,"offset":9960},"indent":[]}}],"position":{"start":{"line":226,"column":1,"offset":9791},"end":{"line":226,"column":170,"offset":9960},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":228,"column":1,"offset":9962},"end":{"line":230,"column":4,"offset":9989},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":232,"column":1,"offset":9991},"end":{"line":232,"column":58,"offset":10048},"indent":[]}}],"position":{"start":{"line":232,"column":1,"offset":9991},"end":{"line":232,"column":58,"offset":10048},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":234,"column":1,"offset":10050},"end":{"line":237,"column":4,"offset":10120},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":239,"column":5,"offset":10126},"end":{"line":239,"column":8,"offset":10129},"indent":[]}}],"position":{"start":{"line":239,"column":1,"offset":10122},"end":{"line":239,"column":8,"offset":10129},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":241,"column":1,"offset":10131},"end":{"line":241,"column":280,"offset":10410},"indent":[]}}],"position":{"start":{"line":241,"column":1,"offset":10131},"end":{"line":241,"column":280,"offset":10410},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":243,"column":1,"offset":10412},"end":{"line":243,"column":37,"offset":10448},"indent":[]}}],"position":{"start":{"line":243,"column":1,"offset":10412},"end":{"line":243,"column":37,"offset":10448},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":245,"column":1,"offset":10450},"end":{"line":247,"column":4,"offset":10623},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":249,"column":1,"offset":10625},"end":{"line":249,"column":25,"offset":10649},"indent":[]}}],"position":{"start":{"line":249,"column":1,"offset":10625},"end":{"line":249,"column":25,"offset":10649},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":251,"column":1,"offset":10651},"end":{"line":254,"column":4,"offset":10755},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":256,"column":1,"offset":10757},"end":{"line":256,"column":118,"offset":10874},"indent":[]}}],"position":{"start":{"line":256,"column":1,"offset":10757},"end":{"line":256,"column":118,"offset":10874},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":258,"column":1,"offset":10876},"end":{"line":278,"column":4,"offset":11383},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":280,"column":1,"offset":11385},"end":{"line":280,"column":14,"offset":11398},"indent":[]}}],"position":{"start":{"line":280,"column":1,"offset":11385},"end":{"line":280,"column":14,"offset":11398},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":282,"column":1,"offset":11400},"end":{"line":284,"column":4,"offset":11436},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":286,"column":1,"offset":11438},"end":{"line":286,"column":91,"offset":11528},"indent":[]}}],"position":{"start":{"line":286,"column":1,"offset":11438},"end":{"line":286,"column":91,"offset":11528},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":288,"column":1,"offset":11530},"end":{"line":296,"column":4,"offset":11903},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":298,"column":1,"offset":11905},"end":{"line":298,"column":145,"offset":12049},"indent":[]}}],"position":{"start":{"line":298,"column":1,"offset":11905},"end":{"line":298,"column":145,"offset":12049},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":300,"column":5,"offset":12055},"end":{"line":300,"column":17,"offset":12067},"indent":[]}}],"position":{"start":{"line":300,"column":1,"offset":12051},"end":{"line":300,"column":17,"offset":12067},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":302,"column":1,"offset":12069},"end":{"line":302,"column":300,"offset":12368},"indent":[]}}],"position":{"start":{"line":302,"column":1,"offset":12069},"end":{"line":302,"column":300,"offset":12368},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":304,"column":1,"offset":12370},"end":{"line":304,"column":178,"offset":12547},"indent":[]}}],"position":{"start":{"line":304,"column":1,"offset":12370},"end":{"line":304,"column":178,"offset":12547},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":306,"column":1,"offset":12549},"end":{"line":306,"column":48,"offset":12596},"indent":[]}}],"position":{"start":{"line":306,"column":1,"offset":12549},"end":{"line":306,"column":48,"offset":12596},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":308,"column":1,"offset":12598},"end":{"line":310,"column":4,"offset":12638},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":312,"column":1,"offset":12640},"end":{"line":312,"column":104,"offset":12743},"indent":[]}}],"position":{"start":{"line":312,"column":1,"offset":12640},"end":{"line":312,"column":104,"offset":12743},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":314,"column":1,"offset":12745},"end":{"line":322,"column":4,"offset":13015},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":324,"column":1,"offset":13017},"end":{"line":324,"column":28,"offset":13044},"indent":[]}}],"position":{"start":{"line":324,"column":1,"offset":13017},"end":{"line":324,"column":28,"offset":13044},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":326,"column":1,"offset":13046},"end":{"line":328,"column":4,"offset":13090},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":330,"column":1,"offset":13092},"end":{"line":330,"column":48,"offset":13139},"indent":[]}}],"position":{"start":{"line":330,"column":1,"offset":13092},"end":{"line":330,"column":48,"offset":13139},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":332,"column":1,"offset":13141},"end":{"line":334,"column":4,"offset":13163},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":336,"column":1,"offset":13165},"end":{"line":336,"column":72,"offset":13236},"indent":[]}}],"position":{"start":{"line":336,"column":1,"offset":13165},"end":{"line":336,"column":72,"offset":13236},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":338,"column":1,"offset":13238},"end":{"line":340,"column":4,"offset":13295},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":342,"column":4,"offset":13300},"end":{"line":342,"column":11,"offset":13307},"indent":[]}}],"position":{"start":{"line":342,"column":1,"offset":13297},"end":{"line":342,"column":11,"offset":13307},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":344,"column":1,"offset":13309},"end":{"line":344,"column":283,"offset":13591},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13309},"end":{"line":344,"column":283,"offset":13591},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":346,"column":3,"offset":13595},"end":{"line":346,"column":54,"offset":13646},"indent":[]}}],"position":{"start":{"line":346,"column":3,"offset":13595},"end":{"line":346,"column":54,"offset":13646},"indent":[]}}],"position":{"start":{"line":346,"column":1,"offset":13593},"end":{"line":346,"column":54,"offset":13646},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":348,"column":5,"offset":13652},"end":{"line":348,"column":14,"offset":13661},"indent":[]}}],"position":{"start":{"line":348,"column":1,"offset":13648},"end":{"line":348,"column":14,"offset":13661},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":350,"column":1,"offset":13663},"end":{"line":350,"column":68,"offset":13730},"indent":[]}}],"position":{"start":{"line":350,"column":1,"offset":13663},"end":{"line":350,"column":68,"offset":13730},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":352,"column":1,"offset":13732},"end":{"line":355,"column":4,"offset":13883},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":357,"column":1,"offset":13885},"end":{"line":357,"column":46,"offset":13930},"indent":[]}}],"position":{"start":{"line":357,"column":1,"offset":13885},"end":{"line":357,"column":46,"offset":13930},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":359,"column":3,"offset":13934},"end":{"line":359,"column":103,"offset":14034},"indent":[]}}],"position":{"start":{"line":359,"column":3,"offset":13934},"end":{"line":359,"column":103,"offset":14034},"indent":[]}}],"position":{"start":{"line":359,"column":1,"offset":13932},"end":{"line":359,"column":103,"offset":14034},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":361,"column":1,"offset":14036},"end":{"line":366,"column":4,"offset":14246},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":368,"column":1,"offset":14248},"end":{"line":368,"column":151,"offset":14398},"indent":[]}}],"position":{"start":{"line":368,"column":1,"offset":14248},"end":{"line":368,"column":151,"offset":14398},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":370,"column":3,"offset":14402},"end":{"line":370,"column":22,"offset":14421},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":370,"column":22,"offset":14421},"end":{"line":370,"column":26,"offset":14425},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":370,"column":26,"offset":14425},"end":{"line":370,"column":40,"offset":14439},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":370,"column":40,"offset":14439},"end":{"line":370,"column":50,"offset":14449},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":370,"column":50,"offset":14449},"end":{"line":370,"column":98,"offset":14497},"indent":[]}}],"position":{"start":{"line":370,"column":3,"offset":14402},"end":{"line":370,"column":98,"offset":14497},"indent":[]}}],"position":{"start":{"line":370,"column":1,"offset":14400},"end":{"line":370,"column":98,"offset":14497},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":372,"column":1,"offset":14499},"end":{"line":376,"column":4,"offset":14661},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":378,"column":1,"offset":14663},"end":{"line":378,"column":72,"offset":14734},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":378,"column":72,"offset":14734},"end":{"line":378,"column":84,"offset":14746},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":378,"column":84,"offset":14746},"end":{"line":378,"column":102,"offset":14764},"indent":[]}}],"position":{"start":{"line":378,"column":1,"offset":14663},"end":{"line":378,"column":102,"offset":14764},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":380,"column":1,"offset":14766},"end":{"line":383,"column":4,"offset":14840},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":385,"column":5,"offset":14846},"end":{"line":385,"column":8,"offset":14849},"indent":[]}}],"position":{"start":{"line":385,"column":1,"offset":14842},"end":{"line":385,"column":8,"offset":14849},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":387,"column":1,"offset":14851},"end":{"line":387,"column":176,"offset":15026},"indent":[]}}],"position":{"start":{"line":387,"column":1,"offset":14851},"end":{"line":387,"column":176,"offset":15026},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":389,"column":1,"offset":15028},"end":{"line":396,"column":4,"offset":15325},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":398,"column":1,"offset":15327},"end":{"line":398,"column":60,"offset":15386},"indent":[]}}],"position":{"start":{"line":398,"column":1,"offset":15327},"end":{"line":398,"column":60,"offset":15386},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":400,"column":1,"offset":15388},"end":{"line":404,"column":4,"offset":15514},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":406,"column":1,"offset":15516},"end":{"line":406,"column":63,"offset":15578},"indent":[]}}],"position":{"start":{"line":406,"column":1,"offset":15516},"end":{"line":406,"column":63,"offset":15578},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":408,"column":1,"offset":15580},"end":{"line":428,"column":4,"offset":16087},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":430,"column":1,"offset":16089},"end":{"line":430,"column":99,"offset":16187},"indent":[]}}],"position":{"start":{"line":430,"column":1,"offset":16089},"end":{"line":430,"column":99,"offset":16187},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":432,"column":1,"offset":16189},"end":{"line":435,"column":4,"offset":16291},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":437,"column":1,"offset":16293},"end":{"line":437,"column":37,"offset":16329},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":437,"column":37,"offset":16329},"end":{"line":437,"column":47,"offset":16339},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":437,"column":47,"offset":16339},"end":{"line":437,"column":89,"offset":16381},"indent":[]}}],"position":{"start":{"line":437,"column":1,"offset":16293},"end":{"line":437,"column":89,"offset":16381},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":439,"column":1,"offset":16383},"end":{"line":443,"column":4,"offset":16508},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":445,"column":1,"offset":16510},"end":{"line":445,"column":78,"offset":16587},"indent":[]}}],"position":{"start":{"line":445,"column":1,"offset":16510},"end":{"line":445,"column":78,"offset":16587},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":447,"column":1,"offset":16589},"end":{"line":451,"column":4,"offset":16693},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":453,"column":1,"offset":16695},"end":{"line":453,"column":75,"offset":16769},"indent":[]}}],"position":{"start":{"line":453,"column":1,"offset":16695},"end":{"line":453,"column":75,"offset":16769},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":455,"column":1,"offset":16771},"end":{"line":459,"column":4,"offset":16844},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":461,"column":1,"offset":16846},"end":{"line":461,"column":145,"offset":16990},"indent":[]}}],"position":{"start":{"line":461,"column":1,"offset":16846},"end":{"line":461,"column":145,"offset":16990},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":463,"column":5,"offset":16996},"end":{"line":463,"column":17,"offset":17008},"indent":[]}}],"position":{"start":{"line":463,"column":1,"offset":16992},"end":{"line":463,"column":17,"offset":17008},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":465,"column":1,"offset":17010},"end":{"line":465,"column":300,"offset":17309},"indent":[]}}],"position":{"start":{"line":465,"column":1,"offset":17010},"end":{"line":465,"column":300,"offset":17309},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":467,"column":1,"offset":17311},"end":{"line":467,"column":178,"offset":17488},"indent":[]}}],"position":{"start":{"line":467,"column":1,"offset":17311},"end":{"line":467,"column":178,"offset":17488},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":469,"column":1,"offset":17490},"end":{"line":469,"column":48,"offset":17537},"indent":[]}}],"position":{"start":{"line":469,"column":1,"offset":17490},"end":{"line":469,"column":48,"offset":17537},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":471,"column":1,"offset":17539},"end":{"line":473,"column":4,"offset":17583},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":475,"column":1,"offset":17585},"end":{"line":475,"column":104,"offset":17688},"indent":[]}}],"position":{"start":{"line":475,"column":1,"offset":17585},"end":{"line":475,"column":104,"offset":17688},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":477,"column":1,"offset":17690},"end":{"line":485,"column":4,"offset":17960},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":487,"column":1,"offset":17962},"end":{"line":487,"column":28,"offset":17989},"indent":[]}}],"position":{"start":{"line":487,"column":1,"offset":17962},"end":{"line":487,"column":28,"offset":17989},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":489,"column":1,"offset":17991},"end":{"line":491,"column":4,"offset":18039},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":493,"column":1,"offset":18041},"end":{"line":493,"column":48,"offset":18088},"indent":[]}}],"position":{"start":{"line":493,"column":1,"offset":18041},"end":{"line":493,"column":48,"offset":18088},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":495,"column":1,"offset":18090},"end":{"line":497,"column":4,"offset":18112},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":499,"column":1,"offset":18114},"end":{"line":499,"column":72,"offset":18185},"indent":[]}}],"position":{"start":{"line":499,"column":1,"offset":18114},"end":{"line":499,"column":72,"offset":18185},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":501,"column":1,"offset":18187},"end":{"line":503,"column":4,"offset":18248},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":506,"column":1,"offset":18251},"end":{"line":506,"column":31,"offset":18281},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":506,"column":31,"offset":18281}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.`}

\n

{`To fill the gap, regarding the latter, we can rely on another solution called `}{`Balena.io`}{`. Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can ship our Kerberos Docker image to the Balena OS.`}

\n

{`On top of supporting a lot of boars,`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0e0eb9e157331fb6122e7ab392cb3c8b.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0e0eb9e157331fb6122e7ab392cb3c8b.json index 3fc942e..a710a0a 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0e0eb9e157331fb6122e7ab392cb3c8b.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0e0eb9e157331fb6122e7ab392cb3c8b.json @@ -1 +1 @@ -{"expireTime":9007200841014157000,"key":"gatsby-plugin-mdx-entire-payload-27ac8172f297bb1f86295f9b26da49db-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Get Started","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":14,"offset":172},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":14,"offset":172},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've installed Kerberos Open Source, you will have access to the web application. This web application allows you to administrate your the machinery.","position":{"start":{"line":10,"column":1,"offset":174},"end":{"line":10,"column":157,"offset":330},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":174},"end":{"line":10,"column":157,"offset":330},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Welcome page","position":{"start":{"line":12,"column":4,"offset":335},"end":{"line":12,"column":16,"offset":347},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":332},"end":{"line":12,"column":16,"offset":347},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The first time you open a browser, and navigate to the web application (ip address of your device), you will land on the welcome page. This page will guide you through some basic steps and set simple configurations such as username and password.","position":{"start":{"line":14,"column":1,"offset":349},"end":{"line":14,"column":246,"offset":594},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":349},"end":{"line":14,"column":246,"offset":594},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-welcome.png","alt":"OpenSource","position":{"start":{"line":16,"column":1,"offset":596},"end":{"line":16,"column":78,"offset":673},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":596},"end":{"line":16,"column":78,"offset":673},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Login page","position":{"start":{"line":18,"column":4,"offset":678},"end":{"line":18,"column":14,"offset":688},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":675},"end":{"line":18,"column":14,"offset":688},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When you've finished the welcome page, you will be redirected to the login page from now one. Use the credentials you have defined during the configuration of the welcome page. By default the username is ","position":{"start":{"line":20,"column":1,"offset":690},"end":{"line":20,"column":205,"offset":894},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"root","position":{"start":{"line":20,"column":207,"offset":896},"end":{"line":20,"column":211,"offset":900},"indent":[]}}],"position":{"start":{"line":20,"column":205,"offset":894},"end":{"line":20,"column":213,"offset":902},"indent":[]}},{"type":"text","value":", and the password is ","position":{"start":{"line":20,"column":213,"offset":902},"end":{"line":20,"column":235,"offset":924},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"root","position":{"start":{"line":20,"column":237,"offset":926},"end":{"line":20,"column":241,"offset":930},"indent":[]}}],"position":{"start":{"line":20,"column":235,"offset":924},"end":{"line":20,"column":243,"offset":932},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":20,"column":243,"offset":932},"end":{"line":20,"column":244,"offset":933},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":690},"end":{"line":20,"column":244,"offset":933},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-login.png","alt":"OpenSource","position":{"start":{"line":22,"column":1,"offset":935},"end":{"line":22,"column":76,"offset":1010},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":935},"end":{"line":22,"column":76,"offset":1010},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Dashboard","position":{"start":{"line":24,"column":4,"offset":1015},"end":{"line":24,"column":13,"offset":1024},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1012},"end":{"line":24,"column":13,"offset":1024},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"After you have signed in successfully, you will land on the dashboard page. This page will give you an overview of some simple statistics. Such as the the activity per day, per hour, etc.","position":{"start":{"line":26,"column":1,"offset":1026},"end":{"line":26,"column":188,"offset":1213},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1026},"end":{"line":26,"column":188,"offset":1213},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-dashboard.png","alt":"OpenSource","position":{"start":{"line":28,"column":1,"offset":1215},"end":{"line":28,"column":80,"offset":1294},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":1215},"end":{"line":28,"column":80,"offset":1294},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Media","position":{"start":{"line":30,"column":4,"offset":1299},"end":{"line":30,"column":9,"offset":1304},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":1296},"end":{"line":30,"column":9,"offset":1304},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By selecting a specific day from the left navigation, or choosing the date picker on the top, you will be shown all the relevant media for that specific day. Both videos and images are listed and grouped (if they are within a specific time span). By scrolling down, more media items will be shown.","position":{"start":{"line":32,"column":1,"offset":1306},"end":{"line":32,"column":298,"offset":1603},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":1306},"end":{"line":32,"column":298,"offset":1603},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can use the timeslider at the top of the page for browsing through the day. The white (no activity) to gray (low activity) to red (high activity), will give you an indications of the amount of recordings for that specific hour.","position":{"start":{"line":34,"column":1,"offset":1605},"end":{"line":34,"column":232,"offset":1836},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":1605},"end":{"line":34,"column":232,"offset":1836},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-media.png","alt":"OpenSource","position":{"start":{"line":36,"column":1,"offset":1838},"end":{"line":36,"column":76,"offset":1913},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":1838},"end":{"line":36,"column":76,"offset":1913},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-media-detail.png","alt":"OpenSource","position":{"start":{"line":38,"column":1,"offset":1915},"end":{"line":38,"column":83,"offset":1997},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":1915},"end":{"line":38,"column":83,"offset":1997},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Settings","position":{"start":{"line":41,"column":4,"offset":2003},"end":{"line":41,"column":12,"offset":2011},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":2000},"end":{"line":41,"column":12,"offset":2011},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before being able to record anything, you will need to specify your capture device. A capture device is what we call: a camera. This camera can be a USB, RPi or IP camera. By default the RPi camera is selected, so if you are planning to use a IP camera make sure to change it on the settings page.","position":{"start":{"line":43,"column":1,"offset":2013},"end":{"line":43,"column":298,"offset":2310},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2013},"end":{"line":43,"column":298,"offset":2310},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-settings.png","alt":"OpenSource","position":{"start":{"line":45,"column":1,"offset":2312},"end":{"line":45,"column":79,"offset":2390},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2312},"end":{"line":45,"column":79,"offset":2390},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Region of interest","position":{"start":{"line":47,"column":5,"offset":2396},"end":{"line":47,"column":23,"offset":2414},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2392},"end":{"line":47,"column":23,"offset":2414},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Besides selecting the capture device, you will have different options to make the detection more intelligent, such as defining a regions of interest, or an activation timeline (when Kerberos Open Source should be active).","position":{"start":{"line":49,"column":1,"offset":2416},"end":{"line":49,"column":222,"offset":2637},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2416},"end":{"line":49,"column":222,"offset":2637},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-motion.png","alt":"OpenSource","position":{"start":{"line":51,"column":1,"offset":2639},"end":{"line":51,"column":77,"offset":2715},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2639},"end":{"line":51,"column":77,"offset":2715},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Storage","position":{"start":{"line":53,"column":5,"offset":2721},"end":{"line":53,"column":12,"offset":2728},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2717},"end":{"line":53,"column":12,"offset":2728},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Storing your recordings on your device is fine, on the other hand you might want to make it available remotely. By giving your ","position":{"start":{"line":55,"column":1,"offset":2730},"end":{"line":55,"column":128,"offset":2857},"indent":[]}},{"type":"link","title":null,"url":"/cloud","children":[{"type":"text","value":"Kerberos Cloud","position":{"start":{"line":55,"column":129,"offset":2858},"end":{"line":55,"column":143,"offset":2872},"indent":[]}}],"position":{"start":{"line":55,"column":128,"offset":2857},"end":{"line":55,"column":152,"offset":2881},"indent":[]}},{"type":"text","value":" credentials in the storage section, your recordings will be synced to our cloud solution.","position":{"start":{"line":55,"column":152,"offset":2881},"end":{"line":55,"column":242,"offset":2971},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2730},"end":{"line":55,"column":242,"offset":2971},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-cloud.png","alt":"OpenSource","position":{"start":{"line":57,"column":1,"offset":2973},"end":{"line":57,"column":76,"offset":3048},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2973},"end":{"line":57,"column":76,"offset":3048},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"System","position":{"start":{"line":59,"column":4,"offset":3053},"end":{"line":59,"column":10,"offset":3059},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":3050},"end":{"line":59,"column":10,"offset":3059},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This page will gave you overall information of Kerberos Open Source. It will give you information (logging) about the system, shows you some system information, the number of recordings on the system and more.","position":{"start":{"line":61,"column":1,"offset":3061},"end":{"line":61,"column":210,"offset":3270},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":3061},"end":{"line":61,"column":210,"offset":3270},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-system.png","alt":"OpenSource","position":{"start":{"line":63,"column":1,"offset":3272},"end":{"line":63,"column":77,"offset":3348},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":3272},"end":{"line":63,"column":77,"offset":3348},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":66,"column":1,"offset":3351},"end":{"line":66,"column":31,"offset":3381},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":66,"column":31,"offset":3381}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Get Started`}

\n

{`Once you've installed Kerberos Open Source, you will have access to the web application. This web application allows you to administrate your the machinery.`}

\n

{`Welcome page`}

\n

{`The first time you open a browser, and navigate to the web application (ip address of your device), you will land on the welcome page. This page will guide you through some basic steps and set simple configurations such as username and password.`}

\n

\"OpenSource\"

\n

{`Login page`}

\n

{`When you've finished the welcome page, you will be redirected to the login page from now one. Use the credentials you have defined during the configuration of the welcome page. By default the username is `}{`root`}{`, and the password is `}{`root`}{`.`}

\n

\"OpenSource\"

\n

{`Dashboard`}

\n

{`After you have signed in successfully, you will land on the dashboard page. This page will give you an overview of some simple statistics. Such as the the activity per day, per hour, etc.`}

\n

\"OpenSource\"

\n

{`Media`}

\n

{`By selecting a specific day from the left navigation, or choosing the date picker on the top, you will be shown all the relevant media for that specific day. Both videos and images are listed and grouped (if they are within a specific time span). By scrolling down, more media items will be shown.`}

\n

{`You can use the timeslider at the top of the page for browsing through the day. The white (no activity) to gray (low activity) to red (high activity), will give you an indications of the amount of recordings for that specific hour.`}

\n

\"OpenSource\"

\n

\"OpenSource\"

\n

{`Settings`}

\n

{`Before being able to record anything, you will need to specify your capture device. A capture device is what we call: a camera. This camera can be a USB, RPi or IP camera. By default the RPi camera is selected, so if you are planning to use a IP camera make sure to change it on the settings page.`}

\n

\"OpenSource\"

\n

{`Region of interest`}

\n

{`Besides selecting the capture device, you will have different options to make the detection more intelligent, such as defining a regions of interest, or an activation timeline (when Kerberos Open Source should be active).`}

\n

\"OpenSource\"

\n

{`Storage`}

\n

{`Storing your recordings on your device is fine, on the other hand you might want to make it available remotely. By giving your `}{`Kerberos Cloud`}{` credentials in the storage section, your recordings will be synced to our cloud solution.`}

\n

\"OpenSource\"

\n

{`System`}

\n

{`This page will gave you overall information of Kerberos Open Source. It will give you information (logging) about the system, shows you some system information, the number of recordings on the system and more.`}

\n

\"OpenSource\"

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974263000,"key":"gatsby-plugin-mdx-entire-payload-27ac8172f297bb1f86295f9b26da49db-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Get Started","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":14,"offset":172},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":14,"offset":172},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've installed Kerberos Open Source, you will have access to the web application. This web application allows you to administrate your the machinery.","position":{"start":{"line":10,"column":1,"offset":174},"end":{"line":10,"column":157,"offset":330},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":174},"end":{"line":10,"column":157,"offset":330},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Welcome page","position":{"start":{"line":12,"column":4,"offset":335},"end":{"line":12,"column":16,"offset":347},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":332},"end":{"line":12,"column":16,"offset":347},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The first time you open a browser, and navigate to the web application (ip address of your device), you will land on the welcome page. This page will guide you through some basic steps and set simple configurations such as username and password.","position":{"start":{"line":14,"column":1,"offset":349},"end":{"line":14,"column":246,"offset":594},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":349},"end":{"line":14,"column":246,"offset":594},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-welcome.png","alt":"OpenSource","position":{"start":{"line":16,"column":1,"offset":596},"end":{"line":16,"column":78,"offset":673},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":596},"end":{"line":16,"column":78,"offset":673},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Login page","position":{"start":{"line":18,"column":4,"offset":678},"end":{"line":18,"column":14,"offset":688},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":675},"end":{"line":18,"column":14,"offset":688},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When you've finished the welcome page, you will be redirected to the login page from now one. Use the credentials you have defined during the configuration of the welcome page. By default the username is ","position":{"start":{"line":20,"column":1,"offset":690},"end":{"line":20,"column":205,"offset":894},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"root","position":{"start":{"line":20,"column":207,"offset":896},"end":{"line":20,"column":211,"offset":900},"indent":[]}}],"position":{"start":{"line":20,"column":205,"offset":894},"end":{"line":20,"column":213,"offset":902},"indent":[]}},{"type":"text","value":", and the password is ","position":{"start":{"line":20,"column":213,"offset":902},"end":{"line":20,"column":235,"offset":924},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"root","position":{"start":{"line":20,"column":237,"offset":926},"end":{"line":20,"column":241,"offset":930},"indent":[]}}],"position":{"start":{"line":20,"column":235,"offset":924},"end":{"line":20,"column":243,"offset":932},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":20,"column":243,"offset":932},"end":{"line":20,"column":244,"offset":933},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":690},"end":{"line":20,"column":244,"offset":933},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-login.png","alt":"OpenSource","position":{"start":{"line":22,"column":1,"offset":935},"end":{"line":22,"column":76,"offset":1010},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":935},"end":{"line":22,"column":76,"offset":1010},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Dashboard","position":{"start":{"line":24,"column":4,"offset":1015},"end":{"line":24,"column":13,"offset":1024},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1012},"end":{"line":24,"column":13,"offset":1024},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"After you have signed in successfully, you will land on the dashboard page. This page will give you an overview of some simple statistics. Such as the the activity per day, per hour, etc.","position":{"start":{"line":26,"column":1,"offset":1026},"end":{"line":26,"column":188,"offset":1213},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1026},"end":{"line":26,"column":188,"offset":1213},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-dashboard.png","alt":"OpenSource","position":{"start":{"line":28,"column":1,"offset":1215},"end":{"line":28,"column":80,"offset":1294},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":1215},"end":{"line":28,"column":80,"offset":1294},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Media","position":{"start":{"line":30,"column":4,"offset":1299},"end":{"line":30,"column":9,"offset":1304},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":1296},"end":{"line":30,"column":9,"offset":1304},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By selecting a specific day from the left navigation, or choosing the date picker on the top, you will be shown all the relevant media for that specific day. Both videos and images are listed and grouped (if they are within a specific time span). By scrolling down, more media items will be shown.","position":{"start":{"line":32,"column":1,"offset":1306},"end":{"line":32,"column":298,"offset":1603},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":1306},"end":{"line":32,"column":298,"offset":1603},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can use the timeslider at the top of the page for browsing through the day. The white (no activity) to gray (low activity) to red (high activity), will give you an indications of the amount of recordings for that specific hour.","position":{"start":{"line":34,"column":1,"offset":1605},"end":{"line":34,"column":232,"offset":1836},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":1605},"end":{"line":34,"column":232,"offset":1836},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-media.png","alt":"OpenSource","position":{"start":{"line":36,"column":1,"offset":1838},"end":{"line":36,"column":76,"offset":1913},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":1838},"end":{"line":36,"column":76,"offset":1913},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-media-detail.png","alt":"OpenSource","position":{"start":{"line":38,"column":1,"offset":1915},"end":{"line":38,"column":83,"offset":1997},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":1915},"end":{"line":38,"column":83,"offset":1997},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Settings","position":{"start":{"line":41,"column":4,"offset":2003},"end":{"line":41,"column":12,"offset":2011},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":2000},"end":{"line":41,"column":12,"offset":2011},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before being able to record anything, you will need to specify your capture device. A capture device is what we call: a camera. This camera can be a USB, RPi or IP camera. By default the RPi camera is selected, so if you are planning to use a IP camera make sure to change it on the settings page.","position":{"start":{"line":43,"column":1,"offset":2013},"end":{"line":43,"column":298,"offset":2310},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2013},"end":{"line":43,"column":298,"offset":2310},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-settings.png","alt":"OpenSource","position":{"start":{"line":45,"column":1,"offset":2312},"end":{"line":45,"column":79,"offset":2390},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2312},"end":{"line":45,"column":79,"offset":2390},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Region of interest","position":{"start":{"line":47,"column":5,"offset":2396},"end":{"line":47,"column":23,"offset":2414},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2392},"end":{"line":47,"column":23,"offset":2414},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Besides selecting the capture device, you will have different options to make the detection more intelligent, such as defining a regions of interest, or an activation timeline (when Kerberos Open Source should be active).","position":{"start":{"line":49,"column":1,"offset":2416},"end":{"line":49,"column":222,"offset":2637},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2416},"end":{"line":49,"column":222,"offset":2637},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-motion.png","alt":"OpenSource","position":{"start":{"line":51,"column":1,"offset":2639},"end":{"line":51,"column":77,"offset":2715},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2639},"end":{"line":51,"column":77,"offset":2715},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Storage","position":{"start":{"line":53,"column":5,"offset":2721},"end":{"line":53,"column":12,"offset":2728},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2717},"end":{"line":53,"column":12,"offset":2728},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Storing your recordings on your device is fine, on the other hand you might want to make it available remotely. By giving your ","position":{"start":{"line":55,"column":1,"offset":2730},"end":{"line":55,"column":128,"offset":2857},"indent":[]}},{"type":"link","title":null,"url":"/cloud","children":[{"type":"text","value":"Kerberos Cloud","position":{"start":{"line":55,"column":129,"offset":2858},"end":{"line":55,"column":143,"offset":2872},"indent":[]}}],"position":{"start":{"line":55,"column":128,"offset":2857},"end":{"line":55,"column":152,"offset":2881},"indent":[]}},{"type":"text","value":" credentials in the storage section, your recordings will be synced to our cloud solution.","position":{"start":{"line":55,"column":152,"offset":2881},"end":{"line":55,"column":242,"offset":2971},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2730},"end":{"line":55,"column":242,"offset":2971},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-cloud.png","alt":"OpenSource","position":{"start":{"line":57,"column":1,"offset":2973},"end":{"line":57,"column":76,"offset":3048},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2973},"end":{"line":57,"column":76,"offset":3048},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"System","position":{"start":{"line":59,"column":4,"offset":3053},"end":{"line":59,"column":10,"offset":3059},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":3050},"end":{"line":59,"column":10,"offset":3059},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This page will gave you overall information of Kerberos Open Source. It will give you information (logging) about the system, shows you some system information, the number of recordings on the system and more.","position":{"start":{"line":61,"column":1,"offset":3061},"end":{"line":61,"column":210,"offset":3270},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":3061},"end":{"line":61,"column":210,"offset":3270},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/opensource/kerberos-opensource-system.png","alt":"OpenSource","position":{"start":{"line":63,"column":1,"offset":3272},"end":{"line":63,"column":77,"offset":3348},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":3272},"end":{"line":63,"column":77,"offset":3348},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":66,"column":1,"offset":3351},"end":{"line":66,"column":31,"offset":3381},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":66,"column":31,"offset":3381}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Get Started`}

\n

{`Once you've installed Kerberos Open Source, you will have access to the web application. This web application allows you to administrate your the machinery.`}

\n

{`Welcome page`}

\n

{`The first time you open a browser, and navigate to the web application (ip address of your device), you will land on the welcome page. This page will guide you through some basic steps and set simple configurations such as username and password.`}

\n

\"OpenSource\"

\n

{`Login page`}

\n

{`When you've finished the welcome page, you will be redirected to the login page from now one. Use the credentials you have defined during the configuration of the welcome page. By default the username is `}{`root`}{`, and the password is `}{`root`}{`.`}

\n

\"OpenSource\"

\n

{`Dashboard`}

\n

{`After you have signed in successfully, you will land on the dashboard page. This page will give you an overview of some simple statistics. Such as the the activity per day, per hour, etc.`}

\n

\"OpenSource\"

\n

{`Media`}

\n

{`By selecting a specific day from the left navigation, or choosing the date picker on the top, you will be shown all the relevant media for that specific day. Both videos and images are listed and grouped (if they are within a specific time span). By scrolling down, more media items will be shown.`}

\n

{`You can use the timeslider at the top of the page for browsing through the day. The white (no activity) to gray (low activity) to red (high activity), will give you an indications of the amount of recordings for that specific hour.`}

\n

\"OpenSource\"

\n

\"OpenSource\"

\n

{`Settings`}

\n

{`Before being able to record anything, you will need to specify your capture device. A capture device is what we call: a camera. This camera can be a USB, RPi or IP camera. By default the RPi camera is selected, so if you are planning to use a IP camera make sure to change it on the settings page.`}

\n

\"OpenSource\"

\n

{`Region of interest`}

\n

{`Besides selecting the capture device, you will have different options to make the detection more intelligent, such as defining a regions of interest, or an activation timeline (when Kerberos Open Source should be active).`}

\n

\"OpenSource\"

\n

{`Storage`}

\n

{`Storing your recordings on your device is fine, on the other hand you might want to make it available remotely. By giving your `}{`Kerberos Cloud`}{` credentials in the storage section, your recordings will be synced to our cloud solution.`}

\n

\"OpenSource\"

\n

{`System`}

\n

{`This page will gave you overall information of Kerberos Open Source. It will give you information (logging) about the system, shows you some system information, the number of recordings on the system and more.`}

\n

\"OpenSource\"

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0f356c72f12f755bb1a43a120418c5ce.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0f356c72f12f755bb1a43a120418c5ce.json index b0ea55f..8377662 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0f356c72f12f755bb1a43a120418c5ce.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-0f356c72f12f755bb1a43a120418c5ce.json @@ -1 +1 @@ -{"expireTime":9007200841014157000,"key":"gatsby-plugin-mdx-entire-payload-552b89364a1e8ed2d65d8a65cc0ef97f-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Enterprise","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":13,"offset":171},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":13,"offset":171},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Over the years Kerberos evolved into a mature and stable solution. Lots of people and companies started to adopt the system, and requested enhancements. Despite the fact that Kerberos Open Source is stable and feature rich, every\nsolution has its limitations, especially if you aim to scale it.","position":{"start":{"line":10,"column":1,"offset":173},"end":{"line":11,"column":65,"offset":467},"indent":[1]}}],"position":{"start":{"line":10,"column":1,"offset":173},"end":{"line":11,"column":65,"offset":467},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"That being said, Kerberos Open Source is perfect when monitoring a limited set of surveillance cameras, but it doesn't scale well if you plan to monitor dozens or hundreds of surveillance cameras. Although Kerberos Open Source ships\nas a docker image, it has no high availability or fail over functionality. Due to these reasons we have developed Kerberos Enterprise, which is suitable for scaling against your ever growing video surveillance landscape, and keeps them up and running in whatever situation.","position":{"start":{"line":13,"column":1,"offset":469},"end":{"line":14,"column":274,"offset":975},"indent":[1]}}],"position":{"start":{"line":13,"column":1,"offset":469},"end":{"line":14,"column":274,"offset":975},"indent":[1]}},{"type":"jsx","value":"
\n
\n

","position":{"start":{"line":16,"column":1,"offset":977},"end":{"line":18,"column":11,"offset":1179},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Kubernetes","position":{"start":{"line":20,"column":4,"offset":1184},"end":{"line":20,"column":14,"offset":1194},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":1181},"end":{"line":20,"column":14,"offset":1194},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To provide our customer with the high availability and fail over requirements they have, Kerberos Enterprise was built on top of Kubernetes (k8s). This container orchestrator allows us to scale a video surveillance landscape horizontally, and deliver a never-seen high available video surveillance system.","position":{"start":{"line":22,"column":1,"offset":1196},"end":{"line":22,"column":306,"offset":1501},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1196},"end":{"line":22,"column":306,"offset":1501},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-agent-architecture-kubernetes.png","alt":"architecture kubernetes","position":{"start":{"line":24,"column":1,"offset":1503},"end":{"line":24,"column":91,"offset":1593},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1503},"end":{"line":24,"column":91,"offset":1593},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Enterprise is installed inside a Kubernetes cluster. It will create pods/deployments for every surveillance camera you want to monitor. Kubernetes will scale and distrubute these pods across your nodes (VM's/Bare metal machines).","position":{"start":{"line":26,"column":1,"offset":1595},"end":{"line":26,"column":239,"offset":1833},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1595},"end":{"line":26,"column":239,"offset":1833},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Nodes inside your cluster can fail or crash, Kubernetes will make sure the Kerberos pods running on the failed nodes will be deployed to healthy node. This, to make sure the monitoring of your video surveillance cameras continues seamlessly.","position":{"start":{"line":28,"column":1,"offset":1835},"end":{"line":28,"column":242,"offset":2076},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":1835},"end":{"line":28,"column":242,"offset":2076},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By having the power to add nodes to your cluster, you can anticipate to the ever growing need of your surveillance cameras. With the Kubernetes tools you can monitor your cluster and get into the details.","position":{"start":{"line":30,"column":1,"offset":2078},"end":{"line":30,"column":205,"offset":2282},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":2078},"end":{"line":30,"column":205,"offset":2282},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Cloud or on premise","position":{"start":{"line":32,"column":4,"offset":2287},"end":{"line":32,"column":23,"offset":2306},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":2284},"end":{"line":32,"column":23,"offset":2306},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You install Kerberos Enterprise inside a Kubernetes cluster, but there are no limitations where this cluster will be actually running. This means that whatever security policy you have within your company, you can run it where you want: on-premise, public cloud, private cloud, etc.","position":{"start":{"line":34,"column":1,"offset":2308},"end":{"line":34,"column":283,"offset":2590},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":2308},"end":{"line":34,"column":283,"offset":2590},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-agent-architecture-kubernetes-cloud.png","alt":"architecture kubernetes","position":{"start":{"line":36,"column":1,"offset":2592},"end":{"line":36,"column":97,"offset":2688},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":2592},"end":{"line":36,"column":97,"offset":2688},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Licensing","position":{"start":{"line":38,"column":4,"offset":2693},"end":{"line":38,"column":13,"offset":2702},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":2690},"end":{"line":38,"column":13,"offset":2702},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Enterprise is publicly available but ","position":{"start":{"line":40,"column":1,"offset":2704},"end":{"line":40,"column":47,"offset":2750},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"requires a license key","position":{"start":{"line":40,"column":49,"offset":2752},"end":{"line":40,"column":71,"offset":2774},"indent":[]}}],"position":{"start":{"line":40,"column":47,"offset":2750},"end":{"line":40,"column":73,"offset":2776},"indent":[]}},{"type":"text","value":" to operate correctly. A license key can be requested by contacting ","position":{"start":{"line":40,"column":73,"offset":2776},"end":{"line":40,"column":141,"offset":2844},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"cedric@verstraeten.io","position":{"start":{"line":40,"column":143,"offset":2846},"end":{"line":40,"column":164,"offset":2867},"indent":[]}}],"position":{"start":{"line":40,"column":141,"offset":2844},"end":{"line":40,"column":166,"offset":2869},"indent":[]}},{"type":"text","value":", you can send an email to have more information about the pricing.","position":{"start":{"line":40,"column":166,"offset":2869},"end":{"line":40,"column":233,"offset":2936},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":2704},"end":{"line":40,"column":233,"offset":2936},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":43,"column":1,"offset":2939},"end":{"line":43,"column":31,"offset":2969},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":43,"column":31,"offset":2969}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Enterprise`}

\n

{`Over the years Kerberos evolved into a mature and stable solution. Lots of people and companies started to adopt the system, and requested enhancements. Despite the fact that Kerberos Open Source is stable and feature rich, every\nsolution has its limitations, especially if you aim to scale it.`}

\n

{`That being said, Kerberos Open Source is perfect when monitoring a limited set of surveillance cameras, but it doesn't scale well if you plan to monitor dozens or hundreds of surveillance cameras. Although Kerberos Open Source ships\nas a docker image, it has no high availability or fail over functionality. Due to these reasons we have developed Kerberos Enterprise, which is suitable for scaling against your ever growing video surveillance landscape, and keeps them up and running in whatever situation.`}

\n
\n
\n

\n

{`Kubernetes`}

\n

{`To provide our customer with the high availability and fail over requirements they have, Kerberos Enterprise was built on top of Kubernetes (k8s). This container orchestrator allows us to scale a video surveillance landscape horizontally, and deliver a never-seen high available video surveillance system.`}

\n

\"architecture

\n

{`Kerberos Enterprise is installed inside a Kubernetes cluster. It will create pods/deployments for every surveillance camera you want to monitor. Kubernetes will scale and distrubute these pods across your nodes (VM's/Bare metal machines).`}

\n

{`Nodes inside your cluster can fail or crash, Kubernetes will make sure the Kerberos pods running on the failed nodes will be deployed to healthy node. This, to make sure the monitoring of your video surveillance cameras continues seamlessly.`}

\n

{`By having the power to add nodes to your cluster, you can anticipate to the ever growing need of your surveillance cameras. With the Kubernetes tools you can monitor your cluster and get into the details.`}

\n

{`Cloud or on premise`}

\n

{`You install Kerberos Enterprise inside a Kubernetes cluster, but there are no limitations where this cluster will be actually running. This means that whatever security policy you have within your company, you can run it where you want: on-premise, public cloud, private cloud, etc.`}

\n

\"architecture

\n

{`Licensing`}

\n

{`Kerberos Enterprise is publicly available but `}{`requires a license key`}{` to operate correctly. A license key can be requested by contacting `}{`cedric@verstraeten.io`}{`, you can send an email to have more information about the pricing.`}

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974263000,"key":"gatsby-plugin-mdx-entire-payload-552b89364a1e8ed2d65d8a65cc0ef97f-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Enterprise","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":13,"offset":171},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":13,"offset":171},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Over the years Kerberos evolved into a mature and stable solution. Lots of people and companies started to adopt the system, and requested enhancements. Despite the fact that Kerberos Open Source is stable and feature rich, every\nsolution has its limitations, especially if you aim to scale it.","position":{"start":{"line":10,"column":1,"offset":173},"end":{"line":11,"column":65,"offset":467},"indent":[1]}}],"position":{"start":{"line":10,"column":1,"offset":173},"end":{"line":11,"column":65,"offset":467},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"That being said, Kerberos Open Source is perfect when monitoring a limited set of surveillance cameras, but it doesn't scale well if you plan to monitor dozens or hundreds of surveillance cameras. Although Kerberos Open Source ships\nas a docker image, it has no high availability or fail over functionality. Due to these reasons we have developed Kerberos Enterprise, which is suitable for scaling against your ever growing video surveillance landscape, and keeps them up and running in whatever situation.","position":{"start":{"line":13,"column":1,"offset":469},"end":{"line":14,"column":274,"offset":975},"indent":[1]}}],"position":{"start":{"line":13,"column":1,"offset":469},"end":{"line":14,"column":274,"offset":975},"indent":[1]}},{"type":"jsx","value":"
\n
\n

","position":{"start":{"line":16,"column":1,"offset":977},"end":{"line":18,"column":11,"offset":1179},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Kubernetes","position":{"start":{"line":20,"column":4,"offset":1184},"end":{"line":20,"column":14,"offset":1194},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":1181},"end":{"line":20,"column":14,"offset":1194},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To provide our customer with the high availability and fail over requirements they have, Kerberos Enterprise was built on top of Kubernetes (k8s). This container orchestrator allows us to scale a video surveillance landscape horizontally, and deliver a never-seen high available video surveillance system.","position":{"start":{"line":22,"column":1,"offset":1196},"end":{"line":22,"column":306,"offset":1501},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1196},"end":{"line":22,"column":306,"offset":1501},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-agent-architecture-kubernetes.png","alt":"architecture kubernetes","position":{"start":{"line":24,"column":1,"offset":1503},"end":{"line":24,"column":91,"offset":1593},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1503},"end":{"line":24,"column":91,"offset":1593},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Enterprise is installed inside a Kubernetes cluster. It will create pods/deployments for every surveillance camera you want to monitor. Kubernetes will scale and distrubute these pods across your nodes (VM's/Bare metal machines).","position":{"start":{"line":26,"column":1,"offset":1595},"end":{"line":26,"column":239,"offset":1833},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1595},"end":{"line":26,"column":239,"offset":1833},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Nodes inside your cluster can fail or crash, Kubernetes will make sure the Kerberos pods running on the failed nodes will be deployed to healthy node. This, to make sure the monitoring of your video surveillance cameras continues seamlessly.","position":{"start":{"line":28,"column":1,"offset":1835},"end":{"line":28,"column":242,"offset":2076},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":1835},"end":{"line":28,"column":242,"offset":2076},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By having the power to add nodes to your cluster, you can anticipate to the ever growing need of your surveillance cameras. With the Kubernetes tools you can monitor your cluster and get into the details.","position":{"start":{"line":30,"column":1,"offset":2078},"end":{"line":30,"column":205,"offset":2282},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":2078},"end":{"line":30,"column":205,"offset":2282},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Cloud or on premise","position":{"start":{"line":32,"column":4,"offset":2287},"end":{"line":32,"column":23,"offset":2306},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":2284},"end":{"line":32,"column":23,"offset":2306},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You install Kerberos Enterprise inside a Kubernetes cluster, but there are no limitations where this cluster will be actually running. This means that whatever security policy you have within your company, you can run it where you want: on-premise, public cloud, private cloud, etc.","position":{"start":{"line":34,"column":1,"offset":2308},"end":{"line":34,"column":283,"offset":2590},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":2308},"end":{"line":34,"column":283,"offset":2590},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-agent-architecture-kubernetes-cloud.png","alt":"architecture kubernetes","position":{"start":{"line":36,"column":1,"offset":2592},"end":{"line":36,"column":97,"offset":2688},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":2592},"end":{"line":36,"column":97,"offset":2688},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Licensing","position":{"start":{"line":38,"column":4,"offset":2693},"end":{"line":38,"column":13,"offset":2702},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":2690},"end":{"line":38,"column":13,"offset":2702},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Enterprise is publicly available but ","position":{"start":{"line":40,"column":1,"offset":2704},"end":{"line":40,"column":47,"offset":2750},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"requires a license key","position":{"start":{"line":40,"column":49,"offset":2752},"end":{"line":40,"column":71,"offset":2774},"indent":[]}}],"position":{"start":{"line":40,"column":47,"offset":2750},"end":{"line":40,"column":73,"offset":2776},"indent":[]}},{"type":"text","value":" to operate correctly. A license key can be requested by contacting ","position":{"start":{"line":40,"column":73,"offset":2776},"end":{"line":40,"column":141,"offset":2844},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"cedric@verstraeten.io","position":{"start":{"line":40,"column":143,"offset":2846},"end":{"line":40,"column":164,"offset":2867},"indent":[]}}],"position":{"start":{"line":40,"column":141,"offset":2844},"end":{"line":40,"column":166,"offset":2869},"indent":[]}},{"type":"text","value":", you can send an email to have more information about the pricing.","position":{"start":{"line":40,"column":166,"offset":2869},"end":{"line":40,"column":233,"offset":2936},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":2704},"end":{"line":40,"column":233,"offset":2936},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":43,"column":1,"offset":2939},"end":{"line":43,"column":31,"offset":2969},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":43,"column":31,"offset":2969}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Enterprise`}

\n

{`Over the years Kerberos evolved into a mature and stable solution. Lots of people and companies started to adopt the system, and requested enhancements. Despite the fact that Kerberos Open Source is stable and feature rich, every\nsolution has its limitations, especially if you aim to scale it.`}

\n

{`That being said, Kerberos Open Source is perfect when monitoring a limited set of surveillance cameras, but it doesn't scale well if you plan to monitor dozens or hundreds of surveillance cameras. Although Kerberos Open Source ships\nas a docker image, it has no high availability or fail over functionality. Due to these reasons we have developed Kerberos Enterprise, which is suitable for scaling against your ever growing video surveillance landscape, and keeps them up and running in whatever situation.`}

\n
\n
\n

\n

{`Kubernetes`}

\n

{`To provide our customer with the high availability and fail over requirements they have, Kerberos Enterprise was built on top of Kubernetes (k8s). This container orchestrator allows us to scale a video surveillance landscape horizontally, and deliver a never-seen high available video surveillance system.`}

\n

\"architecture

\n

{`Kerberos Enterprise is installed inside a Kubernetes cluster. It will create pods/deployments for every surveillance camera you want to monitor. Kubernetes will scale and distrubute these pods across your nodes (VM's/Bare metal machines).`}

\n

{`Nodes inside your cluster can fail or crash, Kubernetes will make sure the Kerberos pods running on the failed nodes will be deployed to healthy node. This, to make sure the monitoring of your video surveillance cameras continues seamlessly.`}

\n

{`By having the power to add nodes to your cluster, you can anticipate to the ever growing need of your surveillance cameras. With the Kubernetes tools you can monitor your cluster and get into the details.`}

\n

{`Cloud or on premise`}

\n

{`You install Kerberos Enterprise inside a Kubernetes cluster, but there are no limitations where this cluster will be actually running. This means that whatever security policy you have within your company, you can run it where you want: on-premise, public cloud, private cloud, etc.`}

\n

\"architecture

\n

{`Licensing`}

\n

{`Kerberos Enterprise is publicly available but `}{`requires a license key`}{` to operate correctly. A license key can be requested by contacting `}{`cedric@verstraeten.io`}{`, you can send an email to have more information about the pricing.`}

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-121c1de76a52ca34d1b049cd4f1606bf.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-121c1de76a52ca34d1b049cd4f1606bf.json new file mode 100644 index 0000000..abf9a04 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-121c1de76a52ca34d1b049cd4f1606bf.json @@ -0,0 +1 @@ +{"expireTime":9007200841981988000,"key":"gatsby-plugin-mdx-entire-payload-b908c5324cb28aa7282889f4322f6214-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":9,"offset":451},"indent":[]}}],"position":{"start":{"line":14,"column":4,"offset":446},"end":{"line":14,"column":41,"offset":483},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":14,"column":41,"offset":483},"end":{"line":14,"column":116,"offset":558},"indent":[]}}],"position":{"start":{"line":14,"column":4,"offset":446},"end":{"line":14,"column":116,"offset":558},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":116,"offset":558},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":15,"column":5,"offset":563},"end":{"line":15,"column":13,"offset":571},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":562},"end":{"line":15,"column":49,"offset":607},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":15,"column":49,"offset":607},"end":{"line":15,"column":139,"offset":697},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":562},"end":{"line":15,"column":139,"offset":697},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":559},"end":{"line":15,"column":139,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":702},"end":{"line":16,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":701},"end":{"line":16,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":742},"end":{"line":16,"column":121,"offset":818},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":701},"end":{"line":16,"column":121,"offset":818},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":698},"end":{"line":16,"column":121,"offset":818},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":823},"end":{"line":17,"column":11,"offset":829},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":822},"end":{"line":17,"column":45,"offset":863},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":863},"end":{"line":17,"column":103,"offset":921},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":822},"end":{"line":17,"column":103,"offset":921},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":819},"end":{"line":17,"column":103,"offset":921},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":18,"column":5,"offset":926},"end":{"line":18,"column":12,"offset":933},"indent":[]}}],"position":{"start":{"line":18,"column":4,"offset":925},"end":{"line":18,"column":47,"offset":968},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":18,"column":47,"offset":968},"end":{"line":18,"column":179,"offset":1100},"indent":[]}}],"position":{"start":{"line":18,"column":4,"offset":925},"end":{"line":18,"column":179,"offset":1100},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":922},"end":{"line":18,"column":179,"offset":1100},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":18,"column":179,"offset":1100},"indent":[1,1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":20,"column":4,"offset":1105},"end":{"line":20,"column":8,"offset":1109},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":1102},"end":{"line":20,"column":8,"offset":1109},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":22,"column":1,"offset":1111},"end":{"line":22,"column":229,"offset":1339},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1111},"end":{"line":22,"column":229,"offset":1339},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":24,"column":1,"offset":1341},"end":{"line":24,"column":197,"offset":1537},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1341},"end":{"line":24,"column":197,"offset":1537},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":26,"column":5,"offset":1543},"end":{"line":26,"column":11,"offset":1549},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1539},"end":{"line":26,"column":11,"offset":1549},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":28,"column":1,"offset":1551},"end":{"line":28,"column":63,"offset":1613},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":28,"column":64,"offset":1614},"end":{"line":28,"column":85,"offset":1635},"indent":[]}}],"position":{"start":{"line":28,"column":63,"offset":1613},"end":{"line":28,"column":123,"offset":1673},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":28,"column":123,"offset":1673},"end":{"line":28,"column":124,"offset":1674},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":1551},"end":{"line":28,"column":124,"offset":1674},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos installer","position":{"start":{"line":30,"column":5,"offset":1680},"end":{"line":30,"column":23,"offset":1698},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":1676},"end":{"line":30,"column":23,"offset":1698},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":32,"column":1,"offset":1700},"end":{"line":32,"column":228,"offset":1927},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":1700},"end":{"line":32,"column":228,"offset":1927},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":34,"column":1,"offset":1929},"end":{"line":34,"column":67,"offset":1995},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":1929},"end":{"line":34,"column":67,"offset":1995},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":36,"column":1,"offset":1997},"end":{"line":36,"column":50,"offset":2046},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":1997},"end":{"line":36,"column":50,"offset":2046},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":38,"column":3,"offset":2050},"end":{"line":38,"column":49,"offset":2096},"indent":[]}}],"position":{"start":{"line":38,"column":3,"offset":2050},"end":{"line":38,"column":49,"offset":2096},"indent":[]}}],"position":{"start":{"line":38,"column":3,"offset":2050},"end":{"line":38,"column":49,"offset":2096},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":2048},"end":{"line":38,"column":49,"offset":2096},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":40,"column":5,"offset":2102},"end":{"line":40,"column":11,"offset":2108},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":2098},"end":{"line":40,"column":11,"offset":2108},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":42,"column":1,"offset":2110},"end":{"line":42,"column":160,"offset":2269},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":2110},"end":{"line":42,"column":160,"offset":2269},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":44,"column":4,"offset":2274},"end":{"line":44,"column":13,"offset":2283},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":44,"column":14,"offset":2284},"end":{"line":44,"column":28,"offset":2298},"indent":[]}}],"position":{"start":{"line":44,"column":13,"offset":2283},"end":{"line":44,"column":75,"offset":2345},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":44,"column":75,"offset":2345},"end":{"line":44,"column":76,"offset":2346},"indent":[]}}],"position":{"start":{"line":44,"column":4,"offset":2274},"end":{"line":44,"column":76,"offset":2346},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":2271},"end":{"line":44,"column":76,"offset":2346},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":45,"column":4,"offset":2350},"end":{"line":45,"column":41,"offset":2387},"indent":[]}}],"position":{"start":{"line":45,"column":4,"offset":2350},"end":{"line":45,"column":41,"offset":2387},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2347},"end":{"line":45,"column":41,"offset":2387},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":46,"column":4,"offset":2391},"end":{"line":46,"column":60,"offset":2447},"indent":[]}}],"position":{"start":{"line":46,"column":4,"offset":2391},"end":{"line":46,"column":60,"offset":2447},"indent":[]}}],"position":{"start":{"line":46,"column":1,"offset":2388},"end":{"line":46,"column":60,"offset":2447},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":2271},"end":{"line":46,"column":60,"offset":2447},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":48,"column":2,"offset":2450},"end":{"line":48,"column":64,"offset":2512},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2449},"end":{"line":48,"column":96,"offset":2544},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2449},"end":{"line":48,"column":96,"offset":2544},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":50,"column":1,"offset":2546},"end":{"line":50,"column":204,"offset":2749},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":2546},"end":{"line":50,"column":204,"offset":2749},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":52,"column":6,"offset":2756},"end":{"line":52,"column":24,"offset":2774},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2751},"end":{"line":52,"column":24,"offset":2774},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":54,"column":1,"offset":2776},"end":{"line":54,"column":95,"offset":2870},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":54,"column":95,"offset":2870},"end":{"line":54,"column":110,"offset":2885},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":54,"column":110,"offset":2885},"end":{"line":54,"column":222,"offset":2997},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2776},"end":{"line":54,"column":222,"offset":2997},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":56,"column":1,"offset":2999},"end":{"line":64,"column":4,"offset":3108},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":66,"column":6,"offset":3115},"end":{"line":66,"column":31,"offset":3140},"indent":[]}}],"position":{"start":{"line":66,"column":1,"offset":3110},"end":{"line":66,"column":31,"offset":3140},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":68,"column":1,"offset":3142},"end":{"line":68,"column":79,"offset":3220},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":68,"column":79,"offset":3220},"end":{"line":68,"column":95,"offset":3236},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":68,"column":95,"offset":3236},"end":{"line":68,"column":137,"offset":3278},"indent":[]}}],"position":{"start":{"line":68,"column":1,"offset":3142},"end":{"line":68,"column":137,"offset":3278},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":70,"column":1,"offset":3280},"end":{"line":80,"column":4,"offset":3648},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":82,"column":5,"offset":3654},"end":{"line":82,"column":30,"offset":3679},"indent":[]}}],"position":{"start":{"line":82,"column":1,"offset":3650},"end":{"line":82,"column":30,"offset":3679},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":84,"column":1,"offset":3681},"end":{"line":84,"column":464,"offset":4144},"indent":[]}}],"position":{"start":{"line":84,"column":1,"offset":3681},"end":{"line":84,"column":464,"offset":4144},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":86,"column":1,"offset":4146},"end":{"line":86,"column":61,"offset":4206},"indent":[]}}],"position":{"start":{"line":86,"column":1,"offset":4146},"end":{"line":86,"column":61,"offset":4206},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":88,"column":5,"offset":4212},"end":{"line":88,"column":28,"offset":4235},"indent":[]}}],"position":{"start":{"line":88,"column":1,"offset":4208},"end":{"line":88,"column":28,"offset":4235},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":90,"column":1,"offset":4237},"end":{"line":90,"column":95,"offset":4331},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":90,"column":95,"offset":4331},"end":{"line":90,"column":100,"offset":4336},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":90,"column":100,"offset":4336},"end":{"line":90,"column":101,"offset":4337},"indent":[]}}],"position":{"start":{"line":90,"column":1,"offset":4237},"end":{"line":90,"column":101,"offset":4337},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":92,"column":1,"offset":4339},"end":{"line":96,"column":4,"offset":4456},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":98,"column":1,"offset":4458},"end":{"line":98,"column":80,"offset":4537},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":98,"column":80,"offset":4537},"end":{"line":98,"column":101,"offset":4558},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":98,"column":101,"offset":4558},"end":{"line":98,"column":162,"offset":4619},"indent":[]}}],"position":{"start":{"line":98,"column":1,"offset":4458},"end":{"line":98,"column":162,"offset":4619},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":100,"column":1,"offset":4621},"end":{"line":103,"column":4,"offset":4710},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":105,"column":4,"offset":4715},"end":{"line":105,"column":12,"offset":4723},"indent":[]}}],"position":{"start":{"line":105,"column":1,"offset":4712},"end":{"line":105,"column":12,"offset":4723},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":107,"column":1,"offset":4725},"end":{"line":107,"column":193,"offset":4917},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4725},"end":{"line":107,"column":193,"offset":4917},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":109,"column":4,"offset":4922},"end":{"line":109,"column":62,"offset":4980},"indent":[]}}],"position":{"start":{"line":109,"column":4,"offset":4922},"end":{"line":109,"column":62,"offset":4980},"indent":[]}}],"position":{"start":{"line":109,"column":1,"offset":4919},"end":{"line":109,"column":62,"offset":4980},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":110,"column":4,"offset":4984},"end":{"line":110,"column":69,"offset":5049},"indent":[]}}],"position":{"start":{"line":110,"column":4,"offset":4984},"end":{"line":110,"column":69,"offset":5049},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4981},"end":{"line":110,"column":69,"offset":5049},"indent":[]}}],"position":{"start":{"line":109,"column":1,"offset":4919},"end":{"line":110,"column":69,"offset":5049},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":112,"column":1,"offset":5051},"end":{"line":112,"column":99,"offset":5149},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":5051},"end":{"line":112,"column":99,"offset":5149},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":114,"column":5,"offset":5155},"end":{"line":114,"column":14,"offset":5164},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":5151},"end":{"line":114,"column":14,"offset":5164},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":116,"column":1,"offset":5166},"end":{"line":116,"column":71,"offset":5236},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":5166},"end":{"line":116,"column":71,"offset":5236},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":118,"column":3,"offset":5240},"end":{"line":118,"column":47,"offset":5284},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":118,"column":47,"offset":5284},"end":{"line":118,"column":79,"offset":5316},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":118,"column":79,"offset":5316},"end":{"line":118,"column":198,"offset":5435},"indent":[]}}],"position":{"start":{"line":118,"column":3,"offset":5240},"end":{"line":118,"column":198,"offset":5435},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5238},"end":{"line":118,"column":198,"offset":5435},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":120,"column":1,"offset":5437},"end":{"line":122,"column":4,"offset":5500},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":124,"column":5,"offset":5506},"end":{"line":124,"column":14,"offset":5515},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5502},"end":{"line":124,"column":14,"offset":5515},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":126,"column":1,"offset":5517},"end":{"line":126,"column":56,"offset":5572},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5517},"end":{"line":126,"column":56,"offset":5572},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":127,"column":3,"offset":5575},"end":{"line":127,"column":52,"offset":5624},"indent":[]}}],"position":{"start":{"line":127,"column":3,"offset":5575},"end":{"line":127,"column":52,"offset":5624},"indent":[]}}],"position":{"start":{"line":127,"column":3,"offset":5575},"end":{"line":127,"column":52,"offset":5624},"indent":[]}}],"position":{"start":{"line":127,"column":1,"offset":5573},"end":{"line":127,"column":52,"offset":5624},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":129,"column":1,"offset":5626},"end":{"line":129,"column":3,"offset":5628},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":129,"column":3,"offset":5628},"end":{"line":129,"column":9,"offset":5634},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":129,"column":9,"offset":5634},"end":{"line":129,"column":223,"offset":5848},"indent":[]}}],"position":{"start":{"line":129,"column":1,"offset":5626},"end":{"line":129,"column":223,"offset":5848},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":131,"column":3,"offset":5852},"end":{"line":131,"column":159,"offset":6008},"indent":[]}}],"position":{"start":{"line":131,"column":3,"offset":5852},"end":{"line":131,"column":159,"offset":6008},"indent":[]}}],"position":{"start":{"line":131,"column":1,"offset":5850},"end":{"line":131,"column":159,"offset":6008},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":133,"column":1,"offset":6010},"end":{"line":136,"column":4,"offset":6187},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":138,"column":1,"offset":6189},"end":{"line":138,"column":160,"offset":6348},"indent":[]}}],"position":{"start":{"line":138,"column":1,"offset":6189},"end":{"line":138,"column":160,"offset":6348},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":140,"column":3,"offset":6352},"end":{"line":140,"column":31,"offset":6380},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":140,"column":31,"offset":6380},"end":{"line":140,"column":101,"offset":6450},"indent":[]}}],"position":{"start":{"line":140,"column":3,"offset":6352},"end":{"line":140,"column":101,"offset":6450},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6350},"end":{"line":140,"column":101,"offset":6450},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":142,"column":1,"offset":6452},"end":{"line":145,"column":4,"offset":6624},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":147,"column":1,"offset":6626},"end":{"line":147,"column":73,"offset":6698},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6626},"end":{"line":147,"column":73,"offset":6698},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":150,"column":3,"offset":6703},"end":{"line":150,"column":31,"offset":6731},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":150,"column":31,"offset":6731},"end":{"line":150,"column":101,"offset":6801},"indent":[]}}],"position":{"start":{"line":150,"column":3,"offset":6703},"end":{"line":150,"column":101,"offset":6801},"indent":[]}}],"position":{"start":{"line":150,"column":1,"offset":6701},"end":{"line":150,"column":101,"offset":6801},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":152,"column":1,"offset":6803},"end":{"line":155,"column":4,"offset":6975},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":157,"column":1,"offset":6977},"end":{"line":157,"column":62,"offset":7038},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":157,"column":63,"offset":7039},"end":{"line":157,"column":75,"offset":7051},"indent":[]}}],"position":{"start":{"line":157,"column":62,"offset":7038},"end":{"line":157,"column":143,"offset":7119},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":157,"column":143,"offset":7119},"end":{"line":157,"column":150,"offset":7126},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":157,"column":150,"offset":7126},"end":{"line":157,"column":169,"offset":7145},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":157,"column":169,"offset":7145},"end":{"line":157,"column":170,"offset":7146},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6977},"end":{"line":157,"column":170,"offset":7146},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":159,"column":1,"offset":7148},"end":{"line":161,"column":4,"offset":7175},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":163,"column":1,"offset":7177},"end":{"line":163,"column":58,"offset":7234},"indent":[]}}],"position":{"start":{"line":163,"column":1,"offset":7177},"end":{"line":163,"column":58,"offset":7234},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":165,"column":1,"offset":7236},"end":{"line":168,"column":4,"offset":7306},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":170,"column":5,"offset":7312},"end":{"line":170,"column":8,"offset":7315},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7308},"end":{"line":170,"column":8,"offset":7315},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":172,"column":1,"offset":7317},"end":{"line":172,"column":280,"offset":7596},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7317},"end":{"line":172,"column":280,"offset":7596},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":174,"column":1,"offset":7598},"end":{"line":174,"column":37,"offset":7634},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7598},"end":{"line":174,"column":37,"offset":7634},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":176,"column":1,"offset":7636},"end":{"line":178,"column":4,"offset":7809},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":180,"column":1,"offset":7811},"end":{"line":180,"column":25,"offset":7835},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7811},"end":{"line":180,"column":25,"offset":7835},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":182,"column":1,"offset":7837},"end":{"line":185,"column":4,"offset":7941},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":187,"column":1,"offset":7943},"end":{"line":187,"column":118,"offset":8060},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":7943},"end":{"line":187,"column":118,"offset":8060},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":189,"column":1,"offset":8062},"end":{"line":209,"column":4,"offset":8569},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":211,"column":1,"offset":8571},"end":{"line":211,"column":14,"offset":8584},"indent":[]}}],"position":{"start":{"line":211,"column":1,"offset":8571},"end":{"line":211,"column":14,"offset":8584},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":213,"column":1,"offset":8586},"end":{"line":215,"column":4,"offset":8622},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":217,"column":1,"offset":8624},"end":{"line":217,"column":91,"offset":8714},"indent":[]}}],"position":{"start":{"line":217,"column":1,"offset":8624},"end":{"line":217,"column":91,"offset":8714},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":219,"column":1,"offset":8716},"end":{"line":227,"column":4,"offset":9089},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":229,"column":1,"offset":9091},"end":{"line":229,"column":145,"offset":9235},"indent":[]}}],"position":{"start":{"line":229,"column":1,"offset":9091},"end":{"line":229,"column":145,"offset":9235},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":231,"column":5,"offset":9241},"end":{"line":231,"column":17,"offset":9253},"indent":[]}}],"position":{"start":{"line":231,"column":1,"offset":9237},"end":{"line":231,"column":17,"offset":9253},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":233,"column":1,"offset":9255},"end":{"line":233,"column":300,"offset":9554},"indent":[]}}],"position":{"start":{"line":233,"column":1,"offset":9255},"end":{"line":233,"column":300,"offset":9554},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":235,"column":1,"offset":9556},"end":{"line":235,"column":178,"offset":9733},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":9556},"end":{"line":235,"column":178,"offset":9733},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":237,"column":1,"offset":9735},"end":{"line":237,"column":48,"offset":9782},"indent":[]}}],"position":{"start":{"line":237,"column":1,"offset":9735},"end":{"line":237,"column":48,"offset":9782},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":239,"column":1,"offset":9784},"end":{"line":241,"column":4,"offset":9824},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":243,"column":1,"offset":9826},"end":{"line":243,"column":104,"offset":9929},"indent":[]}}],"position":{"start":{"line":243,"column":1,"offset":9826},"end":{"line":243,"column":104,"offset":9929},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":245,"column":1,"offset":9931},"end":{"line":253,"column":4,"offset":10201},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":255,"column":1,"offset":10203},"end":{"line":255,"column":28,"offset":10230},"indent":[]}}],"position":{"start":{"line":255,"column":1,"offset":10203},"end":{"line":255,"column":28,"offset":10230},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":257,"column":1,"offset":10232},"end":{"line":259,"column":4,"offset":10276},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":261,"column":1,"offset":10278},"end":{"line":261,"column":48,"offset":10325},"indent":[]}}],"position":{"start":{"line":261,"column":1,"offset":10278},"end":{"line":261,"column":48,"offset":10325},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":263,"column":1,"offset":10327},"end":{"line":265,"column":4,"offset":10349},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":267,"column":1,"offset":10351},"end":{"line":267,"column":72,"offset":10422},"indent":[]}}],"position":{"start":{"line":267,"column":1,"offset":10351},"end":{"line":267,"column":72,"offset":10422},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":269,"column":1,"offset":10424},"end":{"line":271,"column":4,"offset":10481},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":273,"column":4,"offset":10486},"end":{"line":273,"column":10,"offset":10492},"indent":[]}}],"position":{"start":{"line":273,"column":1,"offset":10483},"end":{"line":273,"column":10,"offset":10492},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":275,"column":1,"offset":10494},"end":{"line":275,"column":337,"offset":10830},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":275,"column":338,"offset":10831},"end":{"line":275,"column":352,"offset":10845},"indent":[]}}],"position":{"start":{"line":275,"column":337,"offset":10830},"end":{"line":275,"column":388,"offset":10881},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":275,"column":388,"offset":10881},"end":{"line":275,"column":389,"offset":10882},"indent":[]}}],"position":{"start":{"line":275,"column":1,"offset":10494},"end":{"line":275,"column":389,"offset":10882},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":277,"column":5,"offset":10888},"end":{"line":277,"column":18,"offset":10901},"indent":[]}}],"position":{"start":{"line":277,"column":1,"offset":10884},"end":{"line":277,"column":18,"offset":10901},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":279,"column":3,"offset":10905},"end":{"line":279,"column":50,"offset":10952},"indent":[]}}],"position":{"start":{"line":279,"column":3,"offset":10905},"end":{"line":279,"column":50,"offset":10952},"indent":[]}}],"position":{"start":{"line":279,"column":1,"offset":10903},"end":{"line":279,"column":50,"offset":10952},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":281,"column":5,"offset":10958},"end":{"line":281,"column":11,"offset":10964},"indent":[]}}],"position":{"start":{"line":281,"column":1,"offset":10954},"end":{"line":281,"column":11,"offset":10964},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":283,"column":1,"offset":10966},"end":{"line":283,"column":64,"offset":11029},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":283,"column":65,"offset":11030},"end":{"line":283,"column":86,"offset":11051},"indent":[]}}],"position":{"start":{"line":283,"column":64,"offset":11029},"end":{"line":283,"column":126,"offset":11091},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":283,"column":126,"offset":11091},"end":{"line":283,"column":127,"offset":11092},"indent":[]}}],"position":{"start":{"line":283,"column":1,"offset":10966},"end":{"line":283,"column":127,"offset":11092},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":285,"column":5,"offset":11098},"end":{"line":285,"column":26,"offset":11119},"indent":[]}}],"position":{"start":{"line":285,"column":1,"offset":11094},"end":{"line":285,"column":26,"offset":11119},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":287,"column":1,"offset":11121},"end":{"line":287,"column":126,"offset":11246},"indent":[]}}],"position":{"start":{"line":287,"column":1,"offset":11121},"end":{"line":287,"column":126,"offset":11246},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":289,"column":1,"offset":11248},"end":{"line":291,"column":4,"offset":11287},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":293,"column":1,"offset":11289},"end":{"line":293,"column":187,"offset":11475},"indent":[]}}],"position":{"start":{"line":293,"column":1,"offset":11289},"end":{"line":293,"column":187,"offset":11475},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":295,"column":1,"offset":11477},"end":{"line":297,"column":4,"offset":11555},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":299,"column":1,"offset":11557},"end":{"line":299,"column":153,"offset":11709},"indent":[]}}],"position":{"start":{"line":299,"column":1,"offset":11557},"end":{"line":299,"column":153,"offset":11709},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":301,"column":1,"offset":11711},"end":{"line":304,"column":4,"offset":11858},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":306,"column":1,"offset":11860},"end":{"line":306,"column":100,"offset":11959},"indent":[]}}],"position":{"start":{"line":306,"column":1,"offset":11860},"end":{"line":306,"column":100,"offset":11959},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":307,"column":1,"offset":11960},"end":{"line":311,"column":4,"offset":12029},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":313,"column":5,"offset":12035},"end":{"line":313,"column":12,"offset":12042},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":12031},"end":{"line":313,"column":12,"offset":12042},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":315,"column":1,"offset":12044},"end":{"line":315,"column":64,"offset":12107},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12044},"end":{"line":315,"column":64,"offset":12107},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":316,"column":3,"offset":12110},"end":{"line":316,"column":25,"offset":12132},"indent":[]}}],"position":{"start":{"line":316,"column":3,"offset":12110},"end":{"line":316,"column":25,"offset":12132},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12108},"end":{"line":316,"column":25,"offset":12132},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":317,"column":3,"offset":12135},"end":{"line":317,"column":59,"offset":12191},"indent":[]}}],"position":{"start":{"line":317,"column":3,"offset":12135},"end":{"line":317,"column":59,"offset":12191},"indent":[]}}],"position":{"start":{"line":317,"column":1,"offset":12133},"end":{"line":317,"column":59,"offset":12191},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12108},"end":{"line":317,"column":59,"offset":12191},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":319,"column":4,"offset":12196},"end":{"line":319,"column":10,"offset":12202},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":12193},"end":{"line":319,"column":10,"offset":12202},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos as a Docker container is great, and makes it possible to run Kerberos everywhere, even on a Raspberry Pi or any other tiny PC. However some you might need more control and flexibility. This is where Balena comes into the picture. ","position":{"start":{"line":321,"column":1,"offset":12204},"end":{"line":321,"column":248,"offset":12451},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":12204},"end":{"line":321,"column":248,"offset":12451},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":322,"column":4,"offset":12455},"end":{"line":322,"column":11,"offset":12462},"indent":[]}}],"position":{"start":{"line":322,"column":1,"offset":12452},"end":{"line":322,"column":11,"offset":12462},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":324,"column":1,"offset":12464},"end":{"line":324,"column":283,"offset":12746},"indent":[]}}],"position":{"start":{"line":324,"column":1,"offset":12464},"end":{"line":324,"column":283,"offset":12746},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":326,"column":3,"offset":12750},"end":{"line":326,"column":54,"offset":12801},"indent":[]}}],"position":{"start":{"line":326,"column":3,"offset":12750},"end":{"line":326,"column":54,"offset":12801},"indent":[]}}],"position":{"start":{"line":326,"column":1,"offset":12748},"end":{"line":326,"column":54,"offset":12801},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":328,"column":5,"offset":12807},"end":{"line":328,"column":14,"offset":12816},"indent":[]}}],"position":{"start":{"line":328,"column":1,"offset":12803},"end":{"line":328,"column":14,"offset":12816},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":330,"column":1,"offset":12818},"end":{"line":330,"column":68,"offset":12885},"indent":[]}}],"position":{"start":{"line":330,"column":1,"offset":12818},"end":{"line":330,"column":68,"offset":12885},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":332,"column":1,"offset":12887},"end":{"line":335,"column":4,"offset":13038},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":337,"column":1,"offset":13040},"end":{"line":337,"column":46,"offset":13085},"indent":[]}}],"position":{"start":{"line":337,"column":1,"offset":13040},"end":{"line":337,"column":46,"offset":13085},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":339,"column":3,"offset":13089},"end":{"line":339,"column":103,"offset":13189},"indent":[]}}],"position":{"start":{"line":339,"column":3,"offset":13089},"end":{"line":339,"column":103,"offset":13189},"indent":[]}}],"position":{"start":{"line":339,"column":1,"offset":13087},"end":{"line":339,"column":103,"offset":13189},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":341,"column":1,"offset":13191},"end":{"line":346,"column":4,"offset":13401},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":348,"column":1,"offset":13403},"end":{"line":348,"column":151,"offset":13553},"indent":[]}}],"position":{"start":{"line":348,"column":1,"offset":13403},"end":{"line":348,"column":151,"offset":13553},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":350,"column":3,"offset":13557},"end":{"line":350,"column":22,"offset":13576},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":350,"column":22,"offset":13576},"end":{"line":350,"column":26,"offset":13580},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":350,"column":26,"offset":13580},"end":{"line":350,"column":40,"offset":13594},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":350,"column":40,"offset":13594},"end":{"line":350,"column":50,"offset":13604},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":350,"column":50,"offset":13604},"end":{"line":350,"column":98,"offset":13652},"indent":[]}}],"position":{"start":{"line":350,"column":3,"offset":13557},"end":{"line":350,"column":98,"offset":13652},"indent":[]}}],"position":{"start":{"line":350,"column":1,"offset":13555},"end":{"line":350,"column":98,"offset":13652},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":352,"column":1,"offset":13654},"end":{"line":356,"column":4,"offset":13816},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":358,"column":1,"offset":13818},"end":{"line":358,"column":72,"offset":13889},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":358,"column":72,"offset":13889},"end":{"line":358,"column":84,"offset":13901},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":358,"column":84,"offset":13901},"end":{"line":358,"column":102,"offset":13919},"indent":[]}}],"position":{"start":{"line":358,"column":1,"offset":13818},"end":{"line":358,"column":102,"offset":13919},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":360,"column":1,"offset":13921},"end":{"line":363,"column":4,"offset":13995},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":365,"column":5,"offset":14001},"end":{"line":365,"column":8,"offset":14004},"indent":[]}}],"position":{"start":{"line":365,"column":1,"offset":13997},"end":{"line":365,"column":8,"offset":14004},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":367,"column":1,"offset":14006},"end":{"line":367,"column":176,"offset":14181},"indent":[]}}],"position":{"start":{"line":367,"column":1,"offset":14006},"end":{"line":367,"column":176,"offset":14181},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":369,"column":1,"offset":14183},"end":{"line":376,"column":4,"offset":14480},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":378,"column":1,"offset":14482},"end":{"line":378,"column":60,"offset":14541},"indent":[]}}],"position":{"start":{"line":378,"column":1,"offset":14482},"end":{"line":378,"column":60,"offset":14541},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":380,"column":1,"offset":14543},"end":{"line":384,"column":4,"offset":14669},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":386,"column":1,"offset":14671},"end":{"line":386,"column":63,"offset":14733},"indent":[]}}],"position":{"start":{"line":386,"column":1,"offset":14671},"end":{"line":386,"column":63,"offset":14733},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":388,"column":1,"offset":14735},"end":{"line":408,"column":4,"offset":15242},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":410,"column":1,"offset":15244},"end":{"line":410,"column":99,"offset":15342},"indent":[]}}],"position":{"start":{"line":410,"column":1,"offset":15244},"end":{"line":410,"column":99,"offset":15342},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":412,"column":1,"offset":15344},"end":{"line":415,"column":4,"offset":15446},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":417,"column":1,"offset":15448},"end":{"line":417,"column":37,"offset":15484},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":417,"column":37,"offset":15484},"end":{"line":417,"column":47,"offset":15494},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":417,"column":47,"offset":15494},"end":{"line":417,"column":89,"offset":15536},"indent":[]}}],"position":{"start":{"line":417,"column":1,"offset":15448},"end":{"line":417,"column":89,"offset":15536},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":419,"column":1,"offset":15538},"end":{"line":423,"column":4,"offset":15663},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":425,"column":1,"offset":15665},"end":{"line":425,"column":78,"offset":15742},"indent":[]}}],"position":{"start":{"line":425,"column":1,"offset":15665},"end":{"line":425,"column":78,"offset":15742},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":427,"column":1,"offset":15744},"end":{"line":431,"column":4,"offset":15848},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":433,"column":1,"offset":15850},"end":{"line":433,"column":75,"offset":15924},"indent":[]}}],"position":{"start":{"line":433,"column":1,"offset":15850},"end":{"line":433,"column":75,"offset":15924},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":435,"column":1,"offset":15926},"end":{"line":439,"column":4,"offset":15999},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":441,"column":1,"offset":16001},"end":{"line":441,"column":145,"offset":16145},"indent":[]}}],"position":{"start":{"line":441,"column":1,"offset":16001},"end":{"line":441,"column":145,"offset":16145},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":443,"column":5,"offset":16151},"end":{"line":443,"column":17,"offset":16163},"indent":[]}}],"position":{"start":{"line":443,"column":1,"offset":16147},"end":{"line":443,"column":17,"offset":16163},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":445,"column":1,"offset":16165},"end":{"line":445,"column":300,"offset":16464},"indent":[]}}],"position":{"start":{"line":445,"column":1,"offset":16165},"end":{"line":445,"column":300,"offset":16464},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":447,"column":1,"offset":16466},"end":{"line":447,"column":178,"offset":16643},"indent":[]}}],"position":{"start":{"line":447,"column":1,"offset":16466},"end":{"line":447,"column":178,"offset":16643},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":449,"column":1,"offset":16645},"end":{"line":449,"column":48,"offset":16692},"indent":[]}}],"position":{"start":{"line":449,"column":1,"offset":16645},"end":{"line":449,"column":48,"offset":16692},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":451,"column":1,"offset":16694},"end":{"line":453,"column":4,"offset":16738},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":455,"column":1,"offset":16740},"end":{"line":455,"column":104,"offset":16843},"indent":[]}}],"position":{"start":{"line":455,"column":1,"offset":16740},"end":{"line":455,"column":104,"offset":16843},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":457,"column":1,"offset":16845},"end":{"line":465,"column":4,"offset":17115},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":467,"column":1,"offset":17117},"end":{"line":467,"column":28,"offset":17144},"indent":[]}}],"position":{"start":{"line":467,"column":1,"offset":17117},"end":{"line":467,"column":28,"offset":17144},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":469,"column":1,"offset":17146},"end":{"line":471,"column":4,"offset":17194},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":473,"column":1,"offset":17196},"end":{"line":473,"column":48,"offset":17243},"indent":[]}}],"position":{"start":{"line":473,"column":1,"offset":17196},"end":{"line":473,"column":48,"offset":17243},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":475,"column":1,"offset":17245},"end":{"line":477,"column":4,"offset":17267},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":479,"column":1,"offset":17269},"end":{"line":479,"column":72,"offset":17340},"indent":[]}}],"position":{"start":{"line":479,"column":1,"offset":17269},"end":{"line":479,"column":72,"offset":17340},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":481,"column":1,"offset":17342},"end":{"line":483,"column":4,"offset":17403},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":486,"column":1,"offset":17406},"end":{"line":486,"column":31,"offset":17436},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":486,"column":31,"offset":17436}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  4. \n
  5. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  6. \n
  7. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  8. \n
  9. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  10. \n
\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Docker`}

\n

{`A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos as a Docker container is great, and makes it possible to run Kerberos everywhere, even on a Raspberry Pi or any other tiny PC. However some you might need more control and flexibility. This is where Balena comes into the picture. `}

\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-159f3a9ffbd7b0bfc9e3a064fc896e42.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-159f3a9ffbd7b0bfc9e3a064fc896e42.json index 92e9f52..7d79e9f 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-159f3a9ffbd7b0bfc9e3a064fc896e42.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-159f3a9ffbd7b0bfc9e3a064fc896e42.json @@ -1 +1 @@ -{"expireTime":9007200841014158000,"key":"gatsby-plugin-mdx-entire-payload-f17055d9de3dd3e1b964c60098526a6f-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"EULA","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":7,"offset":165},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":7,"offset":165},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This agreement (or “EULA”) is a legal agreement between the person, company or organization (“You”) that has licensed a software product (Kerberos Enterprise) and Verstraeten.io (“Licensor” or “Application Provider”). The Product is to be obtained only through Docker Hub (","position":{"start":{"line":10,"column":1,"offset":167},"end":{"line":10,"column":274,"offset":440},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com","children":[{"type":"text","value":"https://hub.docker.com","position":{"start":{"line":10,"column":274,"offset":440},"end":{"line":10,"column":296,"offset":462},"indent":[]}}],"position":{"start":{"line":10,"column":274,"offset":440},"end":{"line":10,"column":296,"offset":462},"indent":[]}},{"type":"text","value":"), and by obtaining a purchased license. By installing and/or using any Product provided by the Licensor, You are confirming your acceptance of this agreement and you are agreeing to become bound by the terms of this agreement.","position":{"start":{"line":10,"column":296,"offset":462},"end":{"line":10,"column":523,"offset":689},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":167},"end":{"line":10,"column":523,"offset":689},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This EULA shall apply only to a Product supplied by the Licensor herewith regardless of whether other software or platform is referred to or described herein.","position":{"start":{"line":12,"column":1,"offset":691},"end":{"line":12,"column":159,"offset":849},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":691},"end":{"line":12,"column":159,"offset":849},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Products transacted through the Services are licensed, not sold, to You for use only under the terms of this license. The Application Provider reserves all rights not expressly granted to You. The Product that is subject to this license is referred to in this license as the “Licensed Application.” The Licensed Application is to be used on any operating system or machine (on-premise/cloud) and the aforementioned devices are referenced in this license as “Devices”.","position":{"start":{"line":14,"column":1,"offset":851},"end":{"line":14,"column":472,"offset":1322},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":851},"end":{"line":14,"column":472,"offset":1322},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"a. Scope of License: This license granted to You for the Licensed Application by Application Provider is limited to a non-transferable license to use the Licensed Application on any Devices that You own or control and as permitted by the Usage Rules. This license does not allow You to use the Licensed Application on any Devices that You do not own or control, and You may not distribute or make the Licensed Application available over a network where it could be used by multiple devices at the same time. You may not rent, lease, lend, sell, redistribute or sublicense the Licensed Application. You may not copy (except as expressly permitted by this license and the Usage Rules), decompile, reverse engineer, disassemble, attempt to derive the source code of, modify, or create derivative works of the Licensed Application, any updates, or any part thereof (except as and only to the extent any foregoing restriction is prohibited by applicable law or to the extent as may be permitted by the licensing terms governing use of any open sourced components included with the Licensed Application). Any attempt to do so is a violation of the rights of the Application Provider and its licensors. If You breach this restriction, You may be subject to prosecution and damages. The terms of the license will govern any upgrades provided by Application Provider that replace and/or supplement the original Product, unless such upgrade is accompanied by a separate license in which case the terms of that license will govern.","position":{"start":{"line":16,"column":1,"offset":1324},"end":{"line":16,"column":1521,"offset":2844},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":1324},"end":{"line":16,"column":1521,"offset":2844},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"b. Consent to Use of Data: You agree that Application Provider may collect and use technical data and related information, including but not limited to technical information about Your device, system and application software, and peripherals, that is gathered periodically to facilitate the provision of software updates, product support and other services to You (if any) related to the Licensed Application. Application Provider may use this information, as long as it is in a form that does not personally identify You, to improve its products or to provide services or technologies to You.","position":{"start":{"line":18,"column":1,"offset":2846},"end":{"line":18,"column":594,"offset":3439},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":2846},"end":{"line":18,"column":594,"offset":3439},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"c. Termination. The license is effective until terminated by You or Application Provider. Your rights under this license will terminate automatically without notice from the Application Provider if You fail to comply with any term(s) of this license. Upon termination of the license, You shall cease all use of the Licensed Application, and destroy all copies, full or partial, of the Licensed Application.","position":{"start":{"line":20,"column":1,"offset":3441},"end":{"line":20,"column":407,"offset":3847},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":3441},"end":{"line":20,"column":407,"offset":3847},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"d. Services; Third Party Materials. The Licensed Application may enable access to Application Provider’s and third party services and web sites (collectively and individually, “Services”). Use of the Services may require Internet access and that You accept additional terms of service.","position":{"start":{"line":22,"column":1,"offset":3849},"end":{"line":22,"column":286,"offset":4134},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":3849},"end":{"line":22,"column":286,"offset":4134},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You understand that by using any of the Services, You may encounter content that may be deemed offensive, indecent, or objectionable, which content may or may not be identified as having explicit language, and that the results of any search or entering of a particular URL may automatically and unintentionally generate links or references to objectionable material. Nevertheless, You agree to use the Services at Your sole risk and that the Application Provider shall not have any liability to You for content that may be found to be offensive, indecent, or objectionable.","position":{"start":{"line":24,"column":1,"offset":4136},"end":{"line":24,"column":574,"offset":4709},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":4136},"end":{"line":24,"column":574,"offset":4709},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Certain Services may display, include or make available content, data, information, applications or materials from third parties (“Third Party Materials”) or provide links to certain third party web sites. By using the Services, You acknowledge and agree that the Application Provider is not responsible for examining or evaluating the content, accuracy, completeness, timeliness, validity, copyright compliance, legality, decency, quality or any other aspect of such Third Party Materials or web sites. The Application Provider does not warrant or endorse and does not assume and will not have any liability or responsibility to You or any other person for any third-party Services, Third Party Materials or web sites, or for any other materials, products, or services of third parties. Third Party Materials and links to other web sites are provided solely as a convenience to You. Financial information displayed by any Services is for general informational purposes only and is not intended to be relied upon as investment advice. Before executing any securities transaction based upon information obtained through the Services, You should consult with a financial professional. Location data provided by any Services is for basic navigational purposes only and is not intended to be relied upon in situations where precise location information is needed or where erroneous, inaccurate or incomplete location data may lead to death, personal injury, property or environmental damage. Neither the Application Provider, nor any of its content providers, guarantees the availability, accuracy, completeness, reliability, or timeliness of stock information or location data displayed by any Services.","position":{"start":{"line":26,"column":1,"offset":4711},"end":{"line":26,"column":1701,"offset":6411},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":4711},"end":{"line":26,"column":1701,"offset":6411},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You agree that any Services contain proprietary content, information and material that is protected by applicable intellectual property and other laws, including but not limited to copyright, and that You will not use such proprietary content, information or materials in any way whatsoever except for permitted use of the Services. No portion of the Services may be reproduced in any form or by any means. You agree not to modify, rent, lease, loan, sell, distribute, or create derivative works based on the Services, in any manner, and You shall not exploit the Services in any unauthorized way whatsoever, including but not limited to, by trespass or burdening network capacity. You further agree not to use the Services in any manner to harass, abuse, stalk, threaten, defame or otherwise infringe or violate the rights of any other party, and that the Application Provider is not in any way responsible for any such use by You, nor for any harassing, threatening, defamatory, offensive or illegal messages or transmissions that You may receive as a result of using any of the Services.","position":{"start":{"line":28,"column":1,"offset":6413},"end":{"line":28,"column":1091,"offset":7503},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":6413},"end":{"line":28,"column":1091,"offset":7503},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"In addition, third party Services and Third Party Materials that may be accessed from, displayed on or linked to from the Devices are not available in all languages or in all countries. The Application Provider makes no representation that such Services and Materials are appropriate or available for use in any particular location. To the extent You choose to access such Services or Materials, You do so at Your own initiative and are responsible for compliance with any applicable laws, including but not limited to applicable local laws. The Application Provider, and its licensors, reserve the right to change, suspend, remove, or disable access to any Services at any time without notice. In no event will the Application Provider be liable for the removal of or disabling of access to any such Services. The Application Provider may also impose limits on the use of or access to certain Services, in any case and without notice or liability.","position":{"start":{"line":30,"column":1,"offset":7505},"end":{"line":30,"column":949,"offset":8453},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":7505},"end":{"line":30,"column":949,"offset":8453},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"e. No Warranty: You expressly acknowledge and agree that use of the licensed application is at your sole risk and that the entire risk as to satisfactory quality, performance, accuracy and effort is with you. To the maximum extent permitted by applicable law, the license application and any services performed or provided by the licensed application (“services”) are provided “as is” and “as available,” with all faults and without warranty of any kind, and application provider hereby disclaims all warranties and conditions with respect to the licensed application and any services, either express, implied or statutory, including, but not limited to, the implied warranties and/or conditions of merchantability, of satisfactory quality, of fitness for a particular purpose, of accuracy, of quiet enjoyment, and non-infringement of third party rights. Application provider does not warrant against interference with your enjoyment of the licensed application, that the functions contained in, or services performed or provided by, the licensed application will meet your requirements, that the operation of the licensed application or services will be uninterrupted or error-free, or that effects in the licensed application or services will be corrected. No oral or written information or advice given by application provider or its authorized representative shall create a warranty. Should the licensed application or services prove defective, you assume the entire cost of all necessary servicing, repair or correction. Some jurisdictions do not allow the exclusion of implied warranties or limitations on applicable statutory rights of a consumer, so the above exclusion and limitations may not apply to you.","position":{"start":{"line":32,"column":1,"offset":8455},"end":{"line":32,"column":1716,"offset":10170},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":8455},"end":{"line":32,"column":1716,"offset":10170},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"f. Limitation of Liability. To the extent not prohibited by law, in no event shall application provider be liable for personal injury, or any incidental, special, indirect or consequential damages whatsoever, including, without limitation, damages for loss of profits, loss of data, business interruption or any other commercial damages or losses, arising out of or related to your use or inability to use the licensed application, however caused, regardless of the theory of liability (contract, tort or otherwise) and even if application provider has been advised of the possibility of such damages. Some jurisdictions do not allow the limitation of liability for personal injury, or of incidental or consequential damages, so this limitation may not apply to you.","position":{"start":{"line":34,"column":1,"offset":10172},"end":{"line":34,"column":767,"offset":10938},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":10172},"end":{"line":34,"column":767,"offset":10938},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"In no event shall Application Provider’s total liability to you for all damages (other than as may be required by applicable law in cases involving personal injury) exceed the amount of fifty dollars ($50.00). The foregoing limitations will apply even if the above stated remedy fails of its essential purpose.","position":{"start":{"line":36,"column":1,"offset":10940},"end":{"line":36,"column":311,"offset":11250},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":10940},"end":{"line":36,"column":311,"offset":11250},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"g. You may not use or otherwise export or re-export the Licensed Application except as authorized by United States law and the laws of the jurisdiction in which the Licensed Application was obtained. In particular, but without limitation, the Licensed Application may not be exported or re-exported (a) into any U.S. embargoed countries or (b) to anyone on the U.S. Treasury Department’s list of Specially Designated Nationals or the U.S. Department of Commerce Denied Person’s List or Entity List. By using the Licensed Application, you represent and warrant that you are not located in any such country or on any such list. You also agree that you will not use these products for any purposes prohibited by United States law, including, without limitation, the development, design, manufacture or production of nuclear, missiles, or chemical or biological weapons.","position":{"start":{"line":38,"column":1,"offset":11252},"end":{"line":38,"column":867,"offset":12118},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":11252},"end":{"line":38,"column":867,"offset":12118},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"h. The Licensed Application and related documentation are “Commercial Items”, as that term is defined at 48 C.F.R. §2.101, consisting of “Commercial Computer Software” and “Commercial Computer Software Documentation”, as such terms are used in 48 C.F.R. §12.212 or 48 C.F.R. §227.7202, as applicable. Consistent with 48 C.F.R. §12.212 or 48 C.F.R. §227.7202-1 through 227.7202-4, as applicable, the Commercial Computer Software and Commercial Computer Software Documentation are being licensed to U.S. Government end users (a) only as Commercial Items and (b) with only those rights as are granted to all other end users pursuant to the terms and conditions herein. Unpublished-rights reserved under the copyright laws of the United States.","position":{"start":{"line":40,"column":1,"offset":12120},"end":{"line":40,"column":741,"offset":12860},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":12120},"end":{"line":40,"column":741,"offset":12860},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"i. The laws of the State of Belgium, excluding its conflicts of law rules, govern this license and your use of the Licensed Application. Your use of the Licensed Application may also be subject to other local, state, national, or international laws.","position":{"start":{"line":42,"column":1,"offset":12862},"end":{"line":42,"column":250,"offset":13111},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":12862},"end":{"line":42,"column":250,"offset":13111},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":45,"column":1,"offset":13114},"end":{"line":45,"column":31,"offset":13144},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":45,"column":31,"offset":13144}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`EULA`}

\n

{`This agreement (or “EULA”) is a legal agreement between the person, company or organization (“You”) that has licensed a software product (Kerberos Enterprise) and Verstraeten.io (“Licensor” or “Application Provider”). The Product is to be obtained only through Docker Hub (`}{`https://hub.docker.com`}{`), and by obtaining a purchased license. By installing and/or using any Product provided by the Licensor, You are confirming your acceptance of this agreement and you are agreeing to become bound by the terms of this agreement.`}

\n

{`This EULA shall apply only to a Product supplied by the Licensor herewith regardless of whether other software or platform is referred to or described herein.`}

\n

{`The Products transacted through the Services are licensed, not sold, to You for use only under the terms of this license. The Application Provider reserves all rights not expressly granted to You. The Product that is subject to this license is referred to in this license as the “Licensed Application.” The Licensed Application is to be used on any operating system or machine (on-premise/cloud) and the aforementioned devices are referenced in this license as “Devices”.`}

\n

{`a. Scope of License: This license granted to You for the Licensed Application by Application Provider is limited to a non-transferable license to use the Licensed Application on any Devices that You own or control and as permitted by the Usage Rules. This license does not allow You to use the Licensed Application on any Devices that You do not own or control, and You may not distribute or make the Licensed Application available over a network where it could be used by multiple devices at the same time. You may not rent, lease, lend, sell, redistribute or sublicense the Licensed Application. You may not copy (except as expressly permitted by this license and the Usage Rules), decompile, reverse engineer, disassemble, attempt to derive the source code of, modify, or create derivative works of the Licensed Application, any updates, or any part thereof (except as and only to the extent any foregoing restriction is prohibited by applicable law or to the extent as may be permitted by the licensing terms governing use of any open sourced components included with the Licensed Application). Any attempt to do so is a violation of the rights of the Application Provider and its licensors. If You breach this restriction, You may be subject to prosecution and damages. The terms of the license will govern any upgrades provided by Application Provider that replace and/or supplement the original Product, unless such upgrade is accompanied by a separate license in which case the terms of that license will govern.`}

\n

{`b. Consent to Use of Data: You agree that Application Provider may collect and use technical data and related information, including but not limited to technical information about Your device, system and application software, and peripherals, that is gathered periodically to facilitate the provision of software updates, product support and other services to You (if any) related to the Licensed Application. Application Provider may use this information, as long as it is in a form that does not personally identify You, to improve its products or to provide services or technologies to You.`}

\n

{`c. Termination. The license is effective until terminated by You or Application Provider. Your rights under this license will terminate automatically without notice from the Application Provider if You fail to comply with any term(s) of this license. Upon termination of the license, You shall cease all use of the Licensed Application, and destroy all copies, full or partial, of the Licensed Application.`}

\n

{`d. Services; Third Party Materials. The Licensed Application may enable access to Application Provider’s and third party services and web sites (collectively and individually, “Services”). Use of the Services may require Internet access and that You accept additional terms of service.`}

\n

{`You understand that by using any of the Services, You may encounter content that may be deemed offensive, indecent, or objectionable, which content may or may not be identified as having explicit language, and that the results of any search or entering of a particular URL may automatically and unintentionally generate links or references to objectionable material. Nevertheless, You agree to use the Services at Your sole risk and that the Application Provider shall not have any liability to You for content that may be found to be offensive, indecent, or objectionable.`}

\n

{`Certain Services may display, include or make available content, data, information, applications or materials from third parties (“Third Party Materials”) or provide links to certain third party web sites. By using the Services, You acknowledge and agree that the Application Provider is not responsible for examining or evaluating the content, accuracy, completeness, timeliness, validity, copyright compliance, legality, decency, quality or any other aspect of such Third Party Materials or web sites. The Application Provider does not warrant or endorse and does not assume and will not have any liability or responsibility to You or any other person for any third-party Services, Third Party Materials or web sites, or for any other materials, products, or services of third parties. Third Party Materials and links to other web sites are provided solely as a convenience to You. Financial information displayed by any Services is for general informational purposes only and is not intended to be relied upon as investment advice. Before executing any securities transaction based upon information obtained through the Services, You should consult with a financial professional. Location data provided by any Services is for basic navigational purposes only and is not intended to be relied upon in situations where precise location information is needed or where erroneous, inaccurate or incomplete location data may lead to death, personal injury, property or environmental damage. Neither the Application Provider, nor any of its content providers, guarantees the availability, accuracy, completeness, reliability, or timeliness of stock information or location data displayed by any Services.`}

\n

{`You agree that any Services contain proprietary content, information and material that is protected by applicable intellectual property and other laws, including but not limited to copyright, and that You will not use such proprietary content, information or materials in any way whatsoever except for permitted use of the Services. No portion of the Services may be reproduced in any form or by any means. You agree not to modify, rent, lease, loan, sell, distribute, or create derivative works based on the Services, in any manner, and You shall not exploit the Services in any unauthorized way whatsoever, including but not limited to, by trespass or burdening network capacity. You further agree not to use the Services in any manner to harass, abuse, stalk, threaten, defame or otherwise infringe or violate the rights of any other party, and that the Application Provider is not in any way responsible for any such use by You, nor for any harassing, threatening, defamatory, offensive or illegal messages or transmissions that You may receive as a result of using any of the Services.`}

\n

{`In addition, third party Services and Third Party Materials that may be accessed from, displayed on or linked to from the Devices are not available in all languages or in all countries. The Application Provider makes no representation that such Services and Materials are appropriate or available for use in any particular location. To the extent You choose to access such Services or Materials, You do so at Your own initiative and are responsible for compliance with any applicable laws, including but not limited to applicable local laws. The Application Provider, and its licensors, reserve the right to change, suspend, remove, or disable access to any Services at any time without notice. In no event will the Application Provider be liable for the removal of or disabling of access to any such Services. The Application Provider may also impose limits on the use of or access to certain Services, in any case and without notice or liability.`}

\n

{`e. No Warranty: You expressly acknowledge and agree that use of the licensed application is at your sole risk and that the entire risk as to satisfactory quality, performance, accuracy and effort is with you. To the maximum extent permitted by applicable law, the license application and any services performed or provided by the licensed application (“services”) are provided “as is” and “as available,” with all faults and without warranty of any kind, and application provider hereby disclaims all warranties and conditions with respect to the licensed application and any services, either express, implied or statutory, including, but not limited to, the implied warranties and/or conditions of merchantability, of satisfactory quality, of fitness for a particular purpose, of accuracy, of quiet enjoyment, and non-infringement of third party rights. Application provider does not warrant against interference with your enjoyment of the licensed application, that the functions contained in, or services performed or provided by, the licensed application will meet your requirements, that the operation of the licensed application or services will be uninterrupted or error-free, or that effects in the licensed application or services will be corrected. No oral or written information or advice given by application provider or its authorized representative shall create a warranty. Should the licensed application or services prove defective, you assume the entire cost of all necessary servicing, repair or correction. Some jurisdictions do not allow the exclusion of implied warranties or limitations on applicable statutory rights of a consumer, so the above exclusion and limitations may not apply to you.`}

\n

{`f. Limitation of Liability. To the extent not prohibited by law, in no event shall application provider be liable for personal injury, or any incidental, special, indirect or consequential damages whatsoever, including, without limitation, damages for loss of profits, loss of data, business interruption or any other commercial damages or losses, arising out of or related to your use or inability to use the licensed application, however caused, regardless of the theory of liability (contract, tort or otherwise) and even if application provider has been advised of the possibility of such damages. Some jurisdictions do not allow the limitation of liability for personal injury, or of incidental or consequential damages, so this limitation may not apply to you.`}

\n

{`In no event shall Application Provider’s total liability to you for all damages (other than as may be required by applicable law in cases involving personal injury) exceed the amount of fifty dollars ($50.00). The foregoing limitations will apply even if the above stated remedy fails of its essential purpose.`}

\n

{`g. You may not use or otherwise export or re-export the Licensed Application except as authorized by United States law and the laws of the jurisdiction in which the Licensed Application was obtained. In particular, but without limitation, the Licensed Application may not be exported or re-exported (a) into any U.S. embargoed countries or (b) to anyone on the U.S. Treasury Department’s list of Specially Designated Nationals or the U.S. Department of Commerce Denied Person’s List or Entity List. By using the Licensed Application, you represent and warrant that you are not located in any such country or on any such list. You also agree that you will not use these products for any purposes prohibited by United States law, including, without limitation, the development, design, manufacture or production of nuclear, missiles, or chemical or biological weapons.`}

\n

{`h. The Licensed Application and related documentation are “Commercial Items”, as that term is defined at 48 C.F.R. §2.101, consisting of “Commercial Computer Software” and “Commercial Computer Software Documentation”, as such terms are used in 48 C.F.R. §12.212 or 48 C.F.R. §227.7202, as applicable. Consistent with 48 C.F.R. §12.212 or 48 C.F.R. §227.7202-1 through 227.7202-4, as applicable, the Commercial Computer Software and Commercial Computer Software Documentation are being licensed to U.S. Government end users (a) only as Commercial Items and (b) with only those rights as are granted to all other end users pursuant to the terms and conditions herein. Unpublished-rights reserved under the copyright laws of the United States.`}

\n

{`i. The laws of the State of Belgium, excluding its conflicts of law rules, govern this license and your use of the Licensed Application. Your use of the Licensed Application may also be subject to other local, state, national, or international laws.`}

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974263000,"key":"gatsby-plugin-mdx-entire-payload-f17055d9de3dd3e1b964c60098526a6f-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"EULA","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":7,"offset":165},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":7,"offset":165},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This agreement (or “EULA”) is a legal agreement between the person, company or organization (“You”) that has licensed a software product (Kerberos Enterprise) and Verstraeten.io (“Licensor” or “Application Provider”). The Product is to be obtained only through Docker Hub (","position":{"start":{"line":10,"column":1,"offset":167},"end":{"line":10,"column":274,"offset":440},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com","children":[{"type":"text","value":"https://hub.docker.com","position":{"start":{"line":10,"column":274,"offset":440},"end":{"line":10,"column":296,"offset":462},"indent":[]}}],"position":{"start":{"line":10,"column":274,"offset":440},"end":{"line":10,"column":296,"offset":462},"indent":[]}},{"type":"text","value":"), and by obtaining a purchased license. By installing and/or using any Product provided by the Licensor, You are confirming your acceptance of this agreement and you are agreeing to become bound by the terms of this agreement.","position":{"start":{"line":10,"column":296,"offset":462},"end":{"line":10,"column":523,"offset":689},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":167},"end":{"line":10,"column":523,"offset":689},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This EULA shall apply only to a Product supplied by the Licensor herewith regardless of whether other software or platform is referred to or described herein.","position":{"start":{"line":12,"column":1,"offset":691},"end":{"line":12,"column":159,"offset":849},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":691},"end":{"line":12,"column":159,"offset":849},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Products transacted through the Services are licensed, not sold, to You for use only under the terms of this license. The Application Provider reserves all rights not expressly granted to You. The Product that is subject to this license is referred to in this license as the “Licensed Application.” The Licensed Application is to be used on any operating system or machine (on-premise/cloud) and the aforementioned devices are referenced in this license as “Devices”.","position":{"start":{"line":14,"column":1,"offset":851},"end":{"line":14,"column":472,"offset":1322},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":851},"end":{"line":14,"column":472,"offset":1322},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"a. Scope of License: This license granted to You for the Licensed Application by Application Provider is limited to a non-transferable license to use the Licensed Application on any Devices that You own or control and as permitted by the Usage Rules. This license does not allow You to use the Licensed Application on any Devices that You do not own or control, and You may not distribute or make the Licensed Application available over a network where it could be used by multiple devices at the same time. You may not rent, lease, lend, sell, redistribute or sublicense the Licensed Application. You may not copy (except as expressly permitted by this license and the Usage Rules), decompile, reverse engineer, disassemble, attempt to derive the source code of, modify, or create derivative works of the Licensed Application, any updates, or any part thereof (except as and only to the extent any foregoing restriction is prohibited by applicable law or to the extent as may be permitted by the licensing terms governing use of any open sourced components included with the Licensed Application). Any attempt to do so is a violation of the rights of the Application Provider and its licensors. If You breach this restriction, You may be subject to prosecution and damages. The terms of the license will govern any upgrades provided by Application Provider that replace and/or supplement the original Product, unless such upgrade is accompanied by a separate license in which case the terms of that license will govern.","position":{"start":{"line":16,"column":1,"offset":1324},"end":{"line":16,"column":1521,"offset":2844},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":1324},"end":{"line":16,"column":1521,"offset":2844},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"b. Consent to Use of Data: You agree that Application Provider may collect and use technical data and related information, including but not limited to technical information about Your device, system and application software, and peripherals, that is gathered periodically to facilitate the provision of software updates, product support and other services to You (if any) related to the Licensed Application. Application Provider may use this information, as long as it is in a form that does not personally identify You, to improve its products or to provide services or technologies to You.","position":{"start":{"line":18,"column":1,"offset":2846},"end":{"line":18,"column":594,"offset":3439},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":2846},"end":{"line":18,"column":594,"offset":3439},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"c. Termination. The license is effective until terminated by You or Application Provider. Your rights under this license will terminate automatically without notice from the Application Provider if You fail to comply with any term(s) of this license. Upon termination of the license, You shall cease all use of the Licensed Application, and destroy all copies, full or partial, of the Licensed Application.","position":{"start":{"line":20,"column":1,"offset":3441},"end":{"line":20,"column":407,"offset":3847},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":3441},"end":{"line":20,"column":407,"offset":3847},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"d. Services; Third Party Materials. The Licensed Application may enable access to Application Provider’s and third party services and web sites (collectively and individually, “Services”). Use of the Services may require Internet access and that You accept additional terms of service.","position":{"start":{"line":22,"column":1,"offset":3849},"end":{"line":22,"column":286,"offset":4134},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":3849},"end":{"line":22,"column":286,"offset":4134},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You understand that by using any of the Services, You may encounter content that may be deemed offensive, indecent, or objectionable, which content may or may not be identified as having explicit language, and that the results of any search or entering of a particular URL may automatically and unintentionally generate links or references to objectionable material. Nevertheless, You agree to use the Services at Your sole risk and that the Application Provider shall not have any liability to You for content that may be found to be offensive, indecent, or objectionable.","position":{"start":{"line":24,"column":1,"offset":4136},"end":{"line":24,"column":574,"offset":4709},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":4136},"end":{"line":24,"column":574,"offset":4709},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Certain Services may display, include or make available content, data, information, applications or materials from third parties (“Third Party Materials”) or provide links to certain third party web sites. By using the Services, You acknowledge and agree that the Application Provider is not responsible for examining or evaluating the content, accuracy, completeness, timeliness, validity, copyright compliance, legality, decency, quality or any other aspect of such Third Party Materials or web sites. The Application Provider does not warrant or endorse and does not assume and will not have any liability or responsibility to You or any other person for any third-party Services, Third Party Materials or web sites, or for any other materials, products, or services of third parties. Third Party Materials and links to other web sites are provided solely as a convenience to You. Financial information displayed by any Services is for general informational purposes only and is not intended to be relied upon as investment advice. Before executing any securities transaction based upon information obtained through the Services, You should consult with a financial professional. Location data provided by any Services is for basic navigational purposes only and is not intended to be relied upon in situations where precise location information is needed or where erroneous, inaccurate or incomplete location data may lead to death, personal injury, property or environmental damage. Neither the Application Provider, nor any of its content providers, guarantees the availability, accuracy, completeness, reliability, or timeliness of stock information or location data displayed by any Services.","position":{"start":{"line":26,"column":1,"offset":4711},"end":{"line":26,"column":1701,"offset":6411},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":4711},"end":{"line":26,"column":1701,"offset":6411},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You agree that any Services contain proprietary content, information and material that is protected by applicable intellectual property and other laws, including but not limited to copyright, and that You will not use such proprietary content, information or materials in any way whatsoever except for permitted use of the Services. No portion of the Services may be reproduced in any form or by any means. You agree not to modify, rent, lease, loan, sell, distribute, or create derivative works based on the Services, in any manner, and You shall not exploit the Services in any unauthorized way whatsoever, including but not limited to, by trespass or burdening network capacity. You further agree not to use the Services in any manner to harass, abuse, stalk, threaten, defame or otherwise infringe or violate the rights of any other party, and that the Application Provider is not in any way responsible for any such use by You, nor for any harassing, threatening, defamatory, offensive or illegal messages or transmissions that You may receive as a result of using any of the Services.","position":{"start":{"line":28,"column":1,"offset":6413},"end":{"line":28,"column":1091,"offset":7503},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":6413},"end":{"line":28,"column":1091,"offset":7503},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"In addition, third party Services and Third Party Materials that may be accessed from, displayed on or linked to from the Devices are not available in all languages or in all countries. The Application Provider makes no representation that such Services and Materials are appropriate or available for use in any particular location. To the extent You choose to access such Services or Materials, You do so at Your own initiative and are responsible for compliance with any applicable laws, including but not limited to applicable local laws. The Application Provider, and its licensors, reserve the right to change, suspend, remove, or disable access to any Services at any time without notice. In no event will the Application Provider be liable for the removal of or disabling of access to any such Services. The Application Provider may also impose limits on the use of or access to certain Services, in any case and without notice or liability.","position":{"start":{"line":30,"column":1,"offset":7505},"end":{"line":30,"column":949,"offset":8453},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":7505},"end":{"line":30,"column":949,"offset":8453},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"e. No Warranty: You expressly acknowledge and agree that use of the licensed application is at your sole risk and that the entire risk as to satisfactory quality, performance, accuracy and effort is with you. To the maximum extent permitted by applicable law, the license application and any services performed or provided by the licensed application (“services”) are provided “as is” and “as available,” with all faults and without warranty of any kind, and application provider hereby disclaims all warranties and conditions with respect to the licensed application and any services, either express, implied or statutory, including, but not limited to, the implied warranties and/or conditions of merchantability, of satisfactory quality, of fitness for a particular purpose, of accuracy, of quiet enjoyment, and non-infringement of third party rights. Application provider does not warrant against interference with your enjoyment of the licensed application, that the functions contained in, or services performed or provided by, the licensed application will meet your requirements, that the operation of the licensed application or services will be uninterrupted or error-free, or that effects in the licensed application or services will be corrected. No oral or written information or advice given by application provider or its authorized representative shall create a warranty. Should the licensed application or services prove defective, you assume the entire cost of all necessary servicing, repair or correction. Some jurisdictions do not allow the exclusion of implied warranties or limitations on applicable statutory rights of a consumer, so the above exclusion and limitations may not apply to you.","position":{"start":{"line":32,"column":1,"offset":8455},"end":{"line":32,"column":1716,"offset":10170},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":8455},"end":{"line":32,"column":1716,"offset":10170},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"f. Limitation of Liability. To the extent not prohibited by law, in no event shall application provider be liable for personal injury, or any incidental, special, indirect or consequential damages whatsoever, including, without limitation, damages for loss of profits, loss of data, business interruption or any other commercial damages or losses, arising out of or related to your use or inability to use the licensed application, however caused, regardless of the theory of liability (contract, tort or otherwise) and even if application provider has been advised of the possibility of such damages. Some jurisdictions do not allow the limitation of liability for personal injury, or of incidental or consequential damages, so this limitation may not apply to you.","position":{"start":{"line":34,"column":1,"offset":10172},"end":{"line":34,"column":767,"offset":10938},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":10172},"end":{"line":34,"column":767,"offset":10938},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"In no event shall Application Provider’s total liability to you for all damages (other than as may be required by applicable law in cases involving personal injury) exceed the amount of fifty dollars ($50.00). The foregoing limitations will apply even if the above stated remedy fails of its essential purpose.","position":{"start":{"line":36,"column":1,"offset":10940},"end":{"line":36,"column":311,"offset":11250},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":10940},"end":{"line":36,"column":311,"offset":11250},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"g. You may not use or otherwise export or re-export the Licensed Application except as authorized by United States law and the laws of the jurisdiction in which the Licensed Application was obtained. In particular, but without limitation, the Licensed Application may not be exported or re-exported (a) into any U.S. embargoed countries or (b) to anyone on the U.S. Treasury Department’s list of Specially Designated Nationals or the U.S. Department of Commerce Denied Person’s List or Entity List. By using the Licensed Application, you represent and warrant that you are not located in any such country or on any such list. You also agree that you will not use these products for any purposes prohibited by United States law, including, without limitation, the development, design, manufacture or production of nuclear, missiles, or chemical or biological weapons.","position":{"start":{"line":38,"column":1,"offset":11252},"end":{"line":38,"column":867,"offset":12118},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":11252},"end":{"line":38,"column":867,"offset":12118},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"h. The Licensed Application and related documentation are “Commercial Items”, as that term is defined at 48 C.F.R. §2.101, consisting of “Commercial Computer Software” and “Commercial Computer Software Documentation”, as such terms are used in 48 C.F.R. §12.212 or 48 C.F.R. §227.7202, as applicable. Consistent with 48 C.F.R. §12.212 or 48 C.F.R. §227.7202-1 through 227.7202-4, as applicable, the Commercial Computer Software and Commercial Computer Software Documentation are being licensed to U.S. Government end users (a) only as Commercial Items and (b) with only those rights as are granted to all other end users pursuant to the terms and conditions herein. Unpublished-rights reserved under the copyright laws of the United States.","position":{"start":{"line":40,"column":1,"offset":12120},"end":{"line":40,"column":741,"offset":12860},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":12120},"end":{"line":40,"column":741,"offset":12860},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"i. The laws of the State of Belgium, excluding its conflicts of law rules, govern this license and your use of the Licensed Application. Your use of the Licensed Application may also be subject to other local, state, national, or international laws.","position":{"start":{"line":42,"column":1,"offset":12862},"end":{"line":42,"column":250,"offset":13111},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":12862},"end":{"line":42,"column":250,"offset":13111},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":45,"column":1,"offset":13114},"end":{"line":45,"column":31,"offset":13144},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":45,"column":31,"offset":13144}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`EULA`}

\n

{`This agreement (or “EULA”) is a legal agreement between the person, company or organization (“You”) that has licensed a software product (Kerberos Enterprise) and Verstraeten.io (“Licensor” or “Application Provider”). The Product is to be obtained only through Docker Hub (`}{`https://hub.docker.com`}{`), and by obtaining a purchased license. By installing and/or using any Product provided by the Licensor, You are confirming your acceptance of this agreement and you are agreeing to become bound by the terms of this agreement.`}

\n

{`This EULA shall apply only to a Product supplied by the Licensor herewith regardless of whether other software or platform is referred to or described herein.`}

\n

{`The Products transacted through the Services are licensed, not sold, to You for use only under the terms of this license. The Application Provider reserves all rights not expressly granted to You. The Product that is subject to this license is referred to in this license as the “Licensed Application.” The Licensed Application is to be used on any operating system or machine (on-premise/cloud) and the aforementioned devices are referenced in this license as “Devices”.`}

\n

{`a. Scope of License: This license granted to You for the Licensed Application by Application Provider is limited to a non-transferable license to use the Licensed Application on any Devices that You own or control and as permitted by the Usage Rules. This license does not allow You to use the Licensed Application on any Devices that You do not own or control, and You may not distribute or make the Licensed Application available over a network where it could be used by multiple devices at the same time. You may not rent, lease, lend, sell, redistribute or sublicense the Licensed Application. You may not copy (except as expressly permitted by this license and the Usage Rules), decompile, reverse engineer, disassemble, attempt to derive the source code of, modify, or create derivative works of the Licensed Application, any updates, or any part thereof (except as and only to the extent any foregoing restriction is prohibited by applicable law or to the extent as may be permitted by the licensing terms governing use of any open sourced components included with the Licensed Application). Any attempt to do so is a violation of the rights of the Application Provider and its licensors. If You breach this restriction, You may be subject to prosecution and damages. The terms of the license will govern any upgrades provided by Application Provider that replace and/or supplement the original Product, unless such upgrade is accompanied by a separate license in which case the terms of that license will govern.`}

\n

{`b. Consent to Use of Data: You agree that Application Provider may collect and use technical data and related information, including but not limited to technical information about Your device, system and application software, and peripherals, that is gathered periodically to facilitate the provision of software updates, product support and other services to You (if any) related to the Licensed Application. Application Provider may use this information, as long as it is in a form that does not personally identify You, to improve its products or to provide services or technologies to You.`}

\n

{`c. Termination. The license is effective until terminated by You or Application Provider. Your rights under this license will terminate automatically without notice from the Application Provider if You fail to comply with any term(s) of this license. Upon termination of the license, You shall cease all use of the Licensed Application, and destroy all copies, full or partial, of the Licensed Application.`}

\n

{`d. Services; Third Party Materials. The Licensed Application may enable access to Application Provider’s and third party services and web sites (collectively and individually, “Services”). Use of the Services may require Internet access and that You accept additional terms of service.`}

\n

{`You understand that by using any of the Services, You may encounter content that may be deemed offensive, indecent, or objectionable, which content may or may not be identified as having explicit language, and that the results of any search or entering of a particular URL may automatically and unintentionally generate links or references to objectionable material. Nevertheless, You agree to use the Services at Your sole risk and that the Application Provider shall not have any liability to You for content that may be found to be offensive, indecent, or objectionable.`}

\n

{`Certain Services may display, include or make available content, data, information, applications or materials from third parties (“Third Party Materials”) or provide links to certain third party web sites. By using the Services, You acknowledge and agree that the Application Provider is not responsible for examining or evaluating the content, accuracy, completeness, timeliness, validity, copyright compliance, legality, decency, quality or any other aspect of such Third Party Materials or web sites. The Application Provider does not warrant or endorse and does not assume and will not have any liability or responsibility to You or any other person for any third-party Services, Third Party Materials or web sites, or for any other materials, products, or services of third parties. Third Party Materials and links to other web sites are provided solely as a convenience to You. Financial information displayed by any Services is for general informational purposes only and is not intended to be relied upon as investment advice. Before executing any securities transaction based upon information obtained through the Services, You should consult with a financial professional. Location data provided by any Services is for basic navigational purposes only and is not intended to be relied upon in situations where precise location information is needed or where erroneous, inaccurate or incomplete location data may lead to death, personal injury, property or environmental damage. Neither the Application Provider, nor any of its content providers, guarantees the availability, accuracy, completeness, reliability, or timeliness of stock information or location data displayed by any Services.`}

\n

{`You agree that any Services contain proprietary content, information and material that is protected by applicable intellectual property and other laws, including but not limited to copyright, and that You will not use such proprietary content, information or materials in any way whatsoever except for permitted use of the Services. No portion of the Services may be reproduced in any form or by any means. You agree not to modify, rent, lease, loan, sell, distribute, or create derivative works based on the Services, in any manner, and You shall not exploit the Services in any unauthorized way whatsoever, including but not limited to, by trespass or burdening network capacity. You further agree not to use the Services in any manner to harass, abuse, stalk, threaten, defame or otherwise infringe or violate the rights of any other party, and that the Application Provider is not in any way responsible for any such use by You, nor for any harassing, threatening, defamatory, offensive or illegal messages or transmissions that You may receive as a result of using any of the Services.`}

\n

{`In addition, third party Services and Third Party Materials that may be accessed from, displayed on or linked to from the Devices are not available in all languages or in all countries. The Application Provider makes no representation that such Services and Materials are appropriate or available for use in any particular location. To the extent You choose to access such Services or Materials, You do so at Your own initiative and are responsible for compliance with any applicable laws, including but not limited to applicable local laws. The Application Provider, and its licensors, reserve the right to change, suspend, remove, or disable access to any Services at any time without notice. In no event will the Application Provider be liable for the removal of or disabling of access to any such Services. The Application Provider may also impose limits on the use of or access to certain Services, in any case and without notice or liability.`}

\n

{`e. No Warranty: You expressly acknowledge and agree that use of the licensed application is at your sole risk and that the entire risk as to satisfactory quality, performance, accuracy and effort is with you. To the maximum extent permitted by applicable law, the license application and any services performed or provided by the licensed application (“services”) are provided “as is” and “as available,” with all faults and without warranty of any kind, and application provider hereby disclaims all warranties and conditions with respect to the licensed application and any services, either express, implied or statutory, including, but not limited to, the implied warranties and/or conditions of merchantability, of satisfactory quality, of fitness for a particular purpose, of accuracy, of quiet enjoyment, and non-infringement of third party rights. Application provider does not warrant against interference with your enjoyment of the licensed application, that the functions contained in, or services performed or provided by, the licensed application will meet your requirements, that the operation of the licensed application or services will be uninterrupted or error-free, or that effects in the licensed application or services will be corrected. No oral or written information or advice given by application provider or its authorized representative shall create a warranty. Should the licensed application or services prove defective, you assume the entire cost of all necessary servicing, repair or correction. Some jurisdictions do not allow the exclusion of implied warranties or limitations on applicable statutory rights of a consumer, so the above exclusion and limitations may not apply to you.`}

\n

{`f. Limitation of Liability. To the extent not prohibited by law, in no event shall application provider be liable for personal injury, or any incidental, special, indirect or consequential damages whatsoever, including, without limitation, damages for loss of profits, loss of data, business interruption or any other commercial damages or losses, arising out of or related to your use or inability to use the licensed application, however caused, regardless of the theory of liability (contract, tort or otherwise) and even if application provider has been advised of the possibility of such damages. Some jurisdictions do not allow the limitation of liability for personal injury, or of incidental or consequential damages, so this limitation may not apply to you.`}

\n

{`In no event shall Application Provider’s total liability to you for all damages (other than as may be required by applicable law in cases involving personal injury) exceed the amount of fifty dollars ($50.00). The foregoing limitations will apply even if the above stated remedy fails of its essential purpose.`}

\n

{`g. You may not use or otherwise export or re-export the Licensed Application except as authorized by United States law and the laws of the jurisdiction in which the Licensed Application was obtained. In particular, but without limitation, the Licensed Application may not be exported or re-exported (a) into any U.S. embargoed countries or (b) to anyone on the U.S. Treasury Department’s list of Specially Designated Nationals or the U.S. Department of Commerce Denied Person’s List or Entity List. By using the Licensed Application, you represent and warrant that you are not located in any such country or on any such list. You also agree that you will not use these products for any purposes prohibited by United States law, including, without limitation, the development, design, manufacture or production of nuclear, missiles, or chemical or biological weapons.`}

\n

{`h. The Licensed Application and related documentation are “Commercial Items”, as that term is defined at 48 C.F.R. §2.101, consisting of “Commercial Computer Software” and “Commercial Computer Software Documentation”, as such terms are used in 48 C.F.R. §12.212 or 48 C.F.R. §227.7202, as applicable. Consistent with 48 C.F.R. §12.212 or 48 C.F.R. §227.7202-1 through 227.7202-4, as applicable, the Commercial Computer Software and Commercial Computer Software Documentation are being licensed to U.S. Government end users (a) only as Commercial Items and (b) with only those rights as are granted to all other end users pursuant to the terms and conditions herein. Unpublished-rights reserved under the copyright laws of the United States.`}

\n

{`i. The laws of the State of Belgium, excluding its conflicts of law rules, govern this license and your use of the Licensed Application. Your use of the Licensed Application may also be subject to other local, state, national, or international laws.`}

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-1d35799b0fd4a99ff0dbdd3b2f81aebf.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-1d35799b0fd4a99ff0dbdd3b2f81aebf.json index 50bf304..4dba58c 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-1d35799b0fd4a99ff0dbdd3b2f81aebf.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-1d35799b0fd4a99ff0dbdd3b2f81aebf.json @@ -1 +1 @@ -{"expireTime":9007200841014164000,"key":"gatsby-plugin-mdx-entire-payload-13c4772d8dccd98e23ab4094aa241345-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Contribute","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":13,"offset":171},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":13,"offset":171},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"In this document we describe the different things you need to know if you would like to add a new feature to Kerberos Open Source, or change some of its behaviour for your own use case.","position":{"start":{"line":10,"column":1,"offset":173},"end":{"line":10,"column":186,"offset":358},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":173},"end":{"line":10,"column":186,"offset":358},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before starting, as you might have read already, you need to know that Kerberos Open Source consists of two solutions. A front-end, also called ","position":{"start":{"line":12,"column":1,"offset":360},"end":{"line":12,"column":145,"offset":504},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"web","position":{"start":{"line":12,"column":147,"offset":506},"end":{"line":12,"column":150,"offset":509},"indent":[]}}],"position":{"start":{"line":12,"column":145,"offset":504},"end":{"line":12,"column":152,"offset":511},"indent":[]}},{"type":"text","value":", which allows you to review the recordings and to configure the back-end settings. A back-end, also called ","position":{"start":{"line":12,"column":152,"offset":511},"end":{"line":12,"column":260,"offset":619},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"machinery","position":{"start":{"line":12,"column":262,"offset":621},"end":{"line":12,"column":271,"offset":630},"indent":[]}}],"position":{"start":{"line":12,"column":260,"offset":619},"end":{"line":12,"column":273,"offset":632},"indent":[]}},{"type":"text","value":", which is computer vision solution that processes the video stream of surveillance camera.","position":{"start":{"line":12,"column":273,"offset":632},"end":{"line":12,"column":364,"offset":723},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":360},"end":{"line":12,"column":364,"offset":723},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you start changing or adding features to Kerberos Open Source, there is a big chance you will need to modify the previously mentioned solutions. That's why we will discuss how you can contribute to one or both solutions.","position":{"start":{"line":14,"column":1,"offset":725},"end":{"line":14,"column":226,"offset":950},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":725},"end":{"line":14,"column":226,"offset":950},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":16,"column":4,"offset":955},"end":{"line":16,"column":13,"offset":964},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":952},"end":{"line":16,"column":13,"offset":964},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Contributing to the ","position":{"start":{"line":18,"column":1,"offset":966},"end":{"line":18,"column":21,"offset":986},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery","children":[{"type":"text","value":"machinery repository","position":{"start":{"line":18,"column":22,"offset":987},"end":{"line":18,"column":42,"offset":1007},"indent":[]}}],"position":{"start":{"line":18,"column":21,"offset":986},"end":{"line":18,"column":85,"offset":1050},"indent":[]}},{"type":"text","value":" requires C++ skills. This section describes all the technical stuff you will need to know. If you want to contribute, the first thing you will need to do is installing the source code on your working station.","position":{"start":{"line":18,"column":85,"offset":1050},"end":{"line":18,"column":294,"offset":1259},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":966},"end":{"line":18,"column":294,"offset":1259},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":20,"column":5,"offset":1265},"end":{"line":20,"column":18,"offset":1278},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":1261},"end":{"line":20,"column":18,"offset":1278},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"A Linux OS, or Mac OSX (Window is not supported).","position":{"start":{"line":22,"column":3,"offset":1282},"end":{"line":22,"column":52,"offset":1331},"indent":[]}}],"position":{"start":{"line":22,"column":3,"offset":1282},"end":{"line":22,"column":52,"offset":1331},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1280},"end":{"line":22,"column":52,"offset":1331},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Installation","position":{"start":{"line":24,"column":5,"offset":1337},"end":{"line":24,"column":17,"offset":1349},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1333},"end":{"line":24,"column":17,"offset":1349},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The complete installation can be found on the advanced installation page, describing the complete set of instructions. However for simplicity we will give a summarized version, as probably you will already have a development environment set up.","position":{"start":{"line":26,"column":1,"offset":1351},"end":{"line":26,"column":245,"offset":1595},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1351},"end":{"line":26,"column":245,"offset":1595},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install development tools (C++, CMake) and V4L utils, and clone the repository. Compile the project using cmake and make.","position":{"start":{"line":28,"column":1,"offset":1597},"end":{"line":28,"column":122,"offset":1718},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":1597},"end":{"line":28,"column":122,"offset":1718},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev\ncd && sudo git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":30,"column":1,"offset":1720},"end":{"line":36,"column":4,"offset":2029},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Testing","position":{"start":{"line":38,"column":5,"offset":2035},"end":{"line":38,"column":12,"offset":2042},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":2031},"end":{"line":38,"column":12,"offset":2042},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"We strongly recommend testing as a best practice in complex projects. Therefore the machinery uses the popular C++ test library: Google Test and Google Mock. The tests can be found in the test directory. You can run the test by executing following command:","position":{"start":{"line":40,"column":1,"offset":2044},"end":{"line":40,"column":257,"offset":2300},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":2044},"end":{"line":40,"column":257,"offset":2300},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"make check","position":{"start":{"line":42,"column":1,"offset":2302},"end":{"line":44,"column":4,"offset":2322},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Adding a new class","position":{"start":{"line":46,"column":5,"offset":2328},"end":{"line":46,"column":23,"offset":2346},"indent":[]}}],"position":{"start":{"line":46,"column":1,"offset":2324},"end":{"line":46,"column":23,"offset":2346},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This paragraph will tell you how to create a new condition, algorithm, expositor, io or capture device. For simplicity we will show how to create a new algorithm; the steps are identical if you want to create for example a new capture device; only the directory will differ.","position":{"start":{"line":48,"column":1,"offset":2348},"end":{"line":48,"column":275,"offset":2622},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2348},"end":{"line":48,"column":275,"offset":2622},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Create the header file","position":{"start":{"line":50,"column":6,"offset":2629},"end":{"line":50,"column":28,"offset":2651},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":2624},"end":{"line":50,"column":28,"offset":2651},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"First we will need to create a new header file in the include/kerberos/machinery/algorithm directory. You can copy an existing algorithm header file, and start from there. You will end up with the following header file:","position":{"start":{"line":52,"column":1,"offset":2653},"end":{"line":52,"column":220,"offset":2872},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2653},"end":{"line":52,"column":220,"offset":2872},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"//\n// Class: AnotherAlgorithm\n// Description: Another algorithm\n// Created: ...\n// Author: ...\n// Mail: ...\n// Website: ...\n//\n// The copyright to the computer program(s) herein\n// is the property of kerberos.io, Belgium.\n// The program(s) may be used and/or copied .\n//\n/////////////////////////////////////////////////////\n#ifndef __AnotherAlgorithm_H_INCLUDED__ // if AnotherAlgorithm.h hasn't been included yet...\n#define __AnotherAlgorithm_H_INCLUDED__ // #define this so the compiler knows it has been included\n#include \"machinery/algorithm/Algorithm.h\"\nnamespace kerberos\n{\n\tchar AnotherAlgorithmName[] = \"AnotherAlgorithm\";\n\tclass AnotherAlgorithm : public AlgorithmCreator\n\t{\n \tprivate:\n \t\tImage m_result;\n \tint m_parameter;\n \tpublic:\n \tAnotherAlgorithm(){}\n \tvoid setup(const StringMap & settings);\n \tvoid initialize(ImageVector & images);\n \tImage evaluate(ImageVector & images, JSON & data);\n \tvoid setParameter(int parameter);\n\t};\n}\n#endif","position":{"start":{"line":54,"column":1,"offset":2874},"end":{"line":88,"column":4,"offset":3959},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When creating a new class you will need to inherit from it corresponding creator, for the algorithm example: AlgorithmCreator. The creator class requires two template parameters. The first one is a unique name for the class, this name will be used to make some kind of dependency injection possible; and is used in the configurations files. The second parameter is the class itself.","position":{"start":{"line":90,"column":1,"offset":3961},"end":{"line":90,"column":383,"offset":4343},"indent":[]}}],"position":{"start":{"line":90,"column":1,"offset":3961},"end":{"line":90,"column":383,"offset":4343},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The inheritance of the creator class can be a little bit strange, but it is required and needed to register the class automatically with the factory. When the code gets compiled, the classes will be automatically registered with the factory, and you can create instances of those classes by using the name we've defined in the first template parameter. For example we could create a new instance of our previously created class with the following command.","position":{"start":{"line":92,"column":1,"offset":4345},"end":{"line":92,"column":456,"offset":4800},"indent":[]}}],"position":{"start":{"line":92,"column":1,"offset":4345},"end":{"line":92,"column":456,"offset":4800},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Algorithm * anotherAlgorithm = Factory::getInstance()->create(\"AnotherAlgorithm\");","position":{"start":{"line":94,"column":1,"offset":4802},"end":{"line":96,"column":4,"offset":4905},"indent":[1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Create the source file","position":{"start":{"line":98,"column":6,"offset":4912},"end":{"line":98,"column":28,"offset":4934},"indent":[]}}],"position":{"start":{"line":98,"column":1,"offset":4907},"end":{"line":98,"column":28,"offset":4934},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Ofcourse we also need to have an implementation file, therefore we need to create a new source file in the src/kerberos/machinery/algorithm directory. Just like the previous example, you can copy an existing class and implement the member functions you've declared in the header file. An example would be:","position":{"start":{"line":100,"column":1,"offset":4936},"end":{"line":100,"column":306,"offset":5241},"indent":[]}}],"position":{"start":{"line":100,"column":1,"offset":4936},"end":{"line":100,"column":306,"offset":5241},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#include \"machinery/algorithm/AnotherAlgorithm.h\"\nnamespace kerberos\n{\n void AnotherAlgorithm::setup(const StringMap & settings)\n {\n Algorithm::setup(settings);\n int parameter = std::atoi(settings.at(\"algorithms.AnotherAlgorithm.parameter\").c_str());\n setParameter(parameter);\n }\n void AnotherAlgorithm::initialize(ImageVector & images)\n {\n ....\n }\n Image AnotherAlgorithm::evaluate(ImageVector & images, JSON & data)\n {\n Image evaluation;\n ... do something ..\n return evaluation;\n }\n void AnotherAlgorithm::setParameter(int parameter)\n {\n m_parameter = parameter;\n }\n}","position":{"start":{"line":102,"column":1,"offset":5243},"end":{"line":127,"column":4,"offset":5914},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Modify the CMakeLists.txt file","position":{"start":{"line":129,"column":6,"offset":5921},"end":{"line":129,"column":36,"offset":5951},"indent":[]}}],"position":{"start":{"line":129,"column":1,"offset":5916},"end":{"line":129,"column":36,"offset":5951},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Open the CMakeLists.txt in the src/kerberos directory file and append the name of the algorithm class to the KERBEROS_FACTORY_ENTITIES variable; for example machinery/algorithm/AnotherAlgorithm.cpp.","position":{"start":{"line":131,"column":1,"offset":5953},"end":{"line":131,"column":199,"offset":6151},"indent":[]}}],"position":{"start":{"line":131,"column":1,"offset":5953},"end":{"line":131,"column":199,"offset":6151},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"# -------------------------------------------------------\n# Entities that have to be registered with the factory\n# - classes are registered on compile time, so they\n# don't belong to a library. New algorithms, expositors\n# or Io classes belong here.\nset(KERBEROS_FACTORY_ENTITIES\n capture/USBCamera.cpp\n machinery/condition/Time.cpp\n machinery/condition/Enabled.cpp\n machinery/algorithm/DifferentialCollins.cpp\n machinery/algorithm/DifferentialCollinsWithColor.cpp\n machinery/algorithm/AnotherAlgorithm.cpp\n machinery/expositor/RectangleExpositor.cpp\n machinery/expositor/HullExpositor.cpp\n machinery/heuristic/Sequence.cpp\n machinery/io/IoDisk.cpp\n machinery/io/IoTCP.cpp\n machinery/io/IoMongoDB.cpp\n)","position":{"start":{"line":133,"column":1,"offset":6153},"end":{"line":153,"column":4,"offset":6907},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Create a new entry in the config file","position":{"start":{"line":155,"column":6,"offset":6914},"end":{"line":155,"column":43,"offset":6951},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":6909},"end":{"line":155,"column":43,"offset":6951},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Open the algorithm.xml file in the config directory, and add a new tag with exactly the same name you've used in the header file; so in our example \"AnotherAlgorithm\". Within the new tag we can add properties that we will be use to configure our algorithm, in our example we defined a field parameter so we can add this field in the config file.","position":{"start":{"line":157,"column":1,"offset":6953},"end":{"line":157,"column":346,"offset":7298},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6953},"end":{"line":157,"column":346,"offset":7298},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"One thing you will need to do is to attach a type to a property. The type will be used by the web to automatically render the properties. For simplicity we can use the type number, this will show an input box on the settings page of the web where we are able to add numbers.","position":{"start":{"line":159,"column":1,"offset":7300},"end":{"line":159,"column":275,"offset":7574},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":7300},"end":{"line":159,"column":275,"offset":7574},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"\n\t\n\t\t5\n \n","position":{"start":{"line":161,"column":1,"offset":7576},"end":{"line":167,"column":4,"offset":7697},"indent":[1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"You can retrieve the parameter in the setup function with the settings parameter.","position":{"start":{"line":169,"column":1,"offset":7699},"end":{"line":169,"column":82,"offset":7780},"indent":[]}}],"position":{"start":{"line":169,"column":1,"offset":7699},"end":{"line":169,"column":82,"offset":7780},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"settings.at(\"algorithms.AnotherAlgorithm.parameter\")","position":{"start":{"line":171,"column":1,"offset":7782},"end":{"line":173,"column":4,"offset":7844},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Compile","position":{"start":{"line":175,"column":5,"offset":7850},"end":{"line":175,"column":12,"offset":7857},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7846},"end":{"line":175,"column":12,"offset":7857},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Hurray, we've made it! So now you can compile the code again, and if you're using an IDE don't forget to include the new source file! If you are compiling from the command-line you just have to go to the build folder and write make.","position":{"start":{"line":177,"column":1,"offset":7859},"end":{"line":177,"column":233,"offset":8091},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7859},"end":{"line":177,"column":233,"offset":8091},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Web","position":{"start":{"line":179,"column":4,"offset":8096},"end":{"line":179,"column":7,"offset":8099},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":8093},"end":{"line":179,"column":7,"offset":8099},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Contributing to ","position":{"start":{"line":181,"column":1,"offset":8101},"end":{"line":181,"column":17,"offset":8117},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web","children":[{"type":"text","value":"the web repository","position":{"start":{"line":181,"column":18,"offset":8118},"end":{"line":181,"column":36,"offset":8136},"indent":[]}}],"position":{"start":{"line":181,"column":17,"offset":8117},"end":{"line":181,"column":73,"offset":8173},"indent":[]}},{"type":"text","value":" requires both front- and back-end skillls, more precisely BackboneJS (JavaScript) and Laravel 5.4 (PHP).","position":{"start":{"line":181,"column":73,"offset":8173},"end":{"line":181,"column":178,"offset":8278},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":8101},"end":{"line":181,"column":178,"offset":8278},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":183,"column":5,"offset":8284},"end":{"line":183,"column":18,"offset":8297},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":8280},"end":{"line":183,"column":18,"offset":8297},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Make sure you have following services installed on your working station.","position":{"start":{"line":185,"column":1,"offset":8299},"end":{"line":185,"column":73,"offset":8371},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":8299},"end":{"line":185,"column":73,"offset":8371},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":">","position":{"start":{"line":187,"column":2,"offset":8374},"end":{"line":187,"column":4,"offset":8376},"indent":[]}},{"type":"text","value":"= PHP 7.1.0, NodeJS and NPM and Nginx or Apache","position":{"start":{"line":187,"column":4,"offset":8376},"end":{"line":187,"column":51,"offset":8423},"indent":[]}}],"position":{"start":{"line":187,"column":2,"offset":8374},"end":{"line":187,"column":51,"offset":8423},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":8373},"end":{"line":187,"column":51,"offset":8423},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Installation","position":{"start":{"line":189,"column":5,"offset":8429},"end":{"line":189,"column":17,"offset":8441},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":8425},"end":{"line":189,"column":17,"offset":8441},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Clone the repository to your working station.","position":{"start":{"line":191,"column":1,"offset":8443},"end":{"line":191,"column":46,"offset":8488},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":8443},"end":{"line":191,"column":46,"offset":8488},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/kerberos-io/web\ncd web","position":{"start":{"line":193,"column":1,"offset":8490},"end":{"line":196,"column":4,"offset":8551},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP libraries using the dependency mananger, ","position":{"start":{"line":198,"column":1,"offset":8553},"end":{"line":198,"column":58,"offset":8610},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Composer","position":{"start":{"line":198,"column":60,"offset":8612},"end":{"line":198,"column":68,"offset":8620},"indent":[]}}],"position":{"start":{"line":198,"column":58,"offset":8610},"end":{"line":198,"column":70,"offset":8622},"indent":[]}},{"type":"text","value":". If you haven't installed composer execute following commands.","position":{"start":{"line":198,"column":70,"offset":8622},"end":{"line":198,"column":133,"offset":8685},"indent":[]}}],"position":{"start":{"line":198,"column":1,"offset":8553},"end":{"line":198,"column":133,"offset":8685},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"php -r \"readfile('https://getcomposer.org/installer');\" > composer-setup.php\nphp -r \"if (hash('SHA384', file_get_contents('composer-setup.php')) === '41e71d86b40f28e771d4bb662b997f79625196afcca95a5abf44391188c695c6c1456e16154c75a211d238cc3bc5cb47') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;\"\nphp composer-setup.php\nphp -r \"unlink('composer-setup.php');\"","position":{"start":{"line":200,"column":1,"offset":8687},"end":{"line":205,"column":4,"offset":9118},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After a succesful installation, you can run composer install or composer update from the root of the project. All dependencies will be installed or updated if a newer version is detected.","position":{"start":{"line":207,"column":1,"offset":9120},"end":{"line":207,"column":188,"offset":9307},"indent":[]}}],"position":{"start":{"line":207,"column":1,"offset":9120},"end":{"line":207,"column":188,"offset":9307},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"composer update","position":{"start":{"line":209,"column":1,"offset":9309},"end":{"line":211,"column":4,"offset":9334},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Besides PHP, the project also relies on BackboneJS (Javascript) for the front-end. Therefore a couple JavaScript dependencies should be installed.","position":{"start":{"line":213,"column":1,"offset":9336},"end":{"line":213,"column":147,"offset":9482},"indent":[]}}],"position":{"start":{"line":213,"column":1,"offset":9336},"end":{"line":213,"column":147,"offset":9482},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"npm -g install bower\ncd public\nbower update","position":{"start":{"line":215,"column":1,"offset":9484},"end":{"line":219,"column":4,"offset":9537},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When everything is installed properly, you need too link the web project with your applicationn server. Read more on the ","position":{"start":{"line":221,"column":1,"offset":9539},"end":{"line":221,"column":122,"offset":9660},"indent":[]}},{"type":"link","title":null,"url":"https://laravel.com/docs/5.8/deployment","children":[{"type":"text","value":"Laravel documentation website","position":{"start":{"line":221,"column":123,"offset":9661},"end":{"line":221,"column":152,"offset":9690},"indent":[]}}],"position":{"start":{"line":221,"column":122,"offset":9660},"end":{"line":221,"column":194,"offset":9732},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":221,"column":194,"offset":9732},"end":{"line":221,"column":195,"offset":9733},"indent":[]}}],"position":{"start":{"line":221,"column":1,"offset":9539},"end":{"line":221,"column":195,"offset":9733},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":224,"column":1,"offset":9736},"end":{"line":224,"column":31,"offset":9766},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":224,"column":31,"offset":9766}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Contribute`}

\n

{`In this document we describe the different things you need to know if you would like to add a new feature to Kerberos Open Source, or change some of its behaviour for your own use case.`}

\n

{`Before starting, as you might have read already, you need to know that Kerberos Open Source consists of two solutions. A front-end, also called `}{`web`}{`, which allows you to review the recordings and to configure the back-end settings. A back-end, also called `}{`machinery`}{`, which is computer vision solution that processes the video stream of surveillance camera.`}

\n

{`Once you start changing or adding features to Kerberos Open Source, there is a big chance you will need to modify the previously mentioned solutions. That's why we will discuss how you can contribute to one or both solutions.`}

\n

{`Machinery`}

\n

{`Contributing to the `}{`machinery repository`}{` requires C++ skills. This section describes all the technical stuff you will need to know. If you want to contribute, the first thing you will need to do is installing the source code on your working station.`}

\n

{`Prerequisites`}

\n
\n

{`A Linux OS, or Mac OSX (Window is not supported).`}

\n
\n

{`Installation`}

\n

{`The complete installation can be found on the advanced installation page, describing the complete set of instructions. However for simplicity we will give a summarized version, as probably you will already have a development environment set up.`}

\n

{`Install development tools (C++, CMake) and V4L utils, and clone the repository. Compile the project using cmake and make.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}{`\n`}{`cd`}{` && `}{`sudo`}{` `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Testing`}

\n

{`We strongly recommend testing as a best practice in complex projects. Therefore the machinery uses the popular C++ test library: Google Test and Google Mock. The tests can be found in the test directory. You can run the test by executing following command:`}

\n
{`make`}{` `}{`check`}
\n

{`Adding a new class`}

\n

{`This paragraph will tell you how to create a new condition, algorithm, expositor, io or capture device. For simplicity we will show how to create a new algorithm; the steps are identical if you want to create for example a new capture device; only the directory will differ.`}

\n

{`Create the header file`}

\n

{`First we will need to create a new header file in the include/kerberos/machinery/algorithm directory. You can copy an existing algorithm header file, and start from there. You will end up with the following header file:`}

\n
{`//`}{`\n`}{`//  Class: AnotherAlgorithm`}{`\n`}{`//  Description: Another algorithm`}{`\n`}{`//  Created:     ...`}{`\n`}{`//  Author:      ...`}{`\n`}{`//  Mail:        ...`}{`\n`}{`//  Website:     ...`}{`\n`}{`//`}{`\n`}{`//  The copyright to the computer program(s) herein`}{`\n`}{`//  is the property of kerberos.io, Belgium.`}{`\n`}{`//  The program(s) may be used and/or copied .`}{`\n`}{`//`}{`\n`}{`/////////////////////////////////////////////////////`}{`\n`}{`#`}{`ifndef`}{` `}{`__AnotherAlgorithm_H_INCLUDED__`}{`   `}{`// if AnotherAlgorithm.h hasn't been included yet...`}{`\n`}{`#`}{`define`}{` `}{`__AnotherAlgorithm_H_INCLUDED__`}{`   `}{`// #define this so the compiler knows it has been included`}{`\n`}{`#`}{`include`}{` `}{`\"machinery/algorithm/Algorithm.h\"`}{`\n`}{`namespace`}{` `}{`kerberos`}{`\n`}{`{`}{`\n`}{`\t`}{`char`}{` `}{`AnotherAlgorithmName`}{`[] = `}{`\"AnotherAlgorithm\"`}{`;`}{`\n`}{`\t`}{`class`}{` `}{`AnotherAlgorithm`}{` : `}{`public`}{` `}{`AlgorithmCreator`}{`<`}{`AnotherAlgorithmName`}{`, `}{`AnotherAlgorithm`}{`>`}{`\n`}{`\t{`}{`\n`}{`    \t`}{`private`}{`:`}{`\n`}{`    \t\t`}{`Image`}{` `}{`m_result`}{`;`}{`\n`}{`        \t`}{`int`}{` `}{`m_parameter`}{`;`}{`\n`}{`    \t`}{`public`}{`:`}{`\n`}{`        \t`}{`AnotherAlgorithm`}{`(){}`}{`\n`}{`        \t`}{`void`}{` `}{`setup`}{`(`}{`const`}{` `}{`StringMap`}{` & `}{`settings`}{`);`}{`\n`}{`        \t`}{`void`}{` `}{`initialize`}{`(`}{`ImageVector`}{` & `}{`images`}{`);`}{`\n`}{`        \t`}{`Image`}{` `}{`evaluate`}{`(`}{`ImageVector`}{` & `}{`images`}{`, `}{`JSON`}{` & `}{`data`}{`);`}{`\n`}{`        \t`}{`void`}{` `}{`setParameter`}{`(`}{`int`}{` `}{`parameter`}{`);`}{`\n`}{`\t};`}{`\n`}{`}`}{`\n`}{`#`}{`endif`}
\n

{`When creating a new class you will need to inherit from it corresponding creator, for the algorithm example: AlgorithmCreator. The creator class requires two template parameters. The first one is a unique name for the class, this name will be used to make some kind of dependency injection possible; and is used in the configurations files. The second parameter is the class itself.`}

\n

{`The inheritance of the creator class can be a little bit strange, but it is required and needed to register the class automatically with the factory. When the code gets compiled, the classes will be automatically registered with the factory, and you can create instances of those classes by using the name we've defined in the first template parameter. For example we could create a new instance of our previously created class with the following command.`}

\n
{`Algorithm`}{` * `}{`anotherAlgorithm`}{` = `}{`Factory`}{`<`}{`Algorithm`}{`>::`}{`getInstance`}{`()->`}{`create`}{`(`}{`\"AnotherAlgorithm\"`}{`);`}
\n

{`Create the source file`}

\n

{`Ofcourse we also need to have an implementation file, therefore we need to create a new source file in the src/kerberos/machinery/algorithm directory. Just like the previous example, you can copy an existing class and implement the member functions you've declared in the header file. An example would be:`}

\n
{`#`}{`include`}{` `}{`\"machinery/algorithm/AnotherAlgorithm.h\"`}{`\n`}{`namespace`}{` `}{`kerberos`}{`\n`}{`{`}{`\n`}{`    `}{`void`}{` AnotherAlgorithm::`}{`setup`}{`(`}{`const`}{` `}{`StringMap`}{` & `}{`settings`}{`)`}{`\n`}{`    {`}{`\n`}{`        Algorithm::`}{`setup`}{`(`}{`settings`}{`);`}{`\n`}{`        `}{`int`}{` `}{`parameter`}{` = std::`}{`atoi`}{`(`}{`settings`}{`.`}{`at`}{`(`}{`\"algorithms.AnotherAlgorithm.parameter\"`}{`).`}{`c_str`}{`());`}{`\n`}{`        `}{`setParameter`}{`(`}{`parameter`}{`);`}{`\n`}{`    }`}{`\n`}{`    `}{`void`}{` AnotherAlgorithm::`}{`initialize`}{`(`}{`ImageVector`}{` & `}{`images`}{`)`}{`\n`}{`    {`}{`\n`}{`        ....`}{`\n`}{`    }`}{`\n`}{`    `}{`Image`}{` AnotherAlgorithm::`}{`evaluate`}{`(`}{`ImageVector`}{` & `}{`images`}{`, `}{`JSON`}{` & `}{`data`}{`)`}{`\n`}{`    {`}{`\n`}{`        `}{`Image`}{` `}{`evaluation`}{`;`}{`\n`}{`        ... `}{`do`}{` `}{`something`}{` ..`}{`\n`}{`        `}{`return`}{` `}{`evaluation`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`void`}{` AnotherAlgorithm::`}{`setParameter`}{`(`}{`int`}{` `}{`parameter`}{`)`}{`\n`}{`    {`}{`\n`}{`        `}{`m_parameter`}{` = `}{`parameter`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Modify the CMakeLists.txt file`}

\n

{`Open the CMakeLists.txt in the src/kerberos directory file and append the name of the algorithm class to the KERBEROS_FACTORY_ENTITIES variable; for example machinery/algorithm/AnotherAlgorithm.cpp.`}

\n
{`# -------------------------------------------------------`}{`\n`}{`# `}{`Entities`}{` `}{`that`}{` `}{`have`}{` `}{`to`}{` `}{`be`}{` `}{`registered`}{` `}{`with`}{` `}{`the`}{` `}{`factory`}{`\n`}{`#   - `}{`classes`}{` `}{`are`}{` `}{`registered`}{` `}{`on`}{` `}{`compile`}{` `}{`time`}{`, `}{`so`}{` `}{`they`}{`\n`}{`#   `}{`don`}{`'t belong to a library. New algorithms, expositor`}{`s`}{`\n`}{`#   `}{`or`}{` `}{`Io`}{` `}{`classes`}{` `}{`belong`}{` `}{`here`}{`.`}{`\n`}{`set`}{`(`}{`KERBEROS_FACTORY_ENTITIES`}{`\n`}{`    `}{`capture`}{`/`}{`USBCamera`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`condition`}{`/`}{`Time`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`condition`}{`/`}{`Enabled`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`algorithm`}{`/`}{`DifferentialCollins`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`algorithm`}{`/`}{`DifferentialCollinsWithColor`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`algorithm`}{`/`}{`AnotherAlgorithm`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`expositor`}{`/`}{`RectangleExpositor`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`expositor`}{`/`}{`HullExpositor`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`heuristic`}{`/`}{`Sequence`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`io`}{`/`}{`IoDisk`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`io`}{`/`}{`IoTCP`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`io`}{`/`}{`IoMongoDB`}{`.`}{`cpp`}{`\n`}{`)`}
\n

{`Create a new entry in the config file`}

\n

{`Open the algorithm.xml file in the config directory, and add a new tag with exactly the same name you've used in the header file; so in our example \"AnotherAlgorithm\". Within the new tag we can add properties that we will be use to configure our algorithm, in our example we defined a field parameter so we can add this field in the config file.`}

\n

{`One thing you will need to do is to attach a type to a property. The type will be used by the web to automatically render the properties. For simplicity we can use the type number, this will show an input box on the settings page of the web where we are able to add numbers.`}

\n
{`<`}{`algorithms`}{`>`}{`\n`}{`\t<`}{`AnotherAlgorithm`}{`>`}{`\n`}{`\t\t<`}{`parameter`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`5`}{`{`parameter`}{`>`}{`\n`}{`    {`AnotherAlgorithm`}{`>`}{`\n`}{`{`algorithms`}{`>`}
\n

{`You can retrieve the parameter in the setup function with the settings parameter.`}

\n
{`settings`}{`.`}{`at`}{`(`}{`\"algorithms.AnotherAlgorithm.parameter\"`}{`)`}
\n

{`Compile`}

\n

{`Hurray, we've made it! So now you can compile the code again, and if you're using an IDE don't forget to include the new source file! If you are compiling from the command-line you just have to go to the build folder and write make.`}

\n

{`Web`}

\n

{`Contributing to `}{`the web repository`}{` requires both front- and back-end skillls, more precisely BackboneJS (JavaScript) and Laravel 5.4 (PHP).`}

\n

{`Prerequisites`}

\n

{`Make sure you have following services installed on your working station.`}

\n
\n

{`>`}{`= PHP 7.1.0, NodeJS and NPM and Nginx or Apache`}

\n
\n

{`Installation`}

\n

{`Clone the repository to your working station.`}

\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/web`}{`\n`}{`cd`}{` `}{`web`}
\n

{`Install the PHP libraries using the dependency mananger, `}{`Composer`}{`. If you haven't installed composer execute following commands.`}

\n
{`php`}{` -`}{`r`}{` `}{`\"readfile('https://getcomposer.org/installer');\"`}{` > `}{`composer`}{`-`}{`setup`}{`.`}{`php`}{`\n`}{`php`}{` -`}{`r`}{` `}{`\"if (hash('SHA384', file_get_contents('composer-setup.php')) === '41e71d86b40f28e771d4bb662b997f79625196afcca95a5abf44391188c695c6c1456e16154c75a211d238cc3bc5cb47') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;\"`}{`\n`}{`php`}{` `}{`composer`}{`-`}{`setup`}{`.`}{`php`}{`\n`}{`php`}{` -`}{`r`}{` `}{`\"unlink('composer-setup.php');\"`}
\n

{`After a succesful installation, you can run composer install or composer update from the root of the project. All dependencies will be installed or updated if a newer version is detected.`}

\n
{`composer`}{` `}{`update`}
\n

{`Besides PHP, the project also relies on BackboneJS (Javascript) for the front-end. Therefore a couple JavaScript dependencies should be installed.`}

\n
{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}{`\n`}{`cd`}{` `}{`public`}{`\n`}{`bower`}{` `}{`update`}
\n

{`When everything is installed properly, you need too link the web project with your applicationn server. Read more on the `}{`Laravel documentation website`}{`.`}

\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974265000,"key":"gatsby-plugin-mdx-entire-payload-13c4772d8dccd98e23ab4094aa241345-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Contribute","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":13,"offset":171},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":13,"offset":171},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"In this document we describe the different things you need to know if you would like to add a new feature to Kerberos Open Source, or change some of its behaviour for your own use case.","position":{"start":{"line":10,"column":1,"offset":173},"end":{"line":10,"column":186,"offset":358},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":173},"end":{"line":10,"column":186,"offset":358},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before starting, as you might have read already, you need to know that Kerberos Open Source consists of two solutions. A front-end, also called ","position":{"start":{"line":12,"column":1,"offset":360},"end":{"line":12,"column":145,"offset":504},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"web","position":{"start":{"line":12,"column":147,"offset":506},"end":{"line":12,"column":150,"offset":509},"indent":[]}}],"position":{"start":{"line":12,"column":145,"offset":504},"end":{"line":12,"column":152,"offset":511},"indent":[]}},{"type":"text","value":", which allows you to review the recordings and to configure the back-end settings. A back-end, also called ","position":{"start":{"line":12,"column":152,"offset":511},"end":{"line":12,"column":260,"offset":619},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"machinery","position":{"start":{"line":12,"column":262,"offset":621},"end":{"line":12,"column":271,"offset":630},"indent":[]}}],"position":{"start":{"line":12,"column":260,"offset":619},"end":{"line":12,"column":273,"offset":632},"indent":[]}},{"type":"text","value":", which is computer vision solution that processes the video stream of surveillance camera.","position":{"start":{"line":12,"column":273,"offset":632},"end":{"line":12,"column":364,"offset":723},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":360},"end":{"line":12,"column":364,"offset":723},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you start changing or adding features to Kerberos Open Source, there is a big chance you will need to modify the previously mentioned solutions. That's why we will discuss how you can contribute to one or both solutions.","position":{"start":{"line":14,"column":1,"offset":725},"end":{"line":14,"column":226,"offset":950},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":725},"end":{"line":14,"column":226,"offset":950},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":16,"column":4,"offset":955},"end":{"line":16,"column":13,"offset":964},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":952},"end":{"line":16,"column":13,"offset":964},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Contributing to the ","position":{"start":{"line":18,"column":1,"offset":966},"end":{"line":18,"column":21,"offset":986},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery","children":[{"type":"text","value":"machinery repository","position":{"start":{"line":18,"column":22,"offset":987},"end":{"line":18,"column":42,"offset":1007},"indent":[]}}],"position":{"start":{"line":18,"column":21,"offset":986},"end":{"line":18,"column":85,"offset":1050},"indent":[]}},{"type":"text","value":" requires C++ skills. This section describes all the technical stuff you will need to know. If you want to contribute, the first thing you will need to do is installing the source code on your working station.","position":{"start":{"line":18,"column":85,"offset":1050},"end":{"line":18,"column":294,"offset":1259},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":966},"end":{"line":18,"column":294,"offset":1259},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":20,"column":5,"offset":1265},"end":{"line":20,"column":18,"offset":1278},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":1261},"end":{"line":20,"column":18,"offset":1278},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"A Linux OS, or Mac OSX (Window is not supported).","position":{"start":{"line":22,"column":3,"offset":1282},"end":{"line":22,"column":52,"offset":1331},"indent":[]}}],"position":{"start":{"line":22,"column":3,"offset":1282},"end":{"line":22,"column":52,"offset":1331},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1280},"end":{"line":22,"column":52,"offset":1331},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Installation","position":{"start":{"line":24,"column":5,"offset":1337},"end":{"line":24,"column":17,"offset":1349},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1333},"end":{"line":24,"column":17,"offset":1349},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The complete installation can be found on the advanced installation page, describing the complete set of instructions. However for simplicity we will give a summarized version, as probably you will already have a development environment set up.","position":{"start":{"line":26,"column":1,"offset":1351},"end":{"line":26,"column":245,"offset":1595},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1351},"end":{"line":26,"column":245,"offset":1595},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install development tools (C++, CMake) and V4L utils, and clone the repository. Compile the project using cmake and make.","position":{"start":{"line":28,"column":1,"offset":1597},"end":{"line":28,"column":122,"offset":1718},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":1597},"end":{"line":28,"column":122,"offset":1718},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev\ncd && sudo git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":30,"column":1,"offset":1720},"end":{"line":36,"column":4,"offset":2029},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Testing","position":{"start":{"line":38,"column":5,"offset":2035},"end":{"line":38,"column":12,"offset":2042},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":2031},"end":{"line":38,"column":12,"offset":2042},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"We strongly recommend testing as a best practice in complex projects. Therefore the machinery uses the popular C++ test library: Google Test and Google Mock. The tests can be found in the test directory. You can run the test by executing following command:","position":{"start":{"line":40,"column":1,"offset":2044},"end":{"line":40,"column":257,"offset":2300},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":2044},"end":{"line":40,"column":257,"offset":2300},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"make check","position":{"start":{"line":42,"column":1,"offset":2302},"end":{"line":44,"column":4,"offset":2322},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Adding a new class","position":{"start":{"line":46,"column":5,"offset":2328},"end":{"line":46,"column":23,"offset":2346},"indent":[]}}],"position":{"start":{"line":46,"column":1,"offset":2324},"end":{"line":46,"column":23,"offset":2346},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This paragraph will tell you how to create a new condition, algorithm, expositor, io or capture device. For simplicity we will show how to create a new algorithm; the steps are identical if you want to create for example a new capture device; only the directory will differ.","position":{"start":{"line":48,"column":1,"offset":2348},"end":{"line":48,"column":275,"offset":2622},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2348},"end":{"line":48,"column":275,"offset":2622},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Create the header file","position":{"start":{"line":50,"column":6,"offset":2629},"end":{"line":50,"column":28,"offset":2651},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":2624},"end":{"line":50,"column":28,"offset":2651},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"First we will need to create a new header file in the include/kerberos/machinery/algorithm directory. You can copy an existing algorithm header file, and start from there. You will end up with the following header file:","position":{"start":{"line":52,"column":1,"offset":2653},"end":{"line":52,"column":220,"offset":2872},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2653},"end":{"line":52,"column":220,"offset":2872},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"//\n// Class: AnotherAlgorithm\n// Description: Another algorithm\n// Created: ...\n// Author: ...\n// Mail: ...\n// Website: ...\n//\n// The copyright to the computer program(s) herein\n// is the property of kerberos.io, Belgium.\n// The program(s) may be used and/or copied .\n//\n/////////////////////////////////////////////////////\n#ifndef __AnotherAlgorithm_H_INCLUDED__ // if AnotherAlgorithm.h hasn't been included yet...\n#define __AnotherAlgorithm_H_INCLUDED__ // #define this so the compiler knows it has been included\n#include \"machinery/algorithm/Algorithm.h\"\nnamespace kerberos\n{\n\tchar AnotherAlgorithmName[] = \"AnotherAlgorithm\";\n\tclass AnotherAlgorithm : public AlgorithmCreator\n\t{\n \tprivate:\n \t\tImage m_result;\n \tint m_parameter;\n \tpublic:\n \tAnotherAlgorithm(){}\n \tvoid setup(const StringMap & settings);\n \tvoid initialize(ImageVector & images);\n \tImage evaluate(ImageVector & images, JSON & data);\n \tvoid setParameter(int parameter);\n\t};\n}\n#endif","position":{"start":{"line":54,"column":1,"offset":2874},"end":{"line":88,"column":4,"offset":3959},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When creating a new class you will need to inherit from it corresponding creator, for the algorithm example: AlgorithmCreator. The creator class requires two template parameters. The first one is a unique name for the class, this name will be used to make some kind of dependency injection possible; and is used in the configurations files. The second parameter is the class itself.","position":{"start":{"line":90,"column":1,"offset":3961},"end":{"line":90,"column":383,"offset":4343},"indent":[]}}],"position":{"start":{"line":90,"column":1,"offset":3961},"end":{"line":90,"column":383,"offset":4343},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The inheritance of the creator class can be a little bit strange, but it is required and needed to register the class automatically with the factory. When the code gets compiled, the classes will be automatically registered with the factory, and you can create instances of those classes by using the name we've defined in the first template parameter. For example we could create a new instance of our previously created class with the following command.","position":{"start":{"line":92,"column":1,"offset":4345},"end":{"line":92,"column":456,"offset":4800},"indent":[]}}],"position":{"start":{"line":92,"column":1,"offset":4345},"end":{"line":92,"column":456,"offset":4800},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Algorithm * anotherAlgorithm = Factory::getInstance()->create(\"AnotherAlgorithm\");","position":{"start":{"line":94,"column":1,"offset":4802},"end":{"line":96,"column":4,"offset":4905},"indent":[1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Create the source file","position":{"start":{"line":98,"column":6,"offset":4912},"end":{"line":98,"column":28,"offset":4934},"indent":[]}}],"position":{"start":{"line":98,"column":1,"offset":4907},"end":{"line":98,"column":28,"offset":4934},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Ofcourse we also need to have an implementation file, therefore we need to create a new source file in the src/kerberos/machinery/algorithm directory. Just like the previous example, you can copy an existing class and implement the member functions you've declared in the header file. An example would be:","position":{"start":{"line":100,"column":1,"offset":4936},"end":{"line":100,"column":306,"offset":5241},"indent":[]}}],"position":{"start":{"line":100,"column":1,"offset":4936},"end":{"line":100,"column":306,"offset":5241},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#include \"machinery/algorithm/AnotherAlgorithm.h\"\nnamespace kerberos\n{\n void AnotherAlgorithm::setup(const StringMap & settings)\n {\n Algorithm::setup(settings);\n int parameter = std::atoi(settings.at(\"algorithms.AnotherAlgorithm.parameter\").c_str());\n setParameter(parameter);\n }\n void AnotherAlgorithm::initialize(ImageVector & images)\n {\n ....\n }\n Image AnotherAlgorithm::evaluate(ImageVector & images, JSON & data)\n {\n Image evaluation;\n ... do something ..\n return evaluation;\n }\n void AnotherAlgorithm::setParameter(int parameter)\n {\n m_parameter = parameter;\n }\n}","position":{"start":{"line":102,"column":1,"offset":5243},"end":{"line":127,"column":4,"offset":5914},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Modify the CMakeLists.txt file","position":{"start":{"line":129,"column":6,"offset":5921},"end":{"line":129,"column":36,"offset":5951},"indent":[]}}],"position":{"start":{"line":129,"column":1,"offset":5916},"end":{"line":129,"column":36,"offset":5951},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Open the CMakeLists.txt in the src/kerberos directory file and append the name of the algorithm class to the KERBEROS_FACTORY_ENTITIES variable; for example machinery/algorithm/AnotherAlgorithm.cpp.","position":{"start":{"line":131,"column":1,"offset":5953},"end":{"line":131,"column":199,"offset":6151},"indent":[]}}],"position":{"start":{"line":131,"column":1,"offset":5953},"end":{"line":131,"column":199,"offset":6151},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"# -------------------------------------------------------\n# Entities that have to be registered with the factory\n# - classes are registered on compile time, so they\n# don't belong to a library. New algorithms, expositors\n# or Io classes belong here.\nset(KERBEROS_FACTORY_ENTITIES\n capture/USBCamera.cpp\n machinery/condition/Time.cpp\n machinery/condition/Enabled.cpp\n machinery/algorithm/DifferentialCollins.cpp\n machinery/algorithm/DifferentialCollinsWithColor.cpp\n machinery/algorithm/AnotherAlgorithm.cpp\n machinery/expositor/RectangleExpositor.cpp\n machinery/expositor/HullExpositor.cpp\n machinery/heuristic/Sequence.cpp\n machinery/io/IoDisk.cpp\n machinery/io/IoTCP.cpp\n machinery/io/IoMongoDB.cpp\n)","position":{"start":{"line":133,"column":1,"offset":6153},"end":{"line":153,"column":4,"offset":6907},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Create a new entry in the config file","position":{"start":{"line":155,"column":6,"offset":6914},"end":{"line":155,"column":43,"offset":6951},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":6909},"end":{"line":155,"column":43,"offset":6951},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Open the algorithm.xml file in the config directory, and add a new tag with exactly the same name you've used in the header file; so in our example \"AnotherAlgorithm\". Within the new tag we can add properties that we will be use to configure our algorithm, in our example we defined a field parameter so we can add this field in the config file.","position":{"start":{"line":157,"column":1,"offset":6953},"end":{"line":157,"column":346,"offset":7298},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6953},"end":{"line":157,"column":346,"offset":7298},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"One thing you will need to do is to attach a type to a property. The type will be used by the web to automatically render the properties. For simplicity we can use the type number, this will show an input box on the settings page of the web where we are able to add numbers.","position":{"start":{"line":159,"column":1,"offset":7300},"end":{"line":159,"column":275,"offset":7574},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":7300},"end":{"line":159,"column":275,"offset":7574},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"\n\t\n\t\t5\n \n","position":{"start":{"line":161,"column":1,"offset":7576},"end":{"line":167,"column":4,"offset":7697},"indent":[1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"You can retrieve the parameter in the setup function with the settings parameter.","position":{"start":{"line":169,"column":1,"offset":7699},"end":{"line":169,"column":82,"offset":7780},"indent":[]}}],"position":{"start":{"line":169,"column":1,"offset":7699},"end":{"line":169,"column":82,"offset":7780},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"settings.at(\"algorithms.AnotherAlgorithm.parameter\")","position":{"start":{"line":171,"column":1,"offset":7782},"end":{"line":173,"column":4,"offset":7844},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Compile","position":{"start":{"line":175,"column":5,"offset":7850},"end":{"line":175,"column":12,"offset":7857},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7846},"end":{"line":175,"column":12,"offset":7857},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Hurray, we've made it! So now you can compile the code again, and if you're using an IDE don't forget to include the new source file! If you are compiling from the command-line you just have to go to the build folder and write make.","position":{"start":{"line":177,"column":1,"offset":7859},"end":{"line":177,"column":233,"offset":8091},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7859},"end":{"line":177,"column":233,"offset":8091},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Web","position":{"start":{"line":179,"column":4,"offset":8096},"end":{"line":179,"column":7,"offset":8099},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":8093},"end":{"line":179,"column":7,"offset":8099},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Contributing to ","position":{"start":{"line":181,"column":1,"offset":8101},"end":{"line":181,"column":17,"offset":8117},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web","children":[{"type":"text","value":"the web repository","position":{"start":{"line":181,"column":18,"offset":8118},"end":{"line":181,"column":36,"offset":8136},"indent":[]}}],"position":{"start":{"line":181,"column":17,"offset":8117},"end":{"line":181,"column":73,"offset":8173},"indent":[]}},{"type":"text","value":" requires both front- and back-end skillls, more precisely BackboneJS (JavaScript) and Laravel 5.4 (PHP).","position":{"start":{"line":181,"column":73,"offset":8173},"end":{"line":181,"column":178,"offset":8278},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":8101},"end":{"line":181,"column":178,"offset":8278},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":183,"column":5,"offset":8284},"end":{"line":183,"column":18,"offset":8297},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":8280},"end":{"line":183,"column":18,"offset":8297},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Make sure you have following services installed on your working station.","position":{"start":{"line":185,"column":1,"offset":8299},"end":{"line":185,"column":73,"offset":8371},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":8299},"end":{"line":185,"column":73,"offset":8371},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":">","position":{"start":{"line":187,"column":2,"offset":8374},"end":{"line":187,"column":4,"offset":8376},"indent":[]}},{"type":"text","value":"= PHP 7.1.0, NodeJS and NPM and Nginx or Apache","position":{"start":{"line":187,"column":4,"offset":8376},"end":{"line":187,"column":51,"offset":8423},"indent":[]}}],"position":{"start":{"line":187,"column":2,"offset":8374},"end":{"line":187,"column":51,"offset":8423},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":8373},"end":{"line":187,"column":51,"offset":8423},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Installation","position":{"start":{"line":189,"column":5,"offset":8429},"end":{"line":189,"column":17,"offset":8441},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":8425},"end":{"line":189,"column":17,"offset":8441},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Clone the repository to your working station.","position":{"start":{"line":191,"column":1,"offset":8443},"end":{"line":191,"column":46,"offset":8488},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":8443},"end":{"line":191,"column":46,"offset":8488},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/kerberos-io/web\ncd web","position":{"start":{"line":193,"column":1,"offset":8490},"end":{"line":196,"column":4,"offset":8551},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP libraries using the dependency mananger, ","position":{"start":{"line":198,"column":1,"offset":8553},"end":{"line":198,"column":58,"offset":8610},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Composer","position":{"start":{"line":198,"column":60,"offset":8612},"end":{"line":198,"column":68,"offset":8620},"indent":[]}}],"position":{"start":{"line":198,"column":58,"offset":8610},"end":{"line":198,"column":70,"offset":8622},"indent":[]}},{"type":"text","value":". If you haven't installed composer execute following commands.","position":{"start":{"line":198,"column":70,"offset":8622},"end":{"line":198,"column":133,"offset":8685},"indent":[]}}],"position":{"start":{"line":198,"column":1,"offset":8553},"end":{"line":198,"column":133,"offset":8685},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"php -r \"readfile('https://getcomposer.org/installer');\" > composer-setup.php\nphp -r \"if (hash('SHA384', file_get_contents('composer-setup.php')) === '41e71d86b40f28e771d4bb662b997f79625196afcca95a5abf44391188c695c6c1456e16154c75a211d238cc3bc5cb47') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;\"\nphp composer-setup.php\nphp -r \"unlink('composer-setup.php');\"","position":{"start":{"line":200,"column":1,"offset":8687},"end":{"line":205,"column":4,"offset":9118},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After a succesful installation, you can run composer install or composer update from the root of the project. All dependencies will be installed or updated if a newer version is detected.","position":{"start":{"line":207,"column":1,"offset":9120},"end":{"line":207,"column":188,"offset":9307},"indent":[]}}],"position":{"start":{"line":207,"column":1,"offset":9120},"end":{"line":207,"column":188,"offset":9307},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"composer update","position":{"start":{"line":209,"column":1,"offset":9309},"end":{"line":211,"column":4,"offset":9334},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Besides PHP, the project also relies on BackboneJS (Javascript) for the front-end. Therefore a couple JavaScript dependencies should be installed.","position":{"start":{"line":213,"column":1,"offset":9336},"end":{"line":213,"column":147,"offset":9482},"indent":[]}}],"position":{"start":{"line":213,"column":1,"offset":9336},"end":{"line":213,"column":147,"offset":9482},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"npm -g install bower\ncd public\nbower update","position":{"start":{"line":215,"column":1,"offset":9484},"end":{"line":219,"column":4,"offset":9537},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When everything is installed properly, you need too link the web project with your applicationn server. Read more on the ","position":{"start":{"line":221,"column":1,"offset":9539},"end":{"line":221,"column":122,"offset":9660},"indent":[]}},{"type":"link","title":null,"url":"https://laravel.com/docs/5.8/deployment","children":[{"type":"text","value":"Laravel documentation website","position":{"start":{"line":221,"column":123,"offset":9661},"end":{"line":221,"column":152,"offset":9690},"indent":[]}}],"position":{"start":{"line":221,"column":122,"offset":9660},"end":{"line":221,"column":194,"offset":9732},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":221,"column":194,"offset":9732},"end":{"line":221,"column":195,"offset":9733},"indent":[]}}],"position":{"start":{"line":221,"column":1,"offset":9539},"end":{"line":221,"column":195,"offset":9733},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":224,"column":1,"offset":9736},"end":{"line":224,"column":31,"offset":9766},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":224,"column":31,"offset":9766}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Contribute`}

\n

{`In this document we describe the different things you need to know if you would like to add a new feature to Kerberos Open Source, or change some of its behaviour for your own use case.`}

\n

{`Before starting, as you might have read already, you need to know that Kerberos Open Source consists of two solutions. A front-end, also called `}{`web`}{`, which allows you to review the recordings and to configure the back-end settings. A back-end, also called `}{`machinery`}{`, which is computer vision solution that processes the video stream of surveillance camera.`}

\n

{`Once you start changing or adding features to Kerberos Open Source, there is a big chance you will need to modify the previously mentioned solutions. That's why we will discuss how you can contribute to one or both solutions.`}

\n

{`Machinery`}

\n

{`Contributing to the `}{`machinery repository`}{` requires C++ skills. This section describes all the technical stuff you will need to know. If you want to contribute, the first thing you will need to do is installing the source code on your working station.`}

\n

{`Prerequisites`}

\n
\n

{`A Linux OS, or Mac OSX (Window is not supported).`}

\n
\n

{`Installation`}

\n

{`The complete installation can be found on the advanced installation page, describing the complete set of instructions. However for simplicity we will give a summarized version, as probably you will already have a development environment set up.`}

\n

{`Install development tools (C++, CMake) and V4L utils, and clone the repository. Compile the project using cmake and make.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}{`\n`}{`cd`}{` && `}{`sudo`}{` `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Testing`}

\n

{`We strongly recommend testing as a best practice in complex projects. Therefore the machinery uses the popular C++ test library: Google Test and Google Mock. The tests can be found in the test directory. You can run the test by executing following command:`}

\n
{`make`}{` `}{`check`}
\n

{`Adding a new class`}

\n

{`This paragraph will tell you how to create a new condition, algorithm, expositor, io or capture device. For simplicity we will show how to create a new algorithm; the steps are identical if you want to create for example a new capture device; only the directory will differ.`}

\n

{`Create the header file`}

\n

{`First we will need to create a new header file in the include/kerberos/machinery/algorithm directory. You can copy an existing algorithm header file, and start from there. You will end up with the following header file:`}

\n
{`//`}{`\n`}{`//  Class: AnotherAlgorithm`}{`\n`}{`//  Description: Another algorithm`}{`\n`}{`//  Created:     ...`}{`\n`}{`//  Author:      ...`}{`\n`}{`//  Mail:        ...`}{`\n`}{`//  Website:     ...`}{`\n`}{`//`}{`\n`}{`//  The copyright to the computer program(s) herein`}{`\n`}{`//  is the property of kerberos.io, Belgium.`}{`\n`}{`//  The program(s) may be used and/or copied .`}{`\n`}{`//`}{`\n`}{`/////////////////////////////////////////////////////`}{`\n`}{`#`}{`ifndef`}{` `}{`__AnotherAlgorithm_H_INCLUDED__`}{`   `}{`// if AnotherAlgorithm.h hasn't been included yet...`}{`\n`}{`#`}{`define`}{` `}{`__AnotherAlgorithm_H_INCLUDED__`}{`   `}{`// #define this so the compiler knows it has been included`}{`\n`}{`#`}{`include`}{` `}{`\"machinery/algorithm/Algorithm.h\"`}{`\n`}{`namespace`}{` `}{`kerberos`}{`\n`}{`{`}{`\n`}{`\t`}{`char`}{` `}{`AnotherAlgorithmName`}{`[] = `}{`\"AnotherAlgorithm\"`}{`;`}{`\n`}{`\t`}{`class`}{` `}{`AnotherAlgorithm`}{` : `}{`public`}{` `}{`AlgorithmCreator`}{`<`}{`AnotherAlgorithmName`}{`, `}{`AnotherAlgorithm`}{`>`}{`\n`}{`\t{`}{`\n`}{`    \t`}{`private`}{`:`}{`\n`}{`    \t\t`}{`Image`}{` `}{`m_result`}{`;`}{`\n`}{`        \t`}{`int`}{` `}{`m_parameter`}{`;`}{`\n`}{`    \t`}{`public`}{`:`}{`\n`}{`        \t`}{`AnotherAlgorithm`}{`(){}`}{`\n`}{`        \t`}{`void`}{` `}{`setup`}{`(`}{`const`}{` `}{`StringMap`}{` & `}{`settings`}{`);`}{`\n`}{`        \t`}{`void`}{` `}{`initialize`}{`(`}{`ImageVector`}{` & `}{`images`}{`);`}{`\n`}{`        \t`}{`Image`}{` `}{`evaluate`}{`(`}{`ImageVector`}{` & `}{`images`}{`, `}{`JSON`}{` & `}{`data`}{`);`}{`\n`}{`        \t`}{`void`}{` `}{`setParameter`}{`(`}{`int`}{` `}{`parameter`}{`);`}{`\n`}{`\t};`}{`\n`}{`}`}{`\n`}{`#`}{`endif`}
\n

{`When creating a new class you will need to inherit from it corresponding creator, for the algorithm example: AlgorithmCreator. The creator class requires two template parameters. The first one is a unique name for the class, this name will be used to make some kind of dependency injection possible; and is used in the configurations files. The second parameter is the class itself.`}

\n

{`The inheritance of the creator class can be a little bit strange, but it is required and needed to register the class automatically with the factory. When the code gets compiled, the classes will be automatically registered with the factory, and you can create instances of those classes by using the name we've defined in the first template parameter. For example we could create a new instance of our previously created class with the following command.`}

\n
{`Algorithm`}{` * `}{`anotherAlgorithm`}{` = `}{`Factory`}{`<`}{`Algorithm`}{`>::`}{`getInstance`}{`()->`}{`create`}{`(`}{`\"AnotherAlgorithm\"`}{`);`}
\n

{`Create the source file`}

\n

{`Ofcourse we also need to have an implementation file, therefore we need to create a new source file in the src/kerberos/machinery/algorithm directory. Just like the previous example, you can copy an existing class and implement the member functions you've declared in the header file. An example would be:`}

\n
{`#`}{`include`}{` `}{`\"machinery/algorithm/AnotherAlgorithm.h\"`}{`\n`}{`namespace`}{` `}{`kerberos`}{`\n`}{`{`}{`\n`}{`    `}{`void`}{` AnotherAlgorithm::`}{`setup`}{`(`}{`const`}{` `}{`StringMap`}{` & `}{`settings`}{`)`}{`\n`}{`    {`}{`\n`}{`        Algorithm::`}{`setup`}{`(`}{`settings`}{`);`}{`\n`}{`        `}{`int`}{` `}{`parameter`}{` = std::`}{`atoi`}{`(`}{`settings`}{`.`}{`at`}{`(`}{`\"algorithms.AnotherAlgorithm.parameter\"`}{`).`}{`c_str`}{`());`}{`\n`}{`        `}{`setParameter`}{`(`}{`parameter`}{`);`}{`\n`}{`    }`}{`\n`}{`    `}{`void`}{` AnotherAlgorithm::`}{`initialize`}{`(`}{`ImageVector`}{` & `}{`images`}{`)`}{`\n`}{`    {`}{`\n`}{`        ....`}{`\n`}{`    }`}{`\n`}{`    `}{`Image`}{` AnotherAlgorithm::`}{`evaluate`}{`(`}{`ImageVector`}{` & `}{`images`}{`, `}{`JSON`}{` & `}{`data`}{`)`}{`\n`}{`    {`}{`\n`}{`        `}{`Image`}{` `}{`evaluation`}{`;`}{`\n`}{`        ... `}{`do`}{` `}{`something`}{` ..`}{`\n`}{`        `}{`return`}{` `}{`evaluation`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`void`}{` AnotherAlgorithm::`}{`setParameter`}{`(`}{`int`}{` `}{`parameter`}{`)`}{`\n`}{`    {`}{`\n`}{`        `}{`m_parameter`}{` = `}{`parameter`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Modify the CMakeLists.txt file`}

\n

{`Open the CMakeLists.txt in the src/kerberos directory file and append the name of the algorithm class to the KERBEROS_FACTORY_ENTITIES variable; for example machinery/algorithm/AnotherAlgorithm.cpp.`}

\n
{`# -------------------------------------------------------`}{`\n`}{`# `}{`Entities`}{` `}{`that`}{` `}{`have`}{` `}{`to`}{` `}{`be`}{` `}{`registered`}{` `}{`with`}{` `}{`the`}{` `}{`factory`}{`\n`}{`#   - `}{`classes`}{` `}{`are`}{` `}{`registered`}{` `}{`on`}{` `}{`compile`}{` `}{`time`}{`, `}{`so`}{` `}{`they`}{`\n`}{`#   `}{`don`}{`'t belong to a library. New algorithms, expositor`}{`s`}{`\n`}{`#   `}{`or`}{` `}{`Io`}{` `}{`classes`}{` `}{`belong`}{` `}{`here`}{`.`}{`\n`}{`set`}{`(`}{`KERBEROS_FACTORY_ENTITIES`}{`\n`}{`    `}{`capture`}{`/`}{`USBCamera`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`condition`}{`/`}{`Time`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`condition`}{`/`}{`Enabled`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`algorithm`}{`/`}{`DifferentialCollins`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`algorithm`}{`/`}{`DifferentialCollinsWithColor`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`algorithm`}{`/`}{`AnotherAlgorithm`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`expositor`}{`/`}{`RectangleExpositor`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`expositor`}{`/`}{`HullExpositor`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`heuristic`}{`/`}{`Sequence`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`io`}{`/`}{`IoDisk`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`io`}{`/`}{`IoTCP`}{`.`}{`cpp`}{`\n`}{`    `}{`machinery`}{`/`}{`io`}{`/`}{`IoMongoDB`}{`.`}{`cpp`}{`\n`}{`)`}
\n

{`Create a new entry in the config file`}

\n

{`Open the algorithm.xml file in the config directory, and add a new tag with exactly the same name you've used in the header file; so in our example \"AnotherAlgorithm\". Within the new tag we can add properties that we will be use to configure our algorithm, in our example we defined a field parameter so we can add this field in the config file.`}

\n

{`One thing you will need to do is to attach a type to a property. The type will be used by the web to automatically render the properties. For simplicity we can use the type number, this will show an input box on the settings page of the web where we are able to add numbers.`}

\n
{`<`}{`algorithms`}{`>`}{`\n`}{`\t<`}{`AnotherAlgorithm`}{`>`}{`\n`}{`\t\t<`}{`parameter`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`5`}{`{`parameter`}{`>`}{`\n`}{`    {`AnotherAlgorithm`}{`>`}{`\n`}{`{`algorithms`}{`>`}
\n

{`You can retrieve the parameter in the setup function with the settings parameter.`}

\n
{`settings`}{`.`}{`at`}{`(`}{`\"algorithms.AnotherAlgorithm.parameter\"`}{`)`}
\n

{`Compile`}

\n

{`Hurray, we've made it! So now you can compile the code again, and if you're using an IDE don't forget to include the new source file! If you are compiling from the command-line you just have to go to the build folder and write make.`}

\n

{`Web`}

\n

{`Contributing to `}{`the web repository`}{` requires both front- and back-end skillls, more precisely BackboneJS (JavaScript) and Laravel 5.4 (PHP).`}

\n

{`Prerequisites`}

\n

{`Make sure you have following services installed on your working station.`}

\n
\n

{`>`}{`= PHP 7.1.0, NodeJS and NPM and Nginx or Apache`}

\n
\n

{`Installation`}

\n

{`Clone the repository to your working station.`}

\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/web`}{`\n`}{`cd`}{` `}{`web`}
\n

{`Install the PHP libraries using the dependency mananger, `}{`Composer`}{`. If you haven't installed composer execute following commands.`}

\n
{`php`}{` -`}{`r`}{` `}{`\"readfile('https://getcomposer.org/installer');\"`}{` > `}{`composer`}{`-`}{`setup`}{`.`}{`php`}{`\n`}{`php`}{` -`}{`r`}{` `}{`\"if (hash('SHA384', file_get_contents('composer-setup.php')) === '41e71d86b40f28e771d4bb662b997f79625196afcca95a5abf44391188c695c6c1456e16154c75a211d238cc3bc5cb47') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;\"`}{`\n`}{`php`}{` `}{`composer`}{`-`}{`setup`}{`.`}{`php`}{`\n`}{`php`}{` -`}{`r`}{` `}{`\"unlink('composer-setup.php');\"`}
\n

{`After a succesful installation, you can run composer install or composer update from the root of the project. All dependencies will be installed or updated if a newer version is detected.`}

\n
{`composer`}{` `}{`update`}
\n

{`Besides PHP, the project also relies on BackboneJS (Javascript) for the front-end. Therefore a couple JavaScript dependencies should be installed.`}

\n
{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}{`\n`}{`cd`}{` `}{`public`}{`\n`}{`bower`}{` `}{`update`}
\n

{`When everything is installed properly, you need too link the web project with your applicationn server. Read more on the `}{`Laravel documentation website`}{`.`}

\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-25dd5b29c7f2c5a385f80ef779c21981.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-25dd5b29c7f2c5a385f80ef779c21981.json new file mode 100644 index 0000000..1e14d48 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-25dd5b29c7f2c5a385f80ef779c21981.json @@ -0,0 +1 @@ +{"expireTime":9007200842068766000,"key":"gatsby-plugin-mdx-entire-payload-83f3a19583d1095496c79bad68aa055d-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4679},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":80,"offset":4760},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4760},"end":{"line":107,"column":101,"offset":4781},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4781},"end":{"line":107,"column":162,"offset":4842},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":162,"offset":4842},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4844},"end":{"line":112,"column":4,"offset":4933},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4938},"end":{"line":114,"column":10,"offset":4944},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4935},"end":{"line":114,"column":10,"offset":4944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":339,"offset":5284},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":340,"offset":5285},"end":{"line":116,"column":354,"offset":5299},"indent":[]}}],"position":{"start":{"line":116,"column":339,"offset":5284},"end":{"line":116,"column":390,"offset":5335},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":390,"offset":5335},"end":{"line":116,"column":391,"offset":5336},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":391,"offset":5336},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5342},"end":{"line":118,"column":18,"offset":5355},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5338},"end":{"line":118,"column":18,"offset":5355},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5357},"end":{"line":120,"column":50,"offset":5406},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5412},"end":{"line":122,"column":11,"offset":5418},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5408},"end":{"line":122,"column":11,"offset":5418},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":64,"offset":5483},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5484},"end":{"line":124,"column":86,"offset":5505},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5483},"end":{"line":124,"column":126,"offset":5545},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5545},"end":{"line":124,"column":127,"offset":5546},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":127,"offset":5546},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5552},"end":{"line":126,"column":26,"offset":5573},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5548},"end":{"line":126,"column":26,"offset":5573},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5702},"end":{"line":132,"column":4,"offset":5741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5931},"end":{"line":138,"column":4,"offset":6009},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6165},"end":{"line":145,"column":4,"offset":6312},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6414},"end":{"line":152,"column":4,"offset":6483},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6489},"end":{"line":154,"column":12,"offset":6496},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6485},"end":{"line":154,"column":12,"offset":6496},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":157,"column":25,"offset":6586},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6587},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":158,"column":59,"offset":6645},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":160,"column":4,"offset":6650},"end":{"line":160,"column":10,"offset":6656},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":6647},"end":{"line":160,"column":10,"offset":6656},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.","position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":310,"offset":6967},"indent":[]}}],"position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":310,"offset":6967},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To fill the gap, regarding the latter, we can rely on another solution called ","position":{"start":{"line":164,"column":1,"offset":6969},"end":{"line":164,"column":79,"offset":7047},"indent":[]}},{"type":"link","title":null,"url":"https://balena.io","children":[{"type":"text","value":"Balena.io","position":{"start":{"line":164,"column":80,"offset":7048},"end":{"line":164,"column":89,"offset":7057},"indent":[]}}],"position":{"start":{"line":164,"column":79,"offset":7047},"end":{"line":164,"column":109,"offset":7077},"indent":[]}},{"type":"text","value":". Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can support this.","position":{"start":{"line":164,"column":109,"offset":7077},"end":{"line":164,"column":332,"offset":7300},"indent":[]}}],"position":{"start":{"line":164,"column":1,"offset":6969},"end":{"line":164,"column":332,"offset":7300},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Especially in the worl\n even on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.","position":{"start":{"line":166,"column":1,"offset":7302},"end":{"line":167,"column":128,"offset":7452},"indent":[1]}}],"position":{"start":{"line":166,"column":1,"offset":7302},"end":{"line":167,"column":128,"offset":7452},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":169,"column":1,"offset":7454},"end":{"line":169,"column":4,"offset":7457},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":171,"column":3,"offset":7461},"end":{"line":171,"column":11,"offset":7469},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":7459},"end":{"line":171,"column":11,"offset":7469},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":173,"column":1,"offset":7471},"end":{"line":173,"column":133,"offset":7603},"indent":[]}}],"position":{"start":{"line":173,"column":1,"offset":7471},"end":{"line":173,"column":133,"offset":7603},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":175,"column":4,"offset":7608},"end":{"line":175,"column":12,"offset":7616},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7605},"end":{"line":175,"column":12,"offset":7616},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":177,"column":1,"offset":7618},"end":{"line":177,"column":193,"offset":7810},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7618},"end":{"line":177,"column":193,"offset":7810},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":179,"column":4,"offset":7815},"end":{"line":179,"column":62,"offset":7873},"indent":[]}}],"position":{"start":{"line":179,"column":4,"offset":7815},"end":{"line":179,"column":62,"offset":7873},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7812},"end":{"line":179,"column":62,"offset":7873},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":180,"column":4,"offset":7877},"end":{"line":180,"column":69,"offset":7942},"indent":[]}}],"position":{"start":{"line":180,"column":4,"offset":7877},"end":{"line":180,"column":69,"offset":7942},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7874},"end":{"line":180,"column":69,"offset":7942},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7812},"end":{"line":180,"column":69,"offset":7942},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":182,"column":1,"offset":7944},"end":{"line":182,"column":99,"offset":8042},"indent":[]}}],"position":{"start":{"line":182,"column":1,"offset":7944},"end":{"line":182,"column":99,"offset":8042},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":184,"column":5,"offset":8048},"end":{"line":184,"column":14,"offset":8057},"indent":[]}}],"position":{"start":{"line":184,"column":1,"offset":8044},"end":{"line":184,"column":14,"offset":8057},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":186,"column":1,"offset":8059},"end":{"line":186,"column":71,"offset":8129},"indent":[]}}],"position":{"start":{"line":186,"column":1,"offset":8059},"end":{"line":186,"column":71,"offset":8129},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":188,"column":3,"offset":8133},"end":{"line":188,"column":47,"offset":8177},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":188,"column":47,"offset":8177},"end":{"line":188,"column":79,"offset":8209},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":188,"column":79,"offset":8209},"end":{"line":188,"column":198,"offset":8328},"indent":[]}}],"position":{"start":{"line":188,"column":3,"offset":8133},"end":{"line":188,"column":198,"offset":8328},"indent":[]}}],"position":{"start":{"line":188,"column":1,"offset":8131},"end":{"line":188,"column":198,"offset":8328},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":190,"column":1,"offset":8330},"end":{"line":192,"column":4,"offset":8393},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":194,"column":5,"offset":8399},"end":{"line":194,"column":14,"offset":8408},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":8395},"end":{"line":194,"column":14,"offset":8408},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":196,"column":1,"offset":8410},"end":{"line":196,"column":56,"offset":8465},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8410},"end":{"line":196,"column":56,"offset":8465},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":197,"column":3,"offset":8468},"end":{"line":197,"column":52,"offset":8517},"indent":[]}}],"position":{"start":{"line":197,"column":3,"offset":8468},"end":{"line":197,"column":52,"offset":8517},"indent":[]}}],"position":{"start":{"line":197,"column":3,"offset":8468},"end":{"line":197,"column":52,"offset":8517},"indent":[]}}],"position":{"start":{"line":197,"column":1,"offset":8466},"end":{"line":197,"column":52,"offset":8517},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":199,"column":1,"offset":8519},"end":{"line":199,"column":3,"offset":8521},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":199,"column":3,"offset":8521},"end":{"line":199,"column":9,"offset":8527},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":199,"column":9,"offset":8527},"end":{"line":199,"column":223,"offset":8741},"indent":[]}}],"position":{"start":{"line":199,"column":1,"offset":8519},"end":{"line":199,"column":223,"offset":8741},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":201,"column":3,"offset":8745},"end":{"line":201,"column":159,"offset":8901},"indent":[]}}],"position":{"start":{"line":201,"column":3,"offset":8745},"end":{"line":201,"column":159,"offset":8901},"indent":[]}}],"position":{"start":{"line":201,"column":1,"offset":8743},"end":{"line":201,"column":159,"offset":8901},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":203,"column":1,"offset":8903},"end":{"line":206,"column":4,"offset":9080},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":208,"column":1,"offset":9082},"end":{"line":208,"column":160,"offset":9241},"indent":[]}}],"position":{"start":{"line":208,"column":1,"offset":9082},"end":{"line":208,"column":160,"offset":9241},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":210,"column":3,"offset":9245},"end":{"line":210,"column":31,"offset":9273},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":210,"column":31,"offset":9273},"end":{"line":210,"column":101,"offset":9343},"indent":[]}}],"position":{"start":{"line":210,"column":3,"offset":9245},"end":{"line":210,"column":101,"offset":9343},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":9243},"end":{"line":210,"column":101,"offset":9343},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":212,"column":1,"offset":9345},"end":{"line":215,"column":4,"offset":9517},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":217,"column":1,"offset":9519},"end":{"line":217,"column":73,"offset":9591},"indent":[]}}],"position":{"start":{"line":217,"column":1,"offset":9519},"end":{"line":217,"column":73,"offset":9591},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":220,"column":3,"offset":9596},"end":{"line":220,"column":31,"offset":9624},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":220,"column":31,"offset":9624},"end":{"line":220,"column":101,"offset":9694},"indent":[]}}],"position":{"start":{"line":220,"column":3,"offset":9596},"end":{"line":220,"column":101,"offset":9694},"indent":[]}}],"position":{"start":{"line":220,"column":1,"offset":9594},"end":{"line":220,"column":101,"offset":9694},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":222,"column":1,"offset":9696},"end":{"line":225,"column":4,"offset":9868},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":227,"column":1,"offset":9870},"end":{"line":227,"column":62,"offset":9931},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":227,"column":63,"offset":9932},"end":{"line":227,"column":75,"offset":9944},"indent":[]}}],"position":{"start":{"line":227,"column":62,"offset":9931},"end":{"line":227,"column":143,"offset":10012},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":227,"column":143,"offset":10012},"end":{"line":227,"column":150,"offset":10019},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":227,"column":150,"offset":10019},"end":{"line":227,"column":169,"offset":10038},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":227,"column":169,"offset":10038},"end":{"line":227,"column":170,"offset":10039},"indent":[]}}],"position":{"start":{"line":227,"column":1,"offset":9870},"end":{"line":227,"column":170,"offset":10039},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":229,"column":1,"offset":10041},"end":{"line":231,"column":4,"offset":10068},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":233,"column":1,"offset":10070},"end":{"line":233,"column":58,"offset":10127},"indent":[]}}],"position":{"start":{"line":233,"column":1,"offset":10070},"end":{"line":233,"column":58,"offset":10127},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":235,"column":1,"offset":10129},"end":{"line":238,"column":4,"offset":10199},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":240,"column":5,"offset":10205},"end":{"line":240,"column":8,"offset":10208},"indent":[]}}],"position":{"start":{"line":240,"column":1,"offset":10201},"end":{"line":240,"column":8,"offset":10208},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":242,"column":1,"offset":10210},"end":{"line":242,"column":280,"offset":10489},"indent":[]}}],"position":{"start":{"line":242,"column":1,"offset":10210},"end":{"line":242,"column":280,"offset":10489},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":244,"column":1,"offset":10491},"end":{"line":244,"column":37,"offset":10527},"indent":[]}}],"position":{"start":{"line":244,"column":1,"offset":10491},"end":{"line":244,"column":37,"offset":10527},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":246,"column":1,"offset":10529},"end":{"line":248,"column":4,"offset":10702},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":250,"column":1,"offset":10704},"end":{"line":250,"column":25,"offset":10728},"indent":[]}}],"position":{"start":{"line":250,"column":1,"offset":10704},"end":{"line":250,"column":25,"offset":10728},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":252,"column":1,"offset":10730},"end":{"line":255,"column":4,"offset":10834},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":257,"column":1,"offset":10836},"end":{"line":257,"column":118,"offset":10953},"indent":[]}}],"position":{"start":{"line":257,"column":1,"offset":10836},"end":{"line":257,"column":118,"offset":10953},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":259,"column":1,"offset":10955},"end":{"line":279,"column":4,"offset":11462},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":281,"column":1,"offset":11464},"end":{"line":281,"column":14,"offset":11477},"indent":[]}}],"position":{"start":{"line":281,"column":1,"offset":11464},"end":{"line":281,"column":14,"offset":11477},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":283,"column":1,"offset":11479},"end":{"line":285,"column":4,"offset":11515},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":287,"column":1,"offset":11517},"end":{"line":287,"column":91,"offset":11607},"indent":[]}}],"position":{"start":{"line":287,"column":1,"offset":11517},"end":{"line":287,"column":91,"offset":11607},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":289,"column":1,"offset":11609},"end":{"line":297,"column":4,"offset":11982},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":299,"column":1,"offset":11984},"end":{"line":299,"column":145,"offset":12128},"indent":[]}}],"position":{"start":{"line":299,"column":1,"offset":11984},"end":{"line":299,"column":145,"offset":12128},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":301,"column":5,"offset":12134},"end":{"line":301,"column":17,"offset":12146},"indent":[]}}],"position":{"start":{"line":301,"column":1,"offset":12130},"end":{"line":301,"column":17,"offset":12146},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":303,"column":1,"offset":12148},"end":{"line":303,"column":300,"offset":12447},"indent":[]}}],"position":{"start":{"line":303,"column":1,"offset":12148},"end":{"line":303,"column":300,"offset":12447},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":305,"column":1,"offset":12449},"end":{"line":305,"column":178,"offset":12626},"indent":[]}}],"position":{"start":{"line":305,"column":1,"offset":12449},"end":{"line":305,"column":178,"offset":12626},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":307,"column":1,"offset":12628},"end":{"line":307,"column":48,"offset":12675},"indent":[]}}],"position":{"start":{"line":307,"column":1,"offset":12628},"end":{"line":307,"column":48,"offset":12675},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":309,"column":1,"offset":12677},"end":{"line":311,"column":4,"offset":12717},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":313,"column":1,"offset":12719},"end":{"line":313,"column":104,"offset":12822},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":12719},"end":{"line":313,"column":104,"offset":12822},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":315,"column":1,"offset":12824},"end":{"line":323,"column":4,"offset":13094},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":325,"column":1,"offset":13096},"end":{"line":325,"column":28,"offset":13123},"indent":[]}}],"position":{"start":{"line":325,"column":1,"offset":13096},"end":{"line":325,"column":28,"offset":13123},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":327,"column":1,"offset":13125},"end":{"line":329,"column":4,"offset":13169},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":331,"column":1,"offset":13171},"end":{"line":331,"column":48,"offset":13218},"indent":[]}}],"position":{"start":{"line":331,"column":1,"offset":13171},"end":{"line":331,"column":48,"offset":13218},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":333,"column":1,"offset":13220},"end":{"line":335,"column":4,"offset":13242},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":337,"column":1,"offset":13244},"end":{"line":337,"column":72,"offset":13315},"indent":[]}}],"position":{"start":{"line":337,"column":1,"offset":13244},"end":{"line":337,"column":72,"offset":13315},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":339,"column":1,"offset":13317},"end":{"line":341,"column":4,"offset":13374},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":343,"column":4,"offset":13379},"end":{"line":343,"column":11,"offset":13386},"indent":[]}}],"position":{"start":{"line":343,"column":1,"offset":13376},"end":{"line":343,"column":11,"offset":13386},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":345,"column":1,"offset":13388},"end":{"line":345,"column":283,"offset":13670},"indent":[]}}],"position":{"start":{"line":345,"column":1,"offset":13388},"end":{"line":345,"column":283,"offset":13670},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":347,"column":3,"offset":13674},"end":{"line":347,"column":54,"offset":13725},"indent":[]}}],"position":{"start":{"line":347,"column":3,"offset":13674},"end":{"line":347,"column":54,"offset":13725},"indent":[]}}],"position":{"start":{"line":347,"column":1,"offset":13672},"end":{"line":347,"column":54,"offset":13725},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":349,"column":5,"offset":13731},"end":{"line":349,"column":14,"offset":13740},"indent":[]}}],"position":{"start":{"line":349,"column":1,"offset":13727},"end":{"line":349,"column":14,"offset":13740},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":351,"column":1,"offset":13742},"end":{"line":351,"column":68,"offset":13809},"indent":[]}}],"position":{"start":{"line":351,"column":1,"offset":13742},"end":{"line":351,"column":68,"offset":13809},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":353,"column":1,"offset":13811},"end":{"line":356,"column":4,"offset":13962},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":358,"column":1,"offset":13964},"end":{"line":358,"column":46,"offset":14009},"indent":[]}}],"position":{"start":{"line":358,"column":1,"offset":13964},"end":{"line":358,"column":46,"offset":14009},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":360,"column":3,"offset":14013},"end":{"line":360,"column":103,"offset":14113},"indent":[]}}],"position":{"start":{"line":360,"column":3,"offset":14013},"end":{"line":360,"column":103,"offset":14113},"indent":[]}}],"position":{"start":{"line":360,"column":1,"offset":14011},"end":{"line":360,"column":103,"offset":14113},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":362,"column":1,"offset":14115},"end":{"line":367,"column":4,"offset":14325},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":369,"column":1,"offset":14327},"end":{"line":369,"column":151,"offset":14477},"indent":[]}}],"position":{"start":{"line":369,"column":1,"offset":14327},"end":{"line":369,"column":151,"offset":14477},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":371,"column":3,"offset":14481},"end":{"line":371,"column":22,"offset":14500},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":371,"column":22,"offset":14500},"end":{"line":371,"column":26,"offset":14504},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":371,"column":26,"offset":14504},"end":{"line":371,"column":40,"offset":14518},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":371,"column":40,"offset":14518},"end":{"line":371,"column":50,"offset":14528},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":371,"column":50,"offset":14528},"end":{"line":371,"column":98,"offset":14576},"indent":[]}}],"position":{"start":{"line":371,"column":3,"offset":14481},"end":{"line":371,"column":98,"offset":14576},"indent":[]}}],"position":{"start":{"line":371,"column":1,"offset":14479},"end":{"line":371,"column":98,"offset":14576},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":373,"column":1,"offset":14578},"end":{"line":377,"column":4,"offset":14740},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":379,"column":1,"offset":14742},"end":{"line":379,"column":72,"offset":14813},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":379,"column":72,"offset":14813},"end":{"line":379,"column":84,"offset":14825},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":379,"column":84,"offset":14825},"end":{"line":379,"column":102,"offset":14843},"indent":[]}}],"position":{"start":{"line":379,"column":1,"offset":14742},"end":{"line":379,"column":102,"offset":14843},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":381,"column":1,"offset":14845},"end":{"line":384,"column":4,"offset":14919},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":386,"column":5,"offset":14925},"end":{"line":386,"column":8,"offset":14928},"indent":[]}}],"position":{"start":{"line":386,"column":1,"offset":14921},"end":{"line":386,"column":8,"offset":14928},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":388,"column":1,"offset":14930},"end":{"line":388,"column":176,"offset":15105},"indent":[]}}],"position":{"start":{"line":388,"column":1,"offset":14930},"end":{"line":388,"column":176,"offset":15105},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":390,"column":1,"offset":15107},"end":{"line":397,"column":4,"offset":15404},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":399,"column":1,"offset":15406},"end":{"line":399,"column":60,"offset":15465},"indent":[]}}],"position":{"start":{"line":399,"column":1,"offset":15406},"end":{"line":399,"column":60,"offset":15465},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":401,"column":1,"offset":15467},"end":{"line":405,"column":4,"offset":15593},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":407,"column":1,"offset":15595},"end":{"line":407,"column":63,"offset":15657},"indent":[]}}],"position":{"start":{"line":407,"column":1,"offset":15595},"end":{"line":407,"column":63,"offset":15657},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":409,"column":1,"offset":15659},"end":{"line":429,"column":4,"offset":16166},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":431,"column":1,"offset":16168},"end":{"line":431,"column":99,"offset":16266},"indent":[]}}],"position":{"start":{"line":431,"column":1,"offset":16168},"end":{"line":431,"column":99,"offset":16266},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":433,"column":1,"offset":16268},"end":{"line":436,"column":4,"offset":16370},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":438,"column":1,"offset":16372},"end":{"line":438,"column":37,"offset":16408},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":438,"column":37,"offset":16408},"end":{"line":438,"column":47,"offset":16418},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":438,"column":47,"offset":16418},"end":{"line":438,"column":89,"offset":16460},"indent":[]}}],"position":{"start":{"line":438,"column":1,"offset":16372},"end":{"line":438,"column":89,"offset":16460},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":440,"column":1,"offset":16462},"end":{"line":444,"column":4,"offset":16587},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":446,"column":1,"offset":16589},"end":{"line":446,"column":78,"offset":16666},"indent":[]}}],"position":{"start":{"line":446,"column":1,"offset":16589},"end":{"line":446,"column":78,"offset":16666},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":448,"column":1,"offset":16668},"end":{"line":452,"column":4,"offset":16772},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":454,"column":1,"offset":16774},"end":{"line":454,"column":75,"offset":16848},"indent":[]}}],"position":{"start":{"line":454,"column":1,"offset":16774},"end":{"line":454,"column":75,"offset":16848},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":456,"column":1,"offset":16850},"end":{"line":460,"column":4,"offset":16923},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":462,"column":1,"offset":16925},"end":{"line":462,"column":145,"offset":17069},"indent":[]}}],"position":{"start":{"line":462,"column":1,"offset":16925},"end":{"line":462,"column":145,"offset":17069},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":464,"column":5,"offset":17075},"end":{"line":464,"column":17,"offset":17087},"indent":[]}}],"position":{"start":{"line":464,"column":1,"offset":17071},"end":{"line":464,"column":17,"offset":17087},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":466,"column":1,"offset":17089},"end":{"line":466,"column":300,"offset":17388},"indent":[]}}],"position":{"start":{"line":466,"column":1,"offset":17089},"end":{"line":466,"column":300,"offset":17388},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":468,"column":1,"offset":17390},"end":{"line":468,"column":178,"offset":17567},"indent":[]}}],"position":{"start":{"line":468,"column":1,"offset":17390},"end":{"line":468,"column":178,"offset":17567},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":470,"column":1,"offset":17569},"end":{"line":470,"column":48,"offset":17616},"indent":[]}}],"position":{"start":{"line":470,"column":1,"offset":17569},"end":{"line":470,"column":48,"offset":17616},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":472,"column":1,"offset":17618},"end":{"line":474,"column":4,"offset":17662},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":476,"column":1,"offset":17664},"end":{"line":476,"column":104,"offset":17767},"indent":[]}}],"position":{"start":{"line":476,"column":1,"offset":17664},"end":{"line":476,"column":104,"offset":17767},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":478,"column":1,"offset":17769},"end":{"line":486,"column":4,"offset":18039},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":488,"column":1,"offset":18041},"end":{"line":488,"column":28,"offset":18068},"indent":[]}}],"position":{"start":{"line":488,"column":1,"offset":18041},"end":{"line":488,"column":28,"offset":18068},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":490,"column":1,"offset":18070},"end":{"line":492,"column":4,"offset":18118},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":494,"column":1,"offset":18120},"end":{"line":494,"column":48,"offset":18167},"indent":[]}}],"position":{"start":{"line":494,"column":1,"offset":18120},"end":{"line":494,"column":48,"offset":18167},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":496,"column":1,"offset":18169},"end":{"line":498,"column":4,"offset":18191},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":500,"column":1,"offset":18193},"end":{"line":500,"column":72,"offset":18264},"indent":[]}}],"position":{"start":{"line":500,"column":1,"offset":18193},"end":{"line":500,"column":72,"offset":18264},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":502,"column":1,"offset":18266},"end":{"line":504,"column":4,"offset":18327},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":507,"column":1,"offset":18330},"end":{"line":507,"column":31,"offset":18360},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":507,"column":31,"offset":18360}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.`}

\n

{`To fill the gap, regarding the latter, we can rely on another solution called `}{`Balena.io`}{`. Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can support this.`}

\n

{`Especially in the worl\neven on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-2700cbe0fa446f181450db29e00f8f7f.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-2700cbe0fa446f181450db29e00f8f7f.json new file mode 100644 index 0000000..52e7e30 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-2700cbe0fa446f181450db29e00f8f7f.json @@ -0,0 +1 @@ +{"expireTime":9007200841981518000,"key":"gatsby-plugin-mdx-entire-payload-b370be834ca6179a5b53b69d54439c33-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":9,"offset":451},"indent":[]}}],"position":{"start":{"line":14,"column":4,"offset":446},"end":{"line":14,"column":41,"offset":483},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":14,"column":41,"offset":483},"end":{"line":14,"column":116,"offset":558},"indent":[]}}],"position":{"start":{"line":14,"column":4,"offset":446},"end":{"line":14,"column":116,"offset":558},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":116,"offset":558},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":15,"column":5,"offset":563},"end":{"line":15,"column":13,"offset":571},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":562},"end":{"line":15,"column":49,"offset":607},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":15,"column":49,"offset":607},"end":{"line":15,"column":139,"offset":697},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":562},"end":{"line":15,"column":139,"offset":697},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":559},"end":{"line":15,"column":139,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":702},"end":{"line":16,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":701},"end":{"line":16,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":742},"end":{"line":16,"column":121,"offset":818},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":701},"end":{"line":16,"column":121,"offset":818},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":698},"end":{"line":16,"column":121,"offset":818},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":823},"end":{"line":17,"column":11,"offset":829},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":822},"end":{"line":17,"column":45,"offset":863},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":863},"end":{"line":17,"column":103,"offset":921},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":822},"end":{"line":17,"column":103,"offset":921},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":819},"end":{"line":17,"column":103,"offset":921},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":18,"column":5,"offset":926},"end":{"line":18,"column":12,"offset":933},"indent":[]}}],"position":{"start":{"line":18,"column":4,"offset":925},"end":{"line":18,"column":47,"offset":968},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":18,"column":47,"offset":968},"end":{"line":18,"column":179,"offset":1100},"indent":[]}}],"position":{"start":{"line":18,"column":4,"offset":925},"end":{"line":18,"column":179,"offset":1100},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":922},"end":{"line":18,"column":179,"offset":1100},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":18,"column":179,"offset":1100},"indent":[1,1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":20,"column":4,"offset":1105},"end":{"line":20,"column":8,"offset":1109},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":1102},"end":{"line":20,"column":8,"offset":1109},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":22,"column":1,"offset":1111},"end":{"line":22,"column":229,"offset":1339},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1111},"end":{"line":22,"column":229,"offset":1339},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":24,"column":1,"offset":1341},"end":{"line":24,"column":197,"offset":1537},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1341},"end":{"line":24,"column":197,"offset":1537},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":26,"column":5,"offset":1543},"end":{"line":26,"column":11,"offset":1549},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1539},"end":{"line":26,"column":11,"offset":1549},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":28,"column":1,"offset":1551},"end":{"line":28,"column":63,"offset":1613},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":28,"column":64,"offset":1614},"end":{"line":28,"column":85,"offset":1635},"indent":[]}}],"position":{"start":{"line":28,"column":63,"offset":1613},"end":{"line":28,"column":123,"offset":1673},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":28,"column":123,"offset":1673},"end":{"line":28,"column":124,"offset":1674},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":1551},"end":{"line":28,"column":124,"offset":1674},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos installer","position":{"start":{"line":30,"column":5,"offset":1680},"end":{"line":30,"column":23,"offset":1698},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":1676},"end":{"line":30,"column":23,"offset":1698},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":32,"column":1,"offset":1700},"end":{"line":32,"column":228,"offset":1927},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":1700},"end":{"line":32,"column":228,"offset":1927},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":34,"column":1,"offset":1929},"end":{"line":34,"column":67,"offset":1995},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":1929},"end":{"line":34,"column":67,"offset":1995},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":36,"column":1,"offset":1997},"end":{"line":36,"column":50,"offset":2046},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":1997},"end":{"line":36,"column":50,"offset":2046},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":38,"column":3,"offset":2050},"end":{"line":38,"column":49,"offset":2096},"indent":[]}}],"position":{"start":{"line":38,"column":3,"offset":2050},"end":{"line":38,"column":49,"offset":2096},"indent":[]}}],"position":{"start":{"line":38,"column":3,"offset":2050},"end":{"line":38,"column":49,"offset":2096},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":2048},"end":{"line":38,"column":49,"offset":2096},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":40,"column":5,"offset":2102},"end":{"line":40,"column":11,"offset":2108},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":2098},"end":{"line":40,"column":11,"offset":2108},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":42,"column":1,"offset":2110},"end":{"line":42,"column":160,"offset":2269},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":2110},"end":{"line":42,"column":160,"offset":2269},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":44,"column":4,"offset":2274},"end":{"line":44,"column":13,"offset":2283},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":44,"column":14,"offset":2284},"end":{"line":44,"column":28,"offset":2298},"indent":[]}}],"position":{"start":{"line":44,"column":13,"offset":2283},"end":{"line":44,"column":75,"offset":2345},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":44,"column":75,"offset":2345},"end":{"line":44,"column":76,"offset":2346},"indent":[]}}],"position":{"start":{"line":44,"column":4,"offset":2274},"end":{"line":44,"column":76,"offset":2346},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":2271},"end":{"line":44,"column":76,"offset":2346},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":45,"column":4,"offset":2350},"end":{"line":45,"column":41,"offset":2387},"indent":[]}}],"position":{"start":{"line":45,"column":4,"offset":2350},"end":{"line":45,"column":41,"offset":2387},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2347},"end":{"line":45,"column":41,"offset":2387},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":46,"column":4,"offset":2391},"end":{"line":46,"column":60,"offset":2447},"indent":[]}}],"position":{"start":{"line":46,"column":4,"offset":2391},"end":{"line":46,"column":60,"offset":2447},"indent":[]}}],"position":{"start":{"line":46,"column":1,"offset":2388},"end":{"line":46,"column":60,"offset":2447},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":2271},"end":{"line":46,"column":60,"offset":2447},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":48,"column":2,"offset":2450},"end":{"line":48,"column":64,"offset":2512},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2449},"end":{"line":48,"column":96,"offset":2544},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2449},"end":{"line":48,"column":96,"offset":2544},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":50,"column":1,"offset":2546},"end":{"line":50,"column":204,"offset":2749},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":2546},"end":{"line":50,"column":204,"offset":2749},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":52,"column":6,"offset":2756},"end":{"line":52,"column":24,"offset":2774},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2751},"end":{"line":52,"column":24,"offset":2774},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":54,"column":1,"offset":2776},"end":{"line":54,"column":95,"offset":2870},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":54,"column":95,"offset":2870},"end":{"line":54,"column":110,"offset":2885},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":54,"column":110,"offset":2885},"end":{"line":54,"column":222,"offset":2997},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2776},"end":{"line":54,"column":222,"offset":2997},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":56,"column":1,"offset":2999},"end":{"line":64,"column":4,"offset":3108},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":66,"column":6,"offset":3115},"end":{"line":66,"column":31,"offset":3140},"indent":[]}}],"position":{"start":{"line":66,"column":1,"offset":3110},"end":{"line":66,"column":31,"offset":3140},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":68,"column":1,"offset":3142},"end":{"line":68,"column":79,"offset":3220},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":68,"column":79,"offset":3220},"end":{"line":68,"column":95,"offset":3236},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":68,"column":95,"offset":3236},"end":{"line":68,"column":137,"offset":3278},"indent":[]}}],"position":{"start":{"line":68,"column":1,"offset":3142},"end":{"line":68,"column":137,"offset":3278},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":70,"column":1,"offset":3280},"end":{"line":80,"column":4,"offset":3648},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":82,"column":5,"offset":3654},"end":{"line":82,"column":30,"offset":3679},"indent":[]}}],"position":{"start":{"line":82,"column":1,"offset":3650},"end":{"line":82,"column":30,"offset":3679},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":84,"column":1,"offset":3681},"end":{"line":84,"column":464,"offset":4144},"indent":[]}}],"position":{"start":{"line":84,"column":1,"offset":3681},"end":{"line":84,"column":464,"offset":4144},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":86,"column":1,"offset":4146},"end":{"line":86,"column":61,"offset":4206},"indent":[]}}],"position":{"start":{"line":86,"column":1,"offset":4146},"end":{"line":86,"column":61,"offset":4206},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":88,"column":5,"offset":4212},"end":{"line":88,"column":28,"offset":4235},"indent":[]}}],"position":{"start":{"line":88,"column":1,"offset":4208},"end":{"line":88,"column":28,"offset":4235},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":90,"column":1,"offset":4237},"end":{"line":90,"column":95,"offset":4331},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":90,"column":95,"offset":4331},"end":{"line":90,"column":100,"offset":4336},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":90,"column":100,"offset":4336},"end":{"line":90,"column":101,"offset":4337},"indent":[]}}],"position":{"start":{"line":90,"column":1,"offset":4237},"end":{"line":90,"column":101,"offset":4337},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":92,"column":1,"offset":4339},"end":{"line":96,"column":4,"offset":4456},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":98,"column":1,"offset":4458},"end":{"line":98,"column":80,"offset":4537},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":98,"column":80,"offset":4537},"end":{"line":98,"column":101,"offset":4558},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":98,"column":101,"offset":4558},"end":{"line":98,"column":162,"offset":4619},"indent":[]}}],"position":{"start":{"line":98,"column":1,"offset":4458},"end":{"line":98,"column":162,"offset":4619},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":100,"column":1,"offset":4621},"end":{"line":103,"column":4,"offset":4710},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":105,"column":4,"offset":4715},"end":{"line":105,"column":12,"offset":4723},"indent":[]}}],"position":{"start":{"line":105,"column":1,"offset":4712},"end":{"line":105,"column":12,"offset":4723},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":107,"column":1,"offset":4725},"end":{"line":107,"column":193,"offset":4917},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4725},"end":{"line":107,"column":193,"offset":4917},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":109,"column":4,"offset":4922},"end":{"line":109,"column":62,"offset":4980},"indent":[]}}],"position":{"start":{"line":109,"column":4,"offset":4922},"end":{"line":109,"column":62,"offset":4980},"indent":[]}}],"position":{"start":{"line":109,"column":1,"offset":4919},"end":{"line":109,"column":62,"offset":4980},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":110,"column":4,"offset":4984},"end":{"line":110,"column":69,"offset":5049},"indent":[]}}],"position":{"start":{"line":110,"column":4,"offset":4984},"end":{"line":110,"column":69,"offset":5049},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4981},"end":{"line":110,"column":69,"offset":5049},"indent":[]}}],"position":{"start":{"line":109,"column":1,"offset":4919},"end":{"line":110,"column":69,"offset":5049},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":112,"column":1,"offset":5051},"end":{"line":112,"column":99,"offset":5149},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":5051},"end":{"line":112,"column":99,"offset":5149},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":114,"column":5,"offset":5155},"end":{"line":114,"column":14,"offset":5164},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":5151},"end":{"line":114,"column":14,"offset":5164},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":116,"column":1,"offset":5166},"end":{"line":116,"column":71,"offset":5236},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":5166},"end":{"line":116,"column":71,"offset":5236},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":118,"column":3,"offset":5240},"end":{"line":118,"column":47,"offset":5284},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":118,"column":47,"offset":5284},"end":{"line":118,"column":79,"offset":5316},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":118,"column":79,"offset":5316},"end":{"line":118,"column":198,"offset":5435},"indent":[]}}],"position":{"start":{"line":118,"column":3,"offset":5240},"end":{"line":118,"column":198,"offset":5435},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5238},"end":{"line":118,"column":198,"offset":5435},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":120,"column":1,"offset":5437},"end":{"line":122,"column":4,"offset":5500},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":124,"column":5,"offset":5506},"end":{"line":124,"column":14,"offset":5515},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5502},"end":{"line":124,"column":14,"offset":5515},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":126,"column":1,"offset":5517},"end":{"line":126,"column":56,"offset":5572},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5517},"end":{"line":126,"column":56,"offset":5572},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":127,"column":3,"offset":5575},"end":{"line":127,"column":52,"offset":5624},"indent":[]}}],"position":{"start":{"line":127,"column":3,"offset":5575},"end":{"line":127,"column":52,"offset":5624},"indent":[]}}],"position":{"start":{"line":127,"column":3,"offset":5575},"end":{"line":127,"column":52,"offset":5624},"indent":[]}}],"position":{"start":{"line":127,"column":1,"offset":5573},"end":{"line":127,"column":52,"offset":5624},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":129,"column":1,"offset":5626},"end":{"line":129,"column":3,"offset":5628},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":129,"column":3,"offset":5628},"end":{"line":129,"column":9,"offset":5634},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":129,"column":9,"offset":5634},"end":{"line":129,"column":223,"offset":5848},"indent":[]}}],"position":{"start":{"line":129,"column":1,"offset":5626},"end":{"line":129,"column":223,"offset":5848},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":131,"column":3,"offset":5852},"end":{"line":131,"column":159,"offset":6008},"indent":[]}}],"position":{"start":{"line":131,"column":3,"offset":5852},"end":{"line":131,"column":159,"offset":6008},"indent":[]}}],"position":{"start":{"line":131,"column":1,"offset":5850},"end":{"line":131,"column":159,"offset":6008},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":133,"column":1,"offset":6010},"end":{"line":136,"column":4,"offset":6187},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":138,"column":1,"offset":6189},"end":{"line":138,"column":160,"offset":6348},"indent":[]}}],"position":{"start":{"line":138,"column":1,"offset":6189},"end":{"line":138,"column":160,"offset":6348},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":140,"column":3,"offset":6352},"end":{"line":140,"column":31,"offset":6380},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":140,"column":31,"offset":6380},"end":{"line":140,"column":101,"offset":6450},"indent":[]}}],"position":{"start":{"line":140,"column":3,"offset":6352},"end":{"line":140,"column":101,"offset":6450},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6350},"end":{"line":140,"column":101,"offset":6450},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":142,"column":1,"offset":6452},"end":{"line":145,"column":4,"offset":6624},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":147,"column":1,"offset":6626},"end":{"line":147,"column":73,"offset":6698},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6626},"end":{"line":147,"column":73,"offset":6698},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":150,"column":3,"offset":6703},"end":{"line":150,"column":31,"offset":6731},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":150,"column":31,"offset":6731},"end":{"line":150,"column":101,"offset":6801},"indent":[]}}],"position":{"start":{"line":150,"column":3,"offset":6703},"end":{"line":150,"column":101,"offset":6801},"indent":[]}}],"position":{"start":{"line":150,"column":1,"offset":6701},"end":{"line":150,"column":101,"offset":6801},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":152,"column":1,"offset":6803},"end":{"line":155,"column":4,"offset":6975},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":157,"column":1,"offset":6977},"end":{"line":157,"column":62,"offset":7038},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":157,"column":63,"offset":7039},"end":{"line":157,"column":75,"offset":7051},"indent":[]}}],"position":{"start":{"line":157,"column":62,"offset":7038},"end":{"line":157,"column":143,"offset":7119},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":157,"column":143,"offset":7119},"end":{"line":157,"column":150,"offset":7126},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":157,"column":150,"offset":7126},"end":{"line":157,"column":169,"offset":7145},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":157,"column":169,"offset":7145},"end":{"line":157,"column":170,"offset":7146},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6977},"end":{"line":157,"column":170,"offset":7146},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":159,"column":1,"offset":7148},"end":{"line":161,"column":4,"offset":7175},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":163,"column":1,"offset":7177},"end":{"line":163,"column":58,"offset":7234},"indent":[]}}],"position":{"start":{"line":163,"column":1,"offset":7177},"end":{"line":163,"column":58,"offset":7234},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":165,"column":1,"offset":7236},"end":{"line":168,"column":4,"offset":7306},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":170,"column":5,"offset":7312},"end":{"line":170,"column":8,"offset":7315},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7308},"end":{"line":170,"column":8,"offset":7315},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":172,"column":1,"offset":7317},"end":{"line":172,"column":280,"offset":7596},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7317},"end":{"line":172,"column":280,"offset":7596},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":174,"column":1,"offset":7598},"end":{"line":174,"column":37,"offset":7634},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7598},"end":{"line":174,"column":37,"offset":7634},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":176,"column":1,"offset":7636},"end":{"line":178,"column":4,"offset":7809},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":180,"column":1,"offset":7811},"end":{"line":180,"column":25,"offset":7835},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7811},"end":{"line":180,"column":25,"offset":7835},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":182,"column":1,"offset":7837},"end":{"line":185,"column":4,"offset":7941},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":187,"column":1,"offset":7943},"end":{"line":187,"column":118,"offset":8060},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":7943},"end":{"line":187,"column":118,"offset":8060},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":189,"column":1,"offset":8062},"end":{"line":209,"column":4,"offset":8569},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":211,"column":1,"offset":8571},"end":{"line":211,"column":14,"offset":8584},"indent":[]}}],"position":{"start":{"line":211,"column":1,"offset":8571},"end":{"line":211,"column":14,"offset":8584},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":213,"column":1,"offset":8586},"end":{"line":215,"column":4,"offset":8622},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":217,"column":1,"offset":8624},"end":{"line":217,"column":91,"offset":8714},"indent":[]}}],"position":{"start":{"line":217,"column":1,"offset":8624},"end":{"line":217,"column":91,"offset":8714},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":219,"column":1,"offset":8716},"end":{"line":227,"column":4,"offset":9089},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":229,"column":1,"offset":9091},"end":{"line":229,"column":145,"offset":9235},"indent":[]}}],"position":{"start":{"line":229,"column":1,"offset":9091},"end":{"line":229,"column":145,"offset":9235},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":231,"column":5,"offset":9241},"end":{"line":231,"column":17,"offset":9253},"indent":[]}}],"position":{"start":{"line":231,"column":1,"offset":9237},"end":{"line":231,"column":17,"offset":9253},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":233,"column":1,"offset":9255},"end":{"line":233,"column":300,"offset":9554},"indent":[]}}],"position":{"start":{"line":233,"column":1,"offset":9255},"end":{"line":233,"column":300,"offset":9554},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":235,"column":1,"offset":9556},"end":{"line":235,"column":178,"offset":9733},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":9556},"end":{"line":235,"column":178,"offset":9733},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":237,"column":1,"offset":9735},"end":{"line":237,"column":48,"offset":9782},"indent":[]}}],"position":{"start":{"line":237,"column":1,"offset":9735},"end":{"line":237,"column":48,"offset":9782},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":239,"column":1,"offset":9784},"end":{"line":241,"column":4,"offset":9824},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":243,"column":1,"offset":9826},"end":{"line":243,"column":104,"offset":9929},"indent":[]}}],"position":{"start":{"line":243,"column":1,"offset":9826},"end":{"line":243,"column":104,"offset":9929},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":245,"column":1,"offset":9931},"end":{"line":253,"column":4,"offset":10201},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":255,"column":1,"offset":10203},"end":{"line":255,"column":28,"offset":10230},"indent":[]}}],"position":{"start":{"line":255,"column":1,"offset":10203},"end":{"line":255,"column":28,"offset":10230},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":257,"column":1,"offset":10232},"end":{"line":259,"column":4,"offset":10276},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":261,"column":1,"offset":10278},"end":{"line":261,"column":48,"offset":10325},"indent":[]}}],"position":{"start":{"line":261,"column":1,"offset":10278},"end":{"line":261,"column":48,"offset":10325},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":263,"column":1,"offset":10327},"end":{"line":265,"column":4,"offset":10349},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":267,"column":1,"offset":10351},"end":{"line":267,"column":72,"offset":10422},"indent":[]}}],"position":{"start":{"line":267,"column":1,"offset":10351},"end":{"line":267,"column":72,"offset":10422},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":269,"column":1,"offset":10424},"end":{"line":271,"column":4,"offset":10481},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":273,"column":4,"offset":10486},"end":{"line":273,"column":10,"offset":10492},"indent":[]}}],"position":{"start":{"line":273,"column":1,"offset":10483},"end":{"line":273,"column":10,"offset":10492},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":275,"column":1,"offset":10494},"end":{"line":275,"column":337,"offset":10830},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":275,"column":338,"offset":10831},"end":{"line":275,"column":352,"offset":10845},"indent":[]}}],"position":{"start":{"line":275,"column":337,"offset":10830},"end":{"line":275,"column":388,"offset":10881},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":275,"column":388,"offset":10881},"end":{"line":275,"column":389,"offset":10882},"indent":[]}}],"position":{"start":{"line":275,"column":1,"offset":10494},"end":{"line":275,"column":389,"offset":10882},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":277,"column":5,"offset":10888},"end":{"line":277,"column":18,"offset":10901},"indent":[]}}],"position":{"start":{"line":277,"column":1,"offset":10884},"end":{"line":277,"column":18,"offset":10901},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":279,"column":3,"offset":10905},"end":{"line":279,"column":50,"offset":10952},"indent":[]}}],"position":{"start":{"line":279,"column":3,"offset":10905},"end":{"line":279,"column":50,"offset":10952},"indent":[]}}],"position":{"start":{"line":279,"column":1,"offset":10903},"end":{"line":279,"column":50,"offset":10952},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":281,"column":5,"offset":10958},"end":{"line":281,"column":11,"offset":10964},"indent":[]}}],"position":{"start":{"line":281,"column":1,"offset":10954},"end":{"line":281,"column":11,"offset":10964},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":283,"column":1,"offset":10966},"end":{"line":283,"column":64,"offset":11029},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":283,"column":65,"offset":11030},"end":{"line":283,"column":86,"offset":11051},"indent":[]}}],"position":{"start":{"line":283,"column":64,"offset":11029},"end":{"line":283,"column":126,"offset":11091},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":283,"column":126,"offset":11091},"end":{"line":283,"column":127,"offset":11092},"indent":[]}}],"position":{"start":{"line":283,"column":1,"offset":10966},"end":{"line":283,"column":127,"offset":11092},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":285,"column":5,"offset":11098},"end":{"line":285,"column":26,"offset":11119},"indent":[]}}],"position":{"start":{"line":285,"column":1,"offset":11094},"end":{"line":285,"column":26,"offset":11119},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":287,"column":1,"offset":11121},"end":{"line":287,"column":126,"offset":11246},"indent":[]}}],"position":{"start":{"line":287,"column":1,"offset":11121},"end":{"line":287,"column":126,"offset":11246},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":289,"column":1,"offset":11248},"end":{"line":291,"column":4,"offset":11287},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":293,"column":1,"offset":11289},"end":{"line":293,"column":187,"offset":11475},"indent":[]}}],"position":{"start":{"line":293,"column":1,"offset":11289},"end":{"line":293,"column":187,"offset":11475},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":295,"column":1,"offset":11477},"end":{"line":297,"column":4,"offset":11555},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":299,"column":1,"offset":11557},"end":{"line":299,"column":153,"offset":11709},"indent":[]}}],"position":{"start":{"line":299,"column":1,"offset":11557},"end":{"line":299,"column":153,"offset":11709},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":301,"column":1,"offset":11711},"end":{"line":304,"column":4,"offset":11858},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":306,"column":1,"offset":11860},"end":{"line":306,"column":100,"offset":11959},"indent":[]}}],"position":{"start":{"line":306,"column":1,"offset":11860},"end":{"line":306,"column":100,"offset":11959},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":307,"column":1,"offset":11960},"end":{"line":311,"column":4,"offset":12029},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":313,"column":5,"offset":12035},"end":{"line":313,"column":12,"offset":12042},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":12031},"end":{"line":313,"column":12,"offset":12042},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":315,"column":1,"offset":12044},"end":{"line":315,"column":64,"offset":12107},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12044},"end":{"line":315,"column":64,"offset":12107},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":316,"column":3,"offset":12110},"end":{"line":316,"column":25,"offset":12132},"indent":[]}}],"position":{"start":{"line":316,"column":3,"offset":12110},"end":{"line":316,"column":25,"offset":12132},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12108},"end":{"line":316,"column":25,"offset":12132},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":317,"column":3,"offset":12135},"end":{"line":317,"column":59,"offset":12191},"indent":[]}}],"position":{"start":{"line":317,"column":3,"offset":12135},"end":{"line":317,"column":59,"offset":12191},"indent":[]}}],"position":{"start":{"line":317,"column":1,"offset":12133},"end":{"line":317,"column":59,"offset":12191},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12108},"end":{"line":317,"column":59,"offset":12191},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":319,"column":4,"offset":12196},"end":{"line":319,"column":10,"offset":12202},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":12193},"end":{"line":319,"column":10,"offset":12202},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":322,"column":4,"offset":12208},"end":{"line":322,"column":11,"offset":12215},"indent":[]}}],"position":{"start":{"line":322,"column":1,"offset":12205},"end":{"line":322,"column":11,"offset":12215},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":324,"column":1,"offset":12217},"end":{"line":324,"column":283,"offset":12499},"indent":[]}}],"position":{"start":{"line":324,"column":1,"offset":12217},"end":{"line":324,"column":283,"offset":12499},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":326,"column":3,"offset":12503},"end":{"line":326,"column":54,"offset":12554},"indent":[]}}],"position":{"start":{"line":326,"column":3,"offset":12503},"end":{"line":326,"column":54,"offset":12554},"indent":[]}}],"position":{"start":{"line":326,"column":1,"offset":12501},"end":{"line":326,"column":54,"offset":12554},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":328,"column":5,"offset":12560},"end":{"line":328,"column":14,"offset":12569},"indent":[]}}],"position":{"start":{"line":328,"column":1,"offset":12556},"end":{"line":328,"column":14,"offset":12569},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":330,"column":1,"offset":12571},"end":{"line":330,"column":68,"offset":12638},"indent":[]}}],"position":{"start":{"line":330,"column":1,"offset":12571},"end":{"line":330,"column":68,"offset":12638},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":332,"column":1,"offset":12640},"end":{"line":335,"column":4,"offset":12791},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":337,"column":1,"offset":12793},"end":{"line":337,"column":46,"offset":12838},"indent":[]}}],"position":{"start":{"line":337,"column":1,"offset":12793},"end":{"line":337,"column":46,"offset":12838},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":339,"column":3,"offset":12842},"end":{"line":339,"column":103,"offset":12942},"indent":[]}}],"position":{"start":{"line":339,"column":3,"offset":12842},"end":{"line":339,"column":103,"offset":12942},"indent":[]}}],"position":{"start":{"line":339,"column":1,"offset":12840},"end":{"line":339,"column":103,"offset":12942},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":341,"column":1,"offset":12944},"end":{"line":346,"column":4,"offset":13154},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":348,"column":1,"offset":13156},"end":{"line":348,"column":151,"offset":13306},"indent":[]}}],"position":{"start":{"line":348,"column":1,"offset":13156},"end":{"line":348,"column":151,"offset":13306},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":350,"column":3,"offset":13310},"end":{"line":350,"column":22,"offset":13329},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":350,"column":22,"offset":13329},"end":{"line":350,"column":26,"offset":13333},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":350,"column":26,"offset":13333},"end":{"line":350,"column":40,"offset":13347},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":350,"column":40,"offset":13347},"end":{"line":350,"column":50,"offset":13357},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":350,"column":50,"offset":13357},"end":{"line":350,"column":98,"offset":13405},"indent":[]}}],"position":{"start":{"line":350,"column":3,"offset":13310},"end":{"line":350,"column":98,"offset":13405},"indent":[]}}],"position":{"start":{"line":350,"column":1,"offset":13308},"end":{"line":350,"column":98,"offset":13405},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":352,"column":1,"offset":13407},"end":{"line":356,"column":4,"offset":13569},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":358,"column":1,"offset":13571},"end":{"line":358,"column":72,"offset":13642},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":358,"column":72,"offset":13642},"end":{"line":358,"column":84,"offset":13654},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":358,"column":84,"offset":13654},"end":{"line":358,"column":102,"offset":13672},"indent":[]}}],"position":{"start":{"line":358,"column":1,"offset":13571},"end":{"line":358,"column":102,"offset":13672},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":360,"column":1,"offset":13674},"end":{"line":363,"column":4,"offset":13748},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":365,"column":5,"offset":13754},"end":{"line":365,"column":8,"offset":13757},"indent":[]}}],"position":{"start":{"line":365,"column":1,"offset":13750},"end":{"line":365,"column":8,"offset":13757},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":367,"column":1,"offset":13759},"end":{"line":367,"column":176,"offset":13934},"indent":[]}}],"position":{"start":{"line":367,"column":1,"offset":13759},"end":{"line":367,"column":176,"offset":13934},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":369,"column":1,"offset":13936},"end":{"line":376,"column":4,"offset":14233},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":378,"column":1,"offset":14235},"end":{"line":378,"column":60,"offset":14294},"indent":[]}}],"position":{"start":{"line":378,"column":1,"offset":14235},"end":{"line":378,"column":60,"offset":14294},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":380,"column":1,"offset":14296},"end":{"line":384,"column":4,"offset":14422},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":386,"column":1,"offset":14424},"end":{"line":386,"column":63,"offset":14486},"indent":[]}}],"position":{"start":{"line":386,"column":1,"offset":14424},"end":{"line":386,"column":63,"offset":14486},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":388,"column":1,"offset":14488},"end":{"line":408,"column":4,"offset":14995},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":410,"column":1,"offset":14997},"end":{"line":410,"column":99,"offset":15095},"indent":[]}}],"position":{"start":{"line":410,"column":1,"offset":14997},"end":{"line":410,"column":99,"offset":15095},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":412,"column":1,"offset":15097},"end":{"line":415,"column":4,"offset":15199},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":417,"column":1,"offset":15201},"end":{"line":417,"column":37,"offset":15237},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":417,"column":37,"offset":15237},"end":{"line":417,"column":47,"offset":15247},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":417,"column":47,"offset":15247},"end":{"line":417,"column":89,"offset":15289},"indent":[]}}],"position":{"start":{"line":417,"column":1,"offset":15201},"end":{"line":417,"column":89,"offset":15289},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":419,"column":1,"offset":15291},"end":{"line":423,"column":4,"offset":15416},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":425,"column":1,"offset":15418},"end":{"line":425,"column":78,"offset":15495},"indent":[]}}],"position":{"start":{"line":425,"column":1,"offset":15418},"end":{"line":425,"column":78,"offset":15495},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":427,"column":1,"offset":15497},"end":{"line":431,"column":4,"offset":15601},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":433,"column":1,"offset":15603},"end":{"line":433,"column":75,"offset":15677},"indent":[]}}],"position":{"start":{"line":433,"column":1,"offset":15603},"end":{"line":433,"column":75,"offset":15677},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":435,"column":1,"offset":15679},"end":{"line":439,"column":4,"offset":15752},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":441,"column":1,"offset":15754},"end":{"line":441,"column":145,"offset":15898},"indent":[]}}],"position":{"start":{"line":441,"column":1,"offset":15754},"end":{"line":441,"column":145,"offset":15898},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":443,"column":5,"offset":15904},"end":{"line":443,"column":17,"offset":15916},"indent":[]}}],"position":{"start":{"line":443,"column":1,"offset":15900},"end":{"line":443,"column":17,"offset":15916},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":445,"column":1,"offset":15918},"end":{"line":445,"column":300,"offset":16217},"indent":[]}}],"position":{"start":{"line":445,"column":1,"offset":15918},"end":{"line":445,"column":300,"offset":16217},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":447,"column":1,"offset":16219},"end":{"line":447,"column":178,"offset":16396},"indent":[]}}],"position":{"start":{"line":447,"column":1,"offset":16219},"end":{"line":447,"column":178,"offset":16396},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":449,"column":1,"offset":16398},"end":{"line":449,"column":48,"offset":16445},"indent":[]}}],"position":{"start":{"line":449,"column":1,"offset":16398},"end":{"line":449,"column":48,"offset":16445},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":451,"column":1,"offset":16447},"end":{"line":453,"column":4,"offset":16491},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":455,"column":1,"offset":16493},"end":{"line":455,"column":104,"offset":16596},"indent":[]}}],"position":{"start":{"line":455,"column":1,"offset":16493},"end":{"line":455,"column":104,"offset":16596},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":457,"column":1,"offset":16598},"end":{"line":465,"column":4,"offset":16868},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":467,"column":1,"offset":16870},"end":{"line":467,"column":28,"offset":16897},"indent":[]}}],"position":{"start":{"line":467,"column":1,"offset":16870},"end":{"line":467,"column":28,"offset":16897},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":469,"column":1,"offset":16899},"end":{"line":471,"column":4,"offset":16947},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":473,"column":1,"offset":16949},"end":{"line":473,"column":48,"offset":16996},"indent":[]}}],"position":{"start":{"line":473,"column":1,"offset":16949},"end":{"line":473,"column":48,"offset":16996},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":475,"column":1,"offset":16998},"end":{"line":477,"column":4,"offset":17020},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":479,"column":1,"offset":17022},"end":{"line":479,"column":72,"offset":17093},"indent":[]}}],"position":{"start":{"line":479,"column":1,"offset":17022},"end":{"line":479,"column":72,"offset":17093},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":481,"column":1,"offset":17095},"end":{"line":483,"column":4,"offset":17156},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":486,"column":1,"offset":17159},"end":{"line":486,"column":31,"offset":17189},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":486,"column":31,"offset":17189}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  4. \n
  5. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  6. \n
  7. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  8. \n
  9. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  10. \n
\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Docker`}

\n

{`A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-2be2590779b804ede018a8925fff1146.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-2be2590779b804ede018a8925fff1146.json index f332b34..8f72396 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-2be2590779b804ede018a8925fff1146.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-2be2590779b804ede018a8925fff1146.json @@ -1 +1 @@ -{"expireTime":9007200841014157000,"key":"gatsby-plugin-mdx-entire-payload-288833c279b8ca663cd64d85ba356e57-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Release notes","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":16,"offset":174},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":16,"offset":174},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"1.0.0","position":{"start":{"line":10,"column":5,"offset":180},"end":{"line":10,"column":10,"offset":185},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":176},"end":{"line":10,"column":10,"offset":185},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Factory","position":{"start":{"line":12,"column":6,"offset":192},"end":{"line":12,"column":13,"offset":199},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":187},"end":{"line":12,"column":13,"offset":199},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"React application using the Kubernetes and Docker Golang SDK.","position":{"start":{"line":14,"column":3,"offset":203},"end":{"line":14,"column":64,"offset":264},"indent":[]}}],"position":{"start":{"line":14,"column":3,"offset":203},"end":{"line":14,"column":64,"offset":264},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":201},"end":{"line":14,"column":64,"offset":264},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Possibility to add deployments one by one or in bulk (Excel).","position":{"start":{"line":15,"column":3,"offset":267},"end":{"line":15,"column":64,"offset":328},"indent":[]}}],"position":{"start":{"line":15,"column":3,"offset":267},"end":{"line":15,"column":64,"offset":328},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":265},"end":{"line":15,"column":64,"offset":328},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Configure machinery deployments: select a region of interest, specify recording time (pre, andd post recording), specify time interval.","position":{"start":{"line":16,"column":3,"offset":331},"end":{"line":16,"column":138,"offset":466},"indent":[]}}],"position":{"start":{"line":16,"column":3,"offset":331},"end":{"line":16,"column":138,"offset":466},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":329},"end":{"line":16,"column":138,"offset":466},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Global configuration page, where you specify your cloud credentials at a single place.","position":{"start":{"line":17,"column":3,"offset":469},"end":{"line":17,"column":89,"offset":555},"indent":[]}}],"position":{"start":{"line":17,"column":3,"offset":469},"end":{"line":17,"column":89,"offset":555},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":467},"end":{"line":17,"column":89,"offset":555},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":201},"end":{"line":17,"column":89,"offset":555},"indent":[1,1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":20,"column":1,"offset":558},"end":{"line":20,"column":31,"offset":588},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":20,"column":31,"offset":588}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Release notes`}

\n

{`1.0.0`}

\n

{`Factory`}

\n
    \n
  • {`React application using the Kubernetes and Docker Golang SDK.`}
  • \n
  • {`Possibility to add deployments one by one or in bulk (Excel).`}
  • \n
  • {`Configure machinery deployments: select a region of interest, specify recording time (pre, andd post recording), specify time interval.`}
  • \n
  • {`Global configuration page, where you specify your cloud credentials at a single place.`}
  • \n
\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974263000,"key":"gatsby-plugin-mdx-entire-payload-288833c279b8ca663cd64d85ba356e57-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Release notes","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":16,"offset":174},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":16,"offset":174},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"1.0.0","position":{"start":{"line":10,"column":5,"offset":180},"end":{"line":10,"column":10,"offset":185},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":176},"end":{"line":10,"column":10,"offset":185},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Factory","position":{"start":{"line":12,"column":6,"offset":192},"end":{"line":12,"column":13,"offset":199},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":187},"end":{"line":12,"column":13,"offset":199},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"React application using the Kubernetes and Docker Golang SDK.","position":{"start":{"line":14,"column":3,"offset":203},"end":{"line":14,"column":64,"offset":264},"indent":[]}}],"position":{"start":{"line":14,"column":3,"offset":203},"end":{"line":14,"column":64,"offset":264},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":201},"end":{"line":14,"column":64,"offset":264},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Possibility to add deployments one by one or in bulk (Excel).","position":{"start":{"line":15,"column":3,"offset":267},"end":{"line":15,"column":64,"offset":328},"indent":[]}}],"position":{"start":{"line":15,"column":3,"offset":267},"end":{"line":15,"column":64,"offset":328},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":265},"end":{"line":15,"column":64,"offset":328},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Configure machinery deployments: select a region of interest, specify recording time (pre, andd post recording), specify time interval.","position":{"start":{"line":16,"column":3,"offset":331},"end":{"line":16,"column":138,"offset":466},"indent":[]}}],"position":{"start":{"line":16,"column":3,"offset":331},"end":{"line":16,"column":138,"offset":466},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":329},"end":{"line":16,"column":138,"offset":466},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Global configuration page, where you specify your cloud credentials at a single place.","position":{"start":{"line":17,"column":3,"offset":469},"end":{"line":17,"column":89,"offset":555},"indent":[]}}],"position":{"start":{"line":17,"column":3,"offset":469},"end":{"line":17,"column":89,"offset":555},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":467},"end":{"line":17,"column":89,"offset":555},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":201},"end":{"line":17,"column":89,"offset":555},"indent":[1,1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":20,"column":1,"offset":558},"end":{"line":20,"column":31,"offset":588},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":20,"column":31,"offset":588}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Release notes`}

\n

{`1.0.0`}

\n

{`Factory`}

\n
    \n
  • {`React application using the Kubernetes and Docker Golang SDK.`}
  • \n
  • {`Possibility to add deployments one by one or in bulk (Excel).`}
  • \n
  • {`Configure machinery deployments: select a region of interest, specify recording time (pre, andd post recording), specify time interval.`}
  • \n
  • {`Global configuration page, where you specify your cloud credentials at a single place.`}
  • \n
\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-2d803be35bbfb2321ee72a233c028b37.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-2d803be35bbfb2321ee72a233c028b37.json new file mode 100644 index 0000000..ffcad0a --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-2d803be35bbfb2321ee72a233c028b37.json @@ -0,0 +1 @@ +{"expireTime":9007200841978291000,"key":"gatsby-plugin-mdx-entire-payload-3f282fe00487b76df3229362406437e7-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":9,"offset":451},"indent":[]}}],"position":{"start":{"line":14,"column":4,"offset":446},"end":{"line":14,"column":41,"offset":483},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":14,"column":41,"offset":483},"end":{"line":14,"column":116,"offset":558},"indent":[]}}],"position":{"start":{"line":14,"column":4,"offset":446},"end":{"line":14,"column":116,"offset":558},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":116,"offset":558},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":15,"column":5,"offset":563},"end":{"line":15,"column":13,"offset":571},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":562},"end":{"line":15,"column":49,"offset":607},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":15,"column":49,"offset":607},"end":{"line":15,"column":139,"offset":697},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":562},"end":{"line":15,"column":139,"offset":697},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":559},"end":{"line":15,"column":139,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":702},"end":{"line":16,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":701},"end":{"line":16,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":742},"end":{"line":16,"column":121,"offset":818},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":701},"end":{"line":16,"column":121,"offset":818},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":698},"end":{"line":16,"column":121,"offset":818},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":823},"end":{"line":17,"column":11,"offset":829},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":822},"end":{"line":17,"column":45,"offset":863},"indent":[]}},{"type":"text","value":": Kerberos on Docker on top of Balena.","position":{"start":{"line":17,"column":45,"offset":863},"end":{"line":17,"column":83,"offset":901},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":822},"end":{"line":17,"column":83,"offset":901},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":819},"end":{"line":17,"column":83,"offset":901},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":18,"column":5,"offset":906},"end":{"line":18,"column":12,"offset":913},"indent":[]}}],"position":{"start":{"line":18,"column":4,"offset":905},"end":{"line":18,"column":47,"offset":948},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":18,"column":47,"offset":948},"end":{"line":18,"column":179,"offset":1080},"indent":[]}}],"position":{"start":{"line":18,"column":4,"offset":905},"end":{"line":18,"column":179,"offset":1080},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":902},"end":{"line":18,"column":179,"offset":1080},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":18,"column":179,"offset":1080},"indent":[1,1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":20,"column":4,"offset":1085},"end":{"line":20,"column":8,"offset":1089},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":1082},"end":{"line":20,"column":8,"offset":1089},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":22,"column":1,"offset":1091},"end":{"line":22,"column":229,"offset":1319},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1091},"end":{"line":22,"column":229,"offset":1319},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":24,"column":1,"offset":1321},"end":{"line":24,"column":197,"offset":1517},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1321},"end":{"line":24,"column":197,"offset":1517},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":26,"column":5,"offset":1523},"end":{"line":26,"column":11,"offset":1529},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1519},"end":{"line":26,"column":11,"offset":1529},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":28,"column":1,"offset":1531},"end":{"line":28,"column":63,"offset":1593},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":28,"column":64,"offset":1594},"end":{"line":28,"column":85,"offset":1615},"indent":[]}}],"position":{"start":{"line":28,"column":63,"offset":1593},"end":{"line":28,"column":123,"offset":1653},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":28,"column":123,"offset":1653},"end":{"line":28,"column":124,"offset":1654},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":1531},"end":{"line":28,"column":124,"offset":1654},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos installer","position":{"start":{"line":30,"column":5,"offset":1660},"end":{"line":30,"column":23,"offset":1678},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":1656},"end":{"line":30,"column":23,"offset":1678},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":32,"column":1,"offset":1680},"end":{"line":32,"column":228,"offset":1907},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":1680},"end":{"line":32,"column":228,"offset":1907},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":34,"column":1,"offset":1909},"end":{"line":34,"column":67,"offset":1975},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":1909},"end":{"line":34,"column":67,"offset":1975},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":36,"column":1,"offset":1977},"end":{"line":36,"column":50,"offset":2026},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":1977},"end":{"line":36,"column":50,"offset":2026},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":38,"column":3,"offset":2030},"end":{"line":38,"column":49,"offset":2076},"indent":[]}}],"position":{"start":{"line":38,"column":3,"offset":2030},"end":{"line":38,"column":49,"offset":2076},"indent":[]}}],"position":{"start":{"line":38,"column":3,"offset":2030},"end":{"line":38,"column":49,"offset":2076},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":2028},"end":{"line":38,"column":49,"offset":2076},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":40,"column":5,"offset":2082},"end":{"line":40,"column":11,"offset":2088},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":2078},"end":{"line":40,"column":11,"offset":2088},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":42,"column":1,"offset":2090},"end":{"line":42,"column":160,"offset":2249},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":2090},"end":{"line":42,"column":160,"offset":2249},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":44,"column":4,"offset":2254},"end":{"line":44,"column":13,"offset":2263},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":44,"column":14,"offset":2264},"end":{"line":44,"column":28,"offset":2278},"indent":[]}}],"position":{"start":{"line":44,"column":13,"offset":2263},"end":{"line":44,"column":75,"offset":2325},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":44,"column":75,"offset":2325},"end":{"line":44,"column":76,"offset":2326},"indent":[]}}],"position":{"start":{"line":44,"column":4,"offset":2254},"end":{"line":44,"column":76,"offset":2326},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":2251},"end":{"line":44,"column":76,"offset":2326},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":45,"column":4,"offset":2330},"end":{"line":45,"column":41,"offset":2367},"indent":[]}}],"position":{"start":{"line":45,"column":4,"offset":2330},"end":{"line":45,"column":41,"offset":2367},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2327},"end":{"line":45,"column":41,"offset":2367},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":46,"column":4,"offset":2371},"end":{"line":46,"column":60,"offset":2427},"indent":[]}}],"position":{"start":{"line":46,"column":4,"offset":2371},"end":{"line":46,"column":60,"offset":2427},"indent":[]}}],"position":{"start":{"line":46,"column":1,"offset":2368},"end":{"line":46,"column":60,"offset":2427},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":2251},"end":{"line":46,"column":60,"offset":2427},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":48,"column":2,"offset":2430},"end":{"line":48,"column":64,"offset":2492},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2429},"end":{"line":48,"column":96,"offset":2524},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2429},"end":{"line":48,"column":96,"offset":2524},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":50,"column":1,"offset":2526},"end":{"line":50,"column":204,"offset":2729},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":2526},"end":{"line":50,"column":204,"offset":2729},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":52,"column":6,"offset":2736},"end":{"line":52,"column":24,"offset":2754},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2731},"end":{"line":52,"column":24,"offset":2754},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":54,"column":1,"offset":2756},"end":{"line":54,"column":95,"offset":2850},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":54,"column":95,"offset":2850},"end":{"line":54,"column":110,"offset":2865},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":54,"column":110,"offset":2865},"end":{"line":54,"column":222,"offset":2977},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2756},"end":{"line":54,"column":222,"offset":2977},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":56,"column":1,"offset":2979},"end":{"line":64,"column":4,"offset":3088},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":66,"column":6,"offset":3095},"end":{"line":66,"column":31,"offset":3120},"indent":[]}}],"position":{"start":{"line":66,"column":1,"offset":3090},"end":{"line":66,"column":31,"offset":3120},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":68,"column":1,"offset":3122},"end":{"line":68,"column":79,"offset":3200},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":68,"column":79,"offset":3200},"end":{"line":68,"column":95,"offset":3216},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":68,"column":95,"offset":3216},"end":{"line":68,"column":137,"offset":3258},"indent":[]}}],"position":{"start":{"line":68,"column":1,"offset":3122},"end":{"line":68,"column":137,"offset":3258},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":70,"column":1,"offset":3260},"end":{"line":80,"column":4,"offset":3628},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":82,"column":5,"offset":3634},"end":{"line":82,"column":30,"offset":3659},"indent":[]}}],"position":{"start":{"line":82,"column":1,"offset":3630},"end":{"line":82,"column":30,"offset":3659},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":84,"column":1,"offset":3661},"end":{"line":84,"column":464,"offset":4124},"indent":[]}}],"position":{"start":{"line":84,"column":1,"offset":3661},"end":{"line":84,"column":464,"offset":4124},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":86,"column":1,"offset":4126},"end":{"line":86,"column":61,"offset":4186},"indent":[]}}],"position":{"start":{"line":86,"column":1,"offset":4126},"end":{"line":86,"column":61,"offset":4186},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":88,"column":5,"offset":4192},"end":{"line":88,"column":28,"offset":4215},"indent":[]}}],"position":{"start":{"line":88,"column":1,"offset":4188},"end":{"line":88,"column":28,"offset":4215},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":90,"column":1,"offset":4217},"end":{"line":90,"column":95,"offset":4311},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":90,"column":95,"offset":4311},"end":{"line":90,"column":100,"offset":4316},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":90,"column":100,"offset":4316},"end":{"line":90,"column":101,"offset":4317},"indent":[]}}],"position":{"start":{"line":90,"column":1,"offset":4217},"end":{"line":90,"column":101,"offset":4317},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":92,"column":1,"offset":4319},"end":{"line":96,"column":4,"offset":4436},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":98,"column":1,"offset":4438},"end":{"line":98,"column":80,"offset":4517},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":98,"column":80,"offset":4517},"end":{"line":98,"column":101,"offset":4538},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":98,"column":101,"offset":4538},"end":{"line":98,"column":162,"offset":4599},"indent":[]}}],"position":{"start":{"line":98,"column":1,"offset":4438},"end":{"line":98,"column":162,"offset":4599},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":100,"column":1,"offset":4601},"end":{"line":103,"column":4,"offset":4690},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":105,"column":4,"offset":4695},"end":{"line":105,"column":12,"offset":4703},"indent":[]}}],"position":{"start":{"line":105,"column":1,"offset":4692},"end":{"line":105,"column":12,"offset":4703},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":107,"column":1,"offset":4705},"end":{"line":107,"column":193,"offset":4897},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4705},"end":{"line":107,"column":193,"offset":4897},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":109,"column":4,"offset":4902},"end":{"line":109,"column":62,"offset":4960},"indent":[]}}],"position":{"start":{"line":109,"column":4,"offset":4902},"end":{"line":109,"column":62,"offset":4960},"indent":[]}}],"position":{"start":{"line":109,"column":1,"offset":4899},"end":{"line":109,"column":62,"offset":4960},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":110,"column":4,"offset":4964},"end":{"line":110,"column":69,"offset":5029},"indent":[]}}],"position":{"start":{"line":110,"column":4,"offset":4964},"end":{"line":110,"column":69,"offset":5029},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4961},"end":{"line":110,"column":69,"offset":5029},"indent":[]}}],"position":{"start":{"line":109,"column":1,"offset":4899},"end":{"line":110,"column":69,"offset":5029},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":112,"column":1,"offset":5031},"end":{"line":112,"column":99,"offset":5129},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":5031},"end":{"line":112,"column":99,"offset":5129},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":114,"column":5,"offset":5135},"end":{"line":114,"column":14,"offset":5144},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":5131},"end":{"line":114,"column":14,"offset":5144},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":116,"column":1,"offset":5146},"end":{"line":116,"column":71,"offset":5216},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":5146},"end":{"line":116,"column":71,"offset":5216},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":118,"column":3,"offset":5220},"end":{"line":118,"column":47,"offset":5264},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":118,"column":47,"offset":5264},"end":{"line":118,"column":79,"offset":5296},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":118,"column":79,"offset":5296},"end":{"line":118,"column":198,"offset":5415},"indent":[]}}],"position":{"start":{"line":118,"column":3,"offset":5220},"end":{"line":118,"column":198,"offset":5415},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5218},"end":{"line":118,"column":198,"offset":5415},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":120,"column":1,"offset":5417},"end":{"line":122,"column":4,"offset":5480},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":124,"column":5,"offset":5486},"end":{"line":124,"column":14,"offset":5495},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5482},"end":{"line":124,"column":14,"offset":5495},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":126,"column":1,"offset":5497},"end":{"line":126,"column":56,"offset":5552},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5497},"end":{"line":126,"column":56,"offset":5552},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":127,"column":3,"offset":5555},"end":{"line":127,"column":52,"offset":5604},"indent":[]}}],"position":{"start":{"line":127,"column":3,"offset":5555},"end":{"line":127,"column":52,"offset":5604},"indent":[]}}],"position":{"start":{"line":127,"column":3,"offset":5555},"end":{"line":127,"column":52,"offset":5604},"indent":[]}}],"position":{"start":{"line":127,"column":1,"offset":5553},"end":{"line":127,"column":52,"offset":5604},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":129,"column":1,"offset":5606},"end":{"line":129,"column":3,"offset":5608},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":129,"column":3,"offset":5608},"end":{"line":129,"column":9,"offset":5614},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":129,"column":9,"offset":5614},"end":{"line":129,"column":223,"offset":5828},"indent":[]}}],"position":{"start":{"line":129,"column":1,"offset":5606},"end":{"line":129,"column":223,"offset":5828},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":131,"column":3,"offset":5832},"end":{"line":131,"column":159,"offset":5988},"indent":[]}}],"position":{"start":{"line":131,"column":3,"offset":5832},"end":{"line":131,"column":159,"offset":5988},"indent":[]}}],"position":{"start":{"line":131,"column":1,"offset":5830},"end":{"line":131,"column":159,"offset":5988},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":133,"column":1,"offset":5990},"end":{"line":136,"column":4,"offset":6167},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":138,"column":1,"offset":6169},"end":{"line":138,"column":160,"offset":6328},"indent":[]}}],"position":{"start":{"line":138,"column":1,"offset":6169},"end":{"line":138,"column":160,"offset":6328},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":140,"column":3,"offset":6332},"end":{"line":140,"column":31,"offset":6360},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":140,"column":31,"offset":6360},"end":{"line":140,"column":101,"offset":6430},"indent":[]}}],"position":{"start":{"line":140,"column":3,"offset":6332},"end":{"line":140,"column":101,"offset":6430},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6330},"end":{"line":140,"column":101,"offset":6430},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":142,"column":1,"offset":6432},"end":{"line":145,"column":4,"offset":6604},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":147,"column":1,"offset":6606},"end":{"line":147,"column":73,"offset":6678},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6606},"end":{"line":147,"column":73,"offset":6678},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":150,"column":3,"offset":6683},"end":{"line":150,"column":31,"offset":6711},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":150,"column":31,"offset":6711},"end":{"line":150,"column":101,"offset":6781},"indent":[]}}],"position":{"start":{"line":150,"column":3,"offset":6683},"end":{"line":150,"column":101,"offset":6781},"indent":[]}}],"position":{"start":{"line":150,"column":1,"offset":6681},"end":{"line":150,"column":101,"offset":6781},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":152,"column":1,"offset":6783},"end":{"line":155,"column":4,"offset":6955},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":157,"column":1,"offset":6957},"end":{"line":157,"column":62,"offset":7018},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":157,"column":63,"offset":7019},"end":{"line":157,"column":75,"offset":7031},"indent":[]}}],"position":{"start":{"line":157,"column":62,"offset":7018},"end":{"line":157,"column":143,"offset":7099},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":157,"column":143,"offset":7099},"end":{"line":157,"column":150,"offset":7106},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":157,"column":150,"offset":7106},"end":{"line":157,"column":169,"offset":7125},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":157,"column":169,"offset":7125},"end":{"line":157,"column":170,"offset":7126},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6957},"end":{"line":157,"column":170,"offset":7126},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":159,"column":1,"offset":7128},"end":{"line":161,"column":4,"offset":7155},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":163,"column":1,"offset":7157},"end":{"line":163,"column":58,"offset":7214},"indent":[]}}],"position":{"start":{"line":163,"column":1,"offset":7157},"end":{"line":163,"column":58,"offset":7214},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":165,"column":1,"offset":7216},"end":{"line":168,"column":4,"offset":7286},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":170,"column":5,"offset":7292},"end":{"line":170,"column":8,"offset":7295},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7288},"end":{"line":170,"column":8,"offset":7295},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":172,"column":1,"offset":7297},"end":{"line":172,"column":280,"offset":7576},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7297},"end":{"line":172,"column":280,"offset":7576},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":174,"column":1,"offset":7578},"end":{"line":174,"column":37,"offset":7614},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7578},"end":{"line":174,"column":37,"offset":7614},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":176,"column":1,"offset":7616},"end":{"line":178,"column":4,"offset":7789},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":180,"column":1,"offset":7791},"end":{"line":180,"column":25,"offset":7815},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7791},"end":{"line":180,"column":25,"offset":7815},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":182,"column":1,"offset":7817},"end":{"line":185,"column":4,"offset":7921},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":187,"column":1,"offset":7923},"end":{"line":187,"column":118,"offset":8040},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":7923},"end":{"line":187,"column":118,"offset":8040},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":189,"column":1,"offset":8042},"end":{"line":209,"column":4,"offset":8549},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":211,"column":1,"offset":8551},"end":{"line":211,"column":14,"offset":8564},"indent":[]}}],"position":{"start":{"line":211,"column":1,"offset":8551},"end":{"line":211,"column":14,"offset":8564},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":213,"column":1,"offset":8566},"end":{"line":215,"column":4,"offset":8602},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":217,"column":1,"offset":8604},"end":{"line":217,"column":91,"offset":8694},"indent":[]}}],"position":{"start":{"line":217,"column":1,"offset":8604},"end":{"line":217,"column":91,"offset":8694},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":219,"column":1,"offset":8696},"end":{"line":227,"column":4,"offset":9069},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":229,"column":1,"offset":9071},"end":{"line":229,"column":145,"offset":9215},"indent":[]}}],"position":{"start":{"line":229,"column":1,"offset":9071},"end":{"line":229,"column":145,"offset":9215},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":231,"column":5,"offset":9221},"end":{"line":231,"column":17,"offset":9233},"indent":[]}}],"position":{"start":{"line":231,"column":1,"offset":9217},"end":{"line":231,"column":17,"offset":9233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":233,"column":1,"offset":9235},"end":{"line":233,"column":300,"offset":9534},"indent":[]}}],"position":{"start":{"line":233,"column":1,"offset":9235},"end":{"line":233,"column":300,"offset":9534},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":235,"column":1,"offset":9536},"end":{"line":235,"column":178,"offset":9713},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":9536},"end":{"line":235,"column":178,"offset":9713},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":237,"column":1,"offset":9715},"end":{"line":237,"column":48,"offset":9762},"indent":[]}}],"position":{"start":{"line":237,"column":1,"offset":9715},"end":{"line":237,"column":48,"offset":9762},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":239,"column":1,"offset":9764},"end":{"line":241,"column":4,"offset":9804},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":243,"column":1,"offset":9806},"end":{"line":243,"column":104,"offset":9909},"indent":[]}}],"position":{"start":{"line":243,"column":1,"offset":9806},"end":{"line":243,"column":104,"offset":9909},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":245,"column":1,"offset":9911},"end":{"line":253,"column":4,"offset":10181},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":255,"column":1,"offset":10183},"end":{"line":255,"column":28,"offset":10210},"indent":[]}}],"position":{"start":{"line":255,"column":1,"offset":10183},"end":{"line":255,"column":28,"offset":10210},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":257,"column":1,"offset":10212},"end":{"line":259,"column":4,"offset":10256},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":261,"column":1,"offset":10258},"end":{"line":261,"column":48,"offset":10305},"indent":[]}}],"position":{"start":{"line":261,"column":1,"offset":10258},"end":{"line":261,"column":48,"offset":10305},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":263,"column":1,"offset":10307},"end":{"line":265,"column":4,"offset":10329},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":267,"column":1,"offset":10331},"end":{"line":267,"column":72,"offset":10402},"indent":[]}}],"position":{"start":{"line":267,"column":1,"offset":10331},"end":{"line":267,"column":72,"offset":10402},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":269,"column":1,"offset":10404},"end":{"line":271,"column":4,"offset":10461},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":273,"column":4,"offset":10466},"end":{"line":273,"column":10,"offset":10472},"indent":[]}}],"position":{"start":{"line":273,"column":1,"offset":10463},"end":{"line":273,"column":10,"offset":10472},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":275,"column":1,"offset":10474},"end":{"line":275,"column":337,"offset":10810},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":275,"column":338,"offset":10811},"end":{"line":275,"column":352,"offset":10825},"indent":[]}}],"position":{"start":{"line":275,"column":337,"offset":10810},"end":{"line":275,"column":388,"offset":10861},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":275,"column":388,"offset":10861},"end":{"line":275,"column":389,"offset":10862},"indent":[]}}],"position":{"start":{"line":275,"column":1,"offset":10474},"end":{"line":275,"column":389,"offset":10862},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":277,"column":5,"offset":10868},"end":{"line":277,"column":18,"offset":10881},"indent":[]}}],"position":{"start":{"line":277,"column":1,"offset":10864},"end":{"line":277,"column":18,"offset":10881},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":279,"column":3,"offset":10885},"end":{"line":279,"column":50,"offset":10932},"indent":[]}}],"position":{"start":{"line":279,"column":3,"offset":10885},"end":{"line":279,"column":50,"offset":10932},"indent":[]}}],"position":{"start":{"line":279,"column":1,"offset":10883},"end":{"line":279,"column":50,"offset":10932},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":281,"column":5,"offset":10938},"end":{"line":281,"column":11,"offset":10944},"indent":[]}}],"position":{"start":{"line":281,"column":1,"offset":10934},"end":{"line":281,"column":11,"offset":10944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":283,"column":1,"offset":10946},"end":{"line":283,"column":64,"offset":11009},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":283,"column":65,"offset":11010},"end":{"line":283,"column":86,"offset":11031},"indent":[]}}],"position":{"start":{"line":283,"column":64,"offset":11009},"end":{"line":283,"column":126,"offset":11071},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":283,"column":126,"offset":11071},"end":{"line":283,"column":127,"offset":11072},"indent":[]}}],"position":{"start":{"line":283,"column":1,"offset":10946},"end":{"line":283,"column":127,"offset":11072},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":285,"column":5,"offset":11078},"end":{"line":285,"column":26,"offset":11099},"indent":[]}}],"position":{"start":{"line":285,"column":1,"offset":11074},"end":{"line":285,"column":26,"offset":11099},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":287,"column":1,"offset":11101},"end":{"line":287,"column":126,"offset":11226},"indent":[]}}],"position":{"start":{"line":287,"column":1,"offset":11101},"end":{"line":287,"column":126,"offset":11226},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":289,"column":1,"offset":11228},"end":{"line":291,"column":4,"offset":11267},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":293,"column":1,"offset":11269},"end":{"line":293,"column":187,"offset":11455},"indent":[]}}],"position":{"start":{"line":293,"column":1,"offset":11269},"end":{"line":293,"column":187,"offset":11455},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":295,"column":1,"offset":11457},"end":{"line":297,"column":4,"offset":11535},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":299,"column":1,"offset":11537},"end":{"line":299,"column":153,"offset":11689},"indent":[]}}],"position":{"start":{"line":299,"column":1,"offset":11537},"end":{"line":299,"column":153,"offset":11689},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":301,"column":1,"offset":11691},"end":{"line":304,"column":4,"offset":11838},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":306,"column":1,"offset":11840},"end":{"line":306,"column":100,"offset":11939},"indent":[]}}],"position":{"start":{"line":306,"column":1,"offset":11840},"end":{"line":306,"column":100,"offset":11939},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":307,"column":1,"offset":11940},"end":{"line":311,"column":4,"offset":12009},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":313,"column":5,"offset":12015},"end":{"line":313,"column":12,"offset":12022},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":12011},"end":{"line":313,"column":12,"offset":12022},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":315,"column":1,"offset":12024},"end":{"line":315,"column":64,"offset":12087},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12024},"end":{"line":315,"column":64,"offset":12087},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":316,"column":3,"offset":12090},"end":{"line":316,"column":25,"offset":12112},"indent":[]}}],"position":{"start":{"line":316,"column":3,"offset":12090},"end":{"line":316,"column":25,"offset":12112},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12088},"end":{"line":316,"column":25,"offset":12112},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":317,"column":3,"offset":12115},"end":{"line":317,"column":59,"offset":12171},"indent":[]}}],"position":{"start":{"line":317,"column":3,"offset":12115},"end":{"line":317,"column":59,"offset":12171},"indent":[]}}],"position":{"start":{"line":317,"column":1,"offset":12113},"end":{"line":317,"column":59,"offset":12171},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12088},"end":{"line":317,"column":59,"offset":12171},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":319,"column":4,"offset":12176},"end":{"line":319,"column":11,"offset":12183},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":12173},"end":{"line":319,"column":11,"offset":12183},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":321,"column":1,"offset":12185},"end":{"line":321,"column":283,"offset":12467},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":12185},"end":{"line":321,"column":283,"offset":12467},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":323,"column":3,"offset":12471},"end":{"line":323,"column":54,"offset":12522},"indent":[]}}],"position":{"start":{"line":323,"column":3,"offset":12471},"end":{"line":323,"column":54,"offset":12522},"indent":[]}}],"position":{"start":{"line":323,"column":1,"offset":12469},"end":{"line":323,"column":54,"offset":12522},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":325,"column":5,"offset":12528},"end":{"line":325,"column":14,"offset":12537},"indent":[]}}],"position":{"start":{"line":325,"column":1,"offset":12524},"end":{"line":325,"column":14,"offset":12537},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":327,"column":1,"offset":12539},"end":{"line":327,"column":68,"offset":12606},"indent":[]}}],"position":{"start":{"line":327,"column":1,"offset":12539},"end":{"line":327,"column":68,"offset":12606},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":329,"column":1,"offset":12608},"end":{"line":332,"column":4,"offset":12759},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":334,"column":1,"offset":12761},"end":{"line":334,"column":46,"offset":12806},"indent":[]}}],"position":{"start":{"line":334,"column":1,"offset":12761},"end":{"line":334,"column":46,"offset":12806},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":336,"column":3,"offset":12810},"end":{"line":336,"column":103,"offset":12910},"indent":[]}}],"position":{"start":{"line":336,"column":3,"offset":12810},"end":{"line":336,"column":103,"offset":12910},"indent":[]}}],"position":{"start":{"line":336,"column":1,"offset":12808},"end":{"line":336,"column":103,"offset":12910},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":338,"column":1,"offset":12912},"end":{"line":343,"column":4,"offset":13122},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":345,"column":1,"offset":13124},"end":{"line":345,"column":151,"offset":13274},"indent":[]}}],"position":{"start":{"line":345,"column":1,"offset":13124},"end":{"line":345,"column":151,"offset":13274},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":347,"column":3,"offset":13278},"end":{"line":347,"column":22,"offset":13297},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":347,"column":22,"offset":13297},"end":{"line":347,"column":26,"offset":13301},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":347,"column":26,"offset":13301},"end":{"line":347,"column":40,"offset":13315},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":347,"column":40,"offset":13315},"end":{"line":347,"column":50,"offset":13325},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":347,"column":50,"offset":13325},"end":{"line":347,"column":98,"offset":13373},"indent":[]}}],"position":{"start":{"line":347,"column":3,"offset":13278},"end":{"line":347,"column":98,"offset":13373},"indent":[]}}],"position":{"start":{"line":347,"column":1,"offset":13276},"end":{"line":347,"column":98,"offset":13373},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":349,"column":1,"offset":13375},"end":{"line":353,"column":4,"offset":13537},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":355,"column":1,"offset":13539},"end":{"line":355,"column":72,"offset":13610},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":355,"column":72,"offset":13610},"end":{"line":355,"column":84,"offset":13622},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":355,"column":84,"offset":13622},"end":{"line":355,"column":102,"offset":13640},"indent":[]}}],"position":{"start":{"line":355,"column":1,"offset":13539},"end":{"line":355,"column":102,"offset":13640},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":357,"column":1,"offset":13642},"end":{"line":360,"column":4,"offset":13716},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":362,"column":5,"offset":13722},"end":{"line":362,"column":8,"offset":13725},"indent":[]}}],"position":{"start":{"line":362,"column":1,"offset":13718},"end":{"line":362,"column":8,"offset":13725},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":364,"column":1,"offset":13727},"end":{"line":364,"column":176,"offset":13902},"indent":[]}}],"position":{"start":{"line":364,"column":1,"offset":13727},"end":{"line":364,"column":176,"offset":13902},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":366,"column":1,"offset":13904},"end":{"line":373,"column":4,"offset":14201},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":375,"column":1,"offset":14203},"end":{"line":375,"column":60,"offset":14262},"indent":[]}}],"position":{"start":{"line":375,"column":1,"offset":14203},"end":{"line":375,"column":60,"offset":14262},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":377,"column":1,"offset":14264},"end":{"line":381,"column":4,"offset":14390},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":383,"column":1,"offset":14392},"end":{"line":383,"column":63,"offset":14454},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14392},"end":{"line":383,"column":63,"offset":14454},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":385,"column":1,"offset":14456},"end":{"line":405,"column":4,"offset":14963},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":407,"column":1,"offset":14965},"end":{"line":407,"column":99,"offset":15063},"indent":[]}}],"position":{"start":{"line":407,"column":1,"offset":14965},"end":{"line":407,"column":99,"offset":15063},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":409,"column":1,"offset":15065},"end":{"line":412,"column":4,"offset":15167},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":414,"column":1,"offset":15169},"end":{"line":414,"column":37,"offset":15205},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":414,"column":37,"offset":15205},"end":{"line":414,"column":47,"offset":15215},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":414,"column":47,"offset":15215},"end":{"line":414,"column":89,"offset":15257},"indent":[]}}],"position":{"start":{"line":414,"column":1,"offset":15169},"end":{"line":414,"column":89,"offset":15257},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":416,"column":1,"offset":15259},"end":{"line":420,"column":4,"offset":15384},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":422,"column":1,"offset":15386},"end":{"line":422,"column":78,"offset":15463},"indent":[]}}],"position":{"start":{"line":422,"column":1,"offset":15386},"end":{"line":422,"column":78,"offset":15463},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":424,"column":1,"offset":15465},"end":{"line":428,"column":4,"offset":15569},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":430,"column":1,"offset":15571},"end":{"line":430,"column":75,"offset":15645},"indent":[]}}],"position":{"start":{"line":430,"column":1,"offset":15571},"end":{"line":430,"column":75,"offset":15645},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":432,"column":1,"offset":15647},"end":{"line":436,"column":4,"offset":15720},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":438,"column":1,"offset":15722},"end":{"line":438,"column":145,"offset":15866},"indent":[]}}],"position":{"start":{"line":438,"column":1,"offset":15722},"end":{"line":438,"column":145,"offset":15866},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":440,"column":5,"offset":15872},"end":{"line":440,"column":17,"offset":15884},"indent":[]}}],"position":{"start":{"line":440,"column":1,"offset":15868},"end":{"line":440,"column":17,"offset":15884},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":442,"column":1,"offset":15886},"end":{"line":442,"column":300,"offset":16185},"indent":[]}}],"position":{"start":{"line":442,"column":1,"offset":15886},"end":{"line":442,"column":300,"offset":16185},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":444,"column":1,"offset":16187},"end":{"line":444,"column":178,"offset":16364},"indent":[]}}],"position":{"start":{"line":444,"column":1,"offset":16187},"end":{"line":444,"column":178,"offset":16364},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":446,"column":1,"offset":16366},"end":{"line":446,"column":48,"offset":16413},"indent":[]}}],"position":{"start":{"line":446,"column":1,"offset":16366},"end":{"line":446,"column":48,"offset":16413},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":448,"column":1,"offset":16415},"end":{"line":450,"column":4,"offset":16459},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":452,"column":1,"offset":16461},"end":{"line":452,"column":104,"offset":16564},"indent":[]}}],"position":{"start":{"line":452,"column":1,"offset":16461},"end":{"line":452,"column":104,"offset":16564},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":454,"column":1,"offset":16566},"end":{"line":462,"column":4,"offset":16836},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":464,"column":1,"offset":16838},"end":{"line":464,"column":28,"offset":16865},"indent":[]}}],"position":{"start":{"line":464,"column":1,"offset":16838},"end":{"line":464,"column":28,"offset":16865},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":466,"column":1,"offset":16867},"end":{"line":468,"column":4,"offset":16915},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":470,"column":1,"offset":16917},"end":{"line":470,"column":48,"offset":16964},"indent":[]}}],"position":{"start":{"line":470,"column":1,"offset":16917},"end":{"line":470,"column":48,"offset":16964},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":472,"column":1,"offset":16966},"end":{"line":474,"column":4,"offset":16988},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":476,"column":1,"offset":16990},"end":{"line":476,"column":72,"offset":17061},"indent":[]}}],"position":{"start":{"line":476,"column":1,"offset":16990},"end":{"line":476,"column":72,"offset":17061},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":478,"column":1,"offset":17063},"end":{"line":480,"column":4,"offset":17124},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":483,"column":1,"offset":17127},"end":{"line":483,"column":31,"offset":17157},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":483,"column":31,"offset":17157}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  4. \n
  5. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  6. \n
  7. {`Balena`}{`: Kerberos on Docker on top of Balena.`}
  8. \n
  9. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  10. \n
\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Docker`}

\n

{`A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-30153aa59279e74ec5bb4c16c59bfd3f.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-30153aa59279e74ec5bb4c16c59bfd3f.json new file mode 100644 index 0000000..1dcbd24 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-30153aa59279e74ec5bb4c16c59bfd3f.json @@ -0,0 +1 @@ +{"expireTime":9007200842319633000,"key":"gatsby-plugin-mdx-entire-payload-42f3d2553029ee430505d9c22f634e68-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4679},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":80,"offset":4760},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4760},"end":{"line":107,"column":101,"offset":4781},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4781},"end":{"line":107,"column":162,"offset":4842},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":162,"offset":4842},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4844},"end":{"line":112,"column":4,"offset":4933},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4938},"end":{"line":114,"column":10,"offset":4944},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4935},"end":{"line":114,"column":10,"offset":4944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":339,"offset":5284},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":340,"offset":5285},"end":{"line":116,"column":354,"offset":5299},"indent":[]}}],"position":{"start":{"line":116,"column":339,"offset":5284},"end":{"line":116,"column":390,"offset":5335},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":390,"offset":5335},"end":{"line":116,"column":391,"offset":5336},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":391,"offset":5336},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5342},"end":{"line":118,"column":18,"offset":5355},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5338},"end":{"line":118,"column":18,"offset":5355},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5357},"end":{"line":120,"column":50,"offset":5406},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5412},"end":{"line":122,"column":11,"offset":5418},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5408},"end":{"line":122,"column":11,"offset":5418},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":64,"offset":5483},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5484},"end":{"line":124,"column":86,"offset":5505},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5483},"end":{"line":124,"column":126,"offset":5545},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5545},"end":{"line":124,"column":127,"offset":5546},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":127,"offset":5546},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5552},"end":{"line":126,"column":26,"offset":5573},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5548},"end":{"line":126,"column":26,"offset":5573},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5702},"end":{"line":132,"column":4,"offset":5741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5931},"end":{"line":138,"column":4,"offset":6009},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6165},"end":{"line":145,"column":4,"offset":6312},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6414},"end":{"line":152,"column":4,"offset":6483},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6489},"end":{"line":154,"column":12,"offset":6496},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6485},"end":{"line":154,"column":12,"offset":6496},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example:","position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":65,"offset":6562},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":65,"offset":6562},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":157,"column":3,"offset":6565},"end":{"line":157,"column":25,"offset":6587},"indent":[]}}],"position":{"start":{"line":157,"column":3,"offset":6565},"end":{"line":157,"column":25,"offset":6587},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6563},"end":{"line":157,"column":25,"offset":6587},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":158,"column":3,"offset":6590},"end":{"line":158,"column":59,"offset":6646},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6590},"end":{"line":158,"column":59,"offset":6646},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6588},"end":{"line":158,"column":59,"offset":6646},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6563},"end":{"line":158,"column":59,"offset":6646},"indent":[1]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name kerberos-camera1 \\\n-p 80:80 -p 8889:8889 \\\n-v ~/config:/etc/opt/kerberosio/config \\\n-v ~/capture:/etc/opt/kerberosio/capture \\\n-v ~/logs:/etc/opt/kerberosio/logs \\\n-v ~/webconfig:/var/www/web/config \\ \n-d kerberos/kerberos\n\nLearn more about volumes in this tutorial.\n\n\n## Balena\n\nRunning Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.\n\nTo fill the gap, regarding the latter, we can rely on another solution called [Balena.io](https://balena.io). Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).\n\nOn top of supporting a lot of boars,\n\n---\n\n# Advanced\n\nFollowing installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.\n\n## Raspbian\n\nIf you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:\n\n1. Install the Kerberos agent using Docker (more info below),\n2. or you can install the Kerberos agent manually (machinery + web).\n\nThis section will focus on option 2, and will show you how to install the Kerberos agent manually.\n\n### Update OS\n\nLet's start with updating the OS, and installing a couple of packages.\n\n> We have tested the Raspbian installation on `Raspbian GNU/Linux 10 (buster)`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.\n\n```ts\nsudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":160,"column":1,"offset":6648},"end":{"line":203,"column":4,"offset":8627},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":205,"column":5,"offset":8633},"end":{"line":205,"column":14,"offset":8642},"indent":[]}}],"position":{"start":{"line":205,"column":1,"offset":8629},"end":{"line":205,"column":14,"offset":8642},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":207,"column":1,"offset":8644},"end":{"line":207,"column":56,"offset":8699},"indent":[]}}],"position":{"start":{"line":207,"column":1,"offset":8644},"end":{"line":207,"column":56,"offset":8699},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":208,"column":3,"offset":8702},"end":{"line":208,"column":52,"offset":8751},"indent":[]}}],"position":{"start":{"line":208,"column":3,"offset":8702},"end":{"line":208,"column":52,"offset":8751},"indent":[]}}],"position":{"start":{"line":208,"column":3,"offset":8702},"end":{"line":208,"column":52,"offset":8751},"indent":[]}}],"position":{"start":{"line":208,"column":1,"offset":8700},"end":{"line":208,"column":52,"offset":8751},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":210,"column":1,"offset":8753},"end":{"line":210,"column":3,"offset":8755},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":210,"column":3,"offset":8755},"end":{"line":210,"column":9,"offset":8761},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":210,"column":9,"offset":8761},"end":{"line":210,"column":223,"offset":8975},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":8753},"end":{"line":210,"column":223,"offset":8975},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":212,"column":3,"offset":8979},"end":{"line":212,"column":159,"offset":9135},"indent":[]}}],"position":{"start":{"line":212,"column":3,"offset":8979},"end":{"line":212,"column":159,"offset":9135},"indent":[]}}],"position":{"start":{"line":212,"column":1,"offset":8977},"end":{"line":212,"column":159,"offset":9135},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":214,"column":1,"offset":9137},"end":{"line":217,"column":4,"offset":9314},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":219,"column":1,"offset":9316},"end":{"line":219,"column":160,"offset":9475},"indent":[]}}],"position":{"start":{"line":219,"column":1,"offset":9316},"end":{"line":219,"column":160,"offset":9475},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":221,"column":3,"offset":9479},"end":{"line":221,"column":31,"offset":9507},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":221,"column":31,"offset":9507},"end":{"line":221,"column":101,"offset":9577},"indent":[]}}],"position":{"start":{"line":221,"column":3,"offset":9479},"end":{"line":221,"column":101,"offset":9577},"indent":[]}}],"position":{"start":{"line":221,"column":1,"offset":9477},"end":{"line":221,"column":101,"offset":9577},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":223,"column":1,"offset":9579},"end":{"line":226,"column":4,"offset":9751},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":228,"column":1,"offset":9753},"end":{"line":228,"column":73,"offset":9825},"indent":[]}}],"position":{"start":{"line":228,"column":1,"offset":9753},"end":{"line":228,"column":73,"offset":9825},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":231,"column":3,"offset":9830},"end":{"line":231,"column":31,"offset":9858},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":231,"column":31,"offset":9858},"end":{"line":231,"column":101,"offset":9928},"indent":[]}}],"position":{"start":{"line":231,"column":3,"offset":9830},"end":{"line":231,"column":101,"offset":9928},"indent":[]}}],"position":{"start":{"line":231,"column":1,"offset":9828},"end":{"line":231,"column":101,"offset":9928},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":233,"column":1,"offset":9930},"end":{"line":236,"column":4,"offset":10102},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":238,"column":1,"offset":10104},"end":{"line":238,"column":62,"offset":10165},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":238,"column":63,"offset":10166},"end":{"line":238,"column":75,"offset":10178},"indent":[]}}],"position":{"start":{"line":238,"column":62,"offset":10165},"end":{"line":238,"column":143,"offset":10246},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":238,"column":143,"offset":10246},"end":{"line":238,"column":150,"offset":10253},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":238,"column":150,"offset":10253},"end":{"line":238,"column":169,"offset":10272},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":238,"column":169,"offset":10272},"end":{"line":238,"column":170,"offset":10273},"indent":[]}}],"position":{"start":{"line":238,"column":1,"offset":10104},"end":{"line":238,"column":170,"offset":10273},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":240,"column":1,"offset":10275},"end":{"line":242,"column":4,"offset":10302},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":244,"column":1,"offset":10304},"end":{"line":244,"column":58,"offset":10361},"indent":[]}}],"position":{"start":{"line":244,"column":1,"offset":10304},"end":{"line":244,"column":58,"offset":10361},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":246,"column":1,"offset":10363},"end":{"line":249,"column":4,"offset":10433},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":251,"column":5,"offset":10439},"end":{"line":251,"column":8,"offset":10442},"indent":[]}}],"position":{"start":{"line":251,"column":1,"offset":10435},"end":{"line":251,"column":8,"offset":10442},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":253,"column":1,"offset":10444},"end":{"line":253,"column":280,"offset":10723},"indent":[]}}],"position":{"start":{"line":253,"column":1,"offset":10444},"end":{"line":253,"column":280,"offset":10723},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":255,"column":1,"offset":10725},"end":{"line":255,"column":37,"offset":10761},"indent":[]}}],"position":{"start":{"line":255,"column":1,"offset":10725},"end":{"line":255,"column":37,"offset":10761},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":257,"column":1,"offset":10763},"end":{"line":259,"column":4,"offset":10936},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":261,"column":1,"offset":10938},"end":{"line":261,"column":25,"offset":10962},"indent":[]}}],"position":{"start":{"line":261,"column":1,"offset":10938},"end":{"line":261,"column":25,"offset":10962},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":263,"column":1,"offset":10964},"end":{"line":266,"column":4,"offset":11068},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":268,"column":1,"offset":11070},"end":{"line":268,"column":118,"offset":11187},"indent":[]}}],"position":{"start":{"line":268,"column":1,"offset":11070},"end":{"line":268,"column":118,"offset":11187},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":270,"column":1,"offset":11189},"end":{"line":290,"column":4,"offset":11696},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":292,"column":1,"offset":11698},"end":{"line":292,"column":14,"offset":11711},"indent":[]}}],"position":{"start":{"line":292,"column":1,"offset":11698},"end":{"line":292,"column":14,"offset":11711},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":294,"column":1,"offset":11713},"end":{"line":296,"column":4,"offset":11749},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":298,"column":1,"offset":11751},"end":{"line":298,"column":91,"offset":11841},"indent":[]}}],"position":{"start":{"line":298,"column":1,"offset":11751},"end":{"line":298,"column":91,"offset":11841},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":300,"column":1,"offset":11843},"end":{"line":308,"column":4,"offset":12216},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":310,"column":1,"offset":12218},"end":{"line":310,"column":145,"offset":12362},"indent":[]}}],"position":{"start":{"line":310,"column":1,"offset":12218},"end":{"line":310,"column":145,"offset":12362},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":312,"column":5,"offset":12368},"end":{"line":312,"column":17,"offset":12380},"indent":[]}}],"position":{"start":{"line":312,"column":1,"offset":12364},"end":{"line":312,"column":17,"offset":12380},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":314,"column":1,"offset":12382},"end":{"line":314,"column":300,"offset":12681},"indent":[]}}],"position":{"start":{"line":314,"column":1,"offset":12382},"end":{"line":314,"column":300,"offset":12681},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":316,"column":1,"offset":12683},"end":{"line":316,"column":178,"offset":12860},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12683},"end":{"line":316,"column":178,"offset":12860},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":318,"column":1,"offset":12862},"end":{"line":318,"column":48,"offset":12909},"indent":[]}}],"position":{"start":{"line":318,"column":1,"offset":12862},"end":{"line":318,"column":48,"offset":12909},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":320,"column":1,"offset":12911},"end":{"line":322,"column":4,"offset":12951},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":324,"column":1,"offset":12953},"end":{"line":324,"column":104,"offset":13056},"indent":[]}}],"position":{"start":{"line":324,"column":1,"offset":12953},"end":{"line":324,"column":104,"offset":13056},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":326,"column":1,"offset":13058},"end":{"line":334,"column":4,"offset":13328},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":336,"column":1,"offset":13330},"end":{"line":336,"column":28,"offset":13357},"indent":[]}}],"position":{"start":{"line":336,"column":1,"offset":13330},"end":{"line":336,"column":28,"offset":13357},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":338,"column":1,"offset":13359},"end":{"line":340,"column":4,"offset":13403},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":342,"column":1,"offset":13405},"end":{"line":342,"column":48,"offset":13452},"indent":[]}}],"position":{"start":{"line":342,"column":1,"offset":13405},"end":{"line":342,"column":48,"offset":13452},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":344,"column":1,"offset":13454},"end":{"line":346,"column":4,"offset":13476},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":348,"column":1,"offset":13478},"end":{"line":348,"column":72,"offset":13549},"indent":[]}}],"position":{"start":{"line":348,"column":1,"offset":13478},"end":{"line":348,"column":72,"offset":13549},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":350,"column":1,"offset":13551},"end":{"line":352,"column":4,"offset":13608},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":354,"column":4,"offset":13613},"end":{"line":354,"column":11,"offset":13620},"indent":[]}}],"position":{"start":{"line":354,"column":1,"offset":13610},"end":{"line":354,"column":11,"offset":13620},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":356,"column":1,"offset":13622},"end":{"line":356,"column":283,"offset":13904},"indent":[]}}],"position":{"start":{"line":356,"column":1,"offset":13622},"end":{"line":356,"column":283,"offset":13904},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":358,"column":3,"offset":13908},"end":{"line":358,"column":54,"offset":13959},"indent":[]}}],"position":{"start":{"line":358,"column":3,"offset":13908},"end":{"line":358,"column":54,"offset":13959},"indent":[]}}],"position":{"start":{"line":358,"column":1,"offset":13906},"end":{"line":358,"column":54,"offset":13959},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":360,"column":5,"offset":13965},"end":{"line":360,"column":14,"offset":13974},"indent":[]}}],"position":{"start":{"line":360,"column":1,"offset":13961},"end":{"line":360,"column":14,"offset":13974},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":362,"column":1,"offset":13976},"end":{"line":362,"column":68,"offset":14043},"indent":[]}}],"position":{"start":{"line":362,"column":1,"offset":13976},"end":{"line":362,"column":68,"offset":14043},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":364,"column":1,"offset":14045},"end":{"line":367,"column":4,"offset":14196},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":369,"column":1,"offset":14198},"end":{"line":369,"column":46,"offset":14243},"indent":[]}}],"position":{"start":{"line":369,"column":1,"offset":14198},"end":{"line":369,"column":46,"offset":14243},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":371,"column":3,"offset":14247},"end":{"line":371,"column":103,"offset":14347},"indent":[]}}],"position":{"start":{"line":371,"column":3,"offset":14247},"end":{"line":371,"column":103,"offset":14347},"indent":[]}}],"position":{"start":{"line":371,"column":1,"offset":14245},"end":{"line":371,"column":103,"offset":14347},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":373,"column":1,"offset":14349},"end":{"line":378,"column":4,"offset":14559},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":380,"column":1,"offset":14561},"end":{"line":380,"column":151,"offset":14711},"indent":[]}}],"position":{"start":{"line":380,"column":1,"offset":14561},"end":{"line":380,"column":151,"offset":14711},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":382,"column":3,"offset":14715},"end":{"line":382,"column":22,"offset":14734},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":382,"column":22,"offset":14734},"end":{"line":382,"column":26,"offset":14738},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":382,"column":26,"offset":14738},"end":{"line":382,"column":40,"offset":14752},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":382,"column":40,"offset":14752},"end":{"line":382,"column":50,"offset":14762},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":382,"column":50,"offset":14762},"end":{"line":382,"column":98,"offset":14810},"indent":[]}}],"position":{"start":{"line":382,"column":3,"offset":14715},"end":{"line":382,"column":98,"offset":14810},"indent":[]}}],"position":{"start":{"line":382,"column":1,"offset":14713},"end":{"line":382,"column":98,"offset":14810},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":384,"column":1,"offset":14812},"end":{"line":388,"column":4,"offset":14974},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":390,"column":1,"offset":14976},"end":{"line":390,"column":72,"offset":15047},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":390,"column":72,"offset":15047},"end":{"line":390,"column":84,"offset":15059},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":390,"column":84,"offset":15059},"end":{"line":390,"column":102,"offset":15077},"indent":[]}}],"position":{"start":{"line":390,"column":1,"offset":14976},"end":{"line":390,"column":102,"offset":15077},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":392,"column":1,"offset":15079},"end":{"line":395,"column":4,"offset":15153},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":397,"column":5,"offset":15159},"end":{"line":397,"column":8,"offset":15162},"indent":[]}}],"position":{"start":{"line":397,"column":1,"offset":15155},"end":{"line":397,"column":8,"offset":15162},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":399,"column":1,"offset":15164},"end":{"line":399,"column":176,"offset":15339},"indent":[]}}],"position":{"start":{"line":399,"column":1,"offset":15164},"end":{"line":399,"column":176,"offset":15339},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":401,"column":1,"offset":15341},"end":{"line":408,"column":4,"offset":15638},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":410,"column":1,"offset":15640},"end":{"line":410,"column":60,"offset":15699},"indent":[]}}],"position":{"start":{"line":410,"column":1,"offset":15640},"end":{"line":410,"column":60,"offset":15699},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":412,"column":1,"offset":15701},"end":{"line":416,"column":4,"offset":15827},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":418,"column":1,"offset":15829},"end":{"line":418,"column":63,"offset":15891},"indent":[]}}],"position":{"start":{"line":418,"column":1,"offset":15829},"end":{"line":418,"column":63,"offset":15891},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":420,"column":1,"offset":15893},"end":{"line":440,"column":4,"offset":16400},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":442,"column":1,"offset":16402},"end":{"line":442,"column":99,"offset":16500},"indent":[]}}],"position":{"start":{"line":442,"column":1,"offset":16402},"end":{"line":442,"column":99,"offset":16500},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":444,"column":1,"offset":16502},"end":{"line":447,"column":4,"offset":16604},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":449,"column":1,"offset":16606},"end":{"line":449,"column":37,"offset":16642},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":449,"column":37,"offset":16642},"end":{"line":449,"column":47,"offset":16652},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":449,"column":47,"offset":16652},"end":{"line":449,"column":89,"offset":16694},"indent":[]}}],"position":{"start":{"line":449,"column":1,"offset":16606},"end":{"line":449,"column":89,"offset":16694},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":451,"column":1,"offset":16696},"end":{"line":455,"column":4,"offset":16821},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":457,"column":1,"offset":16823},"end":{"line":457,"column":78,"offset":16900},"indent":[]}}],"position":{"start":{"line":457,"column":1,"offset":16823},"end":{"line":457,"column":78,"offset":16900},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":459,"column":1,"offset":16902},"end":{"line":463,"column":4,"offset":17006},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":465,"column":1,"offset":17008},"end":{"line":465,"column":75,"offset":17082},"indent":[]}}],"position":{"start":{"line":465,"column":1,"offset":17008},"end":{"line":465,"column":75,"offset":17082},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":467,"column":1,"offset":17084},"end":{"line":471,"column":4,"offset":17157},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":473,"column":1,"offset":17159},"end":{"line":473,"column":145,"offset":17303},"indent":[]}}],"position":{"start":{"line":473,"column":1,"offset":17159},"end":{"line":473,"column":145,"offset":17303},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":475,"column":5,"offset":17309},"end":{"line":475,"column":17,"offset":17321},"indent":[]}}],"position":{"start":{"line":475,"column":1,"offset":17305},"end":{"line":475,"column":17,"offset":17321},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":477,"column":1,"offset":17323},"end":{"line":477,"column":300,"offset":17622},"indent":[]}}],"position":{"start":{"line":477,"column":1,"offset":17323},"end":{"line":477,"column":300,"offset":17622},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":479,"column":1,"offset":17624},"end":{"line":479,"column":178,"offset":17801},"indent":[]}}],"position":{"start":{"line":479,"column":1,"offset":17624},"end":{"line":479,"column":178,"offset":17801},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":481,"column":1,"offset":17803},"end":{"line":481,"column":48,"offset":17850},"indent":[]}}],"position":{"start":{"line":481,"column":1,"offset":17803},"end":{"line":481,"column":48,"offset":17850},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":483,"column":1,"offset":17852},"end":{"line":485,"column":4,"offset":17896},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":487,"column":1,"offset":17898},"end":{"line":487,"column":104,"offset":18001},"indent":[]}}],"position":{"start":{"line":487,"column":1,"offset":17898},"end":{"line":487,"column":104,"offset":18001},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":489,"column":1,"offset":18003},"end":{"line":497,"column":4,"offset":18273},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":499,"column":1,"offset":18275},"end":{"line":499,"column":28,"offset":18302},"indent":[]}}],"position":{"start":{"line":499,"column":1,"offset":18275},"end":{"line":499,"column":28,"offset":18302},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":501,"column":1,"offset":18304},"end":{"line":503,"column":4,"offset":18352},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":505,"column":1,"offset":18354},"end":{"line":505,"column":48,"offset":18401},"indent":[]}}],"position":{"start":{"line":505,"column":1,"offset":18354},"end":{"line":505,"column":48,"offset":18401},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":507,"column":1,"offset":18403},"end":{"line":509,"column":4,"offset":18425},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":511,"column":1,"offset":18427},"end":{"line":511,"column":72,"offset":18498},"indent":[]}}],"position":{"start":{"line":511,"column":1,"offset":18427},"end":{"line":511,"column":72,"offset":18498},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":513,"column":1,"offset":18500},"end":{"line":515,"column":4,"offset":18561},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":518,"column":1,"offset":18564},"end":{"line":518,"column":31,"offset":18594},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":518,"column":31,"offset":18594}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example:`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`kerberos`}{`-`}{`camera1`}{` \\\\`}{`\n`}{`-`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/config:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`config`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/capture:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`capture`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/logs:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`logs`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/webconfig:/`}{`var`}{`/`}{`www`}{`/web/config \\\\ `}{`\n`}{`-`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`\n`}{`Learn`}{` `}{`more`}{` `}{`about`}{` `}{`volumes`}{` `}{`in`}{` `}{`this`}{` `}{`tutorial`}{`.`}{`\n`}{`\n`}{`\n`}{`## `}{`Balena`}{`\n`}{`\n`}{`Running`}{` `}{`Kerberos`}{` `}{`inside`}{` `}{`a`}{` `}{`Docker`}{` `}{`container`}{` `}{`is`}{` `}{`great`}{`, `}{`it`}{` `}{`makes`}{` `}{`it`}{` `}{`possible`}{` `}{`to`}{` `}{`run`}{` `}{`Kerberos`}{` `}{`everywhere`}{`, `}{`basically`}{` `}{`on`}{` `}{`any`}{` `}{`Linux`}{` `}{`OS`}{`. `}{`These`}{` `}{`days`}{` `}{`we`}{` `}{`have`}{` `}{`a`}{` `}{`lot`}{` `}{`of`}{` `}{`IoT`}{` `}{`boards`}{`, `}{`however`}{` `}{`by`}{` `}{`default`}{` `}{`we`}{` `}{`only`}{` `}{`support`}{` `}{`the`}{` `}{`Raspberry`}{` `}{`Pi`}{` `}{`versions`}{`. `}{`The`}{` `}{`reason`}{` `}{`is`}{` `}{`simple`}{`, `}{`it`}{`'s not our major concern to support any kind of board`}{`.`}{`\n`}{`\n`}{`To`}{` `}{`fill`}{` `}{`the`}{` `}{`gap`}{`, `}{`regarding`}{` `}{`the`}{` `}{`latter`}{`, `}{`we`}{` `}{`can`}{` `}{`rely`}{` `}{`on`}{` `}{`another`}{` `}{`solution`}{` `}{`called`}{` [`}{`Balena`}{`.`}{`io`}{`](`}{`https`}{`:`}{`//balena.io). Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).`}{`\n`}{`\n`}{`On`}{` `}{`top`}{` `}{`of`}{` `}{`supporting`}{` `}{`a`}{` `}{`lot`}{` `}{`of`}{` `}{`boars`}{`,`}{`\n`}{`\n`}{`---`}{`\n`}{`\n`}{`# `}{`Advanced`}{`\n`}{`\n`}{`Following`}{` `}{`installation`}{` `}{`methods`}{` `}{`are`}{` `}{`only`}{` `}{`for`}{` `}{`advanced`}{` `}{`users`}{`, `}{`who`}{` `}{`need`}{` `}{`to`}{` `}{`have`}{` `}{`more`}{` `}{`control`}{` `}{`over`}{` `}{`the`}{` `}{`Kerberos`}{` `}{`Open`}{` `}{`Source`}{` `}{`environment`}{`.`}{`\n`}{`\n`}{`## `}{`Raspbian`}{`\n`}{`\n`}{`If`}{` `}{`you`}{` `}{`have`}{` `}{`already`}{` `}{`an`}{` `}{`OS`}{` (`}{`e`}{`.`}{`g`}{`. `}{`Raspbian`}{` `}{`Buster`}{`) `}{`flashed`}{` `}{`to`}{` `}{`your`}{` `}{`Raspberry`}{` `}{`Pi`}{`, `}{`then`}{` `}{`it`}{` `}{`makes`}{` `}{`sense`}{` `}{`to`}{` `}{`install`}{` `}{`the`}{` `}{`Kerberos`}{` `}{`agent`}{` `}{`on`}{` `}{`top`}{` `}{`of`}{` `}{`your`}{` `}{`existing`}{` `}{`OS`}{`. `}{`There`}{` `}{`are`}{` `}{`two`}{` `}{`ways`}{` `}{`to`}{` `}{`achieve`}{` `}{`this`}{`:`}{`\n`}{`\n`}{`1.`}{` `}{`Install`}{` `}{`the`}{` `}{`Kerberos`}{` `}{`agent`}{` `}{`using`}{` `}{`Docker`}{` (`}{`more`}{` `}{`info`}{` `}{`below`}{`),`}{`\n`}{`2.`}{` `}{`or`}{` `}{`you`}{` `}{`can`}{` `}{`install`}{` `}{`the`}{` `}{`Kerberos`}{` `}{`agent`}{` `}{`manually`}{` (`}{`machinery`}{` + `}{`web`}{`).`}{`\n`}{`\n`}{`This`}{` `}{`section`}{` `}{`will`}{` `}{`focus`}{` `}{`on`}{` `}{`option`}{` `}{`2`}{`, `}{`and`}{` `}{`will`}{` `}{`show`}{` `}{`you`}{` `}{`how`}{` `}{`to`}{` `}{`install`}{` `}{`the`}{` `}{`Kerberos`}{` `}{`agent`}{` `}{`manually`}{`.`}{`\n`}{`\n`}{`### `}{`Update`}{` `}{`OS`}{`\n`}{`\n`}{`Let`}{`'s start with updating the OS, and installing a couple of packages`}{`.`}{`\n`}{`\n`}{`> `}{`We`}{` `}{`have`}{` `}{`tested`}{` `}{`the`}{` `}{`Raspbian`}{` `}{`installation`}{` `}{`on`}{` `}{`\\`Raspbian GNU/Linux 10 (buster)\\``}{`. `}{`It`}{` `}{`might`}{` `}{`be`}{` `}{`that`}{` `}{`if`}{` `}{`you`}{` `}{`have`}{` `}{`a`}{` `}{`different`}{` `}{`version`}{` `}{`of`}{` `}{`Raspbian`}{`, `}{`you`}{` `}{`will`}{` `}{`need`}{` `}{`to`}{` `}{`install`}{` `}{`additional`}{`/`}{`different`}{` `}{`packages`}{`.`}{`\n`}{`\n`}{`\\`\\`\\`ts`}{`\n`}{`sudo apt-get update && sudo apt-get install -y ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-3116a5c30580652aa7fed0ac6e1075d8.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-3116a5c30580652aa7fed0ac6e1075d8.json new file mode 100644 index 0000000..f55af54 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-3116a5c30580652aa7fed0ac6e1075d8.json @@ -0,0 +1 @@ +{"expireTime":9007200842320160000,"key":"gatsby-plugin-mdx-entire-payload-f9a2a7ea1e3d4c785f77edf2f02b6d07-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4645},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4647},"end":{"line":107,"column":80,"offset":4726},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4726},"end":{"line":107,"column":101,"offset":4747},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4747},"end":{"line":107,"column":162,"offset":4808},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4647},"end":{"line":107,"column":162,"offset":4808},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4810},"end":{"line":112,"column":4,"offset":4899},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4904},"end":{"line":114,"column":10,"offset":4910},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4901},"end":{"line":114,"column":10,"offset":4910},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on ","position":{"start":{"line":116,"column":1,"offset":4912},"end":{"line":116,"column":54,"offset":4965},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":55,"offset":4966},"end":{"line":116,"column":69,"offset":4980},"indent":[]}}],"position":{"start":{"line":116,"column":54,"offset":4965},"end":{"line":116,"column":105,"offset":5016},"indent":[]}},{"type":"text","value":", which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use Docker, to get the Kerberos agent up and running. All Docker images can be found on ","position":{"start":{"line":116,"column":105,"offset":5016},"end":{"line":116,"column":376,"offset":5287},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":377,"offset":5288},"end":{"line":116,"column":391,"offset":5302},"indent":[]}}],"position":{"start":{"line":116,"column":376,"offset":5287},"end":{"line":116,"column":427,"offset":5338},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":427,"offset":5338},"end":{"line":116,"column":428,"offset":5339},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4912},"end":{"line":116,"column":428,"offset":5339},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5345},"end":{"line":118,"column":18,"offset":5358},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5341},"end":{"line":118,"column":18,"offset":5358},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5362},"end":{"line":120,"column":50,"offset":5409},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5362},"end":{"line":120,"column":50,"offset":5409},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5360},"end":{"line":120,"column":50,"offset":5409},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5415},"end":{"line":122,"column":11,"offset":5421},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5411},"end":{"line":122,"column":11,"offset":5421},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5423},"end":{"line":124,"column":64,"offset":5486},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5487},"end":{"line":124,"column":86,"offset":5508},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5486},"end":{"line":124,"column":126,"offset":5548},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5548},"end":{"line":124,"column":127,"offset":5549},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5423},"end":{"line":124,"column":127,"offset":5549},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5555},"end":{"line":126,"column":26,"offset":5576},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5551},"end":{"line":126,"column":26,"offset":5576},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5578},"end":{"line":128,"column":126,"offset":5703},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5578},"end":{"line":128,"column":126,"offset":5703},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5705},"end":{"line":132,"column":4,"offset":5744},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5746},"end":{"line":134,"column":187,"offset":5932},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5746},"end":{"line":134,"column":187,"offset":5932},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5934},"end":{"line":138,"column":4,"offset":6012},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6014},"end":{"line":140,"column":153,"offset":6166},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6014},"end":{"line":140,"column":153,"offset":6166},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6168},"end":{"line":145,"column":4,"offset":6315},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6317},"end":{"line":147,"column":100,"offset":6416},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6317},"end":{"line":147,"column":100,"offset":6416},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6417},"end":{"line":152,"column":4,"offset":6486},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6492},"end":{"line":154,"column":12,"offset":6499},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6488},"end":{"line":154,"column":12,"offset":6499},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Instead of just running the Kerberos container, you can also persist your configuration by assigning volumes. An example of mounting volumes looks like this; an overview of ","position":{"start":{"line":156,"column":1,"offset":6501},"end":{"line":156,"column":174,"offset":6674},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker/blob/master/Dockerfile#L171-L177","children":[{"type":"text","value":"the different volumes can be found here","position":{"start":{"line":156,"column":175,"offset":6675},"end":{"line":156,"column":214,"offset":6714},"indent":[]}}],"position":{"start":{"line":156,"column":174,"offset":6674},"end":{"line":156,"column":287,"offset":6787},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":156,"column":287,"offset":6787},"end":{"line":156,"column":288,"offset":6788},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6501},"end":{"line":156,"column":288,"offset":6788},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":158,"column":3,"offset":6792},"end":{"line":158,"column":25,"offset":6814},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6792},"end":{"line":158,"column":25,"offset":6814},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6790},"end":{"line":158,"column":25,"offset":6814},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":159,"column":3,"offset":6817},"end":{"line":159,"column":59,"offset":6873},"indent":[]}}],"position":{"start":{"line":159,"column":3,"offset":6817},"end":{"line":159,"column":59,"offset":6873},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":6815},"end":{"line":159,"column":59,"offset":6873},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6790},"end":{"line":159,"column":59,"offset":6873},"indent":[1]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name kerberos-camera1 \\\n-p 80:80 -p 8889:8889 \\\n-v ~/config:/etc/opt/kerberosio/config \\\n-v ~/capture:/etc/opt/kerberosio/capture \\\n-v ~/logs:/etc/opt/kerberosio/logs \\\n-v ~/webconfig:/var/www/web/config \\\n-d kerberos/kerberos","position":{"start":{"line":161,"column":1,"offset":6875},"end":{"line":169,"column":4,"offset":7124},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.","position":{"start":{"line":171,"column":1,"offset":7126},"end":{"line":171,"column":87,"offset":7212},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":7126},"end":{"line":171,"column":87,"offset":7212},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://medium.com/@cedricverst/kerberos-io-the-road-to-docker-8e048a480241","children":[{"type":"text","value":"Kerberos.io — the road to Docker","position":{"start":{"line":172,"column":4,"offset":7216},"end":{"line":172,"column":36,"offset":7248},"indent":[]}}],"position":{"start":{"line":172,"column":3,"offset":7215},"end":{"line":172,"column":114,"offset":7326},"indent":[]}}],"position":{"start":{"line":172,"column":3,"offset":7215},"end":{"line":172,"column":114,"offset":7326},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7213},"end":{"line":172,"column":114,"offset":7326},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7213},"end":{"line":172,"column":114,"offset":7326},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":175,"column":4,"offset":7332},"end":{"line":175,"column":10,"offset":7338},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7329},"end":{"line":175,"column":10,"offset":7338},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.","position":{"start":{"line":177,"column":1,"offset":7340},"end":{"line":177,"column":310,"offset":7649},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7340},"end":{"line":177,"column":310,"offset":7649},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To fill the gap, regarding the latter, we can rely on another solution called ","position":{"start":{"line":179,"column":1,"offset":7651},"end":{"line":179,"column":79,"offset":7729},"indent":[]}},{"type":"link","title":null,"url":"https://balena.io","children":[{"type":"text","value":"Balena.io","position":{"start":{"line":179,"column":80,"offset":7730},"end":{"line":179,"column":89,"offset":7739},"indent":[]}}],"position":{"start":{"line":179,"column":79,"offset":7729},"end":{"line":179,"column":109,"offset":7759},"indent":[]}},{"type":"text","value":". Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).","position":{"start":{"line":179,"column":109,"offset":7759},"end":{"line":179,"column":386,"offset":8036},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7651},"end":{"line":179,"column":386,"offset":8036},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On top of supporting a lot of boars,","position":{"start":{"line":181,"column":1,"offset":8038},"end":{"line":181,"column":37,"offset":8074},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":8038},"end":{"line":181,"column":37,"offset":8074},"indent":[]}},{"type":"thematicBreak","position":{"start":{"line":183,"column":1,"offset":8076},"end":{"line":183,"column":4,"offset":8079},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":185,"column":3,"offset":8083},"end":{"line":185,"column":11,"offset":8091},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":8081},"end":{"line":185,"column":11,"offset":8091},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":187,"column":1,"offset":8093},"end":{"line":187,"column":133,"offset":8225},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":8093},"end":{"line":187,"column":133,"offset":8225},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":189,"column":4,"offset":8230},"end":{"line":189,"column":12,"offset":8238},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":8227},"end":{"line":189,"column":12,"offset":8238},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":191,"column":1,"offset":8240},"end":{"line":191,"column":193,"offset":8432},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":8240},"end":{"line":191,"column":193,"offset":8432},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":193,"column":4,"offset":8437},"end":{"line":193,"column":62,"offset":8495},"indent":[]}}],"position":{"start":{"line":193,"column":4,"offset":8437},"end":{"line":193,"column":62,"offset":8495},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8434},"end":{"line":193,"column":62,"offset":8495},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":194,"column":4,"offset":8499},"end":{"line":194,"column":69,"offset":8564},"indent":[]}}],"position":{"start":{"line":194,"column":4,"offset":8499},"end":{"line":194,"column":69,"offset":8564},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":8496},"end":{"line":194,"column":69,"offset":8564},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8434},"end":{"line":194,"column":69,"offset":8564},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":196,"column":1,"offset":8566},"end":{"line":196,"column":99,"offset":8664},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8566},"end":{"line":196,"column":99,"offset":8664},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":198,"column":5,"offset":8670},"end":{"line":198,"column":14,"offset":8679},"indent":[]}}],"position":{"start":{"line":198,"column":1,"offset":8666},"end":{"line":198,"column":14,"offset":8679},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":200,"column":1,"offset":8681},"end":{"line":200,"column":71,"offset":8751},"indent":[]}}],"position":{"start":{"line":200,"column":1,"offset":8681},"end":{"line":200,"column":71,"offset":8751},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":202,"column":3,"offset":8755},"end":{"line":202,"column":47,"offset":8799},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":202,"column":47,"offset":8799},"end":{"line":202,"column":79,"offset":8831},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":202,"column":79,"offset":8831},"end":{"line":202,"column":198,"offset":8950},"indent":[]}}],"position":{"start":{"line":202,"column":3,"offset":8755},"end":{"line":202,"column":198,"offset":8950},"indent":[]}}],"position":{"start":{"line":202,"column":1,"offset":8753},"end":{"line":202,"column":198,"offset":8950},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":204,"column":1,"offset":8952},"end":{"line":206,"column":4,"offset":9015},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":208,"column":5,"offset":9021},"end":{"line":208,"column":14,"offset":9030},"indent":[]}}],"position":{"start":{"line":208,"column":1,"offset":9017},"end":{"line":208,"column":14,"offset":9030},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":210,"column":1,"offset":9032},"end":{"line":210,"column":56,"offset":9087},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":9032},"end":{"line":210,"column":56,"offset":9087},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":211,"column":3,"offset":9090},"end":{"line":211,"column":52,"offset":9139},"indent":[]}}],"position":{"start":{"line":211,"column":3,"offset":9090},"end":{"line":211,"column":52,"offset":9139},"indent":[]}}],"position":{"start":{"line":211,"column":3,"offset":9090},"end":{"line":211,"column":52,"offset":9139},"indent":[]}}],"position":{"start":{"line":211,"column":1,"offset":9088},"end":{"line":211,"column":52,"offset":9139},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":213,"column":1,"offset":9141},"end":{"line":213,"column":3,"offset":9143},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":213,"column":3,"offset":9143},"end":{"line":213,"column":9,"offset":9149},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":213,"column":9,"offset":9149},"end":{"line":213,"column":223,"offset":9363},"indent":[]}}],"position":{"start":{"line":213,"column":1,"offset":9141},"end":{"line":213,"column":223,"offset":9363},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":215,"column":3,"offset":9367},"end":{"line":215,"column":159,"offset":9523},"indent":[]}}],"position":{"start":{"line":215,"column":3,"offset":9367},"end":{"line":215,"column":159,"offset":9523},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":9365},"end":{"line":215,"column":159,"offset":9523},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":217,"column":1,"offset":9525},"end":{"line":220,"column":4,"offset":9702},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":222,"column":1,"offset":9704},"end":{"line":222,"column":160,"offset":9863},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":9704},"end":{"line":222,"column":160,"offset":9863},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":224,"column":3,"offset":9867},"end":{"line":224,"column":31,"offset":9895},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":224,"column":31,"offset":9895},"end":{"line":224,"column":101,"offset":9965},"indent":[]}}],"position":{"start":{"line":224,"column":3,"offset":9867},"end":{"line":224,"column":101,"offset":9965},"indent":[]}}],"position":{"start":{"line":224,"column":1,"offset":9865},"end":{"line":224,"column":101,"offset":9965},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":226,"column":1,"offset":9967},"end":{"line":229,"column":4,"offset":10139},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":231,"column":1,"offset":10141},"end":{"line":231,"column":73,"offset":10213},"indent":[]}}],"position":{"start":{"line":231,"column":1,"offset":10141},"end":{"line":231,"column":73,"offset":10213},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":234,"column":3,"offset":10218},"end":{"line":234,"column":31,"offset":10246},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":234,"column":31,"offset":10246},"end":{"line":234,"column":101,"offset":10316},"indent":[]}}],"position":{"start":{"line":234,"column":3,"offset":10218},"end":{"line":234,"column":101,"offset":10316},"indent":[]}}],"position":{"start":{"line":234,"column":1,"offset":10216},"end":{"line":234,"column":101,"offset":10316},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":236,"column":1,"offset":10318},"end":{"line":239,"column":4,"offset":10490},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":241,"column":1,"offset":10492},"end":{"line":241,"column":62,"offset":10553},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":241,"column":63,"offset":10554},"end":{"line":241,"column":75,"offset":10566},"indent":[]}}],"position":{"start":{"line":241,"column":62,"offset":10553},"end":{"line":241,"column":143,"offset":10634},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":241,"column":143,"offset":10634},"end":{"line":241,"column":150,"offset":10641},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":241,"column":150,"offset":10641},"end":{"line":241,"column":169,"offset":10660},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":241,"column":169,"offset":10660},"end":{"line":241,"column":170,"offset":10661},"indent":[]}}],"position":{"start":{"line":241,"column":1,"offset":10492},"end":{"line":241,"column":170,"offset":10661},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":243,"column":1,"offset":10663},"end":{"line":245,"column":4,"offset":10690},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":247,"column":1,"offset":10692},"end":{"line":247,"column":58,"offset":10749},"indent":[]}}],"position":{"start":{"line":247,"column":1,"offset":10692},"end":{"line":247,"column":58,"offset":10749},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":249,"column":1,"offset":10751},"end":{"line":252,"column":4,"offset":10821},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":254,"column":5,"offset":10827},"end":{"line":254,"column":8,"offset":10830},"indent":[]}}],"position":{"start":{"line":254,"column":1,"offset":10823},"end":{"line":254,"column":8,"offset":10830},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":256,"column":1,"offset":10832},"end":{"line":256,"column":280,"offset":11111},"indent":[]}}],"position":{"start":{"line":256,"column":1,"offset":10832},"end":{"line":256,"column":280,"offset":11111},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":258,"column":1,"offset":11113},"end":{"line":258,"column":37,"offset":11149},"indent":[]}}],"position":{"start":{"line":258,"column":1,"offset":11113},"end":{"line":258,"column":37,"offset":11149},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":260,"column":1,"offset":11151},"end":{"line":262,"column":4,"offset":11324},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":264,"column":1,"offset":11326},"end":{"line":264,"column":25,"offset":11350},"indent":[]}}],"position":{"start":{"line":264,"column":1,"offset":11326},"end":{"line":264,"column":25,"offset":11350},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":266,"column":1,"offset":11352},"end":{"line":269,"column":4,"offset":11456},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":271,"column":1,"offset":11458},"end":{"line":271,"column":118,"offset":11575},"indent":[]}}],"position":{"start":{"line":271,"column":1,"offset":11458},"end":{"line":271,"column":118,"offset":11575},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":273,"column":1,"offset":11577},"end":{"line":293,"column":4,"offset":12084},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":295,"column":1,"offset":12086},"end":{"line":295,"column":14,"offset":12099},"indent":[]}}],"position":{"start":{"line":295,"column":1,"offset":12086},"end":{"line":295,"column":14,"offset":12099},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":297,"column":1,"offset":12101},"end":{"line":299,"column":4,"offset":12137},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":301,"column":1,"offset":12139},"end":{"line":301,"column":91,"offset":12229},"indent":[]}}],"position":{"start":{"line":301,"column":1,"offset":12139},"end":{"line":301,"column":91,"offset":12229},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":303,"column":1,"offset":12231},"end":{"line":311,"column":4,"offset":12604},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":313,"column":1,"offset":12606},"end":{"line":313,"column":145,"offset":12750},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":12606},"end":{"line":313,"column":145,"offset":12750},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":315,"column":5,"offset":12756},"end":{"line":315,"column":17,"offset":12768},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12752},"end":{"line":315,"column":17,"offset":12768},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":317,"column":1,"offset":12770},"end":{"line":317,"column":300,"offset":13069},"indent":[]}}],"position":{"start":{"line":317,"column":1,"offset":12770},"end":{"line":317,"column":300,"offset":13069},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":319,"column":1,"offset":13071},"end":{"line":319,"column":178,"offset":13248},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":13071},"end":{"line":319,"column":178,"offset":13248},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":321,"column":1,"offset":13250},"end":{"line":321,"column":48,"offset":13297},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":13250},"end":{"line":321,"column":48,"offset":13297},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":323,"column":1,"offset":13299},"end":{"line":325,"column":4,"offset":13339},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":327,"column":1,"offset":13341},"end":{"line":327,"column":104,"offset":13444},"indent":[]}}],"position":{"start":{"line":327,"column":1,"offset":13341},"end":{"line":327,"column":104,"offset":13444},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":329,"column":1,"offset":13446},"end":{"line":337,"column":4,"offset":13716},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":339,"column":1,"offset":13718},"end":{"line":339,"column":28,"offset":13745},"indent":[]}}],"position":{"start":{"line":339,"column":1,"offset":13718},"end":{"line":339,"column":28,"offset":13745},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":341,"column":1,"offset":13747},"end":{"line":343,"column":4,"offset":13791},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":345,"column":1,"offset":13793},"end":{"line":345,"column":48,"offset":13840},"indent":[]}}],"position":{"start":{"line":345,"column":1,"offset":13793},"end":{"line":345,"column":48,"offset":13840},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":347,"column":1,"offset":13842},"end":{"line":349,"column":4,"offset":13864},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":351,"column":1,"offset":13866},"end":{"line":351,"column":72,"offset":13937},"indent":[]}}],"position":{"start":{"line":351,"column":1,"offset":13866},"end":{"line":351,"column":72,"offset":13937},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":353,"column":1,"offset":13939},"end":{"line":355,"column":4,"offset":13996},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":357,"column":4,"offset":14001},"end":{"line":357,"column":11,"offset":14008},"indent":[]}}],"position":{"start":{"line":357,"column":1,"offset":13998},"end":{"line":357,"column":11,"offset":14008},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":359,"column":1,"offset":14010},"end":{"line":359,"column":283,"offset":14292},"indent":[]}}],"position":{"start":{"line":359,"column":1,"offset":14010},"end":{"line":359,"column":283,"offset":14292},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":361,"column":3,"offset":14296},"end":{"line":361,"column":54,"offset":14347},"indent":[]}}],"position":{"start":{"line":361,"column":3,"offset":14296},"end":{"line":361,"column":54,"offset":14347},"indent":[]}}],"position":{"start":{"line":361,"column":1,"offset":14294},"end":{"line":361,"column":54,"offset":14347},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":363,"column":5,"offset":14353},"end":{"line":363,"column":14,"offset":14362},"indent":[]}}],"position":{"start":{"line":363,"column":1,"offset":14349},"end":{"line":363,"column":14,"offset":14362},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":365,"column":1,"offset":14364},"end":{"line":365,"column":68,"offset":14431},"indent":[]}}],"position":{"start":{"line":365,"column":1,"offset":14364},"end":{"line":365,"column":68,"offset":14431},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":367,"column":1,"offset":14433},"end":{"line":370,"column":4,"offset":14584},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":372,"column":1,"offset":14586},"end":{"line":372,"column":46,"offset":14631},"indent":[]}}],"position":{"start":{"line":372,"column":1,"offset":14586},"end":{"line":372,"column":46,"offset":14631},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":374,"column":3,"offset":14635},"end":{"line":374,"column":103,"offset":14735},"indent":[]}}],"position":{"start":{"line":374,"column":3,"offset":14635},"end":{"line":374,"column":103,"offset":14735},"indent":[]}}],"position":{"start":{"line":374,"column":1,"offset":14633},"end":{"line":374,"column":103,"offset":14735},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":376,"column":1,"offset":14737},"end":{"line":381,"column":4,"offset":14947},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":383,"column":1,"offset":14949},"end":{"line":383,"column":151,"offset":15099},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14949},"end":{"line":383,"column":151,"offset":15099},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":385,"column":3,"offset":15103},"end":{"line":385,"column":22,"offset":15122},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":385,"column":22,"offset":15122},"end":{"line":385,"column":26,"offset":15126},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":385,"column":26,"offset":15126},"end":{"line":385,"column":40,"offset":15140},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":385,"column":40,"offset":15140},"end":{"line":385,"column":50,"offset":15150},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":385,"column":50,"offset":15150},"end":{"line":385,"column":98,"offset":15198},"indent":[]}}],"position":{"start":{"line":385,"column":3,"offset":15103},"end":{"line":385,"column":98,"offset":15198},"indent":[]}}],"position":{"start":{"line":385,"column":1,"offset":15101},"end":{"line":385,"column":98,"offset":15198},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":387,"column":1,"offset":15200},"end":{"line":391,"column":4,"offset":15362},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":393,"column":1,"offset":15364},"end":{"line":393,"column":72,"offset":15435},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":393,"column":72,"offset":15435},"end":{"line":393,"column":84,"offset":15447},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":393,"column":84,"offset":15447},"end":{"line":393,"column":102,"offset":15465},"indent":[]}}],"position":{"start":{"line":393,"column":1,"offset":15364},"end":{"line":393,"column":102,"offset":15465},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":395,"column":1,"offset":15467},"end":{"line":398,"column":4,"offset":15541},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":400,"column":5,"offset":15547},"end":{"line":400,"column":8,"offset":15550},"indent":[]}}],"position":{"start":{"line":400,"column":1,"offset":15543},"end":{"line":400,"column":8,"offset":15550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":402,"column":1,"offset":15552},"end":{"line":402,"column":176,"offset":15727},"indent":[]}}],"position":{"start":{"line":402,"column":1,"offset":15552},"end":{"line":402,"column":176,"offset":15727},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":404,"column":1,"offset":15729},"end":{"line":411,"column":4,"offset":16026},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":413,"column":1,"offset":16028},"end":{"line":413,"column":60,"offset":16087},"indent":[]}}],"position":{"start":{"line":413,"column":1,"offset":16028},"end":{"line":413,"column":60,"offset":16087},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":415,"column":1,"offset":16089},"end":{"line":419,"column":4,"offset":16215},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":421,"column":1,"offset":16217},"end":{"line":421,"column":63,"offset":16279},"indent":[]}}],"position":{"start":{"line":421,"column":1,"offset":16217},"end":{"line":421,"column":63,"offset":16279},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":423,"column":1,"offset":16281},"end":{"line":443,"column":4,"offset":16788},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":445,"column":1,"offset":16790},"end":{"line":445,"column":99,"offset":16888},"indent":[]}}],"position":{"start":{"line":445,"column":1,"offset":16790},"end":{"line":445,"column":99,"offset":16888},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":447,"column":1,"offset":16890},"end":{"line":450,"column":4,"offset":16992},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":452,"column":1,"offset":16994},"end":{"line":452,"column":37,"offset":17030},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":452,"column":37,"offset":17030},"end":{"line":452,"column":47,"offset":17040},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":452,"column":47,"offset":17040},"end":{"line":452,"column":89,"offset":17082},"indent":[]}}],"position":{"start":{"line":452,"column":1,"offset":16994},"end":{"line":452,"column":89,"offset":17082},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":454,"column":1,"offset":17084},"end":{"line":458,"column":4,"offset":17209},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":460,"column":1,"offset":17211},"end":{"line":460,"column":78,"offset":17288},"indent":[]}}],"position":{"start":{"line":460,"column":1,"offset":17211},"end":{"line":460,"column":78,"offset":17288},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":462,"column":1,"offset":17290},"end":{"line":466,"column":4,"offset":17394},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":468,"column":1,"offset":17396},"end":{"line":468,"column":75,"offset":17470},"indent":[]}}],"position":{"start":{"line":468,"column":1,"offset":17396},"end":{"line":468,"column":75,"offset":17470},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":470,"column":1,"offset":17472},"end":{"line":474,"column":4,"offset":17545},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":476,"column":1,"offset":17547},"end":{"line":476,"column":145,"offset":17691},"indent":[]}}],"position":{"start":{"line":476,"column":1,"offset":17547},"end":{"line":476,"column":145,"offset":17691},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":478,"column":5,"offset":17697},"end":{"line":478,"column":17,"offset":17709},"indent":[]}}],"position":{"start":{"line":478,"column":1,"offset":17693},"end":{"line":478,"column":17,"offset":17709},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":480,"column":1,"offset":17711},"end":{"line":480,"column":300,"offset":18010},"indent":[]}}],"position":{"start":{"line":480,"column":1,"offset":17711},"end":{"line":480,"column":300,"offset":18010},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":482,"column":1,"offset":18012},"end":{"line":482,"column":178,"offset":18189},"indent":[]}}],"position":{"start":{"line":482,"column":1,"offset":18012},"end":{"line":482,"column":178,"offset":18189},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":484,"column":1,"offset":18191},"end":{"line":484,"column":48,"offset":18238},"indent":[]}}],"position":{"start":{"line":484,"column":1,"offset":18191},"end":{"line":484,"column":48,"offset":18238},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":486,"column":1,"offset":18240},"end":{"line":488,"column":4,"offset":18284},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":490,"column":1,"offset":18286},"end":{"line":490,"column":104,"offset":18389},"indent":[]}}],"position":{"start":{"line":490,"column":1,"offset":18286},"end":{"line":490,"column":104,"offset":18389},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":492,"column":1,"offset":18391},"end":{"line":500,"column":4,"offset":18661},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":502,"column":1,"offset":18663},"end":{"line":502,"column":28,"offset":18690},"indent":[]}}],"position":{"start":{"line":502,"column":1,"offset":18663},"end":{"line":502,"column":28,"offset":18690},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":504,"column":1,"offset":18692},"end":{"line":506,"column":4,"offset":18740},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":508,"column":1,"offset":18742},"end":{"line":508,"column":48,"offset":18789},"indent":[]}}],"position":{"start":{"line":508,"column":1,"offset":18742},"end":{"line":508,"column":48,"offset":18789},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":510,"column":1,"offset":18791},"end":{"line":512,"column":4,"offset":18813},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":514,"column":1,"offset":18815},"end":{"line":514,"column":72,"offset":18886},"indent":[]}}],"position":{"start":{"line":514,"column":1,"offset":18815},"end":{"line":514,"column":72,"offset":18886},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":516,"column":1,"offset":18888},"end":{"line":518,"column":4,"offset":18949},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":521,"column":1,"offset":18952},"end":{"line":521,"column":31,"offset":18982},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":521,"column":31,"offset":18982}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on `}{`the Docker hub`}{`, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use Docker, to get the Kerberos agent up and running. All Docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`Instead of just running the Kerberos container, you can also persist your configuration by assigning volumes. An example of mounting volumes looks like this; an overview of `}{`the different volumes can be found here`}{`.`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`kerberos`}{`-`}{`camera1`}{` \\\\`}{`\n`}{`-`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/config:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`config`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/capture:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`capture`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/logs:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`logs`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/webconfig:/`}{`var`}{`/`}{`www`}{`/web/config \\\\`}{`\n`}{`-`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.`}

\n \n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.`}

\n

{`To fill the gap, regarding the latter, we can rely on another solution called `}{`Balena.io`}{`. Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).`}

\n

{`On top of supporting a lot of boars,`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-32b2afad1d87d362789a8512873828bb.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-32b2afad1d87d362789a8512873828bb.json index 1525c2e..0c82120 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-32b2afad1d87d362789a8512873828bb.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-32b2afad1d87d362789a8512873828bb.json @@ -1 +1 @@ -{"expireTime":9007200841014157000,"key":"gatsby-plugin-mdx-entire-payload-b34dc2451d26a40200ded75d09d54590-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"First things first","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":21,"offset":179},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":21,"offset":179},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos started as an Open Source project back in 2014. Our main goal was, and still is, to provide everyone in this world with a free, professional and complete video surveillance system, which they can install in a couple of minutes.\nKerberos was initially developed for the Raspberry Pi, due to this many of the tools we have been using are lightweight and fast (such as C++). Over the years we have found other ways to make Kerberos available, such as KiOS (our custom Linux), Docker and Kubernetes.","position":{"start":{"line":10,"column":1,"offset":181},"end":{"line":11,"column":268,"offset":685},"indent":[1]}}],"position":{"start":{"line":10,"column":1,"offset":181},"end":{"line":11,"column":268,"offset":685},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"In this section we want to make clear what the Open Source version of Kerberos is about, and when you should be using it. What it can do, and what it can't do.","position":{"start":{"line":13,"column":1,"offset":687},"end":{"line":13,"column":160,"offset":846},"indent":[]}}],"position":{"start":{"line":13,"column":1,"offset":687},"end":{"line":13,"column":160,"offset":846},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"License","position":{"start":{"line":15,"column":4,"offset":851},"end":{"line":15,"column":11,"offset":858},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":848},"end":{"line":15,"column":11,"offset":858},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Kerberos Open Source project is licensed with ","position":{"start":{"line":17,"column":1,"offset":860},"end":{"line":17,"column":51,"offset":910},"indent":[]}},{"type":"link","title":null,"url":"/opensource/license","children":[{"type":"text","value":"BY-NC-SA 4.0","position":{"start":{"line":17,"column":52,"offset":911},"end":{"line":17,"column":64,"offset":923},"indent":[]}}],"position":{"start":{"line":17,"column":51,"offset":910},"end":{"line":17,"column":86,"offset":945},"indent":[]}},{"type":"text","value":", this means that everyone can use Kerberos and modify if to their needs, in a non commercial activity.","position":{"start":{"line":17,"column":86,"offset":945},"end":{"line":17,"column":189,"offset":1048},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":860},"end":{"line":17,"column":189,"offset":1048},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"When using the Open Source version","position":{"start":{"line":20,"column":4,"offset":1054},"end":{"line":20,"column":38,"offset":1088},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":1051},"end":{"line":20,"column":38,"offset":1088},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source is perfect for personal usage. It's great if you only have a couple of surveillance cameras to be managed. A Kerberos agent (e.g. on a Raspberry Pi or inside a Docker container) runs for each camera. Their are many different installation possibilities, please have a look at the ","position":{"start":{"line":22,"column":1,"offset":1090},"end":{"line":22,"column":301,"offset":1390},"indent":[]}},{"type":"link","title":null,"url":"/architectures","children":[{"type":"text","value":"architecture","position":{"start":{"line":22,"column":302,"offset":1391},"end":{"line":22,"column":314,"offset":1403},"indent":[]}}],"position":{"start":{"line":22,"column":301,"offset":1390},"end":{"line":22,"column":331,"offset":1420},"indent":[]}},{"type":"text","value":" or ","position":{"start":{"line":22,"column":331,"offset":1420},"end":{"line":22,"column":335,"offset":1424},"indent":[]}},{"type":"link","title":null,"url":"/opensource/installation","children":[{"type":"text","value":"installation page","position":{"start":{"line":22,"column":336,"offset":1425},"end":{"line":22,"column":353,"offset":1442},"indent":[]}}],"position":{"start":{"line":22,"column":335,"offset":1424},"end":{"line":22,"column":380,"offset":1469},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":22,"column":380,"offset":1469},"end":{"line":22,"column":381,"offset":1470},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1090},"end":{"line":22,"column":381,"offset":1470},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Every Kerberos agent has it's own web interface (front-end) to review media recording, and processing engine (back-end) of a specific surveillance camera. The Open Source version doesn't come with a central overview of all recordings generated by your Kerberos agents. For this feature we highly recommend ","position":{"start":{"line":24,"column":1,"offset":1472},"end":{"line":24,"column":307,"offset":1778},"indent":[]}},{"type":"link","title":null,"url":"/cloud","children":[{"type":"text","value":"Kerberos cloud","position":{"start":{"line":24,"column":308,"offset":1779},"end":{"line":24,"column":322,"offset":1793},"indent":[]}}],"position":{"start":{"line":24,"column":307,"offset":1778},"end":{"line":24,"column":331,"offset":1802},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":24,"column":331,"offset":1802},"end":{"line":24,"column":332,"offset":1803},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1472},"end":{"line":24,"column":332,"offset":1803},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to manage more than 10 Kerberos agents, it's recommended to use ","position":{"start":{"line":26,"column":1,"offset":1805},"end":{"line":26,"column":77,"offset":1881},"indent":[]}},{"type":"link","title":null,"url":"/enterprise","children":[{"type":"text","value":"Kerberos Enterprise","position":{"start":{"line":26,"column":78,"offset":1882},"end":{"line":26,"column":97,"offset":1901},"indent":[]}}],"position":{"start":{"line":26,"column":77,"offset":1881},"end":{"line":26,"column":111,"offset":1915},"indent":[]}},{"type":"text","value":". This will help you to scale, support high availability and load balancing. Check out the ","position":{"start":{"line":26,"column":111,"offset":1915},"end":{"line":26,"column":202,"offset":2006},"indent":[]}},{"type":"link","title":null,"url":"/architectures","children":[{"type":"text","value":"architectures section","position":{"start":{"line":26,"column":203,"offset":2007},"end":{"line":26,"column":224,"offset":2028},"indent":[]}}],"position":{"start":{"line":26,"column":202,"offset":2006},"end":{"line":26,"column":241,"offset":2045},"indent":[]}},{"type":"text","value":" for a better understanding of when to use what.","position":{"start":{"line":26,"column":241,"offset":2045},"end":{"line":26,"column":289,"offset":2093},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1805},"end":{"line":26,"column":289,"offset":2093},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"How to install","position":{"start":{"line":28,"column":4,"offset":2098},"end":{"line":28,"column":18,"offset":2112},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":2095},"end":{"line":28,"column":18,"offset":2112},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Kerberos Open Source agent can be installed in different ways. Every installation method have their own advantages and disadvantages. Depending on the usecase you could choose one method over the other. Read more on the ","position":{"start":{"line":30,"column":1,"offset":2114},"end":{"line":30,"column":223,"offset":2336},"indent":[]}},{"type":"link","title":null,"url":"/opensource/installation","children":[{"type":"text","value":"installation section","position":{"start":{"line":30,"column":224,"offset":2337},"end":{"line":30,"column":244,"offset":2357},"indent":[]}}],"position":{"start":{"line":30,"column":223,"offset":2336},"end":{"line":30,"column":271,"offset":2384},"indent":[]}},{"type":"text","value":", to learn about the different installation methods.","position":{"start":{"line":30,"column":271,"offset":2384},"end":{"line":30,"column":323,"offset":2436},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":2114},"end":{"line":30,"column":323,"offset":2436},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"KiOS: You have a Raspberry Pi, and you only want to run the Kerberos agent on it.","position":{"start":{"line":32,"column":4,"offset":2441},"end":{"line":32,"column":85,"offset":2522},"indent":[]}}],"position":{"start":{"line":32,"column":4,"offset":2441},"end":{"line":32,"column":85,"offset":2522},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":2438},"end":{"line":32,"column":85,"offset":2522},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Raspbian: You have a Raspberry Pi, but you want other services running next to your Kerberos agent.","position":{"start":{"line":33,"column":4,"offset":2526},"end":{"line":33,"column":103,"offset":2625},"indent":[]}}],"position":{"start":{"line":33,"column":4,"offset":2526},"end":{"line":33,"column":103,"offset":2625},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":2523},"end":{"line":33,"column":103,"offset":2625},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Docker: You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":34,"column":4,"offset":2629},"end":{"line":34,"column":86,"offset":2711},"indent":[]}}],"position":{"start":{"line":34,"column":4,"offset":2629},"end":{"line":34,"column":86,"offset":2711},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":2626},"end":{"line":34,"column":86,"offset":2711},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Generic: You want to develop/extend Kerberos Open Source with your own features, or you want to run the Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":35,"column":4,"offset":2715},"end":{"line":35,"column":158,"offset":2869},"indent":[]}}],"position":{"start":{"line":35,"column":4,"offset":2715},"end":{"line":35,"column":158,"offset":2869},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":2712},"end":{"line":35,"column":158,"offset":2869},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":2438},"end":{"line":35,"column":158,"offset":2869},"indent":[1,1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":38,"column":1,"offset":2872},"end":{"line":38,"column":31,"offset":2902},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":38,"column":31,"offset":2902}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`First things first`}

\n

{`Kerberos started as an Open Source project back in 2014. Our main goal was, and still is, to provide everyone in this world with a free, professional and complete video surveillance system, which they can install in a couple of minutes.\nKerberos was initially developed for the Raspberry Pi, due to this many of the tools we have been using are lightweight and fast (such as C++). Over the years we have found other ways to make Kerberos available, such as KiOS (our custom Linux), Docker and Kubernetes.`}

\n

{`In this section we want to make clear what the Open Source version of Kerberos is about, and when you should be using it. What it can do, and what it can't do.`}

\n

{`License`}

\n

{`The Kerberos Open Source project is licensed with `}{`BY-NC-SA 4.0`}{`, this means that everyone can use Kerberos and modify if to their needs, in a non commercial activity.`}

\n

{`When using the Open Source version`}

\n

{`Kerberos Open Source is perfect for personal usage. It's great if you only have a couple of surveillance cameras to be managed. A Kerberos agent (e.g. on a Raspberry Pi or inside a Docker container) runs for each camera. Their are many different installation possibilities, please have a look at the `}{`architecture`}{` or `}{`installation page`}{`.`}

\n

{`Every Kerberos agent has it's own web interface (front-end) to review media recording, and processing engine (back-end) of a specific surveillance camera. The Open Source version doesn't come with a central overview of all recordings generated by your Kerberos agents. For this feature we highly recommend `}{`Kerberos cloud`}{`.`}

\n

{`If you want to manage more than 10 Kerberos agents, it's recommended to use `}{`Kerberos Enterprise`}{`. This will help you to scale, support high availability and load balancing. Check out the `}{`architectures section`}{` for a better understanding of when to use what.`}

\n

{`How to install`}

\n

{`A Kerberos Open Source agent can be installed in different ways. Every installation method have their own advantages and disadvantages. Depending on the usecase you could choose one method over the other. Read more on the `}{`installation section`}{`, to learn about the different installation methods.`}

\n
    \n
  1. {`KiOS: You have a Raspberry Pi, and you only want to run the Kerberos agent on it.`}
  2. \n
  3. {`Raspbian: You have a Raspberry Pi, but you want other services running next to your Kerberos agent.`}
  4. \n
  5. {`Docker: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  6. \n
  7. {`Generic: You want to develop/extend Kerberos Open Source with your own features, or you want to run the Kerberos agent on a not supported OS/architecure.`}
  8. \n
\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974263000,"key":"gatsby-plugin-mdx-entire-payload-b34dc2451d26a40200ded75d09d54590-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"First things first","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":21,"offset":179},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":21,"offset":179},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos started as an Open Source project back in 2014. Our main goal was, and still is, to provide everyone in this world with a free, professional and complete video surveillance system, which they can install in a couple of minutes.\nKerberos was initially developed for the Raspberry Pi, due to this many of the tools we have been using are lightweight and fast (such as C++). Over the years we have found other ways to make Kerberos available, such as KiOS (our custom Linux), Docker and Kubernetes.","position":{"start":{"line":10,"column":1,"offset":181},"end":{"line":11,"column":268,"offset":685},"indent":[1]}}],"position":{"start":{"line":10,"column":1,"offset":181},"end":{"line":11,"column":268,"offset":685},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"In this section we want to make clear what the Open Source version of Kerberos is about, and when you should be using it. What it can do, and what it can't do.","position":{"start":{"line":13,"column":1,"offset":687},"end":{"line":13,"column":160,"offset":846},"indent":[]}}],"position":{"start":{"line":13,"column":1,"offset":687},"end":{"line":13,"column":160,"offset":846},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"License","position":{"start":{"line":15,"column":4,"offset":851},"end":{"line":15,"column":11,"offset":858},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":848},"end":{"line":15,"column":11,"offset":858},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Kerberos Open Source project is licensed with ","position":{"start":{"line":17,"column":1,"offset":860},"end":{"line":17,"column":51,"offset":910},"indent":[]}},{"type":"link","title":null,"url":"/opensource/license","children":[{"type":"text","value":"BY-NC-SA 4.0","position":{"start":{"line":17,"column":52,"offset":911},"end":{"line":17,"column":64,"offset":923},"indent":[]}}],"position":{"start":{"line":17,"column":51,"offset":910},"end":{"line":17,"column":86,"offset":945},"indent":[]}},{"type":"text","value":", this means that everyone can use Kerberos and modify if to their needs, in a non commercial activity.","position":{"start":{"line":17,"column":86,"offset":945},"end":{"line":17,"column":189,"offset":1048},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":860},"end":{"line":17,"column":189,"offset":1048},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"When using the Open Source version","position":{"start":{"line":20,"column":4,"offset":1054},"end":{"line":20,"column":38,"offset":1088},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":1051},"end":{"line":20,"column":38,"offset":1088},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source is perfect for personal usage. It's great if you only have a couple of surveillance cameras to be managed. A Kerberos agent (e.g. on a Raspberry Pi or inside a Docker container) runs for each camera. Their are many different installation possibilities, please have a look at the ","position":{"start":{"line":22,"column":1,"offset":1090},"end":{"line":22,"column":301,"offset":1390},"indent":[]}},{"type":"link","title":null,"url":"/architectures","children":[{"type":"text","value":"architecture","position":{"start":{"line":22,"column":302,"offset":1391},"end":{"line":22,"column":314,"offset":1403},"indent":[]}}],"position":{"start":{"line":22,"column":301,"offset":1390},"end":{"line":22,"column":331,"offset":1420},"indent":[]}},{"type":"text","value":" or ","position":{"start":{"line":22,"column":331,"offset":1420},"end":{"line":22,"column":335,"offset":1424},"indent":[]}},{"type":"link","title":null,"url":"/opensource/installation","children":[{"type":"text","value":"installation page","position":{"start":{"line":22,"column":336,"offset":1425},"end":{"line":22,"column":353,"offset":1442},"indent":[]}}],"position":{"start":{"line":22,"column":335,"offset":1424},"end":{"line":22,"column":380,"offset":1469},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":22,"column":380,"offset":1469},"end":{"line":22,"column":381,"offset":1470},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1090},"end":{"line":22,"column":381,"offset":1470},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Every Kerberos agent has it's own web interface (front-end) to review media recording, and processing engine (back-end) of a specific surveillance camera. The Open Source version doesn't come with a central overview of all recordings generated by your Kerberos agents. For this feature we highly recommend ","position":{"start":{"line":24,"column":1,"offset":1472},"end":{"line":24,"column":307,"offset":1778},"indent":[]}},{"type":"link","title":null,"url":"/cloud","children":[{"type":"text","value":"Kerberos cloud","position":{"start":{"line":24,"column":308,"offset":1779},"end":{"line":24,"column":322,"offset":1793},"indent":[]}}],"position":{"start":{"line":24,"column":307,"offset":1778},"end":{"line":24,"column":331,"offset":1802},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":24,"column":331,"offset":1802},"end":{"line":24,"column":332,"offset":1803},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1472},"end":{"line":24,"column":332,"offset":1803},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to manage more than 10 Kerberos agents, it's recommended to use ","position":{"start":{"line":26,"column":1,"offset":1805},"end":{"line":26,"column":77,"offset":1881},"indent":[]}},{"type":"link","title":null,"url":"/enterprise","children":[{"type":"text","value":"Kerberos Enterprise","position":{"start":{"line":26,"column":78,"offset":1882},"end":{"line":26,"column":97,"offset":1901},"indent":[]}}],"position":{"start":{"line":26,"column":77,"offset":1881},"end":{"line":26,"column":111,"offset":1915},"indent":[]}},{"type":"text","value":". This will help you to scale, support high availability and load balancing. Check out the ","position":{"start":{"line":26,"column":111,"offset":1915},"end":{"line":26,"column":202,"offset":2006},"indent":[]}},{"type":"link","title":null,"url":"/architectures","children":[{"type":"text","value":"architectures section","position":{"start":{"line":26,"column":203,"offset":2007},"end":{"line":26,"column":224,"offset":2028},"indent":[]}}],"position":{"start":{"line":26,"column":202,"offset":2006},"end":{"line":26,"column":241,"offset":2045},"indent":[]}},{"type":"text","value":" for a better understanding of when to use what.","position":{"start":{"line":26,"column":241,"offset":2045},"end":{"line":26,"column":289,"offset":2093},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1805},"end":{"line":26,"column":289,"offset":2093},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"How to install","position":{"start":{"line":28,"column":4,"offset":2098},"end":{"line":28,"column":18,"offset":2112},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":2095},"end":{"line":28,"column":18,"offset":2112},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Kerberos Open Source agent can be installed in different ways. Every installation method have their own advantages and disadvantages. Depending on the usecase you could choose one method over the other. Read more on the ","position":{"start":{"line":30,"column":1,"offset":2114},"end":{"line":30,"column":223,"offset":2336},"indent":[]}},{"type":"link","title":null,"url":"/opensource/installation","children":[{"type":"text","value":"installation section","position":{"start":{"line":30,"column":224,"offset":2337},"end":{"line":30,"column":244,"offset":2357},"indent":[]}}],"position":{"start":{"line":30,"column":223,"offset":2336},"end":{"line":30,"column":271,"offset":2384},"indent":[]}},{"type":"text","value":", to learn about the different installation methods.","position":{"start":{"line":30,"column":271,"offset":2384},"end":{"line":30,"column":323,"offset":2436},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":2114},"end":{"line":30,"column":323,"offset":2436},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"KiOS: You have a Raspberry Pi, and you only want to run the Kerberos agent on it.","position":{"start":{"line":32,"column":4,"offset":2441},"end":{"line":32,"column":85,"offset":2522},"indent":[]}}],"position":{"start":{"line":32,"column":4,"offset":2441},"end":{"line":32,"column":85,"offset":2522},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":2438},"end":{"line":32,"column":85,"offset":2522},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Raspbian: You have a Raspberry Pi, but you want other services running next to your Kerberos agent.","position":{"start":{"line":33,"column":4,"offset":2526},"end":{"line":33,"column":103,"offset":2625},"indent":[]}}],"position":{"start":{"line":33,"column":4,"offset":2526},"end":{"line":33,"column":103,"offset":2625},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":2523},"end":{"line":33,"column":103,"offset":2625},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Docker: You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":34,"column":4,"offset":2629},"end":{"line":34,"column":86,"offset":2711},"indent":[]}}],"position":{"start":{"line":34,"column":4,"offset":2629},"end":{"line":34,"column":86,"offset":2711},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":2626},"end":{"line":34,"column":86,"offset":2711},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Generic: You want to develop/extend Kerberos Open Source with your own features, or you want to run the Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":35,"column":4,"offset":2715},"end":{"line":35,"column":158,"offset":2869},"indent":[]}}],"position":{"start":{"line":35,"column":4,"offset":2715},"end":{"line":35,"column":158,"offset":2869},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":2712},"end":{"line":35,"column":158,"offset":2869},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":2438},"end":{"line":35,"column":158,"offset":2869},"indent":[1,1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":38,"column":1,"offset":2872},"end":{"line":38,"column":31,"offset":2902},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":38,"column":31,"offset":2902}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`First things first`}

\n

{`Kerberos started as an Open Source project back in 2014. Our main goal was, and still is, to provide everyone in this world with a free, professional and complete video surveillance system, which they can install in a couple of minutes.\nKerberos was initially developed for the Raspberry Pi, due to this many of the tools we have been using are lightweight and fast (such as C++). Over the years we have found other ways to make Kerberos available, such as KiOS (our custom Linux), Docker and Kubernetes.`}

\n

{`In this section we want to make clear what the Open Source version of Kerberos is about, and when you should be using it. What it can do, and what it can't do.`}

\n

{`License`}

\n

{`The Kerberos Open Source project is licensed with `}{`BY-NC-SA 4.0`}{`, this means that everyone can use Kerberos and modify if to their needs, in a non commercial activity.`}

\n

{`When using the Open Source version`}

\n

{`Kerberos Open Source is perfect for personal usage. It's great if you only have a couple of surveillance cameras to be managed. A Kerberos agent (e.g. on a Raspberry Pi or inside a Docker container) runs for each camera. Their are many different installation possibilities, please have a look at the `}{`architecture`}{` or `}{`installation page`}{`.`}

\n

{`Every Kerberos agent has it's own web interface (front-end) to review media recording, and processing engine (back-end) of a specific surveillance camera. The Open Source version doesn't come with a central overview of all recordings generated by your Kerberos agents. For this feature we highly recommend `}{`Kerberos cloud`}{`.`}

\n

{`If you want to manage more than 10 Kerberos agents, it's recommended to use `}{`Kerberos Enterprise`}{`. This will help you to scale, support high availability and load balancing. Check out the `}{`architectures section`}{` for a better understanding of when to use what.`}

\n

{`How to install`}

\n

{`A Kerberos Open Source agent can be installed in different ways. Every installation method have their own advantages and disadvantages. Depending on the usecase you could choose one method over the other. Read more on the `}{`installation section`}{`, to learn about the different installation methods.`}

\n
    \n
  1. {`KiOS: You have a Raspberry Pi, and you only want to run the Kerberos agent on it.`}
  2. \n
  3. {`Raspbian: You have a Raspberry Pi, but you want other services running next to your Kerberos agent.`}
  4. \n
  5. {`Docker: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  6. \n
  7. {`Generic: You want to develop/extend Kerberos Open Source with your own features, or you want to run the Kerberos agent on a not supported OS/architecure.`}
  8. \n
\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-390c49abb652dc1d2fbce6848089e625.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-390c49abb652dc1d2fbce6848089e625.json index 84efbf3..162c268 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-390c49abb652dc1d2fbce6848089e625.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-390c49abb652dc1d2fbce6848089e625.json @@ -1 +1 @@ -{"expireTime":9007200841014158000,"key":"gatsby-plugin-mdx-entire-payload-6b3b0bb987de28787ec211d312f8356b-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Release notes","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":16,"offset":174},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":16,"offset":174},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.8.0","position":{"start":{"line":10,"column":5,"offset":180},"end":{"line":10,"column":10,"offset":185},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":176},"end":{"line":10,"column":10,"offset":185},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Aligned machinery, web and KiOS versions. Too many people were confused by the versioning.","position":{"start":{"line":12,"column":1,"offset":187},"end":{"line":12,"column":91,"offset":277},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":187},"end":{"line":12,"column":91,"offset":277},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":14,"column":6,"offset":284},"end":{"line":14,"column":9,"offset":287},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":279},"end":{"line":14,"column":9,"offset":287},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Videos displayed on canvas were blocked in latest browsers.","position":{"start":{"line":16,"column":3,"offset":291},"end":{"line":16,"column":62,"offset":350},"indent":[]}}],"position":{"start":{"line":16,"column":3,"offset":291},"end":{"line":16,"column":62,"offset":350},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":289},"end":{"line":16,"column":62,"offset":350},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Disabled reboot and shutdown.","position":{"start":{"line":17,"column":3,"offset":353},"end":{"line":17,"column":32,"offset":382},"indent":[]}}],"position":{"start":{"line":17,"column":3,"offset":353},"end":{"line":17,"column":32,"offset":382},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":351},"end":{"line":17,"column":32,"offset":382},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Disabled upgrade process, use fwupdate shell command instead.","position":{"start":{"line":18,"column":3,"offset":385},"end":{"line":18,"column":64,"offset":446},"indent":[]}}],"position":{"start":{"line":18,"column":3,"offset":385},"end":{"line":18,"column":64,"offset":446},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":383},"end":{"line":18,"column":64,"offset":446},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":289},"end":{"line":18,"column":64,"offset":446},"indent":[1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":20,"column":6,"offset":453},"end":{"line":20,"column":10,"offset":457},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":448},"end":{"line":20,"column":10,"offset":457},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Major upgrade, solved many different problems (list to long); not possible to upgrade from 2.7.0 to 2.8.0.","position":{"start":{"line":22,"column":3,"offset":461},"end":{"line":22,"column":109,"offset":567},"indent":[]}}],"position":{"start":{"line":22,"column":3,"offset":461},"end":{"line":22,"column":109,"offset":567},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":459},"end":{"line":22,"column":109,"offset":567},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Updated firmware to latest Raspbian (raspberrypi-kernel_1.20180417-1).","position":{"start":{"line":23,"column":3,"offset":570},"end":{"line":23,"column":73,"offset":640},"indent":[]}}],"position":{"start":{"line":23,"column":3,"offset":570},"end":{"line":23,"column":73,"offset":640},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":568},"end":{"line":23,"column":73,"offset":640},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support for the Raspberry Pi 4.","position":{"start":{"line":24,"column":3,"offset":643},"end":{"line":24,"column":34,"offset":674},"indent":[]}}],"position":{"start":{"line":24,"column":3,"offset":643},"end":{"line":24,"column":34,"offset":674},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":641},"end":{"line":24,"column":34,"offset":674},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":459},"end":{"line":24,"column":34,"offset":674},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.7.2","position":{"start":{"line":26,"column":5,"offset":680},"end":{"line":26,"column":10,"offset":685},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":676},"end":{"line":26,"column":10,"offset":685},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":28,"column":6,"offset":692},"end":{"line":28,"column":15,"offset":701},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":687},"end":{"line":28,"column":15,"offset":701},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"To optimise the cloud experience we've added a proxy.kerberos.io machine in between.","position":{"start":{"line":30,"column":3,"offset":705},"end":{"line":30,"column":87,"offset":789},"indent":[]}}],"position":{"start":{"line":30,"column":3,"offset":705},"end":{"line":30,"column":87,"offset":789},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":703},"end":{"line":30,"column":87,"offset":789},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"We've changed the S3 storage scheme (class:ONEZONE_IA).","position":{"start":{"line":31,"column":3,"offset":792},"end":{"line":31,"column":58,"offset":847},"indent":[]}}],"position":{"start":{"line":31,"column":3,"offset":792},"end":{"line":31,"column":58,"offset":847},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":790},"end":{"line":31,"column":58,"offset":847},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":703},"end":{"line":31,"column":58,"offset":847},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.7.1","position":{"start":{"line":33,"column":5,"offset":853},"end":{"line":33,"column":10,"offset":858},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":849},"end":{"line":33,"column":10,"offset":858},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":35,"column":6,"offset":865},"end":{"line":35,"column":15,"offset":874},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":860},"end":{"line":35,"column":15,"offset":874},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Resolved deadlock with livestreaming while restarting machinery.","position":{"start":{"line":37,"column":3,"offset":878},"end":{"line":37,"column":67,"offset":942},"indent":[]}}],"position":{"start":{"line":37,"column":3,"offset":878},"end":{"line":37,"column":67,"offset":942},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":876},"end":{"line":37,"column":67,"offset":942},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Revert logging library; enabled log rotating.","position":{"start":{"line":38,"column":3,"offset":945},"end":{"line":38,"column":48,"offset":990},"indent":[]}}],"position":{"start":{"line":38,"column":3,"offset":945},"end":{"line":38,"column":48,"offset":990},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":943},"end":{"line":38,"column":48,"offset":990},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":876},"end":{"line":38,"column":48,"offset":990},"indent":[1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":40,"column":6,"offset":997},"end":{"line":40,"column":10,"offset":1001},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":992},"end":{"line":40,"column":10,"offset":1001},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Updated firmware to latest Raspbian (raspberrypi-kernel_1.20180417-1).","position":{"start":{"line":42,"column":3,"offset":1005},"end":{"line":42,"column":73,"offset":1075},"indent":[]}}],"position":{"start":{"line":42,"column":3,"offset":1005},"end":{"line":42,"column":73,"offset":1075},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":1003},"end":{"line":42,"column":73,"offset":1075},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Resolved issue with WIFI on Raspberry Pi 3B+","position":{"start":{"line":43,"column":3,"offset":1078},"end":{"line":43,"column":47,"offset":1122},"indent":[]}}],"position":{"start":{"line":43,"column":3,"offset":1078},"end":{"line":43,"column":47,"offset":1122},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":1076},"end":{"line":43,"column":47,"offset":1122},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":1003},"end":{"line":43,"column":47,"offset":1122},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.7.0","position":{"start":{"line":45,"column":5,"offset":1128},"end":{"line":45,"column":10,"offset":1133},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":1124},"end":{"line":45,"column":10,"offset":1133},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":47,"column":6,"offset":1140},"end":{"line":47,"column":9,"offset":1143},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":1135},"end":{"line":47,"column":9,"offset":1143},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Unique session cookie, which allows to open multiple web interfaces (e.g. when using docker).","position":{"start":{"line":49,"column":3,"offset":1147},"end":{"line":49,"column":96,"offset":1240},"indent":[]}}],"position":{"start":{"line":49,"column":3,"offset":1147},"end":{"line":49,"column":96,"offset":1240},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":1145},"end":{"line":49,"column":96,"offset":1240},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":1145},"end":{"line":49,"column":96,"offset":1240},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":51,"column":6,"offset":1247},"end":{"line":51,"column":15,"offset":1256},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":1242},"end":{"line":51,"column":15,"offset":1256},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added live streaming feature for app.kerberos.io","position":{"start":{"line":53,"column":3,"offset":1260},"end":{"line":53,"column":51,"offset":1308},"indent":[]}}],"position":{"start":{"line":53,"column":3,"offset":1260},"end":{"line":53,"column":51,"offset":1308},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":1258},"end":{"line":53,"column":51,"offset":1308},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Upgraded logging library: log file can be max 5MB, and will rotate.","position":{"start":{"line":54,"column":3,"offset":1311},"end":{"line":54,"column":70,"offset":1378},"indent":[]}}],"position":{"start":{"line":54,"column":3,"offset":1311},"end":{"line":54,"column":70,"offset":1378},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":1309},"end":{"line":54,"column":70,"offset":1378},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Better logging for cloud uploads (failed information).","position":{"start":{"line":55,"column":3,"offset":1381},"end":{"line":55,"column":57,"offset":1435},"indent":[]}}],"position":{"start":{"line":55,"column":3,"offset":1381},"end":{"line":55,"column":57,"offset":1435},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":1379},"end":{"line":55,"column":57,"offset":1435},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":1258},"end":{"line":55,"column":57,"offset":1435},"indent":[1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Docker","position":{"start":{"line":57,"column":6,"offset":1442},"end":{"line":57,"column":12,"offset":1448},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":1437},"end":{"line":57,"column":12,"offset":1448},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"No longer need docker-compose, we merged the web and machinery containers to ","position":{"start":{"line":59,"column":3,"offset":1452},"end":{"line":59,"column":80,"offset":1529},"indent":[]}},{"type":"link","title":null,"url":"http://hub.docker.com/r/kerberos/kerberos","children":[{"type":"text","value":"a single container","position":{"start":{"line":59,"column":81,"offset":1530},"end":{"line":59,"column":99,"offset":1548},"indent":[]}}],"position":{"start":{"line":59,"column":80,"offset":1529},"end":{"line":59,"column":143,"offset":1592},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":59,"column":143,"offset":1592},"end":{"line":59,"column":144,"offset":1593},"indent":[]}}],"position":{"start":{"line":59,"column":3,"offset":1452},"end":{"line":59,"column":144,"offset":1593},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":1450},"end":{"line":59,"column":144,"offset":1593},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":1450},"end":{"line":59,"column":144,"offset":1593},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":61,"column":6,"offset":1600},"end":{"line":61,"column":10,"offset":1604},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":1595},"end":{"line":61,"column":10,"offset":1604},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Updated firmware to latest Raspbian.","position":{"start":{"line":63,"column":3,"offset":1608},"end":{"line":63,"column":39,"offset":1644},"indent":[]}}],"position":{"start":{"line":63,"column":3,"offset":1608},"end":{"line":63,"column":39,"offset":1644},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":1606},"end":{"line":63,"column":39,"offset":1644},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support for the Raspberry Pi 3B+.","position":{"start":{"line":64,"column":3,"offset":1647},"end":{"line":64,"column":36,"offset":1680},"indent":[]}}],"position":{"start":{"line":64,"column":3,"offset":1647},"end":{"line":64,"column":36,"offset":1680},"indent":[]}}],"position":{"start":{"line":64,"column":1,"offset":1645},"end":{"line":64,"column":36,"offset":1680},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":1606},"end":{"line":64,"column":36,"offset":1680},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.6.1","position":{"start":{"line":66,"column":5,"offset":1686},"end":{"line":66,"column":10,"offset":1691},"indent":[]}}],"position":{"start":{"line":66,"column":1,"offset":1682},"end":{"line":66,"column":10,"offset":1691},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":68,"column":6,"offset":1698},"end":{"line":68,"column":9,"offset":1701},"indent":[]}}],"position":{"start":{"line":68,"column":1,"offset":1693},"end":{"line":68,"column":9,"offset":1701},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Solved issue with persisting login configuration. ","position":{"start":{"line":70,"column":3,"offset":1705},"end":{"line":70,"column":53,"offset":1755},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/111","children":[{"type":"text","value":"#111","position":{"start":{"line":70,"column":54,"offset":1756},"end":{"line":70,"column":58,"offset":1760},"indent":[]}}],"position":{"start":{"line":70,"column":53,"offset":1755},"end":{"line":70,"column":106,"offset":1808},"indent":[]}}],"position":{"start":{"line":70,"column":3,"offset":1705},"end":{"line":70,"column":106,"offset":1808},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":1703},"end":{"line":70,"column":106,"offset":1808},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":1703},"end":{"line":70,"column":106,"offset":1808},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":72,"column":6,"offset":1815},"end":{"line":72,"column":15,"offset":1824},"indent":[]}}],"position":{"start":{"line":72,"column":1,"offset":1810},"end":{"line":72,"column":15,"offset":1824},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added Pushbullet. ","position":{"start":{"line":74,"column":3,"offset":1828},"end":{"line":74,"column":21,"offset":1846},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/pull/139","children":[{"type":"text","value":"#139","position":{"start":{"line":74,"column":22,"offset":1847},"end":{"line":74,"column":26,"offset":1851},"indent":[]}}],"position":{"start":{"line":74,"column":21,"offset":1846},"end":{"line":74,"column":78,"offset":1903},"indent":[]}}],"position":{"start":{"line":74,"column":3,"offset":1828},"end":{"line":74,"column":78,"offset":1903},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":1826},"end":{"line":74,"column":78,"offset":1903},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Cloud upload was not longer working (hotfix also in 2.6.0).","position":{"start":{"line":75,"column":3,"offset":1906},"end":{"line":75,"column":62,"offset":1965},"indent":[]}}],"position":{"start":{"line":75,"column":3,"offset":1906},"end":{"line":75,"column":62,"offset":1965},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":1904},"end":{"line":75,"column":62,"offset":1965},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":1826},"end":{"line":75,"column":62,"offset":1965},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.6.0","position":{"start":{"line":77,"column":5,"offset":1971},"end":{"line":77,"column":10,"offset":1976},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":1967},"end":{"line":77,"column":10,"offset":1976},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":79,"column":6,"offset":1983},"end":{"line":79,"column":9,"offset":1986},"indent":[]}}],"position":{"start":{"line":79,"column":1,"offset":1978},"end":{"line":79,"column":9,"offset":1986},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Add a cloud connection verification method. ","position":{"start":{"line":81,"column":3,"offset":1990},"end":{"line":81,"column":47,"offset":2034},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/112","children":[{"type":"text","value":"#112","position":{"start":{"line":81,"column":48,"offset":2035},"end":{"line":81,"column":52,"offset":2039},"indent":[]}}],"position":{"start":{"line":81,"column":47,"offset":2034},"end":{"line":81,"column":100,"offset":2087},"indent":[]}}],"position":{"start":{"line":81,"column":3,"offset":1990},"end":{"line":81,"column":100,"offset":2087},"indent":[]}}],"position":{"start":{"line":81,"column":1,"offset":1988},"end":{"line":81,"column":100,"offset":2087},"indent":[]}}],"position":{"start":{"line":81,"column":1,"offset":1988},"end":{"line":81,"column":100,"offset":2087},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":83,"column":6,"offset":2094},"end":{"line":83,"column":15,"offset":2103},"indent":[]}}],"position":{"start":{"line":83,"column":1,"offset":2089},"end":{"line":83,"column":15,"offset":2103},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Add background color timestamp. ","position":{"start":{"line":85,"column":3,"offset":2107},"end":{"line":85,"column":35,"offset":2139},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/128","children":[{"type":"text","value":"#128","position":{"start":{"line":85,"column":36,"offset":2140},"end":{"line":85,"column":40,"offset":2144},"indent":[]}}],"position":{"start":{"line":85,"column":35,"offset":2139},"end":{"line":85,"column":94,"offset":2198},"indent":[]}}],"position":{"start":{"line":85,"column":3,"offset":2107},"end":{"line":85,"column":94,"offset":2198},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":2105},"end":{"line":85,"column":94,"offset":2198},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Send instanceId in AWS header when uploading to cloud (necessary for new cloud app).","position":{"start":{"line":86,"column":3,"offset":2201},"end":{"line":86,"column":87,"offset":2285},"indent":[]}}],"position":{"start":{"line":86,"column":3,"offset":2201},"end":{"line":86,"column":87,"offset":2285},"indent":[]}}],"position":{"start":{"line":86,"column":1,"offset":2199},"end":{"line":86,"column":87,"offset":2285},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Better support for Chinese IP cameras.","position":{"start":{"line":87,"column":3,"offset":2288},"end":{"line":87,"column":41,"offset":2326},"indent":[]}}],"position":{"start":{"line":87,"column":3,"offset":2288},"end":{"line":87,"column":41,"offset":2326},"indent":[]}}],"position":{"start":{"line":87,"column":1,"offset":2286},"end":{"line":87,"column":41,"offset":2326},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":2105},"end":{"line":87,"column":41,"offset":2326},"indent":[1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Docker","position":{"start":{"line":89,"column":6,"offset":2333},"end":{"line":89,"column":12,"offset":2339},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":2328},"end":{"line":89,"column":12,"offset":2339},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Bug: Autoremove old images/video within Docker Containers. ","position":{"start":{"line":91,"column":3,"offset":2343},"end":{"line":91,"column":62,"offset":2402},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/104","children":[{"type":"text","value":"#104","position":{"start":{"line":91,"column":63,"offset":2403},"end":{"line":91,"column":67,"offset":2407},"indent":[]}}],"position":{"start":{"line":91,"column":62,"offset":2402},"end":{"line":91,"column":115,"offset":2455},"indent":[]}}],"position":{"start":{"line":91,"column":3,"offset":2343},"end":{"line":91,"column":115,"offset":2455},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":2341},"end":{"line":91,"column":115,"offset":2455},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":2341},"end":{"line":91,"column":115,"offset":2455},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.5.0","position":{"start":{"line":93,"column":5,"offset":2461},"end":{"line":93,"column":10,"offset":2466},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":2457},"end":{"line":93,"column":10,"offset":2466},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":95,"column":6,"offset":2473},"end":{"line":95,"column":9,"offset":2476},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":2468},"end":{"line":95,"column":9,"offset":2476},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added Chinese and Italian language.","position":{"start":{"line":97,"column":3,"offset":2480},"end":{"line":97,"column":38,"offset":2515},"indent":[]}}],"position":{"start":{"line":97,"column":3,"offset":2480},"end":{"line":97,"column":38,"offset":2515},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":2478},"end":{"line":97,"column":38,"offset":2515},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Resolved issue with INSTALLED=true.","position":{"start":{"line":98,"column":3,"offset":2518},"end":{"line":98,"column":38,"offset":2553},"indent":[]}}],"position":{"start":{"line":98,"column":3,"offset":2518},"end":{"line":98,"column":38,"offset":2553},"indent":[]}}],"position":{"start":{"line":98,"column":1,"offset":2516},"end":{"line":98,"column":38,"offset":2553},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Make latest_sequence available with basic auth. ","position":{"start":{"line":99,"column":3,"offset":2556},"end":{"line":99,"column":52,"offset":2605},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/99","children":[{"type":"text","value":"#99","position":{"start":{"line":99,"column":53,"offset":2606},"end":{"line":99,"column":56,"offset":2609},"indent":[]}}],"position":{"start":{"line":99,"column":52,"offset":2605},"end":{"line":99,"column":103,"offset":2656},"indent":[]}}],"position":{"start":{"line":99,"column":3,"offset":2556},"end":{"line":99,"column":103,"offset":2656},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":2554},"end":{"line":99,"column":103,"offset":2656},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":2478},"end":{"line":99,"column":103,"offset":2656},"indent":[1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":101,"column":6,"offset":2663},"end":{"line":101,"column":15,"offset":2672},"indent":[]}}],"position":{"start":{"line":101,"column":1,"offset":2658},"end":{"line":101,"column":15,"offset":2672},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Provide an IO service for publishing events to MQTT. ","position":{"start":{"line":103,"column":3,"offset":2676},"end":{"line":103,"column":56,"offset":2729},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/89","children":[{"type":"text","value":"#89","position":{"start":{"line":103,"column":57,"offset":2730},"end":{"line":103,"column":60,"offset":2733},"indent":[]}}],"position":{"start":{"line":103,"column":56,"offset":2729},"end":{"line":103,"column":113,"offset":2786},"indent":[]}}],"position":{"start":{"line":103,"column":3,"offset":2676},"end":{"line":103,"column":113,"offset":2786},"indent":[]}}],"position":{"start":{"line":103,"column":1,"offset":2674},"end":{"line":103,"column":113,"offset":2786},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Optimize recording with H264_OMX. ","position":{"start":{"line":104,"column":3,"offset":2789},"end":{"line":104,"column":37,"offset":2823},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/83","children":[{"type":"text","value":"#83","position":{"start":{"line":104,"column":38,"offset":2824},"end":{"line":104,"column":41,"offset":2827},"indent":[]}}],"position":{"start":{"line":104,"column":37,"offset":2823},"end":{"line":104,"column":94,"offset":2880},"indent":[]}}],"position":{"start":{"line":104,"column":3,"offset":2789},"end":{"line":104,"column":94,"offset":2880},"indent":[]}}],"position":{"start":{"line":104,"column":1,"offset":2787},"end":{"line":104,"column":94,"offset":2880},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Implement throttler for Io detections. ","position":{"start":{"line":105,"column":3,"offset":2883},"end":{"line":105,"column":42,"offset":2922},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/96","children":[{"type":"text","value":"#96","position":{"start":{"line":105,"column":43,"offset":2923},"end":{"line":105,"column":46,"offset":2926},"indent":[]}}],"position":{"start":{"line":105,"column":42,"offset":2922},"end":{"line":105,"column":99,"offset":2979},"indent":[]}}],"position":{"start":{"line":105,"column":3,"offset":2883},"end":{"line":105,"column":99,"offset":2979},"indent":[]}}],"position":{"start":{"line":105,"column":1,"offset":2881},"end":{"line":105,"column":99,"offset":2979},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"SSL version 1.0.0 is no longer accessible in Raspbian. ","position":{"start":{"line":106,"column":3,"offset":2982},"end":{"line":106,"column":58,"offset":3037},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/109","children":[{"type":"text","value":"#109","position":{"start":{"line":106,"column":59,"offset":3038},"end":{"line":106,"column":63,"offset":3042},"indent":[]}}],"position":{"start":{"line":106,"column":58,"offset":3037},"end":{"line":106,"column":117,"offset":3096},"indent":[]}}],"position":{"start":{"line":106,"column":3,"offset":2982},"end":{"line":106,"column":117,"offset":3096},"indent":[]}}],"position":{"start":{"line":106,"column":1,"offset":2980},"end":{"line":106,"column":117,"offset":3096},"indent":[]}}],"position":{"start":{"line":103,"column":1,"offset":2674},"end":{"line":106,"column":117,"offset":3096},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.4.2","position":{"start":{"line":108,"column":5,"offset":3102},"end":{"line":108,"column":10,"offset":3107},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":3098},"end":{"line":108,"column":10,"offset":3107},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":110,"column":6,"offset":3114},"end":{"line":110,"column":9,"offset":3117},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":3109},"end":{"line":110,"column":9,"offset":3117},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Typo in french translation, causes the web interface crash.","position":{"start":{"line":112,"column":3,"offset":3121},"end":{"line":112,"column":62,"offset":3180},"indent":[]}}],"position":{"start":{"line":112,"column":3,"offset":3121},"end":{"line":112,"column":62,"offset":3180},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":3119},"end":{"line":112,"column":62,"offset":3180},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":3119},"end":{"line":112,"column":62,"offset":3180},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":114,"column":6,"offset":3187},"end":{"line":114,"column":15,"offset":3196},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":3182},"end":{"line":114,"column":15,"offset":3196},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Resolved major bug in livestream: memory leak in stream class. ","position":{"start":{"line":116,"column":3,"offset":3200},"end":{"line":116,"column":66,"offset":3263},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/94","children":[{"type":"text","value":"#94","position":{"start":{"line":116,"column":67,"offset":3264},"end":{"line":116,"column":70,"offset":3267},"indent":[]}}],"position":{"start":{"line":116,"column":66,"offset":3263},"end":{"line":116,"column":123,"offset":3320},"indent":[]}}],"position":{"start":{"line":116,"column":3,"offset":3200},"end":{"line":116,"column":123,"offset":3320},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":3198},"end":{"line":116,"column":123,"offset":3320},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Capture health verification: check if the chosen capture device is still grabbing (and didn't stalled).","position":{"start":{"line":117,"column":3,"offset":3323},"end":{"line":117,"column":106,"offset":3426},"indent":[]}}],"position":{"start":{"line":117,"column":3,"offset":3323},"end":{"line":117,"column":106,"offset":3426},"indent":[]}}],"position":{"start":{"line":117,"column":1,"offset":3321},"end":{"line":117,"column":106,"offset":3426},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Extra logging when recording with raspberry pi camera.","position":{"start":{"line":118,"column":3,"offset":3429},"end":{"line":118,"column":57,"offset":3483},"indent":[]}}],"position":{"start":{"line":118,"column":3,"offset":3429},"end":{"line":118,"column":57,"offset":3483},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":3427},"end":{"line":118,"column":57,"offset":3483},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Make sure the cloud upload is functioning properly, after an upload it's verified if the files really exist in the cloud.","position":{"start":{"line":119,"column":3,"offset":3486},"end":{"line":119,"column":124,"offset":3607},"indent":[]}}],"position":{"start":{"line":119,"column":3,"offset":3486},"end":{"line":119,"column":124,"offset":3607},"indent":[]}}],"position":{"start":{"line":119,"column":1,"offset":3484},"end":{"line":119,"column":124,"offset":3607},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":3198},"end":{"line":119,"column":124,"offset":3607},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.4.1","position":{"start":{"line":121,"column":5,"offset":3613},"end":{"line":121,"column":10,"offset":3618},"indent":[]}}],"position":{"start":{"line":121,"column":1,"offset":3609},"end":{"line":121,"column":10,"offset":3618},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":123,"column":6,"offset":3625},"end":{"line":123,"column":9,"offset":3628},"indent":[]}}],"position":{"start":{"line":123,"column":1,"offset":3620},"end":{"line":123,"column":9,"offset":3628},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Show warning when system is disabled. ","position":{"start":{"line":125,"column":3,"offset":3632},"end":{"line":125,"column":41,"offset":3670},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/88","children":[{"type":"text","value":"#88","position":{"start":{"line":125,"column":42,"offset":3671},"end":{"line":125,"column":45,"offset":3674},"indent":[]}}],"position":{"start":{"line":125,"column":41,"offset":3670},"end":{"line":125,"column":92,"offset":3721},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":125,"column":92,"offset":3721},"end":{"line":125,"column":93,"offset":3722},"indent":[]}}],"position":{"start":{"line":125,"column":3,"offset":3632},"end":{"line":125,"column":93,"offset":3722},"indent":[]}}],"position":{"start":{"line":125,"column":1,"offset":3630},"end":{"line":125,"column":93,"offset":3722},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Hull selector in basic view not always working.","position":{"start":{"line":126,"column":3,"offset":3725},"end":{"line":126,"column":50,"offset":3772},"indent":[]}}],"position":{"start":{"line":126,"column":3,"offset":3725},"end":{"line":126,"column":50,"offset":3772},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":3723},"end":{"line":126,"column":50,"offset":3772},"indent":[]}}],"position":{"start":{"line":125,"column":1,"offset":3630},"end":{"line":126,"column":50,"offset":3772},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.4.0","position":{"start":{"line":128,"column":5,"offset":3778},"end":{"line":128,"column":10,"offset":3783},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":3774},"end":{"line":128,"column":10,"offset":3783},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Ecosystem","position":{"start":{"line":130,"column":6,"offset":3790},"end":{"line":130,"column":15,"offset":3799},"indent":[]}}],"position":{"start":{"line":130,"column":1,"offset":3785},"end":{"line":130,"column":15,"offset":3799},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Enable/Disable force network mode.","position":{"start":{"line":132,"column":3,"offset":3803},"end":{"line":132,"column":37,"offset":3837},"indent":[]}}],"position":{"start":{"line":132,"column":3,"offset":3803},"end":{"line":132,"column":37,"offset":3837},"indent":[]}}],"position":{"start":{"line":132,"column":1,"offset":3801},"end":{"line":132,"column":37,"offset":3837},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Enable/Disable auto removal media.","position":{"start":{"line":133,"column":3,"offset":3840},"end":{"line":133,"column":37,"offset":3874},"indent":[]}}],"position":{"start":{"line":133,"column":3,"offset":3840},"end":{"line":133,"column":37,"offset":3874},"indent":[]}}],"position":{"start":{"line":133,"column":1,"offset":3838},"end":{"line":133,"column":37,"offset":3874},"indent":[]}}],"position":{"start":{"line":132,"column":1,"offset":3801},"end":{"line":133,"column":37,"offset":3874},"indent":[1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":135,"column":6,"offset":3881},"end":{"line":135,"column":9,"offset":3884},"indent":[]}}],"position":{"start":{"line":135,"column":1,"offset":3876},"end":{"line":135,"column":9,"offset":3884},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Upgrade from Laravel 4.2 to Laravel 5.4 ","position":{"start":{"line":137,"column":3,"offset":3888},"end":{"line":137,"column":43,"offset":3928},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/70","children":[{"type":"text","value":"#70","position":{"start":{"line":137,"column":44,"offset":3929},"end":{"line":137,"column":47,"offset":3932},"indent":[]}}],"position":{"start":{"line":137,"column":43,"offset":3928},"end":{"line":137,"column":94,"offset":3979},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":137,"column":94,"offset":3979},"end":{"line":137,"column":95,"offset":3980},"indent":[]}}],"position":{"start":{"line":137,"column":3,"offset":3888},"end":{"line":137,"column":95,"offset":3980},"indent":[]}}],"position":{"start":{"line":137,"column":1,"offset":3886},"end":{"line":137,"column":95,"offset":3980},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fix bug with heatmap radius slider ","position":{"start":{"line":138,"column":3,"offset":3983},"end":{"line":138,"column":38,"offset":4018},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/84","children":[{"type":"text","value":"#84","position":{"start":{"line":138,"column":39,"offset":4019},"end":{"line":138,"column":42,"offset":4022},"indent":[]}}],"position":{"start":{"line":138,"column":38,"offset":4018},"end":{"line":138,"column":89,"offset":4069},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":138,"column":89,"offset":4069},"end":{"line":138,"column":90,"offset":4070},"indent":[]}}],"position":{"start":{"line":138,"column":3,"offset":3983},"end":{"line":138,"column":90,"offset":4070},"indent":[]}}],"position":{"start":{"line":138,"column":1,"offset":3981},"end":{"line":138,"column":90,"offset":4070},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Design tweaks toggle button (remove outline).","position":{"start":{"line":139,"column":3,"offset":4073},"end":{"line":139,"column":48,"offset":4118},"indent":[]}}],"position":{"start":{"line":139,"column":3,"offset":4073},"end":{"line":139,"column":48,"offset":4118},"indent":[]}}],"position":{"start":{"line":139,"column":1,"offset":4071},"end":{"line":139,"column":48,"offset":4118},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Disabled possibility to timestamp video when using hardware acceleration.","position":{"start":{"line":140,"column":3,"offset":4121},"end":{"line":140,"column":76,"offset":4194},"indent":[]}}],"position":{"start":{"line":140,"column":3,"offset":4121},"end":{"line":140,"column":76,"offset":4194},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":4119},"end":{"line":140,"column":76,"offset":4194},"indent":[]}}],"position":{"start":{"line":137,"column":1,"offset":3886},"end":{"line":140,"column":76,"offset":4194},"indent":[1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Docker","position":{"start":{"line":142,"column":6,"offset":4201},"end":{"line":142,"column":12,"offset":4207},"indent":[]}}],"position":{"start":{"line":142,"column":1,"offset":4196},"end":{"line":142,"column":12,"offset":4207},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fix SSL support ","position":{"start":{"line":144,"column":3,"offset":4211},"end":{"line":144,"column":19,"offset":4227},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker/issues/4","children":[{"type":"text","value":"#4","position":{"start":{"line":144,"column":20,"offset":4228},"end":{"line":144,"column":22,"offset":4230},"indent":[]}}],"position":{"start":{"line":144,"column":19,"offset":4227},"end":{"line":144,"column":71,"offset":4279},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":144,"column":71,"offset":4279},"end":{"line":144,"column":72,"offset":4280},"indent":[]}}],"position":{"start":{"line":144,"column":3,"offset":4211},"end":{"line":144,"column":72,"offset":4280},"indent":[]}}],"position":{"start":{"line":144,"column":1,"offset":4209},"end":{"line":144,"column":72,"offset":4280},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Auto removal if disk is full.","position":{"start":{"line":145,"column":3,"offset":4283},"end":{"line":145,"column":32,"offset":4312},"indent":[]}}],"position":{"start":{"line":145,"column":3,"offset":4283},"end":{"line":145,"column":32,"offset":4312},"indent":[]}}],"position":{"start":{"line":145,"column":1,"offset":4281},"end":{"line":145,"column":32,"offset":4312},"indent":[]}}],"position":{"start":{"line":144,"column":1,"offset":4209},"end":{"line":145,"column":32,"offset":4312},"indent":[1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":147,"column":6,"offset":4319},"end":{"line":147,"column":15,"offset":4328},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":4314},"end":{"line":147,"column":15,"offset":4328},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"OpenMAX IL hardware encoding for Raspberry Pi camera. ","position":{"start":{"line":149,"column":3,"offset":4332},"end":{"line":149,"column":57,"offset":4386},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/83","children":[{"type":"text","value":"#83","position":{"start":{"line":149,"column":58,"offset":4387},"end":{"line":149,"column":61,"offset":4390},"indent":[]}}],"position":{"start":{"line":149,"column":57,"offset":4386},"end":{"line":149,"column":114,"offset":4443},"indent":[]}}],"position":{"start":{"line":149,"column":3,"offset":4332},"end":{"line":149,"column":114,"offset":4443},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Optimized live streaming.","position":{"start":{"line":150,"column":5,"offset":4448},"end":{"line":150,"column":30,"offset":4473},"indent":[]}}],"position":{"start":{"line":150,"column":5,"offset":4448},"end":{"line":150,"column":30,"offset":4473},"indent":[]}}],"position":{"start":{"line":150,"column":3,"offset":4446},"end":{"line":150,"column":30,"offset":4473},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Optimized h264 recording.","position":{"start":{"line":151,"column":5,"offset":4478},"end":{"line":151,"column":30,"offset":4503},"indent":[]}}],"position":{"start":{"line":151,"column":5,"offset":4478},"end":{"line":151,"column":30,"offset":4503},"indent":[]}}],"position":{"start":{"line":151,"column":3,"offset":4476},"end":{"line":151,"column":30,"offset":4503},"indent":[]}}],"position":{"start":{"line":150,"column":3,"offset":4446},"end":{"line":151,"column":30,"offset":4503},"indent":[3]}}],"position":{"start":{"line":149,"column":1,"offset":4330},"end":{"line":151,"column":30,"offset":4503},"indent":[1,1]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Basic authentication for live streaming (username and password). ","position":{"start":{"line":152,"column":3,"offset":4506},"end":{"line":152,"column":68,"offset":4571},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/80","children":[{"type":"text","value":"#80","position":{"start":{"line":152,"column":69,"offset":4572},"end":{"line":152,"column":72,"offset":4575},"indent":[]}}],"position":{"start":{"line":152,"column":68,"offset":4571},"end":{"line":152,"column":125,"offset":4628},"indent":[]}}],"position":{"start":{"line":152,"column":3,"offset":4506},"end":{"line":152,"column":125,"offset":4628},"indent":[]}}],"position":{"start":{"line":152,"column":1,"offset":4504},"end":{"line":152,"column":125,"offset":4628},"indent":[]}}],"position":{"start":{"line":149,"column":1,"offset":4330},"end":{"line":152,"column":125,"offset":4628},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.3.1","position":{"start":{"line":154,"column":5,"offset":4634},"end":{"line":154,"column":10,"offset":4639},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":4630},"end":{"line":154,"column":10,"offset":4639},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":156,"column":6,"offset":4646},"end":{"line":156,"column":15,"offset":4655},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":4641},"end":{"line":156,"column":15,"offset":4655},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Update for kerberos.cloud: pushing content-type.","position":{"start":{"line":158,"column":3,"offset":4659},"end":{"line":158,"column":51,"offset":4707},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":4659},"end":{"line":158,"column":51,"offset":4707},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":4657},"end":{"line":158,"column":51,"offset":4707},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Change default configurations.","position":{"start":{"line":159,"column":3,"offset":4710},"end":{"line":159,"column":33,"offset":4740},"indent":[]}}],"position":{"start":{"line":159,"column":3,"offset":4710},"end":{"line":159,"column":33,"offset":4740},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":4708},"end":{"line":159,"column":33,"offset":4740},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":4657},"end":{"line":159,"column":33,"offset":4740},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.3.0","position":{"start":{"line":161,"column":5,"offset":4746},"end":{"line":161,"column":10,"offset":4751},"indent":[]}}],"position":{"start":{"line":161,"column":1,"offset":4742},"end":{"line":161,"column":10,"offset":4751},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Ecosystem","position":{"start":{"line":163,"column":6,"offset":4758},"end":{"line":163,"column":15,"offset":4767},"indent":[]}}],"position":{"start":{"line":163,"column":1,"offset":4753},"end":{"line":163,"column":15,"offset":4767},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support for Raspberry Pi Zero W. ","position":{"start":{"line":165,"column":3,"offset":4771},"end":{"line":165,"column":36,"offset":4804},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/issues/8","children":[{"type":"text","value":"#8","position":{"start":{"line":165,"column":37,"offset":4805},"end":{"line":165,"column":39,"offset":4807},"indent":[]}}],"position":{"start":{"line":165,"column":36,"offset":4804},"end":{"line":165,"column":86,"offset":4854},"indent":[]}}],"position":{"start":{"line":165,"column":3,"offset":4771},"end":{"line":165,"column":86,"offset":4854},"indent":[]}}],"position":{"start":{"line":165,"column":1,"offset":4769},"end":{"line":165,"column":86,"offset":4854},"indent":[]}}],"position":{"start":{"line":165,"column":1,"offset":4769},"end":{"line":165,"column":86,"offset":4854},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.2.1","position":{"start":{"line":167,"column":5,"offset":4860},"end":{"line":167,"column":10,"offset":4865},"indent":[]}}],"position":{"start":{"line":167,"column":1,"offset":4856},"end":{"line":167,"column":10,"offset":4865},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Ecosystem","position":{"start":{"line":169,"column":6,"offset":4872},"end":{"line":169,"column":15,"offset":4881},"indent":[]}}],"position":{"start":{"line":169,"column":1,"offset":4867},"end":{"line":169,"column":15,"offset":4881},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Upgraded FFmpeg and libx264 on KiOS.","position":{"start":{"line":171,"column":3,"offset":4885},"end":{"line":171,"column":39,"offset":4921},"indent":[]}}],"position":{"start":{"line":171,"column":3,"offset":4885},"end":{"line":171,"column":39,"offset":4921},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":4883},"end":{"line":171,"column":39,"offset":4921},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":4883},"end":{"line":171,"column":39,"offset":4921},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":173,"column":6,"offset":4928},"end":{"line":173,"column":9,"offset":4931},"indent":[]}}],"position":{"start":{"line":173,"column":1,"offset":4923},"end":{"line":173,"column":9,"offset":4931},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Add Bulgarian translation. ","position":{"start":{"line":175,"column":3,"offset":4935},"end":{"line":175,"column":30,"offset":4962},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/pull/81","children":[{"type":"text","value":"#81","position":{"start":{"line":175,"column":31,"offset":4963},"end":{"line":175,"column":34,"offset":4966},"indent":[]}}],"position":{"start":{"line":175,"column":30,"offset":4962},"end":{"line":175,"column":79,"offset":5011},"indent":[]}}],"position":{"start":{"line":175,"column":3,"offset":4935},"end":{"line":175,"column":79,"offset":5011},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":4933},"end":{"line":175,"column":79,"offset":5011},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":4933},"end":{"line":175,"column":79,"offset":5011},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":177,"column":6,"offset":5018},"end":{"line":177,"column":15,"offset":5027},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":5013},"end":{"line":177,"column":15,"offset":5027},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Bug: IoVideo crashes due to a memory leak. ","position":{"start":{"line":179,"column":3,"offset":5031},"end":{"line":179,"column":46,"offset":5074},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/70","children":[{"type":"text","value":"#70","position":{"start":{"line":179,"column":47,"offset":5075},"end":{"line":179,"column":50,"offset":5078},"indent":[]}}],"position":{"start":{"line":179,"column":46,"offset":5074},"end":{"line":179,"column":103,"offset":5131},"indent":[]}}],"position":{"start":{"line":179,"column":3,"offset":5031},"end":{"line":179,"column":103,"offset":5131},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":5029},"end":{"line":179,"column":103,"offset":5131},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":5029},"end":{"line":179,"column":103,"offset":5131},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.2.0","position":{"start":{"line":181,"column":5,"offset":5137},"end":{"line":181,"column":10,"offset":5142},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":5133},"end":{"line":181,"column":10,"offset":5142},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Ecosystem","position":{"start":{"line":183,"column":6,"offset":5149},"end":{"line":183,"column":15,"offset":5158},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":5144},"end":{"line":183,"column":15,"offset":5158},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added support for Armbian.","position":{"start":{"line":185,"column":3,"offset":5162},"end":{"line":185,"column":29,"offset":5188},"indent":[]}}],"position":{"start":{"line":185,"column":3,"offset":5162},"end":{"line":185,"column":29,"offset":5188},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":5160},"end":{"line":185,"column":29,"offset":5188},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Raspbian: Async requests causes session corruption. ","position":{"start":{"line":186,"column":3,"offset":5191},"end":{"line":186,"column":55,"offset":5243},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/78","children":[{"type":"text","value":"#78","position":{"start":{"line":186,"column":56,"offset":5244},"end":{"line":186,"column":59,"offset":5247},"indent":[]}}],"position":{"start":{"line":186,"column":55,"offset":5243},"end":{"line":186,"column":106,"offset":5294},"indent":[]}}],"position":{"start":{"line":186,"column":3,"offset":5191},"end":{"line":186,"column":106,"offset":5294},"indent":[]}}],"position":{"start":{"line":186,"column":1,"offset":5189},"end":{"line":186,"column":106,"offset":5294},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":5160},"end":{"line":186,"column":106,"offset":5294},"indent":[1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":188,"column":6,"offset":5301},"end":{"line":188,"column":9,"offset":5304},"indent":[]}}],"position":{"start":{"line":188,"column":1,"offset":5296},"end":{"line":188,"column":9,"offset":5304},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Bug: Issue format instance name. ","position":{"start":{"line":190,"column":3,"offset":5308},"end":{"line":190,"column":36,"offset":5341},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/57","children":[{"type":"text","value":"#57","position":{"start":{"line":190,"column":37,"offset":5342},"end":{"line":190,"column":40,"offset":5345},"indent":[]}}],"position":{"start":{"line":190,"column":36,"offset":5341},"end":{"line":190,"column":87,"offset":5392},"indent":[]}}],"position":{"start":{"line":190,"column":3,"offset":5308},"end":{"line":190,"column":87,"offset":5392},"indent":[]}}],"position":{"start":{"line":190,"column":1,"offset":5306},"end":{"line":190,"column":87,"offset":5392},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Redesign settings page (better UX). ","position":{"start":{"line":191,"column":3,"offset":5395},"end":{"line":191,"column":39,"offset":5431},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/39","children":[{"type":"text","value":"#39","position":{"start":{"line":191,"column":40,"offset":5432},"end":{"line":191,"column":43,"offset":5435},"indent":[]}}],"position":{"start":{"line":191,"column":39,"offset":5431},"end":{"line":191,"column":90,"offset":5482},"indent":[]}}],"position":{"start":{"line":191,"column":3,"offset":5395},"end":{"line":191,"column":90,"offset":5482},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":5393},"end":{"line":191,"column":90,"offset":5482},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Possibility to edit password through web interface. ","position":{"start":{"line":192,"column":3,"offset":5485},"end":{"line":192,"column":55,"offset":5537},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/63","children":[{"type":"text","value":"#63","position":{"start":{"line":192,"column":56,"offset":5538},"end":{"line":192,"column":59,"offset":5541},"indent":[]}}],"position":{"start":{"line":192,"column":55,"offset":5537},"end":{"line":192,"column":106,"offset":5588},"indent":[]}}],"position":{"start":{"line":192,"column":3,"offset":5485},"end":{"line":192,"column":106,"offset":5588},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":5483},"end":{"line":192,"column":106,"offset":5588},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support for viewing videos.","position":{"start":{"line":193,"column":3,"offset":5591},"end":{"line":193,"column":30,"offset":5618},"indent":[]}}],"position":{"start":{"line":193,"column":3,"offset":5591},"end":{"line":193,"column":30,"offset":5618},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":5589},"end":{"line":193,"column":30,"offset":5618},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Update radius of heatmap.","position":{"start":{"line":194,"column":3,"offset":5621},"end":{"line":194,"column":28,"offset":5646},"indent":[]}}],"position":{"start":{"line":194,"column":3,"offset":5621},"end":{"line":194,"column":28,"offset":5646},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":5619},"end":{"line":194,"column":28,"offset":5646},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"PHP7 support. ","position":{"start":{"line":195,"column":3,"offset":5649},"end":{"line":195,"column":17,"offset":5663},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/60","children":[{"type":"text","value":"#60","position":{"start":{"line":195,"column":18,"offset":5664},"end":{"line":195,"column":21,"offset":5667},"indent":[]}}],"position":{"start":{"line":195,"column":17,"offset":5663},"end":{"line":195,"column":68,"offset":5714},"indent":[]}}],"position":{"start":{"line":195,"column":3,"offset":5649},"end":{"line":195,"column":68,"offset":5714},"indent":[]}}],"position":{"start":{"line":195,"column":1,"offset":5647},"end":{"line":195,"column":68,"offset":5714},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Welcome/installation page. ","position":{"start":{"line":196,"column":3,"offset":5717},"end":{"line":196,"column":30,"offset":5744},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/60","children":[{"type":"text","value":"#60","position":{"start":{"line":196,"column":31,"offset":5745},"end":{"line":196,"column":34,"offset":5748},"indent":[]}}],"position":{"start":{"line":196,"column":30,"offset":5744},"end":{"line":196,"column":81,"offset":5795},"indent":[]}}],"position":{"start":{"line":196,"column":3,"offset":5717},"end":{"line":196,"column":81,"offset":5795},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":5715},"end":{"line":196,"column":81,"offset":5795},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Translation updated. ","position":{"start":{"line":197,"column":3,"offset":5798},"end":{"line":197,"column":24,"offset":5819},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/74","children":[{"type":"text","value":"#74","position":{"start":{"line":197,"column":25,"offset":5820},"end":{"line":197,"column":28,"offset":5823},"indent":[]}}],"position":{"start":{"line":197,"column":24,"offset":5819},"end":{"line":197,"column":75,"offset":5870},"indent":[]}}],"position":{"start":{"line":197,"column":3,"offset":5798},"end":{"line":197,"column":75,"offset":5870},"indent":[]}}],"position":{"start":{"line":197,"column":1,"offset":5796},"end":{"line":197,"column":75,"offset":5870},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Privacy mode. ","position":{"start":{"line":198,"column":3,"offset":5873},"end":{"line":198,"column":17,"offset":5887},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/54","children":[{"type":"text","value":"#54","position":{"start":{"line":198,"column":18,"offset":5888},"end":{"line":198,"column":21,"offset":5891},"indent":[]}}],"position":{"start":{"line":198,"column":17,"offset":5887},"end":{"line":198,"column":68,"offset":5938},"indent":[]}}],"position":{"start":{"line":198,"column":3,"offset":5873},"end":{"line":198,"column":68,"offset":5938},"indent":[]}}],"position":{"start":{"line":198,"column":1,"offset":5871},"end":{"line":198,"column":68,"offset":5938},"indent":[]}}],"position":{"start":{"line":190,"column":1,"offset":5306},"end":{"line":198,"column":68,"offset":5938},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":200,"column":6,"offset":5945},"end":{"line":200,"column":15,"offset":5954},"indent":[]}}],"position":{"start":{"line":200,"column":1,"offset":5940},"end":{"line":200,"column":15,"offset":5954},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Output as video file. ","position":{"start":{"line":202,"column":3,"offset":5958},"end":{"line":202,"column":25,"offset":5980},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/60","children":[{"type":"text","value":"#60","position":{"start":{"line":202,"column":26,"offset":5981},"end":{"line":202,"column":29,"offset":5984},"indent":[]}}],"position":{"start":{"line":202,"column":25,"offset":5980},"end":{"line":202,"column":82,"offset":6037},"indent":[]}}],"position":{"start":{"line":202,"column":3,"offset":5958},"end":{"line":202,"column":82,"offset":6037},"indent":[]}}],"position":{"start":{"line":202,"column":1,"offset":5956},"end":{"line":202,"column":82,"offset":6037},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Bug: System hangs when a wrong IP camera url was defined. ","position":{"start":{"line":203,"column":3,"offset":6040},"end":{"line":203,"column":61,"offset":6098},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/48","children":[{"type":"text","value":"#48","position":{"start":{"line":203,"column":62,"offset":6099},"end":{"line":203,"column":65,"offset":6102},"indent":[]}}],"position":{"start":{"line":203,"column":61,"offset":6098},"end":{"line":203,"column":118,"offset":6155},"indent":[]}}],"position":{"start":{"line":203,"column":3,"offset":6040},"end":{"line":203,"column":118,"offset":6155},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":6038},"end":{"line":203,"column":118,"offset":6155},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Run arbitrary script/program. ","position":{"start":{"line":204,"column":3,"offset":6158},"end":{"line":204,"column":33,"offset":6188},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/31","children":[{"type":"text","value":"#31","position":{"start":{"line":204,"column":34,"offset":6189},"end":{"line":204,"column":37,"offset":6192},"indent":[]}}],"position":{"start":{"line":204,"column":33,"offset":6188},"end":{"line":204,"column":90,"offset":6245},"indent":[]}}],"position":{"start":{"line":204,"column":3,"offset":6158},"end":{"line":204,"column":90,"offset":6245},"indent":[]}}],"position":{"start":{"line":204,"column":1,"offset":6156},"end":{"line":204,"column":90,"offset":6245},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Bug: Weird colors from RPi Camera. ","position":{"start":{"line":205,"column":3,"offset":6248},"end":{"line":205,"column":38,"offset":6283},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/64","children":[{"type":"text","value":"#64","position":{"start":{"line":205,"column":39,"offset":6284},"end":{"line":205,"column":42,"offset":6287},"indent":[]}}],"position":{"start":{"line":205,"column":38,"offset":6283},"end":{"line":205,"column":95,"offset":6340},"indent":[]}}],"position":{"start":{"line":205,"column":3,"offset":6248},"end":{"line":205,"column":95,"offset":6340},"indent":[]}}],"position":{"start":{"line":205,"column":1,"offset":6246},"end":{"line":205,"column":95,"offset":6340},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Upgrade to OpenCV 3.2.0.","position":{"start":{"line":206,"column":3,"offset":6343},"end":{"line":206,"column":27,"offset":6367},"indent":[]}}],"position":{"start":{"line":206,"column":3,"offset":6343},"end":{"line":206,"column":27,"offset":6367},"indent":[]}}],"position":{"start":{"line":206,"column":1,"offset":6341},"end":{"line":206,"column":27,"offset":6367},"indent":[]}}],"position":{"start":{"line":202,"column":1,"offset":5956},"end":{"line":206,"column":27,"offset":6367},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.1.0","position":{"start":{"line":208,"column":5,"offset":6373},"end":{"line":208,"column":10,"offset":6378},"indent":[]}}],"position":{"start":{"line":208,"column":1,"offset":6369},"end":{"line":208,"column":10,"offset":6378},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":210,"column":6,"offset":6385},"end":{"line":210,"column":9,"offset":6388},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":6380},"end":{"line":210,"column":9,"offset":6388},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added PhotoSwipe for image overview (easier to browse through images). ","position":{"start":{"line":212,"column":3,"offset":6392},"end":{"line":212,"column":74,"offset":6463},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/45","children":[{"type":"text","value":"#45","position":{"start":{"line":212,"column":75,"offset":6464},"end":{"line":212,"column":78,"offset":6467},"indent":[]}}],"position":{"start":{"line":212,"column":74,"offset":6463},"end":{"line":212,"column":125,"offset":6514},"indent":[]}}],"position":{"start":{"line":212,"column":3,"offset":6392},"end":{"line":212,"column":125,"offset":6514},"indent":[]}}],"position":{"start":{"line":212,"column":1,"offset":6390},"end":{"line":212,"column":125,"offset":6514},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added reboot and shutdown commands. ","position":{"start":{"line":213,"column":3,"offset":6517},"end":{"line":213,"column":39,"offset":6553},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/46","children":[{"type":"text","value":"#46","position":{"start":{"line":213,"column":40,"offset":6554},"end":{"line":213,"column":43,"offset":6557},"indent":[]}}],"position":{"start":{"line":213,"column":39,"offset":6553},"end":{"line":213,"column":90,"offset":6604},"indent":[]}}],"position":{"start":{"line":213,"column":3,"offset":6517},"end":{"line":213,"column":90,"offset":6604},"indent":[]}}],"position":{"start":{"line":213,"column":1,"offset":6515},"end":{"line":213,"column":90,"offset":6604},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added logging view to system page. ","position":{"start":{"line":214,"column":3,"offset":6607},"end":{"line":214,"column":38,"offset":6642},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/33","children":[{"type":"text","value":"#33","position":{"start":{"line":214,"column":39,"offset":6643},"end":{"line":214,"column":42,"offset":6646},"indent":[]}}],"position":{"start":{"line":214,"column":38,"offset":6642},"end":{"line":214,"column":89,"offset":6693},"indent":[]}}],"position":{"start":{"line":214,"column":3,"offset":6607},"end":{"line":214,"column":89,"offset":6693},"indent":[]}}],"position":{"start":{"line":214,"column":1,"offset":6605},"end":{"line":214,"column":89,"offset":6693},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added labels to check if machinery is running.","position":{"start":{"line":215,"column":3,"offset":6696},"end":{"line":215,"column":49,"offset":6742},"indent":[]}}],"position":{"start":{"line":215,"column":3,"offset":6696},"end":{"line":215,"column":49,"offset":6742},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":6694},"end":{"line":215,"column":49,"offset":6742},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added error handling if web interface isn’t working properly.","position":{"start":{"line":216,"column":3,"offset":6745},"end":{"line":216,"column":64,"offset":6806},"indent":[]}}],"position":{"start":{"line":216,"column":3,"offset":6745},"end":{"line":216,"column":64,"offset":6806},"indent":[]}}],"position":{"start":{"line":216,"column":1,"offset":6743},"end":{"line":216,"column":64,"offset":6806},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fixed Heatmap.js fail to load by ad-blocker. ","position":{"start":{"line":217,"column":3,"offset":6809},"end":{"line":217,"column":48,"offset":6854},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/42","children":[{"type":"text","value":"#42","position":{"start":{"line":217,"column":49,"offset":6855},"end":{"line":217,"column":52,"offset":6858},"indent":[]}}],"position":{"start":{"line":217,"column":48,"offset":6854},"end":{"line":217,"column":99,"offset":6905},"indent":[]}}],"position":{"start":{"line":217,"column":3,"offset":6809},"end":{"line":217,"column":99,"offset":6905},"indent":[]}}],"position":{"start":{"line":217,"column":1,"offset":6807},"end":{"line":217,"column":99,"offset":6905},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Show additional information on the dashboard (streaming is opening or not) there is no data available.","position":{"start":{"line":218,"column":3,"offset":6908},"end":{"line":218,"column":105,"offset":7010},"indent":[]}}],"position":{"start":{"line":218,"column":3,"offset":6908},"end":{"line":218,"column":105,"offset":7010},"indent":[]}}],"position":{"start":{"line":218,"column":1,"offset":6906},"end":{"line":218,"column":105,"offset":7010},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Settings page is now visible on mobile (+ changed icon).","position":{"start":{"line":219,"column":3,"offset":7013},"end":{"line":219,"column":59,"offset":7069},"indent":[]}}],"position":{"start":{"line":219,"column":3,"offset":7013},"end":{"line":219,"column":59,"offset":7069},"indent":[]}}],"position":{"start":{"line":219,"column":1,"offset":7011},"end":{"line":219,"column":59,"offset":7069},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fixed sorting of news articles.","position":{"start":{"line":220,"column":3,"offset":7072},"end":{"line":220,"column":34,"offset":7103},"indent":[]}}],"position":{"start":{"line":220,"column":3,"offset":7072},"end":{"line":220,"column":34,"offset":7103},"indent":[]}}],"position":{"start":{"line":220,"column":1,"offset":7070},"end":{"line":220,"column":34,"offset":7103},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Removed links to assets in the cloud (.css files).","position":{"start":{"line":221,"column":3,"offset":7106},"end":{"line":221,"column":53,"offset":7156},"indent":[]}}],"position":{"start":{"line":221,"column":3,"offset":7106},"end":{"line":221,"column":53,"offset":7156},"indent":[]}}],"position":{"start":{"line":221,"column":1,"offset":7104},"end":{"line":221,"column":53,"offset":7156},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Design: improved layout of login page, async loading of image view.","position":{"start":{"line":222,"column":3,"offset":7159},"end":{"line":222,"column":70,"offset":7226},"indent":[]}}],"position":{"start":{"line":222,"column":3,"offset":7159},"end":{"line":222,"column":70,"offset":7226},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":7157},"end":{"line":222,"column":70,"offset":7226},"indent":[]}}],"position":{"start":{"line":212,"column":1,"offset":6390},"end":{"line":222,"column":70,"offset":7226},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":224,"column":6,"offset":7233},"end":{"line":224,"column":15,"offset":7242},"indent":[]}}],"position":{"start":{"line":224,"column":1,"offset":7228},"end":{"line":224,"column":15,"offset":7242},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added configurable streaming port and quality. ","position":{"start":{"line":226,"column":3,"offset":7246},"end":{"line":226,"column":50,"offset":7293},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/41","children":[{"type":"text","value":"#41","position":{"start":{"line":226,"column":51,"offset":7294},"end":{"line":226,"column":54,"offset":7297},"indent":[]}}],"position":{"start":{"line":226,"column":50,"offset":7293},"end":{"line":226,"column":107,"offset":7350},"indent":[]}}],"position":{"start":{"line":226,"column":3,"offset":7246},"end":{"line":226,"column":107,"offset":7350},"indent":[]}}],"position":{"start":{"line":226,"column":1,"offset":7244},"end":{"line":226,"column":107,"offset":7350},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added new algorithm: Background subtraction.","position":{"start":{"line":227,"column":3,"offset":7353},"end":{"line":227,"column":47,"offset":7397},"indent":[]}}],"position":{"start":{"line":227,"column":3,"offset":7353},"end":{"line":227,"column":47,"offset":7397},"indent":[]}}],"position":{"start":{"line":227,"column":1,"offset":7351},"end":{"line":227,"column":47,"offset":7397},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added new heuristic: Counter (for object/people counting). ","position":{"start":{"line":228,"column":3,"offset":7400},"end":{"line":228,"column":62,"offset":7459},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/42","children":[{"type":"text","value":"#42","position":{"start":{"line":228,"column":63,"offset":7460},"end":{"line":228,"column":66,"offset":7463},"indent":[]}}],"position":{"start":{"line":228,"column":62,"offset":7459},"end":{"line":228,"column":119,"offset":7516},"indent":[]}}],"position":{"start":{"line":228,"column":3,"offset":7400},"end":{"line":228,"column":119,"offset":7516},"indent":[]}}],"position":{"start":{"line":228,"column":1,"offset":7398},"end":{"line":228,"column":119,"offset":7516},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added video capture, which can be used for debugging purposes (replay a video fragment).","position":{"start":{"line":229,"column":3,"offset":7519},"end":{"line":229,"column":91,"offset":7607},"indent":[]}}],"position":{"start":{"line":229,"column":3,"offset":7519},"end":{"line":229,"column":91,"offset":7607},"indent":[]}}],"position":{"start":{"line":229,"column":1,"offset":7517},"end":{"line":229,"column":91,"offset":7607},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"It’s now possible to mark the images with a timestamp. ","position":{"start":{"line":230,"column":3,"offset":7610},"end":{"line":230,"column":58,"offset":7665},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/36","children":[{"type":"text","value":"#36","position":{"start":{"line":230,"column":59,"offset":7666},"end":{"line":230,"column":62,"offset":7669},"indent":[]}}],"position":{"start":{"line":230,"column":58,"offset":7665},"end":{"line":230,"column":115,"offset":7722},"indent":[]}}],"position":{"start":{"line":230,"column":3,"offset":7610},"end":{"line":230,"column":115,"offset":7722},"indent":[]}}],"position":{"start":{"line":230,"column":1,"offset":7608},"end":{"line":230,"column":115,"offset":7722},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fixed blocking streaming socket. ","position":{"start":{"line":231,"column":3,"offset":7725},"end":{"line":231,"column":36,"offset":7758},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/39","children":[{"type":"text","value":"#39","position":{"start":{"line":231,"column":37,"offset":7759},"end":{"line":231,"column":40,"offset":7762},"indent":[]}}],"position":{"start":{"line":231,"column":36,"offset":7758},"end":{"line":231,"column":93,"offset":7815},"indent":[]}}],"position":{"start":{"line":231,"column":3,"offset":7725},"end":{"line":231,"column":93,"offset":7815},"indent":[]}}],"position":{"start":{"line":231,"column":1,"offset":7723},"end":{"line":231,"column":93,"offset":7815},"indent":[]}}],"position":{"start":{"line":226,"column":1,"offset":7244},"end":{"line":231,"column":93,"offset":7815},"indent":[1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Ecosystem","position":{"start":{"line":233,"column":6,"offset":7822},"end":{"line":233,"column":15,"offset":7831},"indent":[]}}],"position":{"start":{"line":233,"column":1,"offset":7817},"end":{"line":233,"column":15,"offset":7831},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fix removal images if disk is almost full (wrong path was defined).","position":{"start":{"line":235,"column":3,"offset":7835},"end":{"line":235,"column":70,"offset":7902},"indent":[]}}],"position":{"start":{"line":235,"column":3,"offset":7835},"end":{"line":235,"column":70,"offset":7902},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":7833},"end":{"line":235,"column":70,"offset":7902},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support for the Raspberry Pi Camera module v2.1. ","position":{"start":{"line":236,"column":3,"offset":7905},"end":{"line":236,"column":52,"offset":7954},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/issues/3","children":[{"type":"text","value":"#3","position":{"start":{"line":236,"column":53,"offset":7955},"end":{"line":236,"column":55,"offset":7957},"indent":[]}}],"position":{"start":{"line":236,"column":52,"offset":7954},"end":{"line":236,"column":102,"offset":8004},"indent":[]}}],"position":{"start":{"line":236,"column":3,"offset":7905},"end":{"line":236,"column":102,"offset":8004},"indent":[]}}],"position":{"start":{"line":236,"column":1,"offset":7903},"end":{"line":236,"column":102,"offset":8004},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support for the Raspberry Pi Zero; updated kernel to latest Raspbian. ","position":{"start":{"line":237,"column":3,"offset":8007},"end":{"line":237,"column":73,"offset":8077},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/issues/3","children":[{"type":"text","value":"#3","position":{"start":{"line":237,"column":74,"offset":8078},"end":{"line":237,"column":76,"offset":8080},"indent":[]}}],"position":{"start":{"line":237,"column":73,"offset":8077},"end":{"line":237,"column":123,"offset":8127},"indent":[]}}],"position":{"start":{"line":237,"column":3,"offset":8007},"end":{"line":237,"column":123,"offset":8127},"indent":[]}}],"position":{"start":{"line":237,"column":1,"offset":8005},"end":{"line":237,"column":123,"offset":8127},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"KiOS GUI installer.","position":{"start":{"line":238,"column":3,"offset":8130},"end":{"line":238,"column":22,"offset":8149},"indent":[]}}],"position":{"start":{"line":238,"column":3,"offset":8130},"end":{"line":238,"column":22,"offset":8149},"indent":[]}}],"position":{"start":{"line":238,"column":1,"offset":8128},"end":{"line":238,"column":22,"offset":8149},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":7833},"end":{"line":238,"column":22,"offset":8149},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.0.0","position":{"start":{"line":240,"column":5,"offset":8155},"end":{"line":240,"column":10,"offset":8160},"indent":[]}}],"position":{"start":{"line":240,"column":1,"offset":8151},"end":{"line":240,"column":10,"offset":8160},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":242,"column":6,"offset":8167},"end":{"line":242,"column":9,"offset":8170},"indent":[]}}],"position":{"start":{"line":242,"column":1,"offset":8162},"end":{"line":242,"column":9,"offset":8170},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Add simple ON/OFF toggle. ","position":{"start":{"line":244,"column":3,"offset":8174},"end":{"line":244,"column":29,"offset":8200},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/24","children":[{"type":"text","value":"#24","position":{"start":{"line":244,"column":30,"offset":8201},"end":{"line":244,"column":33,"offset":8204},"indent":[]}}],"position":{"start":{"line":244,"column":29,"offset":8200},"end":{"line":244,"column":80,"offset":8251},"indent":[]}}],"position":{"start":{"line":244,"column":3,"offset":8174},"end":{"line":244,"column":80,"offset":8251},"indent":[]}}],"position":{"start":{"line":244,"column":1,"offset":8172},"end":{"line":244,"column":80,"offset":8251},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added update strategy when using KiOS. ","position":{"start":{"line":245,"column":3,"offset":8254},"end":{"line":245,"column":42,"offset":8293},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/23","children":[{"type":"text","value":"#23","position":{"start":{"line":245,"column":43,"offset":8294},"end":{"line":245,"column":46,"offset":8297},"indent":[]}}],"position":{"start":{"line":245,"column":42,"offset":8293},"end":{"line":245,"column":93,"offset":8344},"indent":[]}}],"position":{"start":{"line":245,"column":3,"offset":8254},"end":{"line":245,"column":93,"offset":8344},"indent":[]}}],"position":{"start":{"line":245,"column":1,"offset":8252},"end":{"line":245,"column":93,"offset":8344},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"A system page which shows system information. ","position":{"start":{"line":246,"column":3,"offset":8347},"end":{"line":246,"column":49,"offset":8393},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/20","children":[{"type":"text","value":"#20","position":{"start":{"line":246,"column":50,"offset":8394},"end":{"line":246,"column":53,"offset":8397},"indent":[]}}],"position":{"start":{"line":246,"column":49,"offset":8393},"end":{"line":246,"column":100,"offset":8444},"indent":[]}}],"position":{"start":{"line":246,"column":3,"offset":8347},"end":{"line":246,"column":100,"offset":8444},"indent":[]}}],"position":{"start":{"line":246,"column":1,"offset":8345},"end":{"line":246,"column":100,"offset":8444},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Heatmap on dashboard page ","position":{"start":{"line":247,"column":3,"offset":8447},"end":{"line":247,"column":29,"offset":8473},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/19","children":[{"type":"text","value":"#19","position":{"start":{"line":247,"column":30,"offset":8474},"end":{"line":247,"column":33,"offset":8477},"indent":[]}}],"position":{"start":{"line":247,"column":29,"offset":8473},"end":{"line":247,"column":80,"offset":8524},"indent":[]}}],"position":{"start":{"line":247,"column":3,"offset":8447},"end":{"line":247,"column":80,"offset":8524},"indent":[]}}],"position":{"start":{"line":247,"column":1,"offset":8445},"end":{"line":247,"column":80,"offset":8524},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added live stream view on the dashboard page ","position":{"start":{"line":248,"column":3,"offset":8527},"end":{"line":248,"column":48,"offset":8572},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/2","children":[{"type":"text","value":"#2","position":{"start":{"line":248,"column":49,"offset":8573},"end":{"line":248,"column":51,"offset":8575},"indent":[]}}],"position":{"start":{"line":248,"column":48,"offset":8572},"end":{"line":248,"column":97,"offset":8621},"indent":[]}}],"position":{"start":{"line":248,"column":3,"offset":8527},"end":{"line":248,"column":97,"offset":8621},"indent":[]}}],"position":{"start":{"line":248,"column":1,"offset":8525},"end":{"line":248,"column":97,"offset":8621},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fixed bug cloud syncing ","position":{"start":{"line":249,"column":3,"offset":8624},"end":{"line":249,"column":27,"offset":8648},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/16","children":[{"type":"text","value":"#16","position":{"start":{"line":249,"column":28,"offset":8649},"end":{"line":249,"column":31,"offset":8652},"indent":[]}}],"position":{"start":{"line":249,"column":27,"offset":8648},"end":{"line":249,"column":78,"offset":8699},"indent":[]}}],"position":{"start":{"line":249,"column":3,"offset":8624},"end":{"line":249,"column":78,"offset":8699},"indent":[]}}],"position":{"start":{"line":249,"column":1,"offset":8622},"end":{"line":249,"column":78,"offset":8699},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fixed broken settings page when space in instane name ","position":{"start":{"line":250,"column":3,"offset":8702},"end":{"line":250,"column":57,"offset":8756},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/16","children":[{"type":"text","value":"#16","position":{"start":{"line":250,"column":58,"offset":8757},"end":{"line":250,"column":61,"offset":8760},"indent":[]}}],"position":{"start":{"line":250,"column":57,"offset":8756},"end":{"line":250,"column":108,"offset":8807},"indent":[]}}],"position":{"start":{"line":250,"column":3,"offset":8702},"end":{"line":250,"column":108,"offset":8807},"indent":[]}}],"position":{"start":{"line":250,"column":1,"offset":8700},"end":{"line":250,"column":108,"offset":8807},"indent":[]}}],"position":{"start":{"line":244,"column":1,"offset":8172},"end":{"line":250,"column":108,"offset":8807},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":252,"column":6,"offset":8814},"end":{"line":252,"column":15,"offset":8823},"indent":[]}}],"position":{"start":{"line":252,"column":1,"offset":8809},"end":{"line":252,"column":15,"offset":8823},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"RTSP support for IP-camera's. ","position":{"start":{"line":254,"column":3,"offset":8827},"end":{"line":254,"column":33,"offset":8857},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/21","children":[{"type":"text","value":"#21","position":{"start":{"line":254,"column":34,"offset":8858},"end":{"line":254,"column":37,"offset":8861},"indent":[]}}],"position":{"start":{"line":254,"column":33,"offset":8857},"end":{"line":254,"column":90,"offset":8914},"indent":[]}}],"position":{"start":{"line":254,"column":3,"offset":8827},"end":{"line":254,"column":90,"offset":8914},"indent":[]}}],"position":{"start":{"line":254,"column":1,"offset":8825},"end":{"line":254,"column":90,"offset":8914},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Verbose logging. ","position":{"start":{"line":255,"column":3,"offset":8917},"end":{"line":255,"column":20,"offset":8934},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/35","children":[{"type":"text","value":"#35","position":{"start":{"line":255,"column":21,"offset":8935},"end":{"line":255,"column":24,"offset":8938},"indent":[]}}],"position":{"start":{"line":255,"column":20,"offset":8934},"end":{"line":255,"column":77,"offset":8991},"indent":[]}}],"position":{"start":{"line":255,"column":3,"offset":8917},"end":{"line":255,"column":77,"offset":8991},"indent":[]}}],"position":{"start":{"line":255,"column":1,"offset":8915},"end":{"line":255,"column":77,"offset":8991},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"IO-devices are executed in a seperate thread. ","position":{"start":{"line":256,"column":3,"offset":8994},"end":{"line":256,"column":49,"offset":9040},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/28","children":[{"type":"text","value":"#28","position":{"start":{"line":256,"column":50,"offset":9041},"end":{"line":256,"column":53,"offset":9044},"indent":[]}}],"position":{"start":{"line":256,"column":49,"offset":9040},"end":{"line":256,"column":106,"offset":9097},"indent":[]}}],"position":{"start":{"line":256,"column":3,"offset":8994},"end":{"line":256,"column":106,"offset":9097},"indent":[]}}],"position":{"start":{"line":256,"column":1,"offset":8992},"end":{"line":256,"column":106,"offset":9097},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Live streaming (MJPEG). ","position":{"start":{"line":257,"column":3,"offset":9100},"end":{"line":257,"column":27,"offset":9124},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/26","children":[{"type":"text","value":"#26","position":{"start":{"line":257,"column":28,"offset":9125},"end":{"line":257,"column":31,"offset":9128},"indent":[]}}],"position":{"start":{"line":257,"column":27,"offset":9124},"end":{"line":257,"column":84,"offset":9181},"indent":[]}}],"position":{"start":{"line":257,"column":3,"offset":9100},"end":{"line":257,"column":84,"offset":9181},"indent":[]}}],"position":{"start":{"line":257,"column":1,"offset":9098},"end":{"line":257,"column":84,"offset":9181},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Execute multiple instances on a machine. ","position":{"start":{"line":258,"column":3,"offset":9184},"end":{"line":258,"column":44,"offset":9225},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/24","children":[{"type":"text","value":"#24","position":{"start":{"line":258,"column":45,"offset":9226},"end":{"line":258,"column":48,"offset":9229},"indent":[]}}],"position":{"start":{"line":258,"column":44,"offset":9225},"end":{"line":258,"column":101,"offset":9282},"indent":[]}}],"position":{"start":{"line":258,"column":3,"offset":9184},"end":{"line":258,"column":101,"offset":9282},"indent":[]}}],"position":{"start":{"line":258,"column":1,"offset":9182},"end":{"line":258,"column":101,"offset":9282},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Override config by arguments. ","position":{"start":{"line":259,"column":3,"offset":9285},"end":{"line":259,"column":33,"offset":9315},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/22","children":[{"type":"text","value":"#22","position":{"start":{"line":259,"column":34,"offset":9316},"end":{"line":259,"column":37,"offset":9319},"indent":[]}}],"position":{"start":{"line":259,"column":33,"offset":9315},"end":{"line":259,"column":90,"offset":9372},"indent":[]}}],"position":{"start":{"line":259,"column":3,"offset":9285},"end":{"line":259,"column":90,"offset":9372},"indent":[]}}],"position":{"start":{"line":259,"column":1,"offset":9283},"end":{"line":259,"column":90,"offset":9372},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Move S3 upload to machinery and remove sync-s3 repository. ","position":{"start":{"line":260,"column":3,"offset":9375},"end":{"line":260,"column":62,"offset":9434},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/16","children":[{"type":"text","value":"#16","position":{"start":{"line":260,"column":63,"offset":9435},"end":{"line":260,"column":66,"offset":9438},"indent":[]}}],"position":{"start":{"line":260,"column":62,"offset":9434},"end":{"line":260,"column":119,"offset":9491},"indent":[]}}],"position":{"start":{"line":260,"column":3,"offset":9375},"end":{"line":260,"column":119,"offset":9491},"indent":[]}}],"position":{"start":{"line":260,"column":1,"offset":9373},"end":{"line":260,"column":119,"offset":9491},"indent":[]}}],"position":{"start":{"line":254,"column":1,"offset":8825},"end":{"line":260,"column":119,"offset":9491},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Docker","position":{"start":{"line":262,"column":6,"offset":9498},"end":{"line":262,"column":12,"offset":9504},"indent":[]}}],"position":{"start":{"line":262,"column":1,"offset":9493},"end":{"line":262,"column":12,"offset":9504},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added Docker image (x86_x64) to Docker Hub.","position":{"start":{"line":264,"column":3,"offset":9508},"end":{"line":264,"column":46,"offset":9551},"indent":[]}}],"position":{"start":{"line":264,"column":3,"offset":9508},"end":{"line":264,"column":46,"offset":9551},"indent":[]}}],"position":{"start":{"line":264,"column":1,"offset":9506},"end":{"line":264,"column":46,"offset":9551},"indent":[]}}],"position":{"start":{"line":264,"column":1,"offset":9506},"end":{"line":264,"column":46,"offset":9551},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Ecosystem","position":{"start":{"line":266,"column":6,"offset":9558},"end":{"line":266,"column":15,"offset":9567},"indent":[]}}],"position":{"start":{"line":266,"column":1,"offset":9553},"end":{"line":266,"column":15,"offset":9567},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Add support for Raspberry Pi 1, 2 and 3. ","position":{"start":{"line":268,"column":3,"offset":9571},"end":{"line":268,"column":44,"offset":9612},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/issues/1","children":[{"type":"text","value":"#1","position":{"start":{"line":268,"column":45,"offset":9613},"end":{"line":268,"column":47,"offset":9615},"indent":[]}}],"position":{"start":{"line":268,"column":44,"offset":9612},"end":{"line":268,"column":94,"offset":9662},"indent":[]}}],"position":{"start":{"line":268,"column":3,"offset":9571},"end":{"line":268,"column":94,"offset":9662},"indent":[]}}],"position":{"start":{"line":268,"column":1,"offset":9569},"end":{"line":268,"column":94,"offset":9662},"indent":[]}}],"position":{"start":{"line":268,"column":1,"offset":9569},"end":{"line":268,"column":94,"offset":9662},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"1.1.0","position":{"start":{"line":270,"column":5,"offset":9668},"end":{"line":270,"column":10,"offset":9673},"indent":[]}}],"position":{"start":{"line":270,"column":1,"offset":9664},"end":{"line":270,"column":10,"offset":9673},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":272,"column":6,"offset":9680},"end":{"line":272,"column":9,"offset":9683},"indent":[]}}],"position":{"start":{"line":272,"column":1,"offset":9675},"end":{"line":272,"column":9,"offset":9683},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support IP camera's with MJPEG stream. ","position":{"start":{"line":274,"column":3,"offset":9687},"end":{"line":274,"column":42,"offset":9726},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/3","children":[{"type":"text","value":"#3","position":{"start":{"line":274,"column":43,"offset":9727},"end":{"line":274,"column":45,"offset":9729},"indent":[]}}],"position":{"start":{"line":274,"column":42,"offset":9726},"end":{"line":274,"column":91,"offset":9775},"indent":[]}}],"position":{"start":{"line":274,"column":3,"offset":9687},"end":{"line":274,"column":91,"offset":9775},"indent":[]}}],"position":{"start":{"line":274,"column":1,"offset":9685},"end":{"line":274,"column":91,"offset":9775},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Introduce new API methods to configure the machinery, using basic auth. ","position":{"start":{"line":275,"column":3,"offset":9778},"end":{"line":275,"column":75,"offset":9850},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/4","children":[{"type":"text","value":"#4","position":{"start":{"line":275,"column":76,"offset":9851},"end":{"line":275,"column":78,"offset":9853},"indent":[]}}],"position":{"start":{"line":275,"column":75,"offset":9850},"end":{"line":275,"column":124,"offset":9899},"indent":[]}}],"position":{"start":{"line":275,"column":3,"offset":9778},"end":{"line":275,"column":124,"offset":9899},"indent":[]}}],"position":{"start":{"line":275,"column":1,"offset":9776},"end":{"line":275,"column":124,"offset":9899},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Optimization of loading image and dashboard page, completely redesigned the retrieval of images. ","position":{"start":{"line":276,"column":3,"offset":9902},"end":{"line":276,"column":100,"offset":9999},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/5","children":[{"type":"text","value":"#5","position":{"start":{"line":276,"column":101,"offset":10000},"end":{"line":276,"column":103,"offset":10002},"indent":[]}}],"position":{"start":{"line":276,"column":100,"offset":9999},"end":{"line":276,"column":149,"offset":10048},"indent":[]}}],"position":{"start":{"line":276,"column":3,"offset":9902},"end":{"line":276,"column":149,"offset":10048},"indent":[]}}],"position":{"start":{"line":276,"column":1,"offset":9900},"end":{"line":276,"column":149,"offset":10048},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Optimization of settings page. ","position":{"start":{"line":277,"column":3,"offset":10051},"end":{"line":277,"column":34,"offset":10082},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/5","children":[{"type":"text","value":"#5","position":{"start":{"line":277,"column":35,"offset":10083},"end":{"line":277,"column":37,"offset":10085},"indent":[]}}],"position":{"start":{"line":277,"column":34,"offset":10082},"end":{"line":277,"column":83,"offset":10131},"indent":[]}}],"position":{"start":{"line":277,"column":3,"offset":10051},"end":{"line":277,"column":83,"offset":10131},"indent":[]}}],"position":{"start":{"line":277,"column":1,"offset":10049},"end":{"line":277,"column":83,"offset":10131},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Timebar gradient only works in Chrome. ","position":{"start":{"line":278,"column":3,"offset":10134},"end":{"line":278,"column":42,"offset":10173},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/6","children":[{"type":"text","value":"#6","position":{"start":{"line":278,"column":43,"offset":10174},"end":{"line":278,"column":45,"offset":10176},"indent":[]}}],"position":{"start":{"line":278,"column":42,"offset":10173},"end":{"line":278,"column":91,"offset":10222},"indent":[]}}],"position":{"start":{"line":278,"column":3,"offset":10134},"end":{"line":278,"column":91,"offset":10222},"indent":[]}}],"position":{"start":{"line":278,"column":1,"offset":10132},"end":{"line":278,"column":91,"offset":10222},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Minor CSS fixes for responsive layout.","position":{"start":{"line":279,"column":3,"offset":10225},"end":{"line":279,"column":41,"offset":10263},"indent":[]}}],"position":{"start":{"line":279,"column":3,"offset":10225},"end":{"line":279,"column":41,"offset":10263},"indent":[]}}],"position":{"start":{"line":279,"column":1,"offset":10223},"end":{"line":279,"column":41,"offset":10263},"indent":[]}}],"position":{"start":{"line":274,"column":1,"offset":9685},"end":{"line":279,"column":41,"offset":10263},"indent":[1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":281,"column":6,"offset":10270},"end":{"line":281,"column":15,"offset":10279},"indent":[]}}],"position":{"start":{"line":281,"column":1,"offset":10265},"end":{"line":281,"column":15,"offset":10279},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Flip/rotate option for capture devices. ","position":{"start":{"line":283,"column":3,"offset":10283},"end":{"line":283,"column":43,"offset":10323},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/1","children":[{"type":"text","value":"#5","position":{"start":{"line":283,"column":44,"offset":10324},"end":{"line":283,"column":46,"offset":10326},"indent":[]}}],"position":{"start":{"line":283,"column":43,"offset":10323},"end":{"line":283,"column":98,"offset":10378},"indent":[]}}],"position":{"start":{"line":283,"column":3,"offset":10283},"end":{"line":283,"column":98,"offset":10378},"indent":[]}}],"position":{"start":{"line":283,"column":1,"offset":10281},"end":{"line":283,"column":98,"offset":10378},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support IP camera's with MJPEG stream. ","position":{"start":{"line":284,"column":3,"offset":10381},"end":{"line":284,"column":42,"offset":10420},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/4","children":[{"type":"text","value":"#4","position":{"start":{"line":284,"column":43,"offset":10421},"end":{"line":284,"column":45,"offset":10423},"indent":[]}}],"position":{"start":{"line":284,"column":42,"offset":10420},"end":{"line":284,"column":97,"offset":10475},"indent":[]}}],"position":{"start":{"line":284,"column":3,"offset":10381},"end":{"line":284,"column":97,"offset":10475},"indent":[]}}],"position":{"start":{"line":284,"column":1,"offset":10379},"end":{"line":284,"column":97,"offset":10475},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Introduced webhook io device. ","position":{"start":{"line":285,"column":3,"offset":10478},"end":{"line":285,"column":33,"offset":10508},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/5","children":[{"type":"text","value":"#5","position":{"start":{"line":285,"column":34,"offset":10509},"end":{"line":285,"column":36,"offset":10511},"indent":[]}}],"position":{"start":{"line":285,"column":33,"offset":10508},"end":{"line":285,"column":88,"offset":10563},"indent":[]}}],"position":{"start":{"line":285,"column":3,"offset":10478},"end":{"line":285,"column":88,"offset":10563},"indent":[]}}],"position":{"start":{"line":285,"column":1,"offset":10476},"end":{"line":285,"column":88,"offset":10563},"indent":[]}}],"position":{"start":{"line":283,"column":1,"offset":10281},"end":{"line":285,"column":88,"offset":10563},"indent":[1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Cloud","position":{"start":{"line":287,"column":6,"offset":10570},"end":{"line":287,"column":11,"offset":10575},"indent":[]}}],"position":{"start":{"line":287,"column":1,"offset":10565},"end":{"line":287,"column":11,"offset":10575},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fixed problem when syncing a huge amount of images. ","position":{"start":{"line":289,"column":3,"offset":10579},"end":{"line":289,"column":55,"offset":10631},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/sync-s3/issues/1","children":[{"type":"text","value":"#1","position":{"start":{"line":289,"column":56,"offset":10632},"end":{"line":289,"column":58,"offset":10634},"indent":[]}}],"position":{"start":{"line":289,"column":55,"offset":10631},"end":{"line":289,"column":108,"offset":10684},"indent":[]}}],"position":{"start":{"line":289,"column":3,"offset":10579},"end":{"line":289,"column":108,"offset":10684},"indent":[]}}],"position":{"start":{"line":289,"column":1,"offset":10577},"end":{"line":289,"column":108,"offset":10684},"indent":[]}}],"position":{"start":{"line":289,"column":1,"offset":10577},"end":{"line":289,"column":108,"offset":10684},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"1.0.3","position":{"start":{"line":291,"column":5,"offset":10690},"end":{"line":291,"column":10,"offset":10695},"indent":[]}}],"position":{"start":{"line":291,"column":1,"offset":10686},"end":{"line":291,"column":10,"offset":10695},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":293,"column":6,"offset":10702},"end":{"line":293,"column":9,"offset":10705},"indent":[]}}],"position":{"start":{"line":293,"column":1,"offset":10697},"end":{"line":293,"column":9,"offset":10705},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Optimize performance, new datastructure has been implemented.","position":{"start":{"line":295,"column":3,"offset":10709},"end":{"line":295,"column":64,"offset":10770},"indent":[]}}],"position":{"start":{"line":295,"column":3,"offset":10709},"end":{"line":295,"column":64,"offset":10770},"indent":[]}}],"position":{"start":{"line":295,"column":1,"offset":10707},"end":{"line":295,"column":64,"offset":10770},"indent":[]}}],"position":{"start":{"line":295,"column":1,"offset":10707},"end":{"line":295,"column":64,"offset":10770},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":297,"column":6,"offset":10777},"end":{"line":297,"column":15,"offset":10786},"indent":[]}}],"position":{"start":{"line":297,"column":1,"offset":10772},"end":{"line":297,"column":15,"offset":10786},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Memory optimization.","position":{"start":{"line":299,"column":3,"offset":10790},"end":{"line":299,"column":23,"offset":10810},"indent":[]}}],"position":{"start":{"line":299,"column":3,"offset":10790},"end":{"line":299,"column":23,"offset":10810},"indent":[]}}],"position":{"start":{"line":299,"column":1,"offset":10788},"end":{"line":299,"column":23,"offset":10810},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Removal of images older than 3 days have been removed.","position":{"start":{"line":300,"column":3,"offset":10813},"end":{"line":300,"column":57,"offset":10867},"indent":[]}}],"position":{"start":{"line":300,"column":3,"offset":10813},"end":{"line":300,"column":57,"offset":10867},"indent":[]}}],"position":{"start":{"line":300,"column":1,"offset":10811},"end":{"line":300,"column":57,"offset":10867},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Start machinery automatically (delay has been removed).","position":{"start":{"line":301,"column":3,"offset":10870},"end":{"line":301,"column":58,"offset":10925},"indent":[]}}],"position":{"start":{"line":301,"column":3,"offset":10870},"end":{"line":301,"column":58,"offset":10925},"indent":[]}}],"position":{"start":{"line":301,"column":1,"offset":10868},"end":{"line":301,"column":58,"offset":10925},"indent":[]}}],"position":{"start":{"line":299,"column":1,"offset":10788},"end":{"line":301,"column":58,"offset":10925},"indent":[1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Cloud","position":{"start":{"line":303,"column":6,"offset":10932},"end":{"line":303,"column":11,"offset":10937},"indent":[]}}],"position":{"start":{"line":303,"column":1,"offset":10927},"end":{"line":303,"column":11,"offset":10937},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Resolved file exist problem.","position":{"start":{"line":305,"column":3,"offset":10941},"end":{"line":305,"column":31,"offset":10969},"indent":[]}}],"position":{"start":{"line":305,"column":3,"offset":10941},"end":{"line":305,"column":31,"offset":10969},"indent":[]}}],"position":{"start":{"line":305,"column":1,"offset":10939},"end":{"line":305,"column":31,"offset":10969},"indent":[]}}],"position":{"start":{"line":305,"column":1,"offset":10939},"end":{"line":305,"column":31,"offset":10969},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"1.0.2","position":{"start":{"line":307,"column":5,"offset":10975},"end":{"line":307,"column":10,"offset":10980},"indent":[]}}],"position":{"start":{"line":307,"column":1,"offset":10971},"end":{"line":307,"column":10,"offset":10980},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":309,"column":6,"offset":10987},"end":{"line":309,"column":9,"offset":10990},"indent":[]}}],"position":{"start":{"line":309,"column":1,"offset":10982},"end":{"line":309,"column":9,"offset":10990},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Timezone on settings page is also used for the webinterface.","position":{"start":{"line":311,"column":3,"offset":10994},"end":{"line":311,"column":63,"offset":11054},"indent":[]}}],"position":{"start":{"line":311,"column":3,"offset":10994},"end":{"line":311,"column":63,"offset":11054},"indent":[]}}],"position":{"start":{"line":311,"column":1,"offset":10992},"end":{"line":311,"column":63,"offset":11054},"indent":[]}}],"position":{"start":{"line":311,"column":1,"offset":10992},"end":{"line":311,"column":63,"offset":11054},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":313,"column":6,"offset":11061},"end":{"line":313,"column":15,"offset":11070},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":11056},"end":{"line":313,"column":15,"offset":11070},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added extra timezones to timezone.xml.","position":{"start":{"line":315,"column":3,"offset":11074},"end":{"line":315,"column":41,"offset":11112},"indent":[]}}],"position":{"start":{"line":315,"column":3,"offset":11074},"end":{"line":315,"column":41,"offset":11112},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":11072},"end":{"line":315,"column":41,"offset":11112},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":11072},"end":{"line":315,"column":41,"offset":11112},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"1.0.1","position":{"start":{"line":317,"column":5,"offset":11118},"end":{"line":317,"column":10,"offset":11123},"indent":[]}}],"position":{"start":{"line":317,"column":1,"offset":11114},"end":{"line":317,"column":10,"offset":11123},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":319,"column":6,"offset":11130},"end":{"line":319,"column":9,"offset":11133},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":11125},"end":{"line":319,"column":9,"offset":11133},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Improved error handling (date search).","position":{"start":{"line":321,"column":3,"offset":11137},"end":{"line":321,"column":41,"offset":11175},"indent":[]}}],"position":{"start":{"line":321,"column":3,"offset":11137},"end":{"line":321,"column":41,"offset":11175},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":11135},"end":{"line":321,"column":41,"offset":11175},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":11135},"end":{"line":321,"column":41,"offset":11175},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":323,"column":6,"offset":11182},"end":{"line":323,"column":15,"offset":11191},"indent":[]}}],"position":{"start":{"line":323,"column":1,"offset":11177},"end":{"line":323,"column":15,"offset":11191},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Improved memory cleanup.","position":{"start":{"line":325,"column":3,"offset":11195},"end":{"line":325,"column":27,"offset":11219},"indent":[]}}],"position":{"start":{"line":325,"column":3,"offset":11195},"end":{"line":325,"column":27,"offset":11219},"indent":[]}}],"position":{"start":{"line":325,"column":1,"offset":11193},"end":{"line":325,"column":27,"offset":11219},"indent":[]}}],"position":{"start":{"line":325,"column":1,"offset":11193},"end":{"line":325,"column":27,"offset":11219},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"1.0.0","position":{"start":{"line":327,"column":5,"offset":11225},"end":{"line":327,"column":10,"offset":11230},"indent":[]}}],"position":{"start":{"line":327,"column":1,"offset":11221},"end":{"line":327,"column":10,"offset":11230},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"First commit of Kerberos.io","position":{"start":{"line":329,"column":6,"offset":11237},"end":{"line":329,"column":33,"offset":11264},"indent":[]}}],"position":{"start":{"line":329,"column":1,"offset":11232},"end":{"line":329,"column":33,"offset":11264},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Camera support: ","position":{"start":{"line":331,"column":3,"offset":11268},"end":{"line":331,"column":19,"offset":11284},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"USBCamera","position":{"start":{"line":331,"column":21,"offset":11286},"end":{"line":331,"column":30,"offset":11295},"indent":[]}}],"position":{"start":{"line":331,"column":19,"offset":11284},"end":{"line":331,"column":32,"offset":11297},"indent":[]}},{"type":"text","value":" (V4L), ","position":{"start":{"line":331,"column":32,"offset":11297},"end":{"line":331,"column":40,"offset":11305},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Raspberry Pi camera module","position":{"start":{"line":331,"column":42,"offset":11307},"end":{"line":331,"column":68,"offset":11333},"indent":[]}}],"position":{"start":{"line":331,"column":40,"offset":11305},"end":{"line":331,"column":70,"offset":11335},"indent":[]}},{"type":"text","value":" (MMAL).","position":{"start":{"line":331,"column":70,"offset":11335},"end":{"line":331,"column":78,"offset":11343},"indent":[]}}],"position":{"start":{"line":331,"column":3,"offset":11268},"end":{"line":331,"column":78,"offset":11343},"indent":[]}}],"position":{"start":{"line":331,"column":1,"offset":11266},"end":{"line":331,"column":78,"offset":11343},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Conditions: ","position":{"start":{"line":332,"column":3,"offset":11346},"end":{"line":332,"column":15,"offset":11358},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Enabled","position":{"start":{"line":332,"column":17,"offset":11360},"end":{"line":332,"column":24,"offset":11367},"indent":[]}}],"position":{"start":{"line":332,"column":15,"offset":11358},"end":{"line":332,"column":26,"offset":11369},"indent":[]}},{"type":"text","value":" (turn on/off Kerberos) and active ","position":{"start":{"line":332,"column":26,"offset":11369},"end":{"line":332,"column":61,"offset":11404},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Time","position":{"start":{"line":332,"column":63,"offset":11406},"end":{"line":332,"column":67,"offset":11410},"indent":[]}}],"position":{"start":{"line":332,"column":61,"offset":11404},"end":{"line":332,"column":69,"offset":11412},"indent":[]}},{"type":"text","value":" per day.","position":{"start":{"line":332,"column":69,"offset":11412},"end":{"line":332,"column":78,"offset":11421},"indent":[]}}],"position":{"start":{"line":332,"column":3,"offset":11346},"end":{"line":332,"column":78,"offset":11421},"indent":[]}}],"position":{"start":{"line":332,"column":1,"offset":11344},"end":{"line":332,"column":78,"offset":11421},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Algorithms: ","position":{"start":{"line":333,"column":3,"offset":11424},"end":{"line":333,"column":15,"offset":11436},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Differential Images","position":{"start":{"line":333,"column":17,"offset":11438},"end":{"line":333,"column":36,"offset":11457},"indent":[]}}],"position":{"start":{"line":333,"column":15,"offset":11436},"end":{"line":333,"column":38,"offset":11459},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":333,"column":38,"offset":11459},"end":{"line":333,"column":39,"offset":11460},"indent":[]}}],"position":{"start":{"line":333,"column":3,"offset":11424},"end":{"line":333,"column":39,"offset":11460},"indent":[]}}],"position":{"start":{"line":333,"column":1,"offset":11422},"end":{"line":333,"column":39,"offset":11460},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Heuristics: ","position":{"start":{"line":334,"column":3,"offset":11463},"end":{"line":334,"column":15,"offset":11475},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Sequence","position":{"start":{"line":334,"column":17,"offset":11477},"end":{"line":334,"column":25,"offset":11485},"indent":[]}}],"position":{"start":{"line":334,"column":15,"offset":11475},"end":{"line":334,"column":27,"offset":11487},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":334,"column":27,"offset":11487},"end":{"line":334,"column":28,"offset":11488},"indent":[]}}],"position":{"start":{"line":334,"column":3,"offset":11463},"end":{"line":334,"column":28,"offset":11488},"indent":[]}}],"position":{"start":{"line":334,"column":1,"offset":11461},"end":{"line":334,"column":28,"offset":11488},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Expositors: Select a ","position":{"start":{"line":335,"column":3,"offset":11491},"end":{"line":335,"column":24,"offset":11512},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Hull","position":{"start":{"line":335,"column":26,"offset":11514},"end":{"line":335,"column":30,"offset":11518},"indent":[]}}],"position":{"start":{"line":335,"column":24,"offset":11512},"end":{"line":335,"column":32,"offset":11520},"indent":[]}},{"type":"text","value":" or ","position":{"start":{"line":335,"column":32,"offset":11520},"end":{"line":335,"column":36,"offset":11524},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Rectangle","position":{"start":{"line":335,"column":38,"offset":11526},"end":{"line":335,"column":47,"offset":11535},"indent":[]}}],"position":{"start":{"line":335,"column":36,"offset":11524},"end":{"line":335,"column":49,"offset":11537},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":335,"column":49,"offset":11537},"end":{"line":335,"column":50,"offset":11538},"indent":[]}}],"position":{"start":{"line":335,"column":3,"offset":11491},"end":{"line":335,"column":50,"offset":11538},"indent":[]}}],"position":{"start":{"line":335,"column":1,"offset":11489},"end":{"line":335,"column":50,"offset":11538},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Outputs: Write image to ","position":{"start":{"line":336,"column":3,"offset":11541},"end":{"line":336,"column":27,"offset":11565},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Disk","position":{"start":{"line":336,"column":29,"offset":11567},"end":{"line":336,"column":33,"offset":11571},"indent":[]}}],"position":{"start":{"line":336,"column":27,"offset":11565},"end":{"line":336,"column":35,"offset":11573},"indent":[]}},{"type":"text","value":", trigger an ","position":{"start":{"line":336,"column":35,"offset":11573},"end":{"line":336,"column":48,"offset":11586},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"GPIO","position":{"start":{"line":336,"column":50,"offset":11588},"end":{"line":336,"column":54,"offset":11592},"indent":[]}}],"position":{"start":{"line":336,"column":48,"offset":11586},"end":{"line":336,"column":56,"offset":11594},"indent":[]}},{"type":"text","value":" output pin and send a ","position":{"start":{"line":336,"column":56,"offset":11594},"end":{"line":336,"column":79,"offset":11617},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"TCP/IP packet","position":{"start":{"line":336,"column":81,"offset":11619},"end":{"line":336,"column":94,"offset":11632},"indent":[]}}],"position":{"start":{"line":336,"column":79,"offset":11617},"end":{"line":336,"column":96,"offset":11634},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":336,"column":96,"offset":11634},"end":{"line":336,"column":97,"offset":11635},"indent":[]}}],"position":{"start":{"line":336,"column":3,"offset":11541},"end":{"line":336,"column":97,"offset":11635},"indent":[]}}],"position":{"start":{"line":336,"column":1,"offset":11539},"end":{"line":336,"column":97,"offset":11635},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Cloud: send your images to the ","position":{"start":{"line":337,"column":3,"offset":11638},"end":{"line":337,"column":34,"offset":11669},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Kerberos.io cloud aplication","position":{"start":{"line":337,"column":36,"offset":11671},"end":{"line":337,"column":64,"offset":11699},"indent":[]}}],"position":{"start":{"line":337,"column":34,"offset":11669},"end":{"line":337,"column":66,"offset":11701},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":337,"column":66,"offset":11701},"end":{"line":337,"column":67,"offset":11702},"indent":[]}}],"position":{"start":{"line":337,"column":3,"offset":11638},"end":{"line":337,"column":67,"offset":11702},"indent":[]}}],"position":{"start":{"line":337,"column":1,"offset":11636},"end":{"line":337,"column":67,"offset":11702},"indent":[]}}],"position":{"start":{"line":331,"column":1,"offset":11266},"end":{"line":337,"column":67,"offset":11702},"indent":[1,1,1,1,1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":340,"column":1,"offset":11705},"end":{"line":340,"column":31,"offset":11735},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":340,"column":31,"offset":11735}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Release notes`}

\n

{`2.8.0`}

\n

{`Aligned machinery, web and KiOS versions. Too many people were confused by the versioning.`}

\n

{`Web`}

\n
    \n
  • {`Videos displayed on canvas were blocked in latest browsers.`}
  • \n
  • {`Disabled reboot and shutdown.`}
  • \n
  • {`Disabled upgrade process, use fwupdate shell command instead.`}
  • \n
\n

{`KiOS`}

\n
    \n
  • {`Major upgrade, solved many different problems (list to long); not possible to upgrade from 2.7.0 to 2.8.0.`}
  • \n
  • {`Updated firmware to latest Raspbian (raspberrypi-kernel_1.20180417-1).`}
  • \n
  • {`Support for the Raspberry Pi 4.`}
  • \n
\n

{`2.7.2`}

\n

{`Machinery`}

\n
    \n
  • {`To optimise the cloud experience we've added a proxy.kerberos.io machine in between.`}
  • \n
  • {`We've changed the S3 storage scheme (class:ONEZONE_IA).`}
  • \n
\n

{`2.7.1`}

\n

{`Machinery`}

\n
    \n
  • {`Resolved deadlock with livestreaming while restarting machinery.`}
  • \n
  • {`Revert logging library; enabled log rotating.`}
  • \n
\n

{`KiOS`}

\n
    \n
  • {`Updated firmware to latest Raspbian (raspberrypi-kernel_1.20180417-1).`}
  • \n
  • {`Resolved issue with WIFI on Raspberry Pi 3B+`}
  • \n
\n

{`2.7.0`}

\n

{`Web`}

\n
    \n
  • {`Unique session cookie, which allows to open multiple web interfaces (e.g. when using docker).`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Added live streaming feature for app.kerberos.io`}
  • \n
  • {`Upgraded logging library: log file can be max 5MB, and will rotate.`}
  • \n
  • {`Better logging for cloud uploads (failed information).`}
  • \n
\n

{`Docker`}

\n
    \n
  • {`No longer need docker-compose, we merged the web and machinery containers to `}{`a single container`}{`.`}
  • \n
\n

{`KiOS`}

\n
    \n
  • {`Updated firmware to latest Raspbian.`}
  • \n
  • {`Support for the Raspberry Pi 3B+.`}
  • \n
\n

{`2.6.1`}

\n

{`Web`}

\n
    \n
  • {`Solved issue with persisting login configuration. `}{`#111`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Added Pushbullet. `}{`#139`}
  • \n
  • {`Cloud upload was not longer working (hotfix also in 2.6.0).`}
  • \n
\n

{`2.6.0`}

\n

{`Web`}

\n
    \n
  • {`Add a cloud connection verification method. `}{`#112`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Add background color timestamp. `}{`#128`}
  • \n
  • {`Send instanceId in AWS header when uploading to cloud (necessary for new cloud app).`}
  • \n
  • {`Better support for Chinese IP cameras.`}
  • \n
\n

{`Docker`}

\n
    \n
  • {`Bug: Autoremove old images/video within Docker Containers. `}{`#104`}
  • \n
\n

{`2.5.0`}

\n

{`Web`}

\n
    \n
  • {`Added Chinese and Italian language.`}
  • \n
  • {`Resolved issue with INSTALLED=true.`}
  • \n
  • {`Make latest_sequence available with basic auth. `}{`#99`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Provide an IO service for publishing events to MQTT. `}{`#89`}
  • \n
  • {`Optimize recording with H264_OMX. `}{`#83`}
  • \n
  • {`Implement throttler for Io detections. `}{`#96`}
  • \n
  • {`SSL version 1.0.0 is no longer accessible in Raspbian. `}{`#109`}
  • \n
\n

{`2.4.2`}

\n

{`Web`}

\n
    \n
  • {`Typo in french translation, causes the web interface crash.`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Resolved major bug in livestream: memory leak in stream class. `}{`#94`}
  • \n
  • {`Capture health verification: check if the chosen capture device is still grabbing (and didn't stalled).`}
  • \n
  • {`Extra logging when recording with raspberry pi camera.`}
  • \n
  • {`Make sure the cloud upload is functioning properly, after an upload it's verified if the files really exist in the cloud.`}
  • \n
\n

{`2.4.1`}

\n

{`Web`}

\n
    \n
  • {`Show warning when system is disabled. `}{`#88`}{`.`}
  • \n
  • {`Hull selector in basic view not always working.`}
  • \n
\n

{`2.4.0`}

\n

{`Ecosystem`}

\n
    \n
  • {`Enable/Disable force network mode.`}
  • \n
  • {`Enable/Disable auto removal media.`}
  • \n
\n

{`Web`}

\n
    \n
  • {`Upgrade from Laravel 4.2 to Laravel 5.4 `}{`#70`}{`.`}
  • \n
  • {`Fix bug with heatmap radius slider `}{`#84`}{`.`}
  • \n
  • {`Design tweaks toggle button (remove outline).`}
  • \n
  • {`Disabled possibility to timestamp video when using hardware acceleration.`}
  • \n
\n

{`Docker`}

\n
    \n
  • {`Fix SSL support `}{`#4`}{`.`}
  • \n
  • {`Auto removal if disk is full.`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`OpenMAX IL hardware encoding for Raspberry Pi camera. `}{`#83`}
      \n
    • {`Optimized live streaming.`}
    • \n
    • {`Optimized h264 recording.`}
    • \n
  • \n
  • {`Basic authentication for live streaming (username and password). `}{`#80`}
  • \n
\n

{`2.3.1`}

\n

{`Machinery`}

\n
    \n
  • {`Update for kerberos.cloud: pushing content-type.`}
  • \n
  • {`Change default configurations.`}
  • \n
\n

{`2.3.0`}

\n

{`Ecosystem`}

\n
    \n
  • {`Support for Raspberry Pi Zero W. `}{`#8`}
  • \n
\n

{`2.2.1`}

\n

{`Ecosystem`}

\n
    \n
  • {`Upgraded FFmpeg and libx264 on KiOS.`}
  • \n
\n

{`Web`}

\n
    \n
  • {`Add Bulgarian translation. `}{`#81`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Bug: IoVideo crashes due to a memory leak. `}{`#70`}
  • \n
\n

{`2.2.0`}

\n

{`Ecosystem`}

\n
    \n
  • {`Added support for Armbian.`}
  • \n
  • {`Raspbian: Async requests causes session corruption. `}{`#78`}
  • \n
\n

{`Web`}

\n
    \n
  • {`Bug: Issue format instance name. `}{`#57`}
  • \n
  • {`Redesign settings page (better UX). `}{`#39`}
  • \n
  • {`Possibility to edit password through web interface. `}{`#63`}
  • \n
  • {`Support for viewing videos.`}
  • \n
  • {`Update radius of heatmap.`}
  • \n
  • {`PHP7 support. `}{`#60`}
  • \n
  • {`Welcome/installation page. `}{`#60`}
  • \n
  • {`Translation updated. `}{`#74`}
  • \n
  • {`Privacy mode. `}{`#54`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Output as video file. `}{`#60`}
  • \n
  • {`Bug: System hangs when a wrong IP camera url was defined. `}{`#48`}
  • \n
  • {`Run arbitrary script/program. `}{`#31`}
  • \n
  • {`Bug: Weird colors from RPi Camera. `}{`#64`}
  • \n
  • {`Upgrade to OpenCV 3.2.0.`}
  • \n
\n

{`2.1.0`}

\n

{`Web`}

\n
    \n
  • {`Added PhotoSwipe for image overview (easier to browse through images). `}{`#45`}
  • \n
  • {`Added reboot and shutdown commands. `}{`#46`}
  • \n
  • {`Added logging view to system page. `}{`#33`}
  • \n
  • {`Added labels to check if machinery is running.`}
  • \n
  • {`Added error handling if web interface isn’t working properly.`}
  • \n
  • {`Fixed Heatmap.js fail to load by ad-blocker. `}{`#42`}
  • \n
  • {`Show additional information on the dashboard (streaming is opening or not) there is no data available.`}
  • \n
  • {`Settings page is now visible on mobile (+ changed icon).`}
  • \n
  • {`Fixed sorting of news articles.`}
  • \n
  • {`Removed links to assets in the cloud (.css files).`}
  • \n
  • {`Design: improved layout of login page, async loading of image view.`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Added configurable streaming port and quality. `}{`#41`}
  • \n
  • {`Added new algorithm: Background subtraction.`}
  • \n
  • {`Added new heuristic: Counter (for object/people counting). `}{`#42`}
  • \n
  • {`Added video capture, which can be used for debugging purposes (replay a video fragment).`}
  • \n
  • {`It’s now possible to mark the images with a timestamp. `}{`#36`}
  • \n
  • {`Fixed blocking streaming socket. `}{`#39`}
  • \n
\n

{`Ecosystem`}

\n
    \n
  • {`Fix removal images if disk is almost full (wrong path was defined).`}
  • \n
  • {`Support for the Raspberry Pi Camera module v2.1. `}{`#3`}
  • \n
  • {`Support for the Raspberry Pi Zero; updated kernel to latest Raspbian. `}{`#3`}
  • \n
  • {`KiOS GUI installer.`}
  • \n
\n

{`2.0.0`}

\n

{`Web`}

\n
    \n
  • {`Add simple ON/OFF toggle. `}{`#24`}
  • \n
  • {`Added update strategy when using KiOS. `}{`#23`}
  • \n
  • {`A system page which shows system information. `}{`#20`}
  • \n
  • {`Heatmap on dashboard page `}{`#19`}
  • \n
  • {`Added live stream view on the dashboard page `}{`#2`}
  • \n
  • {`Fixed bug cloud syncing `}{`#16`}
  • \n
  • {`Fixed broken settings page when space in instane name `}{`#16`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`RTSP support for IP-camera's. `}{`#21`}
  • \n
  • {`Verbose logging. `}{`#35`}
  • \n
  • {`IO-devices are executed in a seperate thread. `}{`#28`}
  • \n
  • {`Live streaming (MJPEG). `}{`#26`}
  • \n
  • {`Execute multiple instances on a machine. `}{`#24`}
  • \n
  • {`Override config by arguments. `}{`#22`}
  • \n
  • {`Move S3 upload to machinery and remove sync-s3 repository. `}{`#16`}
  • \n
\n

{`Docker`}

\n
    \n
  • {`Added Docker image (x86_x64) to Docker Hub.`}
  • \n
\n

{`Ecosystem`}

\n
    \n
  • {`Add support for Raspberry Pi 1, 2 and 3. `}{`#1`}
  • \n
\n

{`1.1.0`}

\n

{`Web`}

\n
    \n
  • {`Support IP camera's with MJPEG stream. `}{`#3`}
  • \n
  • {`Introduce new API methods to configure the machinery, using basic auth. `}{`#4`}
  • \n
  • {`Optimization of loading image and dashboard page, completely redesigned the retrieval of images. `}{`#5`}
  • \n
  • {`Optimization of settings page. `}{`#5`}
  • \n
  • {`Timebar gradient only works in Chrome. `}{`#6`}
  • \n
  • {`Minor CSS fixes for responsive layout.`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Flip/rotate option for capture devices. `}{`#5`}
  • \n
  • {`Support IP camera's with MJPEG stream. `}{`#4`}
  • \n
  • {`Introduced webhook io device. `}{`#5`}
  • \n
\n

{`Cloud`}

\n
    \n
  • {`Fixed problem when syncing a huge amount of images. `}{`#1`}
  • \n
\n

{`1.0.3`}

\n

{`Web`}

\n
    \n
  • {`Optimize performance, new datastructure has been implemented.`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Memory optimization.`}
  • \n
  • {`Removal of images older than 3 days have been removed.`}
  • \n
  • {`Start machinery automatically (delay has been removed).`}
  • \n
\n

{`Cloud`}

\n
    \n
  • {`Resolved file exist problem.`}
  • \n
\n

{`1.0.2`}

\n

{`Web`}

\n
    \n
  • {`Timezone on settings page is also used for the webinterface.`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Added extra timezones to timezone.xml.`}
  • \n
\n

{`1.0.1`}

\n

{`Web`}

\n
    \n
  • {`Improved error handling (date search).`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Improved memory cleanup.`}
  • \n
\n

{`1.0.0`}

\n

{`First commit of Kerberos.io`}

\n
    \n
  • {`Camera support: `}{`USBCamera`}{` (V4L), `}{`Raspberry Pi camera module`}{` (MMAL).`}
  • \n
  • {`Conditions: `}{`Enabled`}{` (turn on/off Kerberos) and active `}{`Time`}{` per day.`}
  • \n
  • {`Algorithms: `}{`Differential Images`}{`.`}
  • \n
  • {`Heuristics: `}{`Sequence`}{`.`}
  • \n
  • {`Expositors: Select a `}{`Hull`}{` or `}{`Rectangle`}{`.`}
  • \n
  • {`Outputs: Write image to `}{`Disk`}{`, trigger an `}{`GPIO`}{` output pin and send a `}{`TCP/IP packet`}{`.`}
  • \n
  • {`Cloud: send your images to the `}{`Kerberos.io cloud aplication`}{`.`}
  • \n
\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974263000,"key":"gatsby-plugin-mdx-entire-payload-6b3b0bb987de28787ec211d312f8356b-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Release notes","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":16,"offset":174},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":16,"offset":174},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.8.0","position":{"start":{"line":10,"column":5,"offset":180},"end":{"line":10,"column":10,"offset":185},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":176},"end":{"line":10,"column":10,"offset":185},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Aligned machinery, web and KiOS versions. Too many people were confused by the versioning.","position":{"start":{"line":12,"column":1,"offset":187},"end":{"line":12,"column":91,"offset":277},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":187},"end":{"line":12,"column":91,"offset":277},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":14,"column":6,"offset":284},"end":{"line":14,"column":9,"offset":287},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":279},"end":{"line":14,"column":9,"offset":287},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Videos displayed on canvas were blocked in latest browsers.","position":{"start":{"line":16,"column":3,"offset":291},"end":{"line":16,"column":62,"offset":350},"indent":[]}}],"position":{"start":{"line":16,"column":3,"offset":291},"end":{"line":16,"column":62,"offset":350},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":289},"end":{"line":16,"column":62,"offset":350},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Disabled reboot and shutdown.","position":{"start":{"line":17,"column":3,"offset":353},"end":{"line":17,"column":32,"offset":382},"indent":[]}}],"position":{"start":{"line":17,"column":3,"offset":353},"end":{"line":17,"column":32,"offset":382},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":351},"end":{"line":17,"column":32,"offset":382},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Disabled upgrade process, use fwupdate shell command instead.","position":{"start":{"line":18,"column":3,"offset":385},"end":{"line":18,"column":64,"offset":446},"indent":[]}}],"position":{"start":{"line":18,"column":3,"offset":385},"end":{"line":18,"column":64,"offset":446},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":383},"end":{"line":18,"column":64,"offset":446},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":289},"end":{"line":18,"column":64,"offset":446},"indent":[1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":20,"column":6,"offset":453},"end":{"line":20,"column":10,"offset":457},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":448},"end":{"line":20,"column":10,"offset":457},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Major upgrade, solved many different problems (list to long); not possible to upgrade from 2.7.0 to 2.8.0.","position":{"start":{"line":22,"column":3,"offset":461},"end":{"line":22,"column":109,"offset":567},"indent":[]}}],"position":{"start":{"line":22,"column":3,"offset":461},"end":{"line":22,"column":109,"offset":567},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":459},"end":{"line":22,"column":109,"offset":567},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Updated firmware to latest Raspbian (raspberrypi-kernel_1.20180417-1).","position":{"start":{"line":23,"column":3,"offset":570},"end":{"line":23,"column":73,"offset":640},"indent":[]}}],"position":{"start":{"line":23,"column":3,"offset":570},"end":{"line":23,"column":73,"offset":640},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":568},"end":{"line":23,"column":73,"offset":640},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support for the Raspberry Pi 4.","position":{"start":{"line":24,"column":3,"offset":643},"end":{"line":24,"column":34,"offset":674},"indent":[]}}],"position":{"start":{"line":24,"column":3,"offset":643},"end":{"line":24,"column":34,"offset":674},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":641},"end":{"line":24,"column":34,"offset":674},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":459},"end":{"line":24,"column":34,"offset":674},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.7.2","position":{"start":{"line":26,"column":5,"offset":680},"end":{"line":26,"column":10,"offset":685},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":676},"end":{"line":26,"column":10,"offset":685},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":28,"column":6,"offset":692},"end":{"line":28,"column":15,"offset":701},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":687},"end":{"line":28,"column":15,"offset":701},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"To optimise the cloud experience we've added a proxy.kerberos.io machine in between.","position":{"start":{"line":30,"column":3,"offset":705},"end":{"line":30,"column":87,"offset":789},"indent":[]}}],"position":{"start":{"line":30,"column":3,"offset":705},"end":{"line":30,"column":87,"offset":789},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":703},"end":{"line":30,"column":87,"offset":789},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"We've changed the S3 storage scheme (class:ONEZONE_IA).","position":{"start":{"line":31,"column":3,"offset":792},"end":{"line":31,"column":58,"offset":847},"indent":[]}}],"position":{"start":{"line":31,"column":3,"offset":792},"end":{"line":31,"column":58,"offset":847},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":790},"end":{"line":31,"column":58,"offset":847},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":703},"end":{"line":31,"column":58,"offset":847},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.7.1","position":{"start":{"line":33,"column":5,"offset":853},"end":{"line":33,"column":10,"offset":858},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":849},"end":{"line":33,"column":10,"offset":858},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":35,"column":6,"offset":865},"end":{"line":35,"column":15,"offset":874},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":860},"end":{"line":35,"column":15,"offset":874},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Resolved deadlock with livestreaming while restarting machinery.","position":{"start":{"line":37,"column":3,"offset":878},"end":{"line":37,"column":67,"offset":942},"indent":[]}}],"position":{"start":{"line":37,"column":3,"offset":878},"end":{"line":37,"column":67,"offset":942},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":876},"end":{"line":37,"column":67,"offset":942},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Revert logging library; enabled log rotating.","position":{"start":{"line":38,"column":3,"offset":945},"end":{"line":38,"column":48,"offset":990},"indent":[]}}],"position":{"start":{"line":38,"column":3,"offset":945},"end":{"line":38,"column":48,"offset":990},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":943},"end":{"line":38,"column":48,"offset":990},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":876},"end":{"line":38,"column":48,"offset":990},"indent":[1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":40,"column":6,"offset":997},"end":{"line":40,"column":10,"offset":1001},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":992},"end":{"line":40,"column":10,"offset":1001},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Updated firmware to latest Raspbian (raspberrypi-kernel_1.20180417-1).","position":{"start":{"line":42,"column":3,"offset":1005},"end":{"line":42,"column":73,"offset":1075},"indent":[]}}],"position":{"start":{"line":42,"column":3,"offset":1005},"end":{"line":42,"column":73,"offset":1075},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":1003},"end":{"line":42,"column":73,"offset":1075},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Resolved issue with WIFI on Raspberry Pi 3B+","position":{"start":{"line":43,"column":3,"offset":1078},"end":{"line":43,"column":47,"offset":1122},"indent":[]}}],"position":{"start":{"line":43,"column":3,"offset":1078},"end":{"line":43,"column":47,"offset":1122},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":1076},"end":{"line":43,"column":47,"offset":1122},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":1003},"end":{"line":43,"column":47,"offset":1122},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.7.0","position":{"start":{"line":45,"column":5,"offset":1128},"end":{"line":45,"column":10,"offset":1133},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":1124},"end":{"line":45,"column":10,"offset":1133},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":47,"column":6,"offset":1140},"end":{"line":47,"column":9,"offset":1143},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":1135},"end":{"line":47,"column":9,"offset":1143},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Unique session cookie, which allows to open multiple web interfaces (e.g. when using docker).","position":{"start":{"line":49,"column":3,"offset":1147},"end":{"line":49,"column":96,"offset":1240},"indent":[]}}],"position":{"start":{"line":49,"column":3,"offset":1147},"end":{"line":49,"column":96,"offset":1240},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":1145},"end":{"line":49,"column":96,"offset":1240},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":1145},"end":{"line":49,"column":96,"offset":1240},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":51,"column":6,"offset":1247},"end":{"line":51,"column":15,"offset":1256},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":1242},"end":{"line":51,"column":15,"offset":1256},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added live streaming feature for app.kerberos.io","position":{"start":{"line":53,"column":3,"offset":1260},"end":{"line":53,"column":51,"offset":1308},"indent":[]}}],"position":{"start":{"line":53,"column":3,"offset":1260},"end":{"line":53,"column":51,"offset":1308},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":1258},"end":{"line":53,"column":51,"offset":1308},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Upgraded logging library: log file can be max 5MB, and will rotate.","position":{"start":{"line":54,"column":3,"offset":1311},"end":{"line":54,"column":70,"offset":1378},"indent":[]}}],"position":{"start":{"line":54,"column":3,"offset":1311},"end":{"line":54,"column":70,"offset":1378},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":1309},"end":{"line":54,"column":70,"offset":1378},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Better logging for cloud uploads (failed information).","position":{"start":{"line":55,"column":3,"offset":1381},"end":{"line":55,"column":57,"offset":1435},"indent":[]}}],"position":{"start":{"line":55,"column":3,"offset":1381},"end":{"line":55,"column":57,"offset":1435},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":1379},"end":{"line":55,"column":57,"offset":1435},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":1258},"end":{"line":55,"column":57,"offset":1435},"indent":[1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Docker","position":{"start":{"line":57,"column":6,"offset":1442},"end":{"line":57,"column":12,"offset":1448},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":1437},"end":{"line":57,"column":12,"offset":1448},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"No longer need docker-compose, we merged the web and machinery containers to ","position":{"start":{"line":59,"column":3,"offset":1452},"end":{"line":59,"column":80,"offset":1529},"indent":[]}},{"type":"link","title":null,"url":"http://hub.docker.com/r/kerberos/kerberos","children":[{"type":"text","value":"a single container","position":{"start":{"line":59,"column":81,"offset":1530},"end":{"line":59,"column":99,"offset":1548},"indent":[]}}],"position":{"start":{"line":59,"column":80,"offset":1529},"end":{"line":59,"column":143,"offset":1592},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":59,"column":143,"offset":1592},"end":{"line":59,"column":144,"offset":1593},"indent":[]}}],"position":{"start":{"line":59,"column":3,"offset":1452},"end":{"line":59,"column":144,"offset":1593},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":1450},"end":{"line":59,"column":144,"offset":1593},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":1450},"end":{"line":59,"column":144,"offset":1593},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":61,"column":6,"offset":1600},"end":{"line":61,"column":10,"offset":1604},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":1595},"end":{"line":61,"column":10,"offset":1604},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Updated firmware to latest Raspbian.","position":{"start":{"line":63,"column":3,"offset":1608},"end":{"line":63,"column":39,"offset":1644},"indent":[]}}],"position":{"start":{"line":63,"column":3,"offset":1608},"end":{"line":63,"column":39,"offset":1644},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":1606},"end":{"line":63,"column":39,"offset":1644},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support for the Raspberry Pi 3B+.","position":{"start":{"line":64,"column":3,"offset":1647},"end":{"line":64,"column":36,"offset":1680},"indent":[]}}],"position":{"start":{"line":64,"column":3,"offset":1647},"end":{"line":64,"column":36,"offset":1680},"indent":[]}}],"position":{"start":{"line":64,"column":1,"offset":1645},"end":{"line":64,"column":36,"offset":1680},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":1606},"end":{"line":64,"column":36,"offset":1680},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.6.1","position":{"start":{"line":66,"column":5,"offset":1686},"end":{"line":66,"column":10,"offset":1691},"indent":[]}}],"position":{"start":{"line":66,"column":1,"offset":1682},"end":{"line":66,"column":10,"offset":1691},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":68,"column":6,"offset":1698},"end":{"line":68,"column":9,"offset":1701},"indent":[]}}],"position":{"start":{"line":68,"column":1,"offset":1693},"end":{"line":68,"column":9,"offset":1701},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Solved issue with persisting login configuration. ","position":{"start":{"line":70,"column":3,"offset":1705},"end":{"line":70,"column":53,"offset":1755},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/111","children":[{"type":"text","value":"#111","position":{"start":{"line":70,"column":54,"offset":1756},"end":{"line":70,"column":58,"offset":1760},"indent":[]}}],"position":{"start":{"line":70,"column":53,"offset":1755},"end":{"line":70,"column":106,"offset":1808},"indent":[]}}],"position":{"start":{"line":70,"column":3,"offset":1705},"end":{"line":70,"column":106,"offset":1808},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":1703},"end":{"line":70,"column":106,"offset":1808},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":1703},"end":{"line":70,"column":106,"offset":1808},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":72,"column":6,"offset":1815},"end":{"line":72,"column":15,"offset":1824},"indent":[]}}],"position":{"start":{"line":72,"column":1,"offset":1810},"end":{"line":72,"column":15,"offset":1824},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added Pushbullet. ","position":{"start":{"line":74,"column":3,"offset":1828},"end":{"line":74,"column":21,"offset":1846},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/pull/139","children":[{"type":"text","value":"#139","position":{"start":{"line":74,"column":22,"offset":1847},"end":{"line":74,"column":26,"offset":1851},"indent":[]}}],"position":{"start":{"line":74,"column":21,"offset":1846},"end":{"line":74,"column":78,"offset":1903},"indent":[]}}],"position":{"start":{"line":74,"column":3,"offset":1828},"end":{"line":74,"column":78,"offset":1903},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":1826},"end":{"line":74,"column":78,"offset":1903},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Cloud upload was not longer working (hotfix also in 2.6.0).","position":{"start":{"line":75,"column":3,"offset":1906},"end":{"line":75,"column":62,"offset":1965},"indent":[]}}],"position":{"start":{"line":75,"column":3,"offset":1906},"end":{"line":75,"column":62,"offset":1965},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":1904},"end":{"line":75,"column":62,"offset":1965},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":1826},"end":{"line":75,"column":62,"offset":1965},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.6.0","position":{"start":{"line":77,"column":5,"offset":1971},"end":{"line":77,"column":10,"offset":1976},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":1967},"end":{"line":77,"column":10,"offset":1976},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":79,"column":6,"offset":1983},"end":{"line":79,"column":9,"offset":1986},"indent":[]}}],"position":{"start":{"line":79,"column":1,"offset":1978},"end":{"line":79,"column":9,"offset":1986},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Add a cloud connection verification method. ","position":{"start":{"line":81,"column":3,"offset":1990},"end":{"line":81,"column":47,"offset":2034},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/112","children":[{"type":"text","value":"#112","position":{"start":{"line":81,"column":48,"offset":2035},"end":{"line":81,"column":52,"offset":2039},"indent":[]}}],"position":{"start":{"line":81,"column":47,"offset":2034},"end":{"line":81,"column":100,"offset":2087},"indent":[]}}],"position":{"start":{"line":81,"column":3,"offset":1990},"end":{"line":81,"column":100,"offset":2087},"indent":[]}}],"position":{"start":{"line":81,"column":1,"offset":1988},"end":{"line":81,"column":100,"offset":2087},"indent":[]}}],"position":{"start":{"line":81,"column":1,"offset":1988},"end":{"line":81,"column":100,"offset":2087},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":83,"column":6,"offset":2094},"end":{"line":83,"column":15,"offset":2103},"indent":[]}}],"position":{"start":{"line":83,"column":1,"offset":2089},"end":{"line":83,"column":15,"offset":2103},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Add background color timestamp. ","position":{"start":{"line":85,"column":3,"offset":2107},"end":{"line":85,"column":35,"offset":2139},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/128","children":[{"type":"text","value":"#128","position":{"start":{"line":85,"column":36,"offset":2140},"end":{"line":85,"column":40,"offset":2144},"indent":[]}}],"position":{"start":{"line":85,"column":35,"offset":2139},"end":{"line":85,"column":94,"offset":2198},"indent":[]}}],"position":{"start":{"line":85,"column":3,"offset":2107},"end":{"line":85,"column":94,"offset":2198},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":2105},"end":{"line":85,"column":94,"offset":2198},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Send instanceId in AWS header when uploading to cloud (necessary for new cloud app).","position":{"start":{"line":86,"column":3,"offset":2201},"end":{"line":86,"column":87,"offset":2285},"indent":[]}}],"position":{"start":{"line":86,"column":3,"offset":2201},"end":{"line":86,"column":87,"offset":2285},"indent":[]}}],"position":{"start":{"line":86,"column":1,"offset":2199},"end":{"line":86,"column":87,"offset":2285},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Better support for Chinese IP cameras.","position":{"start":{"line":87,"column":3,"offset":2288},"end":{"line":87,"column":41,"offset":2326},"indent":[]}}],"position":{"start":{"line":87,"column":3,"offset":2288},"end":{"line":87,"column":41,"offset":2326},"indent":[]}}],"position":{"start":{"line":87,"column":1,"offset":2286},"end":{"line":87,"column":41,"offset":2326},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":2105},"end":{"line":87,"column":41,"offset":2326},"indent":[1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Docker","position":{"start":{"line":89,"column":6,"offset":2333},"end":{"line":89,"column":12,"offset":2339},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":2328},"end":{"line":89,"column":12,"offset":2339},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Bug: Autoremove old images/video within Docker Containers. ","position":{"start":{"line":91,"column":3,"offset":2343},"end":{"line":91,"column":62,"offset":2402},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/104","children":[{"type":"text","value":"#104","position":{"start":{"line":91,"column":63,"offset":2403},"end":{"line":91,"column":67,"offset":2407},"indent":[]}}],"position":{"start":{"line":91,"column":62,"offset":2402},"end":{"line":91,"column":115,"offset":2455},"indent":[]}}],"position":{"start":{"line":91,"column":3,"offset":2343},"end":{"line":91,"column":115,"offset":2455},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":2341},"end":{"line":91,"column":115,"offset":2455},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":2341},"end":{"line":91,"column":115,"offset":2455},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.5.0","position":{"start":{"line":93,"column":5,"offset":2461},"end":{"line":93,"column":10,"offset":2466},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":2457},"end":{"line":93,"column":10,"offset":2466},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":95,"column":6,"offset":2473},"end":{"line":95,"column":9,"offset":2476},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":2468},"end":{"line":95,"column":9,"offset":2476},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added Chinese and Italian language.","position":{"start":{"line":97,"column":3,"offset":2480},"end":{"line":97,"column":38,"offset":2515},"indent":[]}}],"position":{"start":{"line":97,"column":3,"offset":2480},"end":{"line":97,"column":38,"offset":2515},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":2478},"end":{"line":97,"column":38,"offset":2515},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Resolved issue with INSTALLED=true.","position":{"start":{"line":98,"column":3,"offset":2518},"end":{"line":98,"column":38,"offset":2553},"indent":[]}}],"position":{"start":{"line":98,"column":3,"offset":2518},"end":{"line":98,"column":38,"offset":2553},"indent":[]}}],"position":{"start":{"line":98,"column":1,"offset":2516},"end":{"line":98,"column":38,"offset":2553},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Make latest_sequence available with basic auth. ","position":{"start":{"line":99,"column":3,"offset":2556},"end":{"line":99,"column":52,"offset":2605},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/99","children":[{"type":"text","value":"#99","position":{"start":{"line":99,"column":53,"offset":2606},"end":{"line":99,"column":56,"offset":2609},"indent":[]}}],"position":{"start":{"line":99,"column":52,"offset":2605},"end":{"line":99,"column":103,"offset":2656},"indent":[]}}],"position":{"start":{"line":99,"column":3,"offset":2556},"end":{"line":99,"column":103,"offset":2656},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":2554},"end":{"line":99,"column":103,"offset":2656},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":2478},"end":{"line":99,"column":103,"offset":2656},"indent":[1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":101,"column":6,"offset":2663},"end":{"line":101,"column":15,"offset":2672},"indent":[]}}],"position":{"start":{"line":101,"column":1,"offset":2658},"end":{"line":101,"column":15,"offset":2672},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Provide an IO service for publishing events to MQTT. ","position":{"start":{"line":103,"column":3,"offset":2676},"end":{"line":103,"column":56,"offset":2729},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/89","children":[{"type":"text","value":"#89","position":{"start":{"line":103,"column":57,"offset":2730},"end":{"line":103,"column":60,"offset":2733},"indent":[]}}],"position":{"start":{"line":103,"column":56,"offset":2729},"end":{"line":103,"column":113,"offset":2786},"indent":[]}}],"position":{"start":{"line":103,"column":3,"offset":2676},"end":{"line":103,"column":113,"offset":2786},"indent":[]}}],"position":{"start":{"line":103,"column":1,"offset":2674},"end":{"line":103,"column":113,"offset":2786},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Optimize recording with H264_OMX. ","position":{"start":{"line":104,"column":3,"offset":2789},"end":{"line":104,"column":37,"offset":2823},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/83","children":[{"type":"text","value":"#83","position":{"start":{"line":104,"column":38,"offset":2824},"end":{"line":104,"column":41,"offset":2827},"indent":[]}}],"position":{"start":{"line":104,"column":37,"offset":2823},"end":{"line":104,"column":94,"offset":2880},"indent":[]}}],"position":{"start":{"line":104,"column":3,"offset":2789},"end":{"line":104,"column":94,"offset":2880},"indent":[]}}],"position":{"start":{"line":104,"column":1,"offset":2787},"end":{"line":104,"column":94,"offset":2880},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Implement throttler for Io detections. ","position":{"start":{"line":105,"column":3,"offset":2883},"end":{"line":105,"column":42,"offset":2922},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/96","children":[{"type":"text","value":"#96","position":{"start":{"line":105,"column":43,"offset":2923},"end":{"line":105,"column":46,"offset":2926},"indent":[]}}],"position":{"start":{"line":105,"column":42,"offset":2922},"end":{"line":105,"column":99,"offset":2979},"indent":[]}}],"position":{"start":{"line":105,"column":3,"offset":2883},"end":{"line":105,"column":99,"offset":2979},"indent":[]}}],"position":{"start":{"line":105,"column":1,"offset":2881},"end":{"line":105,"column":99,"offset":2979},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"SSL version 1.0.0 is no longer accessible in Raspbian. ","position":{"start":{"line":106,"column":3,"offset":2982},"end":{"line":106,"column":58,"offset":3037},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/109","children":[{"type":"text","value":"#109","position":{"start":{"line":106,"column":59,"offset":3038},"end":{"line":106,"column":63,"offset":3042},"indent":[]}}],"position":{"start":{"line":106,"column":58,"offset":3037},"end":{"line":106,"column":117,"offset":3096},"indent":[]}}],"position":{"start":{"line":106,"column":3,"offset":2982},"end":{"line":106,"column":117,"offset":3096},"indent":[]}}],"position":{"start":{"line":106,"column":1,"offset":2980},"end":{"line":106,"column":117,"offset":3096},"indent":[]}}],"position":{"start":{"line":103,"column":1,"offset":2674},"end":{"line":106,"column":117,"offset":3096},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.4.2","position":{"start":{"line":108,"column":5,"offset":3102},"end":{"line":108,"column":10,"offset":3107},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":3098},"end":{"line":108,"column":10,"offset":3107},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":110,"column":6,"offset":3114},"end":{"line":110,"column":9,"offset":3117},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":3109},"end":{"line":110,"column":9,"offset":3117},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Typo in french translation, causes the web interface crash.","position":{"start":{"line":112,"column":3,"offset":3121},"end":{"line":112,"column":62,"offset":3180},"indent":[]}}],"position":{"start":{"line":112,"column":3,"offset":3121},"end":{"line":112,"column":62,"offset":3180},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":3119},"end":{"line":112,"column":62,"offset":3180},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":3119},"end":{"line":112,"column":62,"offset":3180},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":114,"column":6,"offset":3187},"end":{"line":114,"column":15,"offset":3196},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":3182},"end":{"line":114,"column":15,"offset":3196},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Resolved major bug in livestream: memory leak in stream class. ","position":{"start":{"line":116,"column":3,"offset":3200},"end":{"line":116,"column":66,"offset":3263},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/94","children":[{"type":"text","value":"#94","position":{"start":{"line":116,"column":67,"offset":3264},"end":{"line":116,"column":70,"offset":3267},"indent":[]}}],"position":{"start":{"line":116,"column":66,"offset":3263},"end":{"line":116,"column":123,"offset":3320},"indent":[]}}],"position":{"start":{"line":116,"column":3,"offset":3200},"end":{"line":116,"column":123,"offset":3320},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":3198},"end":{"line":116,"column":123,"offset":3320},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Capture health verification: check if the chosen capture device is still grabbing (and didn't stalled).","position":{"start":{"line":117,"column":3,"offset":3323},"end":{"line":117,"column":106,"offset":3426},"indent":[]}}],"position":{"start":{"line":117,"column":3,"offset":3323},"end":{"line":117,"column":106,"offset":3426},"indent":[]}}],"position":{"start":{"line":117,"column":1,"offset":3321},"end":{"line":117,"column":106,"offset":3426},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Extra logging when recording with raspberry pi camera.","position":{"start":{"line":118,"column":3,"offset":3429},"end":{"line":118,"column":57,"offset":3483},"indent":[]}}],"position":{"start":{"line":118,"column":3,"offset":3429},"end":{"line":118,"column":57,"offset":3483},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":3427},"end":{"line":118,"column":57,"offset":3483},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Make sure the cloud upload is functioning properly, after an upload it's verified if the files really exist in the cloud.","position":{"start":{"line":119,"column":3,"offset":3486},"end":{"line":119,"column":124,"offset":3607},"indent":[]}}],"position":{"start":{"line":119,"column":3,"offset":3486},"end":{"line":119,"column":124,"offset":3607},"indent":[]}}],"position":{"start":{"line":119,"column":1,"offset":3484},"end":{"line":119,"column":124,"offset":3607},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":3198},"end":{"line":119,"column":124,"offset":3607},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.4.1","position":{"start":{"line":121,"column":5,"offset":3613},"end":{"line":121,"column":10,"offset":3618},"indent":[]}}],"position":{"start":{"line":121,"column":1,"offset":3609},"end":{"line":121,"column":10,"offset":3618},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":123,"column":6,"offset":3625},"end":{"line":123,"column":9,"offset":3628},"indent":[]}}],"position":{"start":{"line":123,"column":1,"offset":3620},"end":{"line":123,"column":9,"offset":3628},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Show warning when system is disabled. ","position":{"start":{"line":125,"column":3,"offset":3632},"end":{"line":125,"column":41,"offset":3670},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/88","children":[{"type":"text","value":"#88","position":{"start":{"line":125,"column":42,"offset":3671},"end":{"line":125,"column":45,"offset":3674},"indent":[]}}],"position":{"start":{"line":125,"column":41,"offset":3670},"end":{"line":125,"column":92,"offset":3721},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":125,"column":92,"offset":3721},"end":{"line":125,"column":93,"offset":3722},"indent":[]}}],"position":{"start":{"line":125,"column":3,"offset":3632},"end":{"line":125,"column":93,"offset":3722},"indent":[]}}],"position":{"start":{"line":125,"column":1,"offset":3630},"end":{"line":125,"column":93,"offset":3722},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Hull selector in basic view not always working.","position":{"start":{"line":126,"column":3,"offset":3725},"end":{"line":126,"column":50,"offset":3772},"indent":[]}}],"position":{"start":{"line":126,"column":3,"offset":3725},"end":{"line":126,"column":50,"offset":3772},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":3723},"end":{"line":126,"column":50,"offset":3772},"indent":[]}}],"position":{"start":{"line":125,"column":1,"offset":3630},"end":{"line":126,"column":50,"offset":3772},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.4.0","position":{"start":{"line":128,"column":5,"offset":3778},"end":{"line":128,"column":10,"offset":3783},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":3774},"end":{"line":128,"column":10,"offset":3783},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Ecosystem","position":{"start":{"line":130,"column":6,"offset":3790},"end":{"line":130,"column":15,"offset":3799},"indent":[]}}],"position":{"start":{"line":130,"column":1,"offset":3785},"end":{"line":130,"column":15,"offset":3799},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Enable/Disable force network mode.","position":{"start":{"line":132,"column":3,"offset":3803},"end":{"line":132,"column":37,"offset":3837},"indent":[]}}],"position":{"start":{"line":132,"column":3,"offset":3803},"end":{"line":132,"column":37,"offset":3837},"indent":[]}}],"position":{"start":{"line":132,"column":1,"offset":3801},"end":{"line":132,"column":37,"offset":3837},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Enable/Disable auto removal media.","position":{"start":{"line":133,"column":3,"offset":3840},"end":{"line":133,"column":37,"offset":3874},"indent":[]}}],"position":{"start":{"line":133,"column":3,"offset":3840},"end":{"line":133,"column":37,"offset":3874},"indent":[]}}],"position":{"start":{"line":133,"column":1,"offset":3838},"end":{"line":133,"column":37,"offset":3874},"indent":[]}}],"position":{"start":{"line":132,"column":1,"offset":3801},"end":{"line":133,"column":37,"offset":3874},"indent":[1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":135,"column":6,"offset":3881},"end":{"line":135,"column":9,"offset":3884},"indent":[]}}],"position":{"start":{"line":135,"column":1,"offset":3876},"end":{"line":135,"column":9,"offset":3884},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Upgrade from Laravel 4.2 to Laravel 5.4 ","position":{"start":{"line":137,"column":3,"offset":3888},"end":{"line":137,"column":43,"offset":3928},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/70","children":[{"type":"text","value":"#70","position":{"start":{"line":137,"column":44,"offset":3929},"end":{"line":137,"column":47,"offset":3932},"indent":[]}}],"position":{"start":{"line":137,"column":43,"offset":3928},"end":{"line":137,"column":94,"offset":3979},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":137,"column":94,"offset":3979},"end":{"line":137,"column":95,"offset":3980},"indent":[]}}],"position":{"start":{"line":137,"column":3,"offset":3888},"end":{"line":137,"column":95,"offset":3980},"indent":[]}}],"position":{"start":{"line":137,"column":1,"offset":3886},"end":{"line":137,"column":95,"offset":3980},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fix bug with heatmap radius slider ","position":{"start":{"line":138,"column":3,"offset":3983},"end":{"line":138,"column":38,"offset":4018},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/84","children":[{"type":"text","value":"#84","position":{"start":{"line":138,"column":39,"offset":4019},"end":{"line":138,"column":42,"offset":4022},"indent":[]}}],"position":{"start":{"line":138,"column":38,"offset":4018},"end":{"line":138,"column":89,"offset":4069},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":138,"column":89,"offset":4069},"end":{"line":138,"column":90,"offset":4070},"indent":[]}}],"position":{"start":{"line":138,"column":3,"offset":3983},"end":{"line":138,"column":90,"offset":4070},"indent":[]}}],"position":{"start":{"line":138,"column":1,"offset":3981},"end":{"line":138,"column":90,"offset":4070},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Design tweaks toggle button (remove outline).","position":{"start":{"line":139,"column":3,"offset":4073},"end":{"line":139,"column":48,"offset":4118},"indent":[]}}],"position":{"start":{"line":139,"column":3,"offset":4073},"end":{"line":139,"column":48,"offset":4118},"indent":[]}}],"position":{"start":{"line":139,"column":1,"offset":4071},"end":{"line":139,"column":48,"offset":4118},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Disabled possibility to timestamp video when using hardware acceleration.","position":{"start":{"line":140,"column":3,"offset":4121},"end":{"line":140,"column":76,"offset":4194},"indent":[]}}],"position":{"start":{"line":140,"column":3,"offset":4121},"end":{"line":140,"column":76,"offset":4194},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":4119},"end":{"line":140,"column":76,"offset":4194},"indent":[]}}],"position":{"start":{"line":137,"column":1,"offset":3886},"end":{"line":140,"column":76,"offset":4194},"indent":[1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Docker","position":{"start":{"line":142,"column":6,"offset":4201},"end":{"line":142,"column":12,"offset":4207},"indent":[]}}],"position":{"start":{"line":142,"column":1,"offset":4196},"end":{"line":142,"column":12,"offset":4207},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fix SSL support ","position":{"start":{"line":144,"column":3,"offset":4211},"end":{"line":144,"column":19,"offset":4227},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker/issues/4","children":[{"type":"text","value":"#4","position":{"start":{"line":144,"column":20,"offset":4228},"end":{"line":144,"column":22,"offset":4230},"indent":[]}}],"position":{"start":{"line":144,"column":19,"offset":4227},"end":{"line":144,"column":71,"offset":4279},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":144,"column":71,"offset":4279},"end":{"line":144,"column":72,"offset":4280},"indent":[]}}],"position":{"start":{"line":144,"column":3,"offset":4211},"end":{"line":144,"column":72,"offset":4280},"indent":[]}}],"position":{"start":{"line":144,"column":1,"offset":4209},"end":{"line":144,"column":72,"offset":4280},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Auto removal if disk is full.","position":{"start":{"line":145,"column":3,"offset":4283},"end":{"line":145,"column":32,"offset":4312},"indent":[]}}],"position":{"start":{"line":145,"column":3,"offset":4283},"end":{"line":145,"column":32,"offset":4312},"indent":[]}}],"position":{"start":{"line":145,"column":1,"offset":4281},"end":{"line":145,"column":32,"offset":4312},"indent":[]}}],"position":{"start":{"line":144,"column":1,"offset":4209},"end":{"line":145,"column":32,"offset":4312},"indent":[1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":147,"column":6,"offset":4319},"end":{"line":147,"column":15,"offset":4328},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":4314},"end":{"line":147,"column":15,"offset":4328},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"OpenMAX IL hardware encoding for Raspberry Pi camera. ","position":{"start":{"line":149,"column":3,"offset":4332},"end":{"line":149,"column":57,"offset":4386},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/83","children":[{"type":"text","value":"#83","position":{"start":{"line":149,"column":58,"offset":4387},"end":{"line":149,"column":61,"offset":4390},"indent":[]}}],"position":{"start":{"line":149,"column":57,"offset":4386},"end":{"line":149,"column":114,"offset":4443},"indent":[]}}],"position":{"start":{"line":149,"column":3,"offset":4332},"end":{"line":149,"column":114,"offset":4443},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Optimized live streaming.","position":{"start":{"line":150,"column":5,"offset":4448},"end":{"line":150,"column":30,"offset":4473},"indent":[]}}],"position":{"start":{"line":150,"column":5,"offset":4448},"end":{"line":150,"column":30,"offset":4473},"indent":[]}}],"position":{"start":{"line":150,"column":3,"offset":4446},"end":{"line":150,"column":30,"offset":4473},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Optimized h264 recording.","position":{"start":{"line":151,"column":5,"offset":4478},"end":{"line":151,"column":30,"offset":4503},"indent":[]}}],"position":{"start":{"line":151,"column":5,"offset":4478},"end":{"line":151,"column":30,"offset":4503},"indent":[]}}],"position":{"start":{"line":151,"column":3,"offset":4476},"end":{"line":151,"column":30,"offset":4503},"indent":[]}}],"position":{"start":{"line":150,"column":3,"offset":4446},"end":{"line":151,"column":30,"offset":4503},"indent":[3]}}],"position":{"start":{"line":149,"column":1,"offset":4330},"end":{"line":151,"column":30,"offset":4503},"indent":[1,1]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Basic authentication for live streaming (username and password). ","position":{"start":{"line":152,"column":3,"offset":4506},"end":{"line":152,"column":68,"offset":4571},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/80","children":[{"type":"text","value":"#80","position":{"start":{"line":152,"column":69,"offset":4572},"end":{"line":152,"column":72,"offset":4575},"indent":[]}}],"position":{"start":{"line":152,"column":68,"offset":4571},"end":{"line":152,"column":125,"offset":4628},"indent":[]}}],"position":{"start":{"line":152,"column":3,"offset":4506},"end":{"line":152,"column":125,"offset":4628},"indent":[]}}],"position":{"start":{"line":152,"column":1,"offset":4504},"end":{"line":152,"column":125,"offset":4628},"indent":[]}}],"position":{"start":{"line":149,"column":1,"offset":4330},"end":{"line":152,"column":125,"offset":4628},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.3.1","position":{"start":{"line":154,"column":5,"offset":4634},"end":{"line":154,"column":10,"offset":4639},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":4630},"end":{"line":154,"column":10,"offset":4639},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":156,"column":6,"offset":4646},"end":{"line":156,"column":15,"offset":4655},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":4641},"end":{"line":156,"column":15,"offset":4655},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Update for kerberos.cloud: pushing content-type.","position":{"start":{"line":158,"column":3,"offset":4659},"end":{"line":158,"column":51,"offset":4707},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":4659},"end":{"line":158,"column":51,"offset":4707},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":4657},"end":{"line":158,"column":51,"offset":4707},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Change default configurations.","position":{"start":{"line":159,"column":3,"offset":4710},"end":{"line":159,"column":33,"offset":4740},"indent":[]}}],"position":{"start":{"line":159,"column":3,"offset":4710},"end":{"line":159,"column":33,"offset":4740},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":4708},"end":{"line":159,"column":33,"offset":4740},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":4657},"end":{"line":159,"column":33,"offset":4740},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.3.0","position":{"start":{"line":161,"column":5,"offset":4746},"end":{"line":161,"column":10,"offset":4751},"indent":[]}}],"position":{"start":{"line":161,"column":1,"offset":4742},"end":{"line":161,"column":10,"offset":4751},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Ecosystem","position":{"start":{"line":163,"column":6,"offset":4758},"end":{"line":163,"column":15,"offset":4767},"indent":[]}}],"position":{"start":{"line":163,"column":1,"offset":4753},"end":{"line":163,"column":15,"offset":4767},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support for Raspberry Pi Zero W. ","position":{"start":{"line":165,"column":3,"offset":4771},"end":{"line":165,"column":36,"offset":4804},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/issues/8","children":[{"type":"text","value":"#8","position":{"start":{"line":165,"column":37,"offset":4805},"end":{"line":165,"column":39,"offset":4807},"indent":[]}}],"position":{"start":{"line":165,"column":36,"offset":4804},"end":{"line":165,"column":86,"offset":4854},"indent":[]}}],"position":{"start":{"line":165,"column":3,"offset":4771},"end":{"line":165,"column":86,"offset":4854},"indent":[]}}],"position":{"start":{"line":165,"column":1,"offset":4769},"end":{"line":165,"column":86,"offset":4854},"indent":[]}}],"position":{"start":{"line":165,"column":1,"offset":4769},"end":{"line":165,"column":86,"offset":4854},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.2.1","position":{"start":{"line":167,"column":5,"offset":4860},"end":{"line":167,"column":10,"offset":4865},"indent":[]}}],"position":{"start":{"line":167,"column":1,"offset":4856},"end":{"line":167,"column":10,"offset":4865},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Ecosystem","position":{"start":{"line":169,"column":6,"offset":4872},"end":{"line":169,"column":15,"offset":4881},"indent":[]}}],"position":{"start":{"line":169,"column":1,"offset":4867},"end":{"line":169,"column":15,"offset":4881},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Upgraded FFmpeg and libx264 on KiOS.","position":{"start":{"line":171,"column":3,"offset":4885},"end":{"line":171,"column":39,"offset":4921},"indent":[]}}],"position":{"start":{"line":171,"column":3,"offset":4885},"end":{"line":171,"column":39,"offset":4921},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":4883},"end":{"line":171,"column":39,"offset":4921},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":4883},"end":{"line":171,"column":39,"offset":4921},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":173,"column":6,"offset":4928},"end":{"line":173,"column":9,"offset":4931},"indent":[]}}],"position":{"start":{"line":173,"column":1,"offset":4923},"end":{"line":173,"column":9,"offset":4931},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Add Bulgarian translation. ","position":{"start":{"line":175,"column":3,"offset":4935},"end":{"line":175,"column":30,"offset":4962},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/pull/81","children":[{"type":"text","value":"#81","position":{"start":{"line":175,"column":31,"offset":4963},"end":{"line":175,"column":34,"offset":4966},"indent":[]}}],"position":{"start":{"line":175,"column":30,"offset":4962},"end":{"line":175,"column":79,"offset":5011},"indent":[]}}],"position":{"start":{"line":175,"column":3,"offset":4935},"end":{"line":175,"column":79,"offset":5011},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":4933},"end":{"line":175,"column":79,"offset":5011},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":4933},"end":{"line":175,"column":79,"offset":5011},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":177,"column":6,"offset":5018},"end":{"line":177,"column":15,"offset":5027},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":5013},"end":{"line":177,"column":15,"offset":5027},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Bug: IoVideo crashes due to a memory leak. ","position":{"start":{"line":179,"column":3,"offset":5031},"end":{"line":179,"column":46,"offset":5074},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/70","children":[{"type":"text","value":"#70","position":{"start":{"line":179,"column":47,"offset":5075},"end":{"line":179,"column":50,"offset":5078},"indent":[]}}],"position":{"start":{"line":179,"column":46,"offset":5074},"end":{"line":179,"column":103,"offset":5131},"indent":[]}}],"position":{"start":{"line":179,"column":3,"offset":5031},"end":{"line":179,"column":103,"offset":5131},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":5029},"end":{"line":179,"column":103,"offset":5131},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":5029},"end":{"line":179,"column":103,"offset":5131},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.2.0","position":{"start":{"line":181,"column":5,"offset":5137},"end":{"line":181,"column":10,"offset":5142},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":5133},"end":{"line":181,"column":10,"offset":5142},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Ecosystem","position":{"start":{"line":183,"column":6,"offset":5149},"end":{"line":183,"column":15,"offset":5158},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":5144},"end":{"line":183,"column":15,"offset":5158},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added support for Armbian.","position":{"start":{"line":185,"column":3,"offset":5162},"end":{"line":185,"column":29,"offset":5188},"indent":[]}}],"position":{"start":{"line":185,"column":3,"offset":5162},"end":{"line":185,"column":29,"offset":5188},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":5160},"end":{"line":185,"column":29,"offset":5188},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Raspbian: Async requests causes session corruption. ","position":{"start":{"line":186,"column":3,"offset":5191},"end":{"line":186,"column":55,"offset":5243},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/78","children":[{"type":"text","value":"#78","position":{"start":{"line":186,"column":56,"offset":5244},"end":{"line":186,"column":59,"offset":5247},"indent":[]}}],"position":{"start":{"line":186,"column":55,"offset":5243},"end":{"line":186,"column":106,"offset":5294},"indent":[]}}],"position":{"start":{"line":186,"column":3,"offset":5191},"end":{"line":186,"column":106,"offset":5294},"indent":[]}}],"position":{"start":{"line":186,"column":1,"offset":5189},"end":{"line":186,"column":106,"offset":5294},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":5160},"end":{"line":186,"column":106,"offset":5294},"indent":[1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":188,"column":6,"offset":5301},"end":{"line":188,"column":9,"offset":5304},"indent":[]}}],"position":{"start":{"line":188,"column":1,"offset":5296},"end":{"line":188,"column":9,"offset":5304},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Bug: Issue format instance name. ","position":{"start":{"line":190,"column":3,"offset":5308},"end":{"line":190,"column":36,"offset":5341},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/57","children":[{"type":"text","value":"#57","position":{"start":{"line":190,"column":37,"offset":5342},"end":{"line":190,"column":40,"offset":5345},"indent":[]}}],"position":{"start":{"line":190,"column":36,"offset":5341},"end":{"line":190,"column":87,"offset":5392},"indent":[]}}],"position":{"start":{"line":190,"column":3,"offset":5308},"end":{"line":190,"column":87,"offset":5392},"indent":[]}}],"position":{"start":{"line":190,"column":1,"offset":5306},"end":{"line":190,"column":87,"offset":5392},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Redesign settings page (better UX). ","position":{"start":{"line":191,"column":3,"offset":5395},"end":{"line":191,"column":39,"offset":5431},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/39","children":[{"type":"text","value":"#39","position":{"start":{"line":191,"column":40,"offset":5432},"end":{"line":191,"column":43,"offset":5435},"indent":[]}}],"position":{"start":{"line":191,"column":39,"offset":5431},"end":{"line":191,"column":90,"offset":5482},"indent":[]}}],"position":{"start":{"line":191,"column":3,"offset":5395},"end":{"line":191,"column":90,"offset":5482},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":5393},"end":{"line":191,"column":90,"offset":5482},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Possibility to edit password through web interface. ","position":{"start":{"line":192,"column":3,"offset":5485},"end":{"line":192,"column":55,"offset":5537},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/63","children":[{"type":"text","value":"#63","position":{"start":{"line":192,"column":56,"offset":5538},"end":{"line":192,"column":59,"offset":5541},"indent":[]}}],"position":{"start":{"line":192,"column":55,"offset":5537},"end":{"line":192,"column":106,"offset":5588},"indent":[]}}],"position":{"start":{"line":192,"column":3,"offset":5485},"end":{"line":192,"column":106,"offset":5588},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":5483},"end":{"line":192,"column":106,"offset":5588},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support for viewing videos.","position":{"start":{"line":193,"column":3,"offset":5591},"end":{"line":193,"column":30,"offset":5618},"indent":[]}}],"position":{"start":{"line":193,"column":3,"offset":5591},"end":{"line":193,"column":30,"offset":5618},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":5589},"end":{"line":193,"column":30,"offset":5618},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Update radius of heatmap.","position":{"start":{"line":194,"column":3,"offset":5621},"end":{"line":194,"column":28,"offset":5646},"indent":[]}}],"position":{"start":{"line":194,"column":3,"offset":5621},"end":{"line":194,"column":28,"offset":5646},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":5619},"end":{"line":194,"column":28,"offset":5646},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"PHP7 support. ","position":{"start":{"line":195,"column":3,"offset":5649},"end":{"line":195,"column":17,"offset":5663},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/60","children":[{"type":"text","value":"#60","position":{"start":{"line":195,"column":18,"offset":5664},"end":{"line":195,"column":21,"offset":5667},"indent":[]}}],"position":{"start":{"line":195,"column":17,"offset":5663},"end":{"line":195,"column":68,"offset":5714},"indent":[]}}],"position":{"start":{"line":195,"column":3,"offset":5649},"end":{"line":195,"column":68,"offset":5714},"indent":[]}}],"position":{"start":{"line":195,"column":1,"offset":5647},"end":{"line":195,"column":68,"offset":5714},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Welcome/installation page. ","position":{"start":{"line":196,"column":3,"offset":5717},"end":{"line":196,"column":30,"offset":5744},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/60","children":[{"type":"text","value":"#60","position":{"start":{"line":196,"column":31,"offset":5745},"end":{"line":196,"column":34,"offset":5748},"indent":[]}}],"position":{"start":{"line":196,"column":30,"offset":5744},"end":{"line":196,"column":81,"offset":5795},"indent":[]}}],"position":{"start":{"line":196,"column":3,"offset":5717},"end":{"line":196,"column":81,"offset":5795},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":5715},"end":{"line":196,"column":81,"offset":5795},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Translation updated. ","position":{"start":{"line":197,"column":3,"offset":5798},"end":{"line":197,"column":24,"offset":5819},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/74","children":[{"type":"text","value":"#74","position":{"start":{"line":197,"column":25,"offset":5820},"end":{"line":197,"column":28,"offset":5823},"indent":[]}}],"position":{"start":{"line":197,"column":24,"offset":5819},"end":{"line":197,"column":75,"offset":5870},"indent":[]}}],"position":{"start":{"line":197,"column":3,"offset":5798},"end":{"line":197,"column":75,"offset":5870},"indent":[]}}],"position":{"start":{"line":197,"column":1,"offset":5796},"end":{"line":197,"column":75,"offset":5870},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Privacy mode. ","position":{"start":{"line":198,"column":3,"offset":5873},"end":{"line":198,"column":17,"offset":5887},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/54","children":[{"type":"text","value":"#54","position":{"start":{"line":198,"column":18,"offset":5888},"end":{"line":198,"column":21,"offset":5891},"indent":[]}}],"position":{"start":{"line":198,"column":17,"offset":5887},"end":{"line":198,"column":68,"offset":5938},"indent":[]}}],"position":{"start":{"line":198,"column":3,"offset":5873},"end":{"line":198,"column":68,"offset":5938},"indent":[]}}],"position":{"start":{"line":198,"column":1,"offset":5871},"end":{"line":198,"column":68,"offset":5938},"indent":[]}}],"position":{"start":{"line":190,"column":1,"offset":5306},"end":{"line":198,"column":68,"offset":5938},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":200,"column":6,"offset":5945},"end":{"line":200,"column":15,"offset":5954},"indent":[]}}],"position":{"start":{"line":200,"column":1,"offset":5940},"end":{"line":200,"column":15,"offset":5954},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Output as video file. ","position":{"start":{"line":202,"column":3,"offset":5958},"end":{"line":202,"column":25,"offset":5980},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/60","children":[{"type":"text","value":"#60","position":{"start":{"line":202,"column":26,"offset":5981},"end":{"line":202,"column":29,"offset":5984},"indent":[]}}],"position":{"start":{"line":202,"column":25,"offset":5980},"end":{"line":202,"column":82,"offset":6037},"indent":[]}}],"position":{"start":{"line":202,"column":3,"offset":5958},"end":{"line":202,"column":82,"offset":6037},"indent":[]}}],"position":{"start":{"line":202,"column":1,"offset":5956},"end":{"line":202,"column":82,"offset":6037},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Bug: System hangs when a wrong IP camera url was defined. ","position":{"start":{"line":203,"column":3,"offset":6040},"end":{"line":203,"column":61,"offset":6098},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/48","children":[{"type":"text","value":"#48","position":{"start":{"line":203,"column":62,"offset":6099},"end":{"line":203,"column":65,"offset":6102},"indent":[]}}],"position":{"start":{"line":203,"column":61,"offset":6098},"end":{"line":203,"column":118,"offset":6155},"indent":[]}}],"position":{"start":{"line":203,"column":3,"offset":6040},"end":{"line":203,"column":118,"offset":6155},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":6038},"end":{"line":203,"column":118,"offset":6155},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Run arbitrary script/program. ","position":{"start":{"line":204,"column":3,"offset":6158},"end":{"line":204,"column":33,"offset":6188},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/31","children":[{"type":"text","value":"#31","position":{"start":{"line":204,"column":34,"offset":6189},"end":{"line":204,"column":37,"offset":6192},"indent":[]}}],"position":{"start":{"line":204,"column":33,"offset":6188},"end":{"line":204,"column":90,"offset":6245},"indent":[]}}],"position":{"start":{"line":204,"column":3,"offset":6158},"end":{"line":204,"column":90,"offset":6245},"indent":[]}}],"position":{"start":{"line":204,"column":1,"offset":6156},"end":{"line":204,"column":90,"offset":6245},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Bug: Weird colors from RPi Camera. ","position":{"start":{"line":205,"column":3,"offset":6248},"end":{"line":205,"column":38,"offset":6283},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/64","children":[{"type":"text","value":"#64","position":{"start":{"line":205,"column":39,"offset":6284},"end":{"line":205,"column":42,"offset":6287},"indent":[]}}],"position":{"start":{"line":205,"column":38,"offset":6283},"end":{"line":205,"column":95,"offset":6340},"indent":[]}}],"position":{"start":{"line":205,"column":3,"offset":6248},"end":{"line":205,"column":95,"offset":6340},"indent":[]}}],"position":{"start":{"line":205,"column":1,"offset":6246},"end":{"line":205,"column":95,"offset":6340},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Upgrade to OpenCV 3.2.0.","position":{"start":{"line":206,"column":3,"offset":6343},"end":{"line":206,"column":27,"offset":6367},"indent":[]}}],"position":{"start":{"line":206,"column":3,"offset":6343},"end":{"line":206,"column":27,"offset":6367},"indent":[]}}],"position":{"start":{"line":206,"column":1,"offset":6341},"end":{"line":206,"column":27,"offset":6367},"indent":[]}}],"position":{"start":{"line":202,"column":1,"offset":5956},"end":{"line":206,"column":27,"offset":6367},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.1.0","position":{"start":{"line":208,"column":5,"offset":6373},"end":{"line":208,"column":10,"offset":6378},"indent":[]}}],"position":{"start":{"line":208,"column":1,"offset":6369},"end":{"line":208,"column":10,"offset":6378},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":210,"column":6,"offset":6385},"end":{"line":210,"column":9,"offset":6388},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":6380},"end":{"line":210,"column":9,"offset":6388},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added PhotoSwipe for image overview (easier to browse through images). ","position":{"start":{"line":212,"column":3,"offset":6392},"end":{"line":212,"column":74,"offset":6463},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/45","children":[{"type":"text","value":"#45","position":{"start":{"line":212,"column":75,"offset":6464},"end":{"line":212,"column":78,"offset":6467},"indent":[]}}],"position":{"start":{"line":212,"column":74,"offset":6463},"end":{"line":212,"column":125,"offset":6514},"indent":[]}}],"position":{"start":{"line":212,"column":3,"offset":6392},"end":{"line":212,"column":125,"offset":6514},"indent":[]}}],"position":{"start":{"line":212,"column":1,"offset":6390},"end":{"line":212,"column":125,"offset":6514},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added reboot and shutdown commands. ","position":{"start":{"line":213,"column":3,"offset":6517},"end":{"line":213,"column":39,"offset":6553},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/46","children":[{"type":"text","value":"#46","position":{"start":{"line":213,"column":40,"offset":6554},"end":{"line":213,"column":43,"offset":6557},"indent":[]}}],"position":{"start":{"line":213,"column":39,"offset":6553},"end":{"line":213,"column":90,"offset":6604},"indent":[]}}],"position":{"start":{"line":213,"column":3,"offset":6517},"end":{"line":213,"column":90,"offset":6604},"indent":[]}}],"position":{"start":{"line":213,"column":1,"offset":6515},"end":{"line":213,"column":90,"offset":6604},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added logging view to system page. ","position":{"start":{"line":214,"column":3,"offset":6607},"end":{"line":214,"column":38,"offset":6642},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/33","children":[{"type":"text","value":"#33","position":{"start":{"line":214,"column":39,"offset":6643},"end":{"line":214,"column":42,"offset":6646},"indent":[]}}],"position":{"start":{"line":214,"column":38,"offset":6642},"end":{"line":214,"column":89,"offset":6693},"indent":[]}}],"position":{"start":{"line":214,"column":3,"offset":6607},"end":{"line":214,"column":89,"offset":6693},"indent":[]}}],"position":{"start":{"line":214,"column":1,"offset":6605},"end":{"line":214,"column":89,"offset":6693},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added labels to check if machinery is running.","position":{"start":{"line":215,"column":3,"offset":6696},"end":{"line":215,"column":49,"offset":6742},"indent":[]}}],"position":{"start":{"line":215,"column":3,"offset":6696},"end":{"line":215,"column":49,"offset":6742},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":6694},"end":{"line":215,"column":49,"offset":6742},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added error handling if web interface isn’t working properly.","position":{"start":{"line":216,"column":3,"offset":6745},"end":{"line":216,"column":64,"offset":6806},"indent":[]}}],"position":{"start":{"line":216,"column":3,"offset":6745},"end":{"line":216,"column":64,"offset":6806},"indent":[]}}],"position":{"start":{"line":216,"column":1,"offset":6743},"end":{"line":216,"column":64,"offset":6806},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fixed Heatmap.js fail to load by ad-blocker. ","position":{"start":{"line":217,"column":3,"offset":6809},"end":{"line":217,"column":48,"offset":6854},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/42","children":[{"type":"text","value":"#42","position":{"start":{"line":217,"column":49,"offset":6855},"end":{"line":217,"column":52,"offset":6858},"indent":[]}}],"position":{"start":{"line":217,"column":48,"offset":6854},"end":{"line":217,"column":99,"offset":6905},"indent":[]}}],"position":{"start":{"line":217,"column":3,"offset":6809},"end":{"line":217,"column":99,"offset":6905},"indent":[]}}],"position":{"start":{"line":217,"column":1,"offset":6807},"end":{"line":217,"column":99,"offset":6905},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Show additional information on the dashboard (streaming is opening or not) there is no data available.","position":{"start":{"line":218,"column":3,"offset":6908},"end":{"line":218,"column":105,"offset":7010},"indent":[]}}],"position":{"start":{"line":218,"column":3,"offset":6908},"end":{"line":218,"column":105,"offset":7010},"indent":[]}}],"position":{"start":{"line":218,"column":1,"offset":6906},"end":{"line":218,"column":105,"offset":7010},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Settings page is now visible on mobile (+ changed icon).","position":{"start":{"line":219,"column":3,"offset":7013},"end":{"line":219,"column":59,"offset":7069},"indent":[]}}],"position":{"start":{"line":219,"column":3,"offset":7013},"end":{"line":219,"column":59,"offset":7069},"indent":[]}}],"position":{"start":{"line":219,"column":1,"offset":7011},"end":{"line":219,"column":59,"offset":7069},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fixed sorting of news articles.","position":{"start":{"line":220,"column":3,"offset":7072},"end":{"line":220,"column":34,"offset":7103},"indent":[]}}],"position":{"start":{"line":220,"column":3,"offset":7072},"end":{"line":220,"column":34,"offset":7103},"indent":[]}}],"position":{"start":{"line":220,"column":1,"offset":7070},"end":{"line":220,"column":34,"offset":7103},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Removed links to assets in the cloud (.css files).","position":{"start":{"line":221,"column":3,"offset":7106},"end":{"line":221,"column":53,"offset":7156},"indent":[]}}],"position":{"start":{"line":221,"column":3,"offset":7106},"end":{"line":221,"column":53,"offset":7156},"indent":[]}}],"position":{"start":{"line":221,"column":1,"offset":7104},"end":{"line":221,"column":53,"offset":7156},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Design: improved layout of login page, async loading of image view.","position":{"start":{"line":222,"column":3,"offset":7159},"end":{"line":222,"column":70,"offset":7226},"indent":[]}}],"position":{"start":{"line":222,"column":3,"offset":7159},"end":{"line":222,"column":70,"offset":7226},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":7157},"end":{"line":222,"column":70,"offset":7226},"indent":[]}}],"position":{"start":{"line":212,"column":1,"offset":6390},"end":{"line":222,"column":70,"offset":7226},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":224,"column":6,"offset":7233},"end":{"line":224,"column":15,"offset":7242},"indent":[]}}],"position":{"start":{"line":224,"column":1,"offset":7228},"end":{"line":224,"column":15,"offset":7242},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added configurable streaming port and quality. ","position":{"start":{"line":226,"column":3,"offset":7246},"end":{"line":226,"column":50,"offset":7293},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/41","children":[{"type":"text","value":"#41","position":{"start":{"line":226,"column":51,"offset":7294},"end":{"line":226,"column":54,"offset":7297},"indent":[]}}],"position":{"start":{"line":226,"column":50,"offset":7293},"end":{"line":226,"column":107,"offset":7350},"indent":[]}}],"position":{"start":{"line":226,"column":3,"offset":7246},"end":{"line":226,"column":107,"offset":7350},"indent":[]}}],"position":{"start":{"line":226,"column":1,"offset":7244},"end":{"line":226,"column":107,"offset":7350},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added new algorithm: Background subtraction.","position":{"start":{"line":227,"column":3,"offset":7353},"end":{"line":227,"column":47,"offset":7397},"indent":[]}}],"position":{"start":{"line":227,"column":3,"offset":7353},"end":{"line":227,"column":47,"offset":7397},"indent":[]}}],"position":{"start":{"line":227,"column":1,"offset":7351},"end":{"line":227,"column":47,"offset":7397},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added new heuristic: Counter (for object/people counting). ","position":{"start":{"line":228,"column":3,"offset":7400},"end":{"line":228,"column":62,"offset":7459},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/42","children":[{"type":"text","value":"#42","position":{"start":{"line":228,"column":63,"offset":7460},"end":{"line":228,"column":66,"offset":7463},"indent":[]}}],"position":{"start":{"line":228,"column":62,"offset":7459},"end":{"line":228,"column":119,"offset":7516},"indent":[]}}],"position":{"start":{"line":228,"column":3,"offset":7400},"end":{"line":228,"column":119,"offset":7516},"indent":[]}}],"position":{"start":{"line":228,"column":1,"offset":7398},"end":{"line":228,"column":119,"offset":7516},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added video capture, which can be used for debugging purposes (replay a video fragment).","position":{"start":{"line":229,"column":3,"offset":7519},"end":{"line":229,"column":91,"offset":7607},"indent":[]}}],"position":{"start":{"line":229,"column":3,"offset":7519},"end":{"line":229,"column":91,"offset":7607},"indent":[]}}],"position":{"start":{"line":229,"column":1,"offset":7517},"end":{"line":229,"column":91,"offset":7607},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"It’s now possible to mark the images with a timestamp. ","position":{"start":{"line":230,"column":3,"offset":7610},"end":{"line":230,"column":58,"offset":7665},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/36","children":[{"type":"text","value":"#36","position":{"start":{"line":230,"column":59,"offset":7666},"end":{"line":230,"column":62,"offset":7669},"indent":[]}}],"position":{"start":{"line":230,"column":58,"offset":7665},"end":{"line":230,"column":115,"offset":7722},"indent":[]}}],"position":{"start":{"line":230,"column":3,"offset":7610},"end":{"line":230,"column":115,"offset":7722},"indent":[]}}],"position":{"start":{"line":230,"column":1,"offset":7608},"end":{"line":230,"column":115,"offset":7722},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fixed blocking streaming socket. ","position":{"start":{"line":231,"column":3,"offset":7725},"end":{"line":231,"column":36,"offset":7758},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/39","children":[{"type":"text","value":"#39","position":{"start":{"line":231,"column":37,"offset":7759},"end":{"line":231,"column":40,"offset":7762},"indent":[]}}],"position":{"start":{"line":231,"column":36,"offset":7758},"end":{"line":231,"column":93,"offset":7815},"indent":[]}}],"position":{"start":{"line":231,"column":3,"offset":7725},"end":{"line":231,"column":93,"offset":7815},"indent":[]}}],"position":{"start":{"line":231,"column":1,"offset":7723},"end":{"line":231,"column":93,"offset":7815},"indent":[]}}],"position":{"start":{"line":226,"column":1,"offset":7244},"end":{"line":231,"column":93,"offset":7815},"indent":[1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Ecosystem","position":{"start":{"line":233,"column":6,"offset":7822},"end":{"line":233,"column":15,"offset":7831},"indent":[]}}],"position":{"start":{"line":233,"column":1,"offset":7817},"end":{"line":233,"column":15,"offset":7831},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fix removal images if disk is almost full (wrong path was defined).","position":{"start":{"line":235,"column":3,"offset":7835},"end":{"line":235,"column":70,"offset":7902},"indent":[]}}],"position":{"start":{"line":235,"column":3,"offset":7835},"end":{"line":235,"column":70,"offset":7902},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":7833},"end":{"line":235,"column":70,"offset":7902},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support for the Raspberry Pi Camera module v2.1. ","position":{"start":{"line":236,"column":3,"offset":7905},"end":{"line":236,"column":52,"offset":7954},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/issues/3","children":[{"type":"text","value":"#3","position":{"start":{"line":236,"column":53,"offset":7955},"end":{"line":236,"column":55,"offset":7957},"indent":[]}}],"position":{"start":{"line":236,"column":52,"offset":7954},"end":{"line":236,"column":102,"offset":8004},"indent":[]}}],"position":{"start":{"line":236,"column":3,"offset":7905},"end":{"line":236,"column":102,"offset":8004},"indent":[]}}],"position":{"start":{"line":236,"column":1,"offset":7903},"end":{"line":236,"column":102,"offset":8004},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support for the Raspberry Pi Zero; updated kernel to latest Raspbian. ","position":{"start":{"line":237,"column":3,"offset":8007},"end":{"line":237,"column":73,"offset":8077},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/issues/3","children":[{"type":"text","value":"#3","position":{"start":{"line":237,"column":74,"offset":8078},"end":{"line":237,"column":76,"offset":8080},"indent":[]}}],"position":{"start":{"line":237,"column":73,"offset":8077},"end":{"line":237,"column":123,"offset":8127},"indent":[]}}],"position":{"start":{"line":237,"column":3,"offset":8007},"end":{"line":237,"column":123,"offset":8127},"indent":[]}}],"position":{"start":{"line":237,"column":1,"offset":8005},"end":{"line":237,"column":123,"offset":8127},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"KiOS GUI installer.","position":{"start":{"line":238,"column":3,"offset":8130},"end":{"line":238,"column":22,"offset":8149},"indent":[]}}],"position":{"start":{"line":238,"column":3,"offset":8130},"end":{"line":238,"column":22,"offset":8149},"indent":[]}}],"position":{"start":{"line":238,"column":1,"offset":8128},"end":{"line":238,"column":22,"offset":8149},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":7833},"end":{"line":238,"column":22,"offset":8149},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"2.0.0","position":{"start":{"line":240,"column":5,"offset":8155},"end":{"line":240,"column":10,"offset":8160},"indent":[]}}],"position":{"start":{"line":240,"column":1,"offset":8151},"end":{"line":240,"column":10,"offset":8160},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":242,"column":6,"offset":8167},"end":{"line":242,"column":9,"offset":8170},"indent":[]}}],"position":{"start":{"line":242,"column":1,"offset":8162},"end":{"line":242,"column":9,"offset":8170},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Add simple ON/OFF toggle. ","position":{"start":{"line":244,"column":3,"offset":8174},"end":{"line":244,"column":29,"offset":8200},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/24","children":[{"type":"text","value":"#24","position":{"start":{"line":244,"column":30,"offset":8201},"end":{"line":244,"column":33,"offset":8204},"indent":[]}}],"position":{"start":{"line":244,"column":29,"offset":8200},"end":{"line":244,"column":80,"offset":8251},"indent":[]}}],"position":{"start":{"line":244,"column":3,"offset":8174},"end":{"line":244,"column":80,"offset":8251},"indent":[]}}],"position":{"start":{"line":244,"column":1,"offset":8172},"end":{"line":244,"column":80,"offset":8251},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added update strategy when using KiOS. ","position":{"start":{"line":245,"column":3,"offset":8254},"end":{"line":245,"column":42,"offset":8293},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/23","children":[{"type":"text","value":"#23","position":{"start":{"line":245,"column":43,"offset":8294},"end":{"line":245,"column":46,"offset":8297},"indent":[]}}],"position":{"start":{"line":245,"column":42,"offset":8293},"end":{"line":245,"column":93,"offset":8344},"indent":[]}}],"position":{"start":{"line":245,"column":3,"offset":8254},"end":{"line":245,"column":93,"offset":8344},"indent":[]}}],"position":{"start":{"line":245,"column":1,"offset":8252},"end":{"line":245,"column":93,"offset":8344},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"A system page which shows system information. ","position":{"start":{"line":246,"column":3,"offset":8347},"end":{"line":246,"column":49,"offset":8393},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/20","children":[{"type":"text","value":"#20","position":{"start":{"line":246,"column":50,"offset":8394},"end":{"line":246,"column":53,"offset":8397},"indent":[]}}],"position":{"start":{"line":246,"column":49,"offset":8393},"end":{"line":246,"column":100,"offset":8444},"indent":[]}}],"position":{"start":{"line":246,"column":3,"offset":8347},"end":{"line":246,"column":100,"offset":8444},"indent":[]}}],"position":{"start":{"line":246,"column":1,"offset":8345},"end":{"line":246,"column":100,"offset":8444},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Heatmap on dashboard page ","position":{"start":{"line":247,"column":3,"offset":8447},"end":{"line":247,"column":29,"offset":8473},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/19","children":[{"type":"text","value":"#19","position":{"start":{"line":247,"column":30,"offset":8474},"end":{"line":247,"column":33,"offset":8477},"indent":[]}}],"position":{"start":{"line":247,"column":29,"offset":8473},"end":{"line":247,"column":80,"offset":8524},"indent":[]}}],"position":{"start":{"line":247,"column":3,"offset":8447},"end":{"line":247,"column":80,"offset":8524},"indent":[]}}],"position":{"start":{"line":247,"column":1,"offset":8445},"end":{"line":247,"column":80,"offset":8524},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added live stream view on the dashboard page ","position":{"start":{"line":248,"column":3,"offset":8527},"end":{"line":248,"column":48,"offset":8572},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/2","children":[{"type":"text","value":"#2","position":{"start":{"line":248,"column":49,"offset":8573},"end":{"line":248,"column":51,"offset":8575},"indent":[]}}],"position":{"start":{"line":248,"column":48,"offset":8572},"end":{"line":248,"column":97,"offset":8621},"indent":[]}}],"position":{"start":{"line":248,"column":3,"offset":8527},"end":{"line":248,"column":97,"offset":8621},"indent":[]}}],"position":{"start":{"line":248,"column":1,"offset":8525},"end":{"line":248,"column":97,"offset":8621},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fixed bug cloud syncing ","position":{"start":{"line":249,"column":3,"offset":8624},"end":{"line":249,"column":27,"offset":8648},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/16","children":[{"type":"text","value":"#16","position":{"start":{"line":249,"column":28,"offset":8649},"end":{"line":249,"column":31,"offset":8652},"indent":[]}}],"position":{"start":{"line":249,"column":27,"offset":8648},"end":{"line":249,"column":78,"offset":8699},"indent":[]}}],"position":{"start":{"line":249,"column":3,"offset":8624},"end":{"line":249,"column":78,"offset":8699},"indent":[]}}],"position":{"start":{"line":249,"column":1,"offset":8622},"end":{"line":249,"column":78,"offset":8699},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fixed broken settings page when space in instane name ","position":{"start":{"line":250,"column":3,"offset":8702},"end":{"line":250,"column":57,"offset":8756},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/16","children":[{"type":"text","value":"#16","position":{"start":{"line":250,"column":58,"offset":8757},"end":{"line":250,"column":61,"offset":8760},"indent":[]}}],"position":{"start":{"line":250,"column":57,"offset":8756},"end":{"line":250,"column":108,"offset":8807},"indent":[]}}],"position":{"start":{"line":250,"column":3,"offset":8702},"end":{"line":250,"column":108,"offset":8807},"indent":[]}}],"position":{"start":{"line":250,"column":1,"offset":8700},"end":{"line":250,"column":108,"offset":8807},"indent":[]}}],"position":{"start":{"line":244,"column":1,"offset":8172},"end":{"line":250,"column":108,"offset":8807},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":252,"column":6,"offset":8814},"end":{"line":252,"column":15,"offset":8823},"indent":[]}}],"position":{"start":{"line":252,"column":1,"offset":8809},"end":{"line":252,"column":15,"offset":8823},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"RTSP support for IP-camera's. ","position":{"start":{"line":254,"column":3,"offset":8827},"end":{"line":254,"column":33,"offset":8857},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/21","children":[{"type":"text","value":"#21","position":{"start":{"line":254,"column":34,"offset":8858},"end":{"line":254,"column":37,"offset":8861},"indent":[]}}],"position":{"start":{"line":254,"column":33,"offset":8857},"end":{"line":254,"column":90,"offset":8914},"indent":[]}}],"position":{"start":{"line":254,"column":3,"offset":8827},"end":{"line":254,"column":90,"offset":8914},"indent":[]}}],"position":{"start":{"line":254,"column":1,"offset":8825},"end":{"line":254,"column":90,"offset":8914},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Verbose logging. ","position":{"start":{"line":255,"column":3,"offset":8917},"end":{"line":255,"column":20,"offset":8934},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/35","children":[{"type":"text","value":"#35","position":{"start":{"line":255,"column":21,"offset":8935},"end":{"line":255,"column":24,"offset":8938},"indent":[]}}],"position":{"start":{"line":255,"column":20,"offset":8934},"end":{"line":255,"column":77,"offset":8991},"indent":[]}}],"position":{"start":{"line":255,"column":3,"offset":8917},"end":{"line":255,"column":77,"offset":8991},"indent":[]}}],"position":{"start":{"line":255,"column":1,"offset":8915},"end":{"line":255,"column":77,"offset":8991},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"IO-devices are executed in a seperate thread. ","position":{"start":{"line":256,"column":3,"offset":8994},"end":{"line":256,"column":49,"offset":9040},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/28","children":[{"type":"text","value":"#28","position":{"start":{"line":256,"column":50,"offset":9041},"end":{"line":256,"column":53,"offset":9044},"indent":[]}}],"position":{"start":{"line":256,"column":49,"offset":9040},"end":{"line":256,"column":106,"offset":9097},"indent":[]}}],"position":{"start":{"line":256,"column":3,"offset":8994},"end":{"line":256,"column":106,"offset":9097},"indent":[]}}],"position":{"start":{"line":256,"column":1,"offset":8992},"end":{"line":256,"column":106,"offset":9097},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Live streaming (MJPEG). ","position":{"start":{"line":257,"column":3,"offset":9100},"end":{"line":257,"column":27,"offset":9124},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/26","children":[{"type":"text","value":"#26","position":{"start":{"line":257,"column":28,"offset":9125},"end":{"line":257,"column":31,"offset":9128},"indent":[]}}],"position":{"start":{"line":257,"column":27,"offset":9124},"end":{"line":257,"column":84,"offset":9181},"indent":[]}}],"position":{"start":{"line":257,"column":3,"offset":9100},"end":{"line":257,"column":84,"offset":9181},"indent":[]}}],"position":{"start":{"line":257,"column":1,"offset":9098},"end":{"line":257,"column":84,"offset":9181},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Execute multiple instances on a machine. ","position":{"start":{"line":258,"column":3,"offset":9184},"end":{"line":258,"column":44,"offset":9225},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/24","children":[{"type":"text","value":"#24","position":{"start":{"line":258,"column":45,"offset":9226},"end":{"line":258,"column":48,"offset":9229},"indent":[]}}],"position":{"start":{"line":258,"column":44,"offset":9225},"end":{"line":258,"column":101,"offset":9282},"indent":[]}}],"position":{"start":{"line":258,"column":3,"offset":9184},"end":{"line":258,"column":101,"offset":9282},"indent":[]}}],"position":{"start":{"line":258,"column":1,"offset":9182},"end":{"line":258,"column":101,"offset":9282},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Override config by arguments. ","position":{"start":{"line":259,"column":3,"offset":9285},"end":{"line":259,"column":33,"offset":9315},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/22","children":[{"type":"text","value":"#22","position":{"start":{"line":259,"column":34,"offset":9316},"end":{"line":259,"column":37,"offset":9319},"indent":[]}}],"position":{"start":{"line":259,"column":33,"offset":9315},"end":{"line":259,"column":90,"offset":9372},"indent":[]}}],"position":{"start":{"line":259,"column":3,"offset":9285},"end":{"line":259,"column":90,"offset":9372},"indent":[]}}],"position":{"start":{"line":259,"column":1,"offset":9283},"end":{"line":259,"column":90,"offset":9372},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Move S3 upload to machinery and remove sync-s3 repository. ","position":{"start":{"line":260,"column":3,"offset":9375},"end":{"line":260,"column":62,"offset":9434},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/16","children":[{"type":"text","value":"#16","position":{"start":{"line":260,"column":63,"offset":9435},"end":{"line":260,"column":66,"offset":9438},"indent":[]}}],"position":{"start":{"line":260,"column":62,"offset":9434},"end":{"line":260,"column":119,"offset":9491},"indent":[]}}],"position":{"start":{"line":260,"column":3,"offset":9375},"end":{"line":260,"column":119,"offset":9491},"indent":[]}}],"position":{"start":{"line":260,"column":1,"offset":9373},"end":{"line":260,"column":119,"offset":9491},"indent":[]}}],"position":{"start":{"line":254,"column":1,"offset":8825},"end":{"line":260,"column":119,"offset":9491},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Docker","position":{"start":{"line":262,"column":6,"offset":9498},"end":{"line":262,"column":12,"offset":9504},"indent":[]}}],"position":{"start":{"line":262,"column":1,"offset":9493},"end":{"line":262,"column":12,"offset":9504},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added Docker image (x86_x64) to Docker Hub.","position":{"start":{"line":264,"column":3,"offset":9508},"end":{"line":264,"column":46,"offset":9551},"indent":[]}}],"position":{"start":{"line":264,"column":3,"offset":9508},"end":{"line":264,"column":46,"offset":9551},"indent":[]}}],"position":{"start":{"line":264,"column":1,"offset":9506},"end":{"line":264,"column":46,"offset":9551},"indent":[]}}],"position":{"start":{"line":264,"column":1,"offset":9506},"end":{"line":264,"column":46,"offset":9551},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Ecosystem","position":{"start":{"line":266,"column":6,"offset":9558},"end":{"line":266,"column":15,"offset":9567},"indent":[]}}],"position":{"start":{"line":266,"column":1,"offset":9553},"end":{"line":266,"column":15,"offset":9567},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Add support for Raspberry Pi 1, 2 and 3. ","position":{"start":{"line":268,"column":3,"offset":9571},"end":{"line":268,"column":44,"offset":9612},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/issues/1","children":[{"type":"text","value":"#1","position":{"start":{"line":268,"column":45,"offset":9613},"end":{"line":268,"column":47,"offset":9615},"indent":[]}}],"position":{"start":{"line":268,"column":44,"offset":9612},"end":{"line":268,"column":94,"offset":9662},"indent":[]}}],"position":{"start":{"line":268,"column":3,"offset":9571},"end":{"line":268,"column":94,"offset":9662},"indent":[]}}],"position":{"start":{"line":268,"column":1,"offset":9569},"end":{"line":268,"column":94,"offset":9662},"indent":[]}}],"position":{"start":{"line":268,"column":1,"offset":9569},"end":{"line":268,"column":94,"offset":9662},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"1.1.0","position":{"start":{"line":270,"column":5,"offset":9668},"end":{"line":270,"column":10,"offset":9673},"indent":[]}}],"position":{"start":{"line":270,"column":1,"offset":9664},"end":{"line":270,"column":10,"offset":9673},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":272,"column":6,"offset":9680},"end":{"line":272,"column":9,"offset":9683},"indent":[]}}],"position":{"start":{"line":272,"column":1,"offset":9675},"end":{"line":272,"column":9,"offset":9683},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support IP camera's with MJPEG stream. ","position":{"start":{"line":274,"column":3,"offset":9687},"end":{"line":274,"column":42,"offset":9726},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/3","children":[{"type":"text","value":"#3","position":{"start":{"line":274,"column":43,"offset":9727},"end":{"line":274,"column":45,"offset":9729},"indent":[]}}],"position":{"start":{"line":274,"column":42,"offset":9726},"end":{"line":274,"column":91,"offset":9775},"indent":[]}}],"position":{"start":{"line":274,"column":3,"offset":9687},"end":{"line":274,"column":91,"offset":9775},"indent":[]}}],"position":{"start":{"line":274,"column":1,"offset":9685},"end":{"line":274,"column":91,"offset":9775},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Introduce new API methods to configure the machinery, using basic auth. ","position":{"start":{"line":275,"column":3,"offset":9778},"end":{"line":275,"column":75,"offset":9850},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/4","children":[{"type":"text","value":"#4","position":{"start":{"line":275,"column":76,"offset":9851},"end":{"line":275,"column":78,"offset":9853},"indent":[]}}],"position":{"start":{"line":275,"column":75,"offset":9850},"end":{"line":275,"column":124,"offset":9899},"indent":[]}}],"position":{"start":{"line":275,"column":3,"offset":9778},"end":{"line":275,"column":124,"offset":9899},"indent":[]}}],"position":{"start":{"line":275,"column":1,"offset":9776},"end":{"line":275,"column":124,"offset":9899},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Optimization of loading image and dashboard page, completely redesigned the retrieval of images. ","position":{"start":{"line":276,"column":3,"offset":9902},"end":{"line":276,"column":100,"offset":9999},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/5","children":[{"type":"text","value":"#5","position":{"start":{"line":276,"column":101,"offset":10000},"end":{"line":276,"column":103,"offset":10002},"indent":[]}}],"position":{"start":{"line":276,"column":100,"offset":9999},"end":{"line":276,"column":149,"offset":10048},"indent":[]}}],"position":{"start":{"line":276,"column":3,"offset":9902},"end":{"line":276,"column":149,"offset":10048},"indent":[]}}],"position":{"start":{"line":276,"column":1,"offset":9900},"end":{"line":276,"column":149,"offset":10048},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Optimization of settings page. ","position":{"start":{"line":277,"column":3,"offset":10051},"end":{"line":277,"column":34,"offset":10082},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/5","children":[{"type":"text","value":"#5","position":{"start":{"line":277,"column":35,"offset":10083},"end":{"line":277,"column":37,"offset":10085},"indent":[]}}],"position":{"start":{"line":277,"column":34,"offset":10082},"end":{"line":277,"column":83,"offset":10131},"indent":[]}}],"position":{"start":{"line":277,"column":3,"offset":10051},"end":{"line":277,"column":83,"offset":10131},"indent":[]}}],"position":{"start":{"line":277,"column":1,"offset":10049},"end":{"line":277,"column":83,"offset":10131},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Timebar gradient only works in Chrome. ","position":{"start":{"line":278,"column":3,"offset":10134},"end":{"line":278,"column":42,"offset":10173},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/web/issues/6","children":[{"type":"text","value":"#6","position":{"start":{"line":278,"column":43,"offset":10174},"end":{"line":278,"column":45,"offset":10176},"indent":[]}}],"position":{"start":{"line":278,"column":42,"offset":10173},"end":{"line":278,"column":91,"offset":10222},"indent":[]}}],"position":{"start":{"line":278,"column":3,"offset":10134},"end":{"line":278,"column":91,"offset":10222},"indent":[]}}],"position":{"start":{"line":278,"column":1,"offset":10132},"end":{"line":278,"column":91,"offset":10222},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Minor CSS fixes for responsive layout.","position":{"start":{"line":279,"column":3,"offset":10225},"end":{"line":279,"column":41,"offset":10263},"indent":[]}}],"position":{"start":{"line":279,"column":3,"offset":10225},"end":{"line":279,"column":41,"offset":10263},"indent":[]}}],"position":{"start":{"line":279,"column":1,"offset":10223},"end":{"line":279,"column":41,"offset":10263},"indent":[]}}],"position":{"start":{"line":274,"column":1,"offset":9685},"end":{"line":279,"column":41,"offset":10263},"indent":[1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":281,"column":6,"offset":10270},"end":{"line":281,"column":15,"offset":10279},"indent":[]}}],"position":{"start":{"line":281,"column":1,"offset":10265},"end":{"line":281,"column":15,"offset":10279},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Flip/rotate option for capture devices. ","position":{"start":{"line":283,"column":3,"offset":10283},"end":{"line":283,"column":43,"offset":10323},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/1","children":[{"type":"text","value":"#5","position":{"start":{"line":283,"column":44,"offset":10324},"end":{"line":283,"column":46,"offset":10326},"indent":[]}}],"position":{"start":{"line":283,"column":43,"offset":10323},"end":{"line":283,"column":98,"offset":10378},"indent":[]}}],"position":{"start":{"line":283,"column":3,"offset":10283},"end":{"line":283,"column":98,"offset":10378},"indent":[]}}],"position":{"start":{"line":283,"column":1,"offset":10281},"end":{"line":283,"column":98,"offset":10378},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Support IP camera's with MJPEG stream. ","position":{"start":{"line":284,"column":3,"offset":10381},"end":{"line":284,"column":42,"offset":10420},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/4","children":[{"type":"text","value":"#4","position":{"start":{"line":284,"column":43,"offset":10421},"end":{"line":284,"column":45,"offset":10423},"indent":[]}}],"position":{"start":{"line":284,"column":42,"offset":10420},"end":{"line":284,"column":97,"offset":10475},"indent":[]}}],"position":{"start":{"line":284,"column":3,"offset":10381},"end":{"line":284,"column":97,"offset":10475},"indent":[]}}],"position":{"start":{"line":284,"column":1,"offset":10379},"end":{"line":284,"column":97,"offset":10475},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Introduced webhook io device. ","position":{"start":{"line":285,"column":3,"offset":10478},"end":{"line":285,"column":33,"offset":10508},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/issues/5","children":[{"type":"text","value":"#5","position":{"start":{"line":285,"column":34,"offset":10509},"end":{"line":285,"column":36,"offset":10511},"indent":[]}}],"position":{"start":{"line":285,"column":33,"offset":10508},"end":{"line":285,"column":88,"offset":10563},"indent":[]}}],"position":{"start":{"line":285,"column":3,"offset":10478},"end":{"line":285,"column":88,"offset":10563},"indent":[]}}],"position":{"start":{"line":285,"column":1,"offset":10476},"end":{"line":285,"column":88,"offset":10563},"indent":[]}}],"position":{"start":{"line":283,"column":1,"offset":10281},"end":{"line":285,"column":88,"offset":10563},"indent":[1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Cloud","position":{"start":{"line":287,"column":6,"offset":10570},"end":{"line":287,"column":11,"offset":10575},"indent":[]}}],"position":{"start":{"line":287,"column":1,"offset":10565},"end":{"line":287,"column":11,"offset":10575},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Fixed problem when syncing a huge amount of images. ","position":{"start":{"line":289,"column":3,"offset":10579},"end":{"line":289,"column":55,"offset":10631},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/sync-s3/issues/1","children":[{"type":"text","value":"#1","position":{"start":{"line":289,"column":56,"offset":10632},"end":{"line":289,"column":58,"offset":10634},"indent":[]}}],"position":{"start":{"line":289,"column":55,"offset":10631},"end":{"line":289,"column":108,"offset":10684},"indent":[]}}],"position":{"start":{"line":289,"column":3,"offset":10579},"end":{"line":289,"column":108,"offset":10684},"indent":[]}}],"position":{"start":{"line":289,"column":1,"offset":10577},"end":{"line":289,"column":108,"offset":10684},"indent":[]}}],"position":{"start":{"line":289,"column":1,"offset":10577},"end":{"line":289,"column":108,"offset":10684},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"1.0.3","position":{"start":{"line":291,"column":5,"offset":10690},"end":{"line":291,"column":10,"offset":10695},"indent":[]}}],"position":{"start":{"line":291,"column":1,"offset":10686},"end":{"line":291,"column":10,"offset":10695},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":293,"column":6,"offset":10702},"end":{"line":293,"column":9,"offset":10705},"indent":[]}}],"position":{"start":{"line":293,"column":1,"offset":10697},"end":{"line":293,"column":9,"offset":10705},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Optimize performance, new datastructure has been implemented.","position":{"start":{"line":295,"column":3,"offset":10709},"end":{"line":295,"column":64,"offset":10770},"indent":[]}}],"position":{"start":{"line":295,"column":3,"offset":10709},"end":{"line":295,"column":64,"offset":10770},"indent":[]}}],"position":{"start":{"line":295,"column":1,"offset":10707},"end":{"line":295,"column":64,"offset":10770},"indent":[]}}],"position":{"start":{"line":295,"column":1,"offset":10707},"end":{"line":295,"column":64,"offset":10770},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":297,"column":6,"offset":10777},"end":{"line":297,"column":15,"offset":10786},"indent":[]}}],"position":{"start":{"line":297,"column":1,"offset":10772},"end":{"line":297,"column":15,"offset":10786},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Memory optimization.","position":{"start":{"line":299,"column":3,"offset":10790},"end":{"line":299,"column":23,"offset":10810},"indent":[]}}],"position":{"start":{"line":299,"column":3,"offset":10790},"end":{"line":299,"column":23,"offset":10810},"indent":[]}}],"position":{"start":{"line":299,"column":1,"offset":10788},"end":{"line":299,"column":23,"offset":10810},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Removal of images older than 3 days have been removed.","position":{"start":{"line":300,"column":3,"offset":10813},"end":{"line":300,"column":57,"offset":10867},"indent":[]}}],"position":{"start":{"line":300,"column":3,"offset":10813},"end":{"line":300,"column":57,"offset":10867},"indent":[]}}],"position":{"start":{"line":300,"column":1,"offset":10811},"end":{"line":300,"column":57,"offset":10867},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Start machinery automatically (delay has been removed).","position":{"start":{"line":301,"column":3,"offset":10870},"end":{"line":301,"column":58,"offset":10925},"indent":[]}}],"position":{"start":{"line":301,"column":3,"offset":10870},"end":{"line":301,"column":58,"offset":10925},"indent":[]}}],"position":{"start":{"line":301,"column":1,"offset":10868},"end":{"line":301,"column":58,"offset":10925},"indent":[]}}],"position":{"start":{"line":299,"column":1,"offset":10788},"end":{"line":301,"column":58,"offset":10925},"indent":[1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Cloud","position":{"start":{"line":303,"column":6,"offset":10932},"end":{"line":303,"column":11,"offset":10937},"indent":[]}}],"position":{"start":{"line":303,"column":1,"offset":10927},"end":{"line":303,"column":11,"offset":10937},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Resolved file exist problem.","position":{"start":{"line":305,"column":3,"offset":10941},"end":{"line":305,"column":31,"offset":10969},"indent":[]}}],"position":{"start":{"line":305,"column":3,"offset":10941},"end":{"line":305,"column":31,"offset":10969},"indent":[]}}],"position":{"start":{"line":305,"column":1,"offset":10939},"end":{"line":305,"column":31,"offset":10969},"indent":[]}}],"position":{"start":{"line":305,"column":1,"offset":10939},"end":{"line":305,"column":31,"offset":10969},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"1.0.2","position":{"start":{"line":307,"column":5,"offset":10975},"end":{"line":307,"column":10,"offset":10980},"indent":[]}}],"position":{"start":{"line":307,"column":1,"offset":10971},"end":{"line":307,"column":10,"offset":10980},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":309,"column":6,"offset":10987},"end":{"line":309,"column":9,"offset":10990},"indent":[]}}],"position":{"start":{"line":309,"column":1,"offset":10982},"end":{"line":309,"column":9,"offset":10990},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Timezone on settings page is also used for the webinterface.","position":{"start":{"line":311,"column":3,"offset":10994},"end":{"line":311,"column":63,"offset":11054},"indent":[]}}],"position":{"start":{"line":311,"column":3,"offset":10994},"end":{"line":311,"column":63,"offset":11054},"indent":[]}}],"position":{"start":{"line":311,"column":1,"offset":10992},"end":{"line":311,"column":63,"offset":11054},"indent":[]}}],"position":{"start":{"line":311,"column":1,"offset":10992},"end":{"line":311,"column":63,"offset":11054},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":313,"column":6,"offset":11061},"end":{"line":313,"column":15,"offset":11070},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":11056},"end":{"line":313,"column":15,"offset":11070},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Added extra timezones to timezone.xml.","position":{"start":{"line":315,"column":3,"offset":11074},"end":{"line":315,"column":41,"offset":11112},"indent":[]}}],"position":{"start":{"line":315,"column":3,"offset":11074},"end":{"line":315,"column":41,"offset":11112},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":11072},"end":{"line":315,"column":41,"offset":11112},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":11072},"end":{"line":315,"column":41,"offset":11112},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"1.0.1","position":{"start":{"line":317,"column":5,"offset":11118},"end":{"line":317,"column":10,"offset":11123},"indent":[]}}],"position":{"start":{"line":317,"column":1,"offset":11114},"end":{"line":317,"column":10,"offset":11123},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Web","position":{"start":{"line":319,"column":6,"offset":11130},"end":{"line":319,"column":9,"offset":11133},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":11125},"end":{"line":319,"column":9,"offset":11133},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Improved error handling (date search).","position":{"start":{"line":321,"column":3,"offset":11137},"end":{"line":321,"column":41,"offset":11175},"indent":[]}}],"position":{"start":{"line":321,"column":3,"offset":11137},"end":{"line":321,"column":41,"offset":11175},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":11135},"end":{"line":321,"column":41,"offset":11175},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":11135},"end":{"line":321,"column":41,"offset":11175},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":323,"column":6,"offset":11182},"end":{"line":323,"column":15,"offset":11191},"indent":[]}}],"position":{"start":{"line":323,"column":1,"offset":11177},"end":{"line":323,"column":15,"offset":11191},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Improved memory cleanup.","position":{"start":{"line":325,"column":3,"offset":11195},"end":{"line":325,"column":27,"offset":11219},"indent":[]}}],"position":{"start":{"line":325,"column":3,"offset":11195},"end":{"line":325,"column":27,"offset":11219},"indent":[]}}],"position":{"start":{"line":325,"column":1,"offset":11193},"end":{"line":325,"column":27,"offset":11219},"indent":[]}}],"position":{"start":{"line":325,"column":1,"offset":11193},"end":{"line":325,"column":27,"offset":11219},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"1.0.0","position":{"start":{"line":327,"column":5,"offset":11225},"end":{"line":327,"column":10,"offset":11230},"indent":[]}}],"position":{"start":{"line":327,"column":1,"offset":11221},"end":{"line":327,"column":10,"offset":11230},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"First commit of Kerberos.io","position":{"start":{"line":329,"column":6,"offset":11237},"end":{"line":329,"column":33,"offset":11264},"indent":[]}}],"position":{"start":{"line":329,"column":1,"offset":11232},"end":{"line":329,"column":33,"offset":11264},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Camera support: ","position":{"start":{"line":331,"column":3,"offset":11268},"end":{"line":331,"column":19,"offset":11284},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"USBCamera","position":{"start":{"line":331,"column":21,"offset":11286},"end":{"line":331,"column":30,"offset":11295},"indent":[]}}],"position":{"start":{"line":331,"column":19,"offset":11284},"end":{"line":331,"column":32,"offset":11297},"indent":[]}},{"type":"text","value":" (V4L), ","position":{"start":{"line":331,"column":32,"offset":11297},"end":{"line":331,"column":40,"offset":11305},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Raspberry Pi camera module","position":{"start":{"line":331,"column":42,"offset":11307},"end":{"line":331,"column":68,"offset":11333},"indent":[]}}],"position":{"start":{"line":331,"column":40,"offset":11305},"end":{"line":331,"column":70,"offset":11335},"indent":[]}},{"type":"text","value":" (MMAL).","position":{"start":{"line":331,"column":70,"offset":11335},"end":{"line":331,"column":78,"offset":11343},"indent":[]}}],"position":{"start":{"line":331,"column":3,"offset":11268},"end":{"line":331,"column":78,"offset":11343},"indent":[]}}],"position":{"start":{"line":331,"column":1,"offset":11266},"end":{"line":331,"column":78,"offset":11343},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Conditions: ","position":{"start":{"line":332,"column":3,"offset":11346},"end":{"line":332,"column":15,"offset":11358},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Enabled","position":{"start":{"line":332,"column":17,"offset":11360},"end":{"line":332,"column":24,"offset":11367},"indent":[]}}],"position":{"start":{"line":332,"column":15,"offset":11358},"end":{"line":332,"column":26,"offset":11369},"indent":[]}},{"type":"text","value":" (turn on/off Kerberos) and active ","position":{"start":{"line":332,"column":26,"offset":11369},"end":{"line":332,"column":61,"offset":11404},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Time","position":{"start":{"line":332,"column":63,"offset":11406},"end":{"line":332,"column":67,"offset":11410},"indent":[]}}],"position":{"start":{"line":332,"column":61,"offset":11404},"end":{"line":332,"column":69,"offset":11412},"indent":[]}},{"type":"text","value":" per day.","position":{"start":{"line":332,"column":69,"offset":11412},"end":{"line":332,"column":78,"offset":11421},"indent":[]}}],"position":{"start":{"line":332,"column":3,"offset":11346},"end":{"line":332,"column":78,"offset":11421},"indent":[]}}],"position":{"start":{"line":332,"column":1,"offset":11344},"end":{"line":332,"column":78,"offset":11421},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Algorithms: ","position":{"start":{"line":333,"column":3,"offset":11424},"end":{"line":333,"column":15,"offset":11436},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Differential Images","position":{"start":{"line":333,"column":17,"offset":11438},"end":{"line":333,"column":36,"offset":11457},"indent":[]}}],"position":{"start":{"line":333,"column":15,"offset":11436},"end":{"line":333,"column":38,"offset":11459},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":333,"column":38,"offset":11459},"end":{"line":333,"column":39,"offset":11460},"indent":[]}}],"position":{"start":{"line":333,"column":3,"offset":11424},"end":{"line":333,"column":39,"offset":11460},"indent":[]}}],"position":{"start":{"line":333,"column":1,"offset":11422},"end":{"line":333,"column":39,"offset":11460},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Heuristics: ","position":{"start":{"line":334,"column":3,"offset":11463},"end":{"line":334,"column":15,"offset":11475},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Sequence","position":{"start":{"line":334,"column":17,"offset":11477},"end":{"line":334,"column":25,"offset":11485},"indent":[]}}],"position":{"start":{"line":334,"column":15,"offset":11475},"end":{"line":334,"column":27,"offset":11487},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":334,"column":27,"offset":11487},"end":{"line":334,"column":28,"offset":11488},"indent":[]}}],"position":{"start":{"line":334,"column":3,"offset":11463},"end":{"line":334,"column":28,"offset":11488},"indent":[]}}],"position":{"start":{"line":334,"column":1,"offset":11461},"end":{"line":334,"column":28,"offset":11488},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Expositors: Select a ","position":{"start":{"line":335,"column":3,"offset":11491},"end":{"line":335,"column":24,"offset":11512},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Hull","position":{"start":{"line":335,"column":26,"offset":11514},"end":{"line":335,"column":30,"offset":11518},"indent":[]}}],"position":{"start":{"line":335,"column":24,"offset":11512},"end":{"line":335,"column":32,"offset":11520},"indent":[]}},{"type":"text","value":" or ","position":{"start":{"line":335,"column":32,"offset":11520},"end":{"line":335,"column":36,"offset":11524},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Rectangle","position":{"start":{"line":335,"column":38,"offset":11526},"end":{"line":335,"column":47,"offset":11535},"indent":[]}}],"position":{"start":{"line":335,"column":36,"offset":11524},"end":{"line":335,"column":49,"offset":11537},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":335,"column":49,"offset":11537},"end":{"line":335,"column":50,"offset":11538},"indent":[]}}],"position":{"start":{"line":335,"column":3,"offset":11491},"end":{"line":335,"column":50,"offset":11538},"indent":[]}}],"position":{"start":{"line":335,"column":1,"offset":11489},"end":{"line":335,"column":50,"offset":11538},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Outputs: Write image to ","position":{"start":{"line":336,"column":3,"offset":11541},"end":{"line":336,"column":27,"offset":11565},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Disk","position":{"start":{"line":336,"column":29,"offset":11567},"end":{"line":336,"column":33,"offset":11571},"indent":[]}}],"position":{"start":{"line":336,"column":27,"offset":11565},"end":{"line":336,"column":35,"offset":11573},"indent":[]}},{"type":"text","value":", trigger an ","position":{"start":{"line":336,"column":35,"offset":11573},"end":{"line":336,"column":48,"offset":11586},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"GPIO","position":{"start":{"line":336,"column":50,"offset":11588},"end":{"line":336,"column":54,"offset":11592},"indent":[]}}],"position":{"start":{"line":336,"column":48,"offset":11586},"end":{"line":336,"column":56,"offset":11594},"indent":[]}},{"type":"text","value":" output pin and send a ","position":{"start":{"line":336,"column":56,"offset":11594},"end":{"line":336,"column":79,"offset":11617},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"TCP/IP packet","position":{"start":{"line":336,"column":81,"offset":11619},"end":{"line":336,"column":94,"offset":11632},"indent":[]}}],"position":{"start":{"line":336,"column":79,"offset":11617},"end":{"line":336,"column":96,"offset":11634},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":336,"column":96,"offset":11634},"end":{"line":336,"column":97,"offset":11635},"indent":[]}}],"position":{"start":{"line":336,"column":3,"offset":11541},"end":{"line":336,"column":97,"offset":11635},"indent":[]}}],"position":{"start":{"line":336,"column":1,"offset":11539},"end":{"line":336,"column":97,"offset":11635},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Cloud: send your images to the ","position":{"start":{"line":337,"column":3,"offset":11638},"end":{"line":337,"column":34,"offset":11669},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Kerberos.io cloud aplication","position":{"start":{"line":337,"column":36,"offset":11671},"end":{"line":337,"column":64,"offset":11699},"indent":[]}}],"position":{"start":{"line":337,"column":34,"offset":11669},"end":{"line":337,"column":66,"offset":11701},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":337,"column":66,"offset":11701},"end":{"line":337,"column":67,"offset":11702},"indent":[]}}],"position":{"start":{"line":337,"column":3,"offset":11638},"end":{"line":337,"column":67,"offset":11702},"indent":[]}}],"position":{"start":{"line":337,"column":1,"offset":11636},"end":{"line":337,"column":67,"offset":11702},"indent":[]}}],"position":{"start":{"line":331,"column":1,"offset":11266},"end":{"line":337,"column":67,"offset":11702},"indent":[1,1,1,1,1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":340,"column":1,"offset":11705},"end":{"line":340,"column":31,"offset":11735},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":340,"column":31,"offset":11735}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Release notes`}

\n

{`2.8.0`}

\n

{`Aligned machinery, web and KiOS versions. Too many people were confused by the versioning.`}

\n

{`Web`}

\n
    \n
  • {`Videos displayed on canvas were blocked in latest browsers.`}
  • \n
  • {`Disabled reboot and shutdown.`}
  • \n
  • {`Disabled upgrade process, use fwupdate shell command instead.`}
  • \n
\n

{`KiOS`}

\n
    \n
  • {`Major upgrade, solved many different problems (list to long); not possible to upgrade from 2.7.0 to 2.8.0.`}
  • \n
  • {`Updated firmware to latest Raspbian (raspberrypi-kernel_1.20180417-1).`}
  • \n
  • {`Support for the Raspberry Pi 4.`}
  • \n
\n

{`2.7.2`}

\n

{`Machinery`}

\n
    \n
  • {`To optimise the cloud experience we've added a proxy.kerberos.io machine in between.`}
  • \n
  • {`We've changed the S3 storage scheme (class:ONEZONE_IA).`}
  • \n
\n

{`2.7.1`}

\n

{`Machinery`}

\n
    \n
  • {`Resolved deadlock with livestreaming while restarting machinery.`}
  • \n
  • {`Revert logging library; enabled log rotating.`}
  • \n
\n

{`KiOS`}

\n
    \n
  • {`Updated firmware to latest Raspbian (raspberrypi-kernel_1.20180417-1).`}
  • \n
  • {`Resolved issue with WIFI on Raspberry Pi 3B+`}
  • \n
\n

{`2.7.0`}

\n

{`Web`}

\n
    \n
  • {`Unique session cookie, which allows to open multiple web interfaces (e.g. when using docker).`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Added live streaming feature for app.kerberos.io`}
  • \n
  • {`Upgraded logging library: log file can be max 5MB, and will rotate.`}
  • \n
  • {`Better logging for cloud uploads (failed information).`}
  • \n
\n

{`Docker`}

\n
    \n
  • {`No longer need docker-compose, we merged the web and machinery containers to `}{`a single container`}{`.`}
  • \n
\n

{`KiOS`}

\n
    \n
  • {`Updated firmware to latest Raspbian.`}
  • \n
  • {`Support for the Raspberry Pi 3B+.`}
  • \n
\n

{`2.6.1`}

\n

{`Web`}

\n
    \n
  • {`Solved issue with persisting login configuration. `}{`#111`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Added Pushbullet. `}{`#139`}
  • \n
  • {`Cloud upload was not longer working (hotfix also in 2.6.0).`}
  • \n
\n

{`2.6.0`}

\n

{`Web`}

\n
    \n
  • {`Add a cloud connection verification method. `}{`#112`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Add background color timestamp. `}{`#128`}
  • \n
  • {`Send instanceId in AWS header when uploading to cloud (necessary for new cloud app).`}
  • \n
  • {`Better support for Chinese IP cameras.`}
  • \n
\n

{`Docker`}

\n
    \n
  • {`Bug: Autoremove old images/video within Docker Containers. `}{`#104`}
  • \n
\n

{`2.5.0`}

\n

{`Web`}

\n
    \n
  • {`Added Chinese and Italian language.`}
  • \n
  • {`Resolved issue with INSTALLED=true.`}
  • \n
  • {`Make latest_sequence available with basic auth. `}{`#99`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Provide an IO service for publishing events to MQTT. `}{`#89`}
  • \n
  • {`Optimize recording with H264_OMX. `}{`#83`}
  • \n
  • {`Implement throttler for Io detections. `}{`#96`}
  • \n
  • {`SSL version 1.0.0 is no longer accessible in Raspbian. `}{`#109`}
  • \n
\n

{`2.4.2`}

\n

{`Web`}

\n
    \n
  • {`Typo in french translation, causes the web interface crash.`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Resolved major bug in livestream: memory leak in stream class. `}{`#94`}
  • \n
  • {`Capture health verification: check if the chosen capture device is still grabbing (and didn't stalled).`}
  • \n
  • {`Extra logging when recording with raspberry pi camera.`}
  • \n
  • {`Make sure the cloud upload is functioning properly, after an upload it's verified if the files really exist in the cloud.`}
  • \n
\n

{`2.4.1`}

\n

{`Web`}

\n
    \n
  • {`Show warning when system is disabled. `}{`#88`}{`.`}
  • \n
  • {`Hull selector in basic view not always working.`}
  • \n
\n

{`2.4.0`}

\n

{`Ecosystem`}

\n
    \n
  • {`Enable/Disable force network mode.`}
  • \n
  • {`Enable/Disable auto removal media.`}
  • \n
\n

{`Web`}

\n
    \n
  • {`Upgrade from Laravel 4.2 to Laravel 5.4 `}{`#70`}{`.`}
  • \n
  • {`Fix bug with heatmap radius slider `}{`#84`}{`.`}
  • \n
  • {`Design tweaks toggle button (remove outline).`}
  • \n
  • {`Disabled possibility to timestamp video when using hardware acceleration.`}
  • \n
\n

{`Docker`}

\n
    \n
  • {`Fix SSL support `}{`#4`}{`.`}
  • \n
  • {`Auto removal if disk is full.`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`OpenMAX IL hardware encoding for Raspberry Pi camera. `}{`#83`}
      \n
    • {`Optimized live streaming.`}
    • \n
    • {`Optimized h264 recording.`}
    • \n
  • \n
  • {`Basic authentication for live streaming (username and password). `}{`#80`}
  • \n
\n

{`2.3.1`}

\n

{`Machinery`}

\n
    \n
  • {`Update for kerberos.cloud: pushing content-type.`}
  • \n
  • {`Change default configurations.`}
  • \n
\n

{`2.3.0`}

\n

{`Ecosystem`}

\n
    \n
  • {`Support for Raspberry Pi Zero W. `}{`#8`}
  • \n
\n

{`2.2.1`}

\n

{`Ecosystem`}

\n
    \n
  • {`Upgraded FFmpeg and libx264 on KiOS.`}
  • \n
\n

{`Web`}

\n
    \n
  • {`Add Bulgarian translation. `}{`#81`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Bug: IoVideo crashes due to a memory leak. `}{`#70`}
  • \n
\n

{`2.2.0`}

\n

{`Ecosystem`}

\n
    \n
  • {`Added support for Armbian.`}
  • \n
  • {`Raspbian: Async requests causes session corruption. `}{`#78`}
  • \n
\n

{`Web`}

\n
    \n
  • {`Bug: Issue format instance name. `}{`#57`}
  • \n
  • {`Redesign settings page (better UX). `}{`#39`}
  • \n
  • {`Possibility to edit password through web interface. `}{`#63`}
  • \n
  • {`Support for viewing videos.`}
  • \n
  • {`Update radius of heatmap.`}
  • \n
  • {`PHP7 support. `}{`#60`}
  • \n
  • {`Welcome/installation page. `}{`#60`}
  • \n
  • {`Translation updated. `}{`#74`}
  • \n
  • {`Privacy mode. `}{`#54`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Output as video file. `}{`#60`}
  • \n
  • {`Bug: System hangs when a wrong IP camera url was defined. `}{`#48`}
  • \n
  • {`Run arbitrary script/program. `}{`#31`}
  • \n
  • {`Bug: Weird colors from RPi Camera. `}{`#64`}
  • \n
  • {`Upgrade to OpenCV 3.2.0.`}
  • \n
\n

{`2.1.0`}

\n

{`Web`}

\n
    \n
  • {`Added PhotoSwipe for image overview (easier to browse through images). `}{`#45`}
  • \n
  • {`Added reboot and shutdown commands. `}{`#46`}
  • \n
  • {`Added logging view to system page. `}{`#33`}
  • \n
  • {`Added labels to check if machinery is running.`}
  • \n
  • {`Added error handling if web interface isn’t working properly.`}
  • \n
  • {`Fixed Heatmap.js fail to load by ad-blocker. `}{`#42`}
  • \n
  • {`Show additional information on the dashboard (streaming is opening or not) there is no data available.`}
  • \n
  • {`Settings page is now visible on mobile (+ changed icon).`}
  • \n
  • {`Fixed sorting of news articles.`}
  • \n
  • {`Removed links to assets in the cloud (.css files).`}
  • \n
  • {`Design: improved layout of login page, async loading of image view.`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Added configurable streaming port and quality. `}{`#41`}
  • \n
  • {`Added new algorithm: Background subtraction.`}
  • \n
  • {`Added new heuristic: Counter (for object/people counting). `}{`#42`}
  • \n
  • {`Added video capture, which can be used for debugging purposes (replay a video fragment).`}
  • \n
  • {`It’s now possible to mark the images with a timestamp. `}{`#36`}
  • \n
  • {`Fixed blocking streaming socket. `}{`#39`}
  • \n
\n

{`Ecosystem`}

\n
    \n
  • {`Fix removal images if disk is almost full (wrong path was defined).`}
  • \n
  • {`Support for the Raspberry Pi Camera module v2.1. `}{`#3`}
  • \n
  • {`Support for the Raspberry Pi Zero; updated kernel to latest Raspbian. `}{`#3`}
  • \n
  • {`KiOS GUI installer.`}
  • \n
\n

{`2.0.0`}

\n

{`Web`}

\n
    \n
  • {`Add simple ON/OFF toggle. `}{`#24`}
  • \n
  • {`Added update strategy when using KiOS. `}{`#23`}
  • \n
  • {`A system page which shows system information. `}{`#20`}
  • \n
  • {`Heatmap on dashboard page `}{`#19`}
  • \n
  • {`Added live stream view on the dashboard page `}{`#2`}
  • \n
  • {`Fixed bug cloud syncing `}{`#16`}
  • \n
  • {`Fixed broken settings page when space in instane name `}{`#16`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`RTSP support for IP-camera's. `}{`#21`}
  • \n
  • {`Verbose logging. `}{`#35`}
  • \n
  • {`IO-devices are executed in a seperate thread. `}{`#28`}
  • \n
  • {`Live streaming (MJPEG). `}{`#26`}
  • \n
  • {`Execute multiple instances on a machine. `}{`#24`}
  • \n
  • {`Override config by arguments. `}{`#22`}
  • \n
  • {`Move S3 upload to machinery and remove sync-s3 repository. `}{`#16`}
  • \n
\n

{`Docker`}

\n
    \n
  • {`Added Docker image (x86_x64) to Docker Hub.`}
  • \n
\n

{`Ecosystem`}

\n
    \n
  • {`Add support for Raspberry Pi 1, 2 and 3. `}{`#1`}
  • \n
\n

{`1.1.0`}

\n

{`Web`}

\n
    \n
  • {`Support IP camera's with MJPEG stream. `}{`#3`}
  • \n
  • {`Introduce new API methods to configure the machinery, using basic auth. `}{`#4`}
  • \n
  • {`Optimization of loading image and dashboard page, completely redesigned the retrieval of images. `}{`#5`}
  • \n
  • {`Optimization of settings page. `}{`#5`}
  • \n
  • {`Timebar gradient only works in Chrome. `}{`#6`}
  • \n
  • {`Minor CSS fixes for responsive layout.`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Flip/rotate option for capture devices. `}{`#5`}
  • \n
  • {`Support IP camera's with MJPEG stream. `}{`#4`}
  • \n
  • {`Introduced webhook io device. `}{`#5`}
  • \n
\n

{`Cloud`}

\n
    \n
  • {`Fixed problem when syncing a huge amount of images. `}{`#1`}
  • \n
\n

{`1.0.3`}

\n

{`Web`}

\n
    \n
  • {`Optimize performance, new datastructure has been implemented.`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Memory optimization.`}
  • \n
  • {`Removal of images older than 3 days have been removed.`}
  • \n
  • {`Start machinery automatically (delay has been removed).`}
  • \n
\n

{`Cloud`}

\n
    \n
  • {`Resolved file exist problem.`}
  • \n
\n

{`1.0.2`}

\n

{`Web`}

\n
    \n
  • {`Timezone on settings page is also used for the webinterface.`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Added extra timezones to timezone.xml.`}
  • \n
\n

{`1.0.1`}

\n

{`Web`}

\n
    \n
  • {`Improved error handling (date search).`}
  • \n
\n

{`Machinery`}

\n
    \n
  • {`Improved memory cleanup.`}
  • \n
\n

{`1.0.0`}

\n

{`First commit of Kerberos.io`}

\n
    \n
  • {`Camera support: `}{`USBCamera`}{` (V4L), `}{`Raspberry Pi camera module`}{` (MMAL).`}
  • \n
  • {`Conditions: `}{`Enabled`}{` (turn on/off Kerberos) and active `}{`Time`}{` per day.`}
  • \n
  • {`Algorithms: `}{`Differential Images`}{`.`}
  • \n
  • {`Heuristics: `}{`Sequence`}{`.`}
  • \n
  • {`Expositors: Select a `}{`Hull`}{` or `}{`Rectangle`}{`.`}
  • \n
  • {`Outputs: Write image to `}{`Disk`}{`, trigger an `}{`GPIO`}{` output pin and send a `}{`TCP/IP packet`}{`.`}
  • \n
  • {`Cloud: send your images to the `}{`Kerberos.io cloud aplication`}{`.`}
  • \n
\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-4145ced9d2b83f44f4a82c4861822fdb.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-4145ced9d2b83f44f4a82c4861822fdb.json new file mode 100644 index 0000000..9c1d015 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-4145ced9d2b83f44f4a82c4861822fdb.json @@ -0,0 +1 @@ +{"expireTime":9007200842068348000,"key":"gatsby-plugin-mdx-entire-payload-a637914a26d8c29cb1bb9879aeb06cfc-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug-and-Play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4679},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":80,"offset":4760},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4760},"end":{"line":107,"column":101,"offset":4781},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4781},"end":{"line":107,"column":162,"offset":4842},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":162,"offset":4842},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4844},"end":{"line":112,"column":4,"offset":4933},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4938},"end":{"line":114,"column":10,"offset":4944},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4935},"end":{"line":114,"column":10,"offset":4944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":339,"offset":5284},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":340,"offset":5285},"end":{"line":116,"column":354,"offset":5299},"indent":[]}}],"position":{"start":{"line":116,"column":339,"offset":5284},"end":{"line":116,"column":390,"offset":5335},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":390,"offset":5335},"end":{"line":116,"column":391,"offset":5336},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":391,"offset":5336},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5342},"end":{"line":118,"column":18,"offset":5355},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5338},"end":{"line":118,"column":18,"offset":5355},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5357},"end":{"line":120,"column":50,"offset":5406},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5412},"end":{"line":122,"column":11,"offset":5418},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5408},"end":{"line":122,"column":11,"offset":5418},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":64,"offset":5483},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5484},"end":{"line":124,"column":86,"offset":5505},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5483},"end":{"line":124,"column":126,"offset":5545},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5545},"end":{"line":124,"column":127,"offset":5546},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":127,"offset":5546},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5552},"end":{"line":126,"column":26,"offset":5573},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5548},"end":{"line":126,"column":26,"offset":5573},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5702},"end":{"line":132,"column":4,"offset":5741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5931},"end":{"line":138,"column":4,"offset":6009},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6165},"end":{"line":145,"column":4,"offset":6312},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6414},"end":{"line":152,"column":4,"offset":6483},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6489},"end":{"line":154,"column":12,"offset":6496},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6485},"end":{"line":154,"column":12,"offset":6496},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":157,"column":25,"offset":6586},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6587},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":158,"column":59,"offset":6645},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":160,"column":4,"offset":6650},"end":{"line":160,"column":10,"offset":6656},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":6647},"end":{"line":160,"column":10,"offset":6656},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.","position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":102,"offset":6759},"indent":[]}}],"position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":102,"offset":6759},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Especially in the worl\n even on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.","position":{"start":{"line":164,"column":1,"offset":6761},"end":{"line":165,"column":128,"offset":6911},"indent":[1]}}],"position":{"start":{"line":164,"column":1,"offset":6761},"end":{"line":165,"column":128,"offset":6911},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":167,"column":4,"offset":6916},"end":{"line":167,"column":12,"offset":6924},"indent":[]}}],"position":{"start":{"line":167,"column":1,"offset":6913},"end":{"line":167,"column":12,"offset":6924},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":169,"column":1,"offset":6926},"end":{"line":169,"column":133,"offset":7058},"indent":[]}}],"position":{"start":{"line":169,"column":1,"offset":6926},"end":{"line":169,"column":133,"offset":7058},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":171,"column":4,"offset":7063},"end":{"line":171,"column":12,"offset":7071},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":7060},"end":{"line":171,"column":12,"offset":7071},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":173,"column":1,"offset":7073},"end":{"line":173,"column":193,"offset":7265},"indent":[]}}],"position":{"start":{"line":173,"column":1,"offset":7073},"end":{"line":173,"column":193,"offset":7265},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":175,"column":4,"offset":7270},"end":{"line":175,"column":62,"offset":7328},"indent":[]}}],"position":{"start":{"line":175,"column":4,"offset":7270},"end":{"line":175,"column":62,"offset":7328},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7267},"end":{"line":175,"column":62,"offset":7328},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":176,"column":4,"offset":7332},"end":{"line":176,"column":69,"offset":7397},"indent":[]}}],"position":{"start":{"line":176,"column":4,"offset":7332},"end":{"line":176,"column":69,"offset":7397},"indent":[]}}],"position":{"start":{"line":176,"column":1,"offset":7329},"end":{"line":176,"column":69,"offset":7397},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7267},"end":{"line":176,"column":69,"offset":7397},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":178,"column":1,"offset":7399},"end":{"line":178,"column":99,"offset":7497},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7399},"end":{"line":178,"column":99,"offset":7497},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":180,"column":5,"offset":7503},"end":{"line":180,"column":14,"offset":7512},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7499},"end":{"line":180,"column":14,"offset":7512},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":182,"column":1,"offset":7514},"end":{"line":182,"column":71,"offset":7584},"indent":[]}}],"position":{"start":{"line":182,"column":1,"offset":7514},"end":{"line":182,"column":71,"offset":7584},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":184,"column":3,"offset":7588},"end":{"line":184,"column":47,"offset":7632},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":184,"column":47,"offset":7632},"end":{"line":184,"column":79,"offset":7664},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":184,"column":79,"offset":7664},"end":{"line":184,"column":198,"offset":7783},"indent":[]}}],"position":{"start":{"line":184,"column":3,"offset":7588},"end":{"line":184,"column":198,"offset":7783},"indent":[]}}],"position":{"start":{"line":184,"column":1,"offset":7586},"end":{"line":184,"column":198,"offset":7783},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":186,"column":1,"offset":7785},"end":{"line":188,"column":4,"offset":7848},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":190,"column":5,"offset":7854},"end":{"line":190,"column":14,"offset":7863},"indent":[]}}],"position":{"start":{"line":190,"column":1,"offset":7850},"end":{"line":190,"column":14,"offset":7863},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":192,"column":1,"offset":7865},"end":{"line":192,"column":56,"offset":7920},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":7865},"end":{"line":192,"column":56,"offset":7920},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":193,"column":3,"offset":7923},"end":{"line":193,"column":52,"offset":7972},"indent":[]}}],"position":{"start":{"line":193,"column":3,"offset":7923},"end":{"line":193,"column":52,"offset":7972},"indent":[]}}],"position":{"start":{"line":193,"column":3,"offset":7923},"end":{"line":193,"column":52,"offset":7972},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":7921},"end":{"line":193,"column":52,"offset":7972},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":195,"column":1,"offset":7974},"end":{"line":195,"column":3,"offset":7976},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":195,"column":3,"offset":7976},"end":{"line":195,"column":9,"offset":7982},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":195,"column":9,"offset":7982},"end":{"line":195,"column":223,"offset":8196},"indent":[]}}],"position":{"start":{"line":195,"column":1,"offset":7974},"end":{"line":195,"column":223,"offset":8196},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":197,"column":3,"offset":8200},"end":{"line":197,"column":159,"offset":8356},"indent":[]}}],"position":{"start":{"line":197,"column":3,"offset":8200},"end":{"line":197,"column":159,"offset":8356},"indent":[]}}],"position":{"start":{"line":197,"column":1,"offset":8198},"end":{"line":197,"column":159,"offset":8356},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":199,"column":1,"offset":8358},"end":{"line":202,"column":4,"offset":8535},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":204,"column":1,"offset":8537},"end":{"line":204,"column":160,"offset":8696},"indent":[]}}],"position":{"start":{"line":204,"column":1,"offset":8537},"end":{"line":204,"column":160,"offset":8696},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":206,"column":3,"offset":8700},"end":{"line":206,"column":31,"offset":8728},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":206,"column":31,"offset":8728},"end":{"line":206,"column":101,"offset":8798},"indent":[]}}],"position":{"start":{"line":206,"column":3,"offset":8700},"end":{"line":206,"column":101,"offset":8798},"indent":[]}}],"position":{"start":{"line":206,"column":1,"offset":8698},"end":{"line":206,"column":101,"offset":8798},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":208,"column":1,"offset":8800},"end":{"line":211,"column":4,"offset":8972},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":213,"column":1,"offset":8974},"end":{"line":213,"column":73,"offset":9046},"indent":[]}}],"position":{"start":{"line":213,"column":1,"offset":8974},"end":{"line":213,"column":73,"offset":9046},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":216,"column":3,"offset":9051},"end":{"line":216,"column":31,"offset":9079},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":216,"column":31,"offset":9079},"end":{"line":216,"column":101,"offset":9149},"indent":[]}}],"position":{"start":{"line":216,"column":3,"offset":9051},"end":{"line":216,"column":101,"offset":9149},"indent":[]}}],"position":{"start":{"line":216,"column":1,"offset":9049},"end":{"line":216,"column":101,"offset":9149},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":218,"column":1,"offset":9151},"end":{"line":221,"column":4,"offset":9323},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":223,"column":1,"offset":9325},"end":{"line":223,"column":62,"offset":9386},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":223,"column":63,"offset":9387},"end":{"line":223,"column":75,"offset":9399},"indent":[]}}],"position":{"start":{"line":223,"column":62,"offset":9386},"end":{"line":223,"column":143,"offset":9467},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":223,"column":143,"offset":9467},"end":{"line":223,"column":150,"offset":9474},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":223,"column":150,"offset":9474},"end":{"line":223,"column":169,"offset":9493},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":223,"column":169,"offset":9493},"end":{"line":223,"column":170,"offset":9494},"indent":[]}}],"position":{"start":{"line":223,"column":1,"offset":9325},"end":{"line":223,"column":170,"offset":9494},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":225,"column":1,"offset":9496},"end":{"line":227,"column":4,"offset":9523},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":229,"column":1,"offset":9525},"end":{"line":229,"column":58,"offset":9582},"indent":[]}}],"position":{"start":{"line":229,"column":1,"offset":9525},"end":{"line":229,"column":58,"offset":9582},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":231,"column":1,"offset":9584},"end":{"line":234,"column":4,"offset":9654},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":236,"column":5,"offset":9660},"end":{"line":236,"column":8,"offset":9663},"indent":[]}}],"position":{"start":{"line":236,"column":1,"offset":9656},"end":{"line":236,"column":8,"offset":9663},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":238,"column":1,"offset":9665},"end":{"line":238,"column":280,"offset":9944},"indent":[]}}],"position":{"start":{"line":238,"column":1,"offset":9665},"end":{"line":238,"column":280,"offset":9944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":240,"column":1,"offset":9946},"end":{"line":240,"column":37,"offset":9982},"indent":[]}}],"position":{"start":{"line":240,"column":1,"offset":9946},"end":{"line":240,"column":37,"offset":9982},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":242,"column":1,"offset":9984},"end":{"line":244,"column":4,"offset":10157},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":246,"column":1,"offset":10159},"end":{"line":246,"column":25,"offset":10183},"indent":[]}}],"position":{"start":{"line":246,"column":1,"offset":10159},"end":{"line":246,"column":25,"offset":10183},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":248,"column":1,"offset":10185},"end":{"line":251,"column":4,"offset":10289},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":253,"column":1,"offset":10291},"end":{"line":253,"column":118,"offset":10408},"indent":[]}}],"position":{"start":{"line":253,"column":1,"offset":10291},"end":{"line":253,"column":118,"offset":10408},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":255,"column":1,"offset":10410},"end":{"line":275,"column":4,"offset":10917},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":277,"column":1,"offset":10919},"end":{"line":277,"column":14,"offset":10932},"indent":[]}}],"position":{"start":{"line":277,"column":1,"offset":10919},"end":{"line":277,"column":14,"offset":10932},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":279,"column":1,"offset":10934},"end":{"line":281,"column":4,"offset":10970},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":283,"column":1,"offset":10972},"end":{"line":283,"column":91,"offset":11062},"indent":[]}}],"position":{"start":{"line":283,"column":1,"offset":10972},"end":{"line":283,"column":91,"offset":11062},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":285,"column":1,"offset":11064},"end":{"line":293,"column":4,"offset":11437},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":295,"column":1,"offset":11439},"end":{"line":295,"column":145,"offset":11583},"indent":[]}}],"position":{"start":{"line":295,"column":1,"offset":11439},"end":{"line":295,"column":145,"offset":11583},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":297,"column":5,"offset":11589},"end":{"line":297,"column":17,"offset":11601},"indent":[]}}],"position":{"start":{"line":297,"column":1,"offset":11585},"end":{"line":297,"column":17,"offset":11601},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":299,"column":1,"offset":11603},"end":{"line":299,"column":300,"offset":11902},"indent":[]}}],"position":{"start":{"line":299,"column":1,"offset":11603},"end":{"line":299,"column":300,"offset":11902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":301,"column":1,"offset":11904},"end":{"line":301,"column":178,"offset":12081},"indent":[]}}],"position":{"start":{"line":301,"column":1,"offset":11904},"end":{"line":301,"column":178,"offset":12081},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":303,"column":1,"offset":12083},"end":{"line":303,"column":48,"offset":12130},"indent":[]}}],"position":{"start":{"line":303,"column":1,"offset":12083},"end":{"line":303,"column":48,"offset":12130},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":305,"column":1,"offset":12132},"end":{"line":307,"column":4,"offset":12172},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":309,"column":1,"offset":12174},"end":{"line":309,"column":104,"offset":12277},"indent":[]}}],"position":{"start":{"line":309,"column":1,"offset":12174},"end":{"line":309,"column":104,"offset":12277},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":311,"column":1,"offset":12279},"end":{"line":319,"column":4,"offset":12549},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":321,"column":1,"offset":12551},"end":{"line":321,"column":28,"offset":12578},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":12551},"end":{"line":321,"column":28,"offset":12578},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":323,"column":1,"offset":12580},"end":{"line":325,"column":4,"offset":12624},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":327,"column":1,"offset":12626},"end":{"line":327,"column":48,"offset":12673},"indent":[]}}],"position":{"start":{"line":327,"column":1,"offset":12626},"end":{"line":327,"column":48,"offset":12673},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":329,"column":1,"offset":12675},"end":{"line":331,"column":4,"offset":12697},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":333,"column":1,"offset":12699},"end":{"line":333,"column":72,"offset":12770},"indent":[]}}],"position":{"start":{"line":333,"column":1,"offset":12699},"end":{"line":333,"column":72,"offset":12770},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":335,"column":1,"offset":12772},"end":{"line":337,"column":4,"offset":12829},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":339,"column":4,"offset":12834},"end":{"line":339,"column":11,"offset":12841},"indent":[]}}],"position":{"start":{"line":339,"column":1,"offset":12831},"end":{"line":339,"column":11,"offset":12841},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":341,"column":1,"offset":12843},"end":{"line":341,"column":283,"offset":13125},"indent":[]}}],"position":{"start":{"line":341,"column":1,"offset":12843},"end":{"line":341,"column":283,"offset":13125},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":343,"column":3,"offset":13129},"end":{"line":343,"column":54,"offset":13180},"indent":[]}}],"position":{"start":{"line":343,"column":3,"offset":13129},"end":{"line":343,"column":54,"offset":13180},"indent":[]}}],"position":{"start":{"line":343,"column":1,"offset":13127},"end":{"line":343,"column":54,"offset":13180},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":345,"column":5,"offset":13186},"end":{"line":345,"column":14,"offset":13195},"indent":[]}}],"position":{"start":{"line":345,"column":1,"offset":13182},"end":{"line":345,"column":14,"offset":13195},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":347,"column":1,"offset":13197},"end":{"line":347,"column":68,"offset":13264},"indent":[]}}],"position":{"start":{"line":347,"column":1,"offset":13197},"end":{"line":347,"column":68,"offset":13264},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":349,"column":1,"offset":13266},"end":{"line":352,"column":4,"offset":13417},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":354,"column":1,"offset":13419},"end":{"line":354,"column":46,"offset":13464},"indent":[]}}],"position":{"start":{"line":354,"column":1,"offset":13419},"end":{"line":354,"column":46,"offset":13464},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":356,"column":3,"offset":13468},"end":{"line":356,"column":103,"offset":13568},"indent":[]}}],"position":{"start":{"line":356,"column":3,"offset":13468},"end":{"line":356,"column":103,"offset":13568},"indent":[]}}],"position":{"start":{"line":356,"column":1,"offset":13466},"end":{"line":356,"column":103,"offset":13568},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":358,"column":1,"offset":13570},"end":{"line":363,"column":4,"offset":13780},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":365,"column":1,"offset":13782},"end":{"line":365,"column":151,"offset":13932},"indent":[]}}],"position":{"start":{"line":365,"column":1,"offset":13782},"end":{"line":365,"column":151,"offset":13932},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":367,"column":3,"offset":13936},"end":{"line":367,"column":22,"offset":13955},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":367,"column":22,"offset":13955},"end":{"line":367,"column":26,"offset":13959},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":367,"column":26,"offset":13959},"end":{"line":367,"column":40,"offset":13973},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":367,"column":40,"offset":13973},"end":{"line":367,"column":50,"offset":13983},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":367,"column":50,"offset":13983},"end":{"line":367,"column":98,"offset":14031},"indent":[]}}],"position":{"start":{"line":367,"column":3,"offset":13936},"end":{"line":367,"column":98,"offset":14031},"indent":[]}}],"position":{"start":{"line":367,"column":1,"offset":13934},"end":{"line":367,"column":98,"offset":14031},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":369,"column":1,"offset":14033},"end":{"line":373,"column":4,"offset":14195},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":375,"column":1,"offset":14197},"end":{"line":375,"column":72,"offset":14268},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":375,"column":72,"offset":14268},"end":{"line":375,"column":84,"offset":14280},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":375,"column":84,"offset":14280},"end":{"line":375,"column":102,"offset":14298},"indent":[]}}],"position":{"start":{"line":375,"column":1,"offset":14197},"end":{"line":375,"column":102,"offset":14298},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":377,"column":1,"offset":14300},"end":{"line":380,"column":4,"offset":14374},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":382,"column":5,"offset":14380},"end":{"line":382,"column":8,"offset":14383},"indent":[]}}],"position":{"start":{"line":382,"column":1,"offset":14376},"end":{"line":382,"column":8,"offset":14383},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":384,"column":1,"offset":14385},"end":{"line":384,"column":176,"offset":14560},"indent":[]}}],"position":{"start":{"line":384,"column":1,"offset":14385},"end":{"line":384,"column":176,"offset":14560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":386,"column":1,"offset":14562},"end":{"line":393,"column":4,"offset":14859},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":395,"column":1,"offset":14861},"end":{"line":395,"column":60,"offset":14920},"indent":[]}}],"position":{"start":{"line":395,"column":1,"offset":14861},"end":{"line":395,"column":60,"offset":14920},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":397,"column":1,"offset":14922},"end":{"line":401,"column":4,"offset":15048},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":403,"column":1,"offset":15050},"end":{"line":403,"column":63,"offset":15112},"indent":[]}}],"position":{"start":{"line":403,"column":1,"offset":15050},"end":{"line":403,"column":63,"offset":15112},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":405,"column":1,"offset":15114},"end":{"line":425,"column":4,"offset":15621},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":427,"column":1,"offset":15623},"end":{"line":427,"column":99,"offset":15721},"indent":[]}}],"position":{"start":{"line":427,"column":1,"offset":15623},"end":{"line":427,"column":99,"offset":15721},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":429,"column":1,"offset":15723},"end":{"line":432,"column":4,"offset":15825},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":434,"column":1,"offset":15827},"end":{"line":434,"column":37,"offset":15863},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":434,"column":37,"offset":15863},"end":{"line":434,"column":47,"offset":15873},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":434,"column":47,"offset":15873},"end":{"line":434,"column":89,"offset":15915},"indent":[]}}],"position":{"start":{"line":434,"column":1,"offset":15827},"end":{"line":434,"column":89,"offset":15915},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":436,"column":1,"offset":15917},"end":{"line":440,"column":4,"offset":16042},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":442,"column":1,"offset":16044},"end":{"line":442,"column":78,"offset":16121},"indent":[]}}],"position":{"start":{"line":442,"column":1,"offset":16044},"end":{"line":442,"column":78,"offset":16121},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":444,"column":1,"offset":16123},"end":{"line":448,"column":4,"offset":16227},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":450,"column":1,"offset":16229},"end":{"line":450,"column":75,"offset":16303},"indent":[]}}],"position":{"start":{"line":450,"column":1,"offset":16229},"end":{"line":450,"column":75,"offset":16303},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":452,"column":1,"offset":16305},"end":{"line":456,"column":4,"offset":16378},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":458,"column":1,"offset":16380},"end":{"line":458,"column":145,"offset":16524},"indent":[]}}],"position":{"start":{"line":458,"column":1,"offset":16380},"end":{"line":458,"column":145,"offset":16524},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":460,"column":5,"offset":16530},"end":{"line":460,"column":17,"offset":16542},"indent":[]}}],"position":{"start":{"line":460,"column":1,"offset":16526},"end":{"line":460,"column":17,"offset":16542},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":462,"column":1,"offset":16544},"end":{"line":462,"column":300,"offset":16843},"indent":[]}}],"position":{"start":{"line":462,"column":1,"offset":16544},"end":{"line":462,"column":300,"offset":16843},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":464,"column":1,"offset":16845},"end":{"line":464,"column":178,"offset":17022},"indent":[]}}],"position":{"start":{"line":464,"column":1,"offset":16845},"end":{"line":464,"column":178,"offset":17022},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":466,"column":1,"offset":17024},"end":{"line":466,"column":48,"offset":17071},"indent":[]}}],"position":{"start":{"line":466,"column":1,"offset":17024},"end":{"line":466,"column":48,"offset":17071},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":468,"column":1,"offset":17073},"end":{"line":470,"column":4,"offset":17117},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":472,"column":1,"offset":17119},"end":{"line":472,"column":104,"offset":17222},"indent":[]}}],"position":{"start":{"line":472,"column":1,"offset":17119},"end":{"line":472,"column":104,"offset":17222},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":474,"column":1,"offset":17224},"end":{"line":482,"column":4,"offset":17494},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":484,"column":1,"offset":17496},"end":{"line":484,"column":28,"offset":17523},"indent":[]}}],"position":{"start":{"line":484,"column":1,"offset":17496},"end":{"line":484,"column":28,"offset":17523},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":486,"column":1,"offset":17525},"end":{"line":488,"column":4,"offset":17573},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":490,"column":1,"offset":17575},"end":{"line":490,"column":48,"offset":17622},"indent":[]}}],"position":{"start":{"line":490,"column":1,"offset":17575},"end":{"line":490,"column":48,"offset":17622},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":492,"column":1,"offset":17624},"end":{"line":494,"column":4,"offset":17646},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":496,"column":1,"offset":17648},"end":{"line":496,"column":72,"offset":17719},"indent":[]}}],"position":{"start":{"line":496,"column":1,"offset":17648},"end":{"line":496,"column":72,"offset":17719},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":498,"column":1,"offset":17721},"end":{"line":500,"column":4,"offset":17782},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":503,"column":1,"offset":17785},"end":{"line":503,"column":31,"offset":17815},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":503,"column":31,"offset":17815}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug-and-Play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.`}

\n

{`Especially in the worl\neven on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.`}

\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-41b16d38bc61c17499eedf3de99373a4.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-41b16d38bc61c17499eedf3de99373a4.json new file mode 100644 index 0000000..379ff92 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-41b16d38bc61c17499eedf3de99373a4.json @@ -0,0 +1 @@ +{"expireTime":9007200842068404000,"key":"gatsby-plugin-mdx-entire-payload-8ddd66cc6c1cc6a493eff091d96bcee1-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4679},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":80,"offset":4760},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4760},"end":{"line":107,"column":101,"offset":4781},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4781},"end":{"line":107,"column":162,"offset":4842},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":162,"offset":4842},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4844},"end":{"line":112,"column":4,"offset":4933},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4938},"end":{"line":114,"column":10,"offset":4944},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4935},"end":{"line":114,"column":10,"offset":4944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":339,"offset":5284},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":340,"offset":5285},"end":{"line":116,"column":354,"offset":5299},"indent":[]}}],"position":{"start":{"line":116,"column":339,"offset":5284},"end":{"line":116,"column":390,"offset":5335},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":390,"offset":5335},"end":{"line":116,"column":391,"offset":5336},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":391,"offset":5336},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5342},"end":{"line":118,"column":18,"offset":5355},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5338},"end":{"line":118,"column":18,"offset":5355},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5357},"end":{"line":120,"column":50,"offset":5406},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5412},"end":{"line":122,"column":11,"offset":5418},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5408},"end":{"line":122,"column":11,"offset":5418},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":64,"offset":5483},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5484},"end":{"line":124,"column":86,"offset":5505},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5483},"end":{"line":124,"column":126,"offset":5545},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5545},"end":{"line":124,"column":127,"offset":5546},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":127,"offset":5546},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5552},"end":{"line":126,"column":26,"offset":5573},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5548},"end":{"line":126,"column":26,"offset":5573},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5702},"end":{"line":132,"column":4,"offset":5741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5931},"end":{"line":138,"column":4,"offset":6009},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6165},"end":{"line":145,"column":4,"offset":6312},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6414},"end":{"line":152,"column":4,"offset":6483},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6489},"end":{"line":154,"column":12,"offset":6496},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6485},"end":{"line":154,"column":12,"offset":6496},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":157,"column":25,"offset":6586},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6587},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":158,"column":59,"offset":6645},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":160,"column":4,"offset":6650},"end":{"line":160,"column":10,"offset":6656},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":6647},"end":{"line":160,"column":10,"offset":6656},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.","position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":102,"offset":6759},"indent":[]}}],"position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":102,"offset":6759},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Especially in the worl\n even on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.","position":{"start":{"line":164,"column":1,"offset":6761},"end":{"line":165,"column":128,"offset":6911},"indent":[1]}}],"position":{"start":{"line":164,"column":1,"offset":6761},"end":{"line":165,"column":128,"offset":6911},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":167,"column":1,"offset":6913},"end":{"line":167,"column":4,"offset":6916},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":169,"column":3,"offset":6920},"end":{"line":169,"column":11,"offset":6928},"indent":[]}}],"position":{"start":{"line":169,"column":1,"offset":6918},"end":{"line":169,"column":11,"offset":6928},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":171,"column":1,"offset":6930},"end":{"line":171,"column":133,"offset":7062},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":6930},"end":{"line":171,"column":133,"offset":7062},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":173,"column":4,"offset":7067},"end":{"line":173,"column":12,"offset":7075},"indent":[]}}],"position":{"start":{"line":173,"column":1,"offset":7064},"end":{"line":173,"column":12,"offset":7075},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":175,"column":1,"offset":7077},"end":{"line":175,"column":193,"offset":7269},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7077},"end":{"line":175,"column":193,"offset":7269},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":177,"column":4,"offset":7274},"end":{"line":177,"column":62,"offset":7332},"indent":[]}}],"position":{"start":{"line":177,"column":4,"offset":7274},"end":{"line":177,"column":62,"offset":7332},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7271},"end":{"line":177,"column":62,"offset":7332},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":178,"column":4,"offset":7336},"end":{"line":178,"column":69,"offset":7401},"indent":[]}}],"position":{"start":{"line":178,"column":4,"offset":7336},"end":{"line":178,"column":69,"offset":7401},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7333},"end":{"line":178,"column":69,"offset":7401},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7271},"end":{"line":178,"column":69,"offset":7401},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":180,"column":1,"offset":7403},"end":{"line":180,"column":99,"offset":7501},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7403},"end":{"line":180,"column":99,"offset":7501},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":182,"column":5,"offset":7507},"end":{"line":182,"column":14,"offset":7516},"indent":[]}}],"position":{"start":{"line":182,"column":1,"offset":7503},"end":{"line":182,"column":14,"offset":7516},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":184,"column":1,"offset":7518},"end":{"line":184,"column":71,"offset":7588},"indent":[]}}],"position":{"start":{"line":184,"column":1,"offset":7518},"end":{"line":184,"column":71,"offset":7588},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":186,"column":3,"offset":7592},"end":{"line":186,"column":47,"offset":7636},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":186,"column":47,"offset":7636},"end":{"line":186,"column":79,"offset":7668},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":186,"column":79,"offset":7668},"end":{"line":186,"column":198,"offset":7787},"indent":[]}}],"position":{"start":{"line":186,"column":3,"offset":7592},"end":{"line":186,"column":198,"offset":7787},"indent":[]}}],"position":{"start":{"line":186,"column":1,"offset":7590},"end":{"line":186,"column":198,"offset":7787},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":188,"column":1,"offset":7789},"end":{"line":190,"column":4,"offset":7852},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":192,"column":5,"offset":7858},"end":{"line":192,"column":14,"offset":7867},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":7854},"end":{"line":192,"column":14,"offset":7867},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":194,"column":1,"offset":7869},"end":{"line":194,"column":56,"offset":7924},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":7869},"end":{"line":194,"column":56,"offset":7924},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":195,"column":3,"offset":7927},"end":{"line":195,"column":52,"offset":7976},"indent":[]}}],"position":{"start":{"line":195,"column":3,"offset":7927},"end":{"line":195,"column":52,"offset":7976},"indent":[]}}],"position":{"start":{"line":195,"column":3,"offset":7927},"end":{"line":195,"column":52,"offset":7976},"indent":[]}}],"position":{"start":{"line":195,"column":1,"offset":7925},"end":{"line":195,"column":52,"offset":7976},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":197,"column":1,"offset":7978},"end":{"line":197,"column":3,"offset":7980},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":197,"column":3,"offset":7980},"end":{"line":197,"column":9,"offset":7986},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":197,"column":9,"offset":7986},"end":{"line":197,"column":223,"offset":8200},"indent":[]}}],"position":{"start":{"line":197,"column":1,"offset":7978},"end":{"line":197,"column":223,"offset":8200},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":199,"column":3,"offset":8204},"end":{"line":199,"column":159,"offset":8360},"indent":[]}}],"position":{"start":{"line":199,"column":3,"offset":8204},"end":{"line":199,"column":159,"offset":8360},"indent":[]}}],"position":{"start":{"line":199,"column":1,"offset":8202},"end":{"line":199,"column":159,"offset":8360},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":201,"column":1,"offset":8362},"end":{"line":204,"column":4,"offset":8539},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":206,"column":1,"offset":8541},"end":{"line":206,"column":160,"offset":8700},"indent":[]}}],"position":{"start":{"line":206,"column":1,"offset":8541},"end":{"line":206,"column":160,"offset":8700},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":208,"column":3,"offset":8704},"end":{"line":208,"column":31,"offset":8732},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":208,"column":31,"offset":8732},"end":{"line":208,"column":101,"offset":8802},"indent":[]}}],"position":{"start":{"line":208,"column":3,"offset":8704},"end":{"line":208,"column":101,"offset":8802},"indent":[]}}],"position":{"start":{"line":208,"column":1,"offset":8702},"end":{"line":208,"column":101,"offset":8802},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":210,"column":1,"offset":8804},"end":{"line":213,"column":4,"offset":8976},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":215,"column":1,"offset":8978},"end":{"line":215,"column":73,"offset":9050},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":8978},"end":{"line":215,"column":73,"offset":9050},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":218,"column":3,"offset":9055},"end":{"line":218,"column":31,"offset":9083},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":218,"column":31,"offset":9083},"end":{"line":218,"column":101,"offset":9153},"indent":[]}}],"position":{"start":{"line":218,"column":3,"offset":9055},"end":{"line":218,"column":101,"offset":9153},"indent":[]}}],"position":{"start":{"line":218,"column":1,"offset":9053},"end":{"line":218,"column":101,"offset":9153},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":220,"column":1,"offset":9155},"end":{"line":223,"column":4,"offset":9327},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":225,"column":1,"offset":9329},"end":{"line":225,"column":62,"offset":9390},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":225,"column":63,"offset":9391},"end":{"line":225,"column":75,"offset":9403},"indent":[]}}],"position":{"start":{"line":225,"column":62,"offset":9390},"end":{"line":225,"column":143,"offset":9471},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":225,"column":143,"offset":9471},"end":{"line":225,"column":150,"offset":9478},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":225,"column":150,"offset":9478},"end":{"line":225,"column":169,"offset":9497},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":225,"column":169,"offset":9497},"end":{"line":225,"column":170,"offset":9498},"indent":[]}}],"position":{"start":{"line":225,"column":1,"offset":9329},"end":{"line":225,"column":170,"offset":9498},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":227,"column":1,"offset":9500},"end":{"line":229,"column":4,"offset":9527},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":231,"column":1,"offset":9529},"end":{"line":231,"column":58,"offset":9586},"indent":[]}}],"position":{"start":{"line":231,"column":1,"offset":9529},"end":{"line":231,"column":58,"offset":9586},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":233,"column":1,"offset":9588},"end":{"line":236,"column":4,"offset":9658},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":238,"column":5,"offset":9664},"end":{"line":238,"column":8,"offset":9667},"indent":[]}}],"position":{"start":{"line":238,"column":1,"offset":9660},"end":{"line":238,"column":8,"offset":9667},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":240,"column":1,"offset":9669},"end":{"line":240,"column":280,"offset":9948},"indent":[]}}],"position":{"start":{"line":240,"column":1,"offset":9669},"end":{"line":240,"column":280,"offset":9948},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":242,"column":1,"offset":9950},"end":{"line":242,"column":37,"offset":9986},"indent":[]}}],"position":{"start":{"line":242,"column":1,"offset":9950},"end":{"line":242,"column":37,"offset":9986},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":244,"column":1,"offset":9988},"end":{"line":246,"column":4,"offset":10161},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":248,"column":1,"offset":10163},"end":{"line":248,"column":25,"offset":10187},"indent":[]}}],"position":{"start":{"line":248,"column":1,"offset":10163},"end":{"line":248,"column":25,"offset":10187},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":250,"column":1,"offset":10189},"end":{"line":253,"column":4,"offset":10293},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":255,"column":1,"offset":10295},"end":{"line":255,"column":118,"offset":10412},"indent":[]}}],"position":{"start":{"line":255,"column":1,"offset":10295},"end":{"line":255,"column":118,"offset":10412},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":257,"column":1,"offset":10414},"end":{"line":277,"column":4,"offset":10921},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":279,"column":1,"offset":10923},"end":{"line":279,"column":14,"offset":10936},"indent":[]}}],"position":{"start":{"line":279,"column":1,"offset":10923},"end":{"line":279,"column":14,"offset":10936},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":281,"column":1,"offset":10938},"end":{"line":283,"column":4,"offset":10974},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":285,"column":1,"offset":10976},"end":{"line":285,"column":91,"offset":11066},"indent":[]}}],"position":{"start":{"line":285,"column":1,"offset":10976},"end":{"line":285,"column":91,"offset":11066},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":287,"column":1,"offset":11068},"end":{"line":295,"column":4,"offset":11441},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":297,"column":1,"offset":11443},"end":{"line":297,"column":145,"offset":11587},"indent":[]}}],"position":{"start":{"line":297,"column":1,"offset":11443},"end":{"line":297,"column":145,"offset":11587},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":299,"column":5,"offset":11593},"end":{"line":299,"column":17,"offset":11605},"indent":[]}}],"position":{"start":{"line":299,"column":1,"offset":11589},"end":{"line":299,"column":17,"offset":11605},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":301,"column":1,"offset":11607},"end":{"line":301,"column":300,"offset":11906},"indent":[]}}],"position":{"start":{"line":301,"column":1,"offset":11607},"end":{"line":301,"column":300,"offset":11906},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":303,"column":1,"offset":11908},"end":{"line":303,"column":178,"offset":12085},"indent":[]}}],"position":{"start":{"line":303,"column":1,"offset":11908},"end":{"line":303,"column":178,"offset":12085},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":305,"column":1,"offset":12087},"end":{"line":305,"column":48,"offset":12134},"indent":[]}}],"position":{"start":{"line":305,"column":1,"offset":12087},"end":{"line":305,"column":48,"offset":12134},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":307,"column":1,"offset":12136},"end":{"line":309,"column":4,"offset":12176},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":311,"column":1,"offset":12178},"end":{"line":311,"column":104,"offset":12281},"indent":[]}}],"position":{"start":{"line":311,"column":1,"offset":12178},"end":{"line":311,"column":104,"offset":12281},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":313,"column":1,"offset":12283},"end":{"line":321,"column":4,"offset":12553},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":323,"column":1,"offset":12555},"end":{"line":323,"column":28,"offset":12582},"indent":[]}}],"position":{"start":{"line":323,"column":1,"offset":12555},"end":{"line":323,"column":28,"offset":12582},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":325,"column":1,"offset":12584},"end":{"line":327,"column":4,"offset":12628},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":329,"column":1,"offset":12630},"end":{"line":329,"column":48,"offset":12677},"indent":[]}}],"position":{"start":{"line":329,"column":1,"offset":12630},"end":{"line":329,"column":48,"offset":12677},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":331,"column":1,"offset":12679},"end":{"line":333,"column":4,"offset":12701},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":335,"column":1,"offset":12703},"end":{"line":335,"column":72,"offset":12774},"indent":[]}}],"position":{"start":{"line":335,"column":1,"offset":12703},"end":{"line":335,"column":72,"offset":12774},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":337,"column":1,"offset":12776},"end":{"line":339,"column":4,"offset":12833},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":341,"column":4,"offset":12838},"end":{"line":341,"column":11,"offset":12845},"indent":[]}}],"position":{"start":{"line":341,"column":1,"offset":12835},"end":{"line":341,"column":11,"offset":12845},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":343,"column":1,"offset":12847},"end":{"line":343,"column":283,"offset":13129},"indent":[]}}],"position":{"start":{"line":343,"column":1,"offset":12847},"end":{"line":343,"column":283,"offset":13129},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":345,"column":3,"offset":13133},"end":{"line":345,"column":54,"offset":13184},"indent":[]}}],"position":{"start":{"line":345,"column":3,"offset":13133},"end":{"line":345,"column":54,"offset":13184},"indent":[]}}],"position":{"start":{"line":345,"column":1,"offset":13131},"end":{"line":345,"column":54,"offset":13184},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":347,"column":5,"offset":13190},"end":{"line":347,"column":14,"offset":13199},"indent":[]}}],"position":{"start":{"line":347,"column":1,"offset":13186},"end":{"line":347,"column":14,"offset":13199},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":349,"column":1,"offset":13201},"end":{"line":349,"column":68,"offset":13268},"indent":[]}}],"position":{"start":{"line":349,"column":1,"offset":13201},"end":{"line":349,"column":68,"offset":13268},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":351,"column":1,"offset":13270},"end":{"line":354,"column":4,"offset":13421},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":356,"column":1,"offset":13423},"end":{"line":356,"column":46,"offset":13468},"indent":[]}}],"position":{"start":{"line":356,"column":1,"offset":13423},"end":{"line":356,"column":46,"offset":13468},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":358,"column":3,"offset":13472},"end":{"line":358,"column":103,"offset":13572},"indent":[]}}],"position":{"start":{"line":358,"column":3,"offset":13472},"end":{"line":358,"column":103,"offset":13572},"indent":[]}}],"position":{"start":{"line":358,"column":1,"offset":13470},"end":{"line":358,"column":103,"offset":13572},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":360,"column":1,"offset":13574},"end":{"line":365,"column":4,"offset":13784},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":367,"column":1,"offset":13786},"end":{"line":367,"column":151,"offset":13936},"indent":[]}}],"position":{"start":{"line":367,"column":1,"offset":13786},"end":{"line":367,"column":151,"offset":13936},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":369,"column":3,"offset":13940},"end":{"line":369,"column":22,"offset":13959},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":369,"column":22,"offset":13959},"end":{"line":369,"column":26,"offset":13963},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":369,"column":26,"offset":13963},"end":{"line":369,"column":40,"offset":13977},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":369,"column":40,"offset":13977},"end":{"line":369,"column":50,"offset":13987},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":369,"column":50,"offset":13987},"end":{"line":369,"column":98,"offset":14035},"indent":[]}}],"position":{"start":{"line":369,"column":3,"offset":13940},"end":{"line":369,"column":98,"offset":14035},"indent":[]}}],"position":{"start":{"line":369,"column":1,"offset":13938},"end":{"line":369,"column":98,"offset":14035},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":371,"column":1,"offset":14037},"end":{"line":375,"column":4,"offset":14199},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":377,"column":1,"offset":14201},"end":{"line":377,"column":72,"offset":14272},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":377,"column":72,"offset":14272},"end":{"line":377,"column":84,"offset":14284},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":377,"column":84,"offset":14284},"end":{"line":377,"column":102,"offset":14302},"indent":[]}}],"position":{"start":{"line":377,"column":1,"offset":14201},"end":{"line":377,"column":102,"offset":14302},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":379,"column":1,"offset":14304},"end":{"line":382,"column":4,"offset":14378},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":384,"column":5,"offset":14384},"end":{"line":384,"column":8,"offset":14387},"indent":[]}}],"position":{"start":{"line":384,"column":1,"offset":14380},"end":{"line":384,"column":8,"offset":14387},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":386,"column":1,"offset":14389},"end":{"line":386,"column":176,"offset":14564},"indent":[]}}],"position":{"start":{"line":386,"column":1,"offset":14389},"end":{"line":386,"column":176,"offset":14564},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":388,"column":1,"offset":14566},"end":{"line":395,"column":4,"offset":14863},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":397,"column":1,"offset":14865},"end":{"line":397,"column":60,"offset":14924},"indent":[]}}],"position":{"start":{"line":397,"column":1,"offset":14865},"end":{"line":397,"column":60,"offset":14924},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":399,"column":1,"offset":14926},"end":{"line":403,"column":4,"offset":15052},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":405,"column":1,"offset":15054},"end":{"line":405,"column":63,"offset":15116},"indent":[]}}],"position":{"start":{"line":405,"column":1,"offset":15054},"end":{"line":405,"column":63,"offset":15116},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":407,"column":1,"offset":15118},"end":{"line":427,"column":4,"offset":15625},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":429,"column":1,"offset":15627},"end":{"line":429,"column":99,"offset":15725},"indent":[]}}],"position":{"start":{"line":429,"column":1,"offset":15627},"end":{"line":429,"column":99,"offset":15725},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":431,"column":1,"offset":15727},"end":{"line":434,"column":4,"offset":15829},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":436,"column":1,"offset":15831},"end":{"line":436,"column":37,"offset":15867},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":436,"column":37,"offset":15867},"end":{"line":436,"column":47,"offset":15877},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":436,"column":47,"offset":15877},"end":{"line":436,"column":89,"offset":15919},"indent":[]}}],"position":{"start":{"line":436,"column":1,"offset":15831},"end":{"line":436,"column":89,"offset":15919},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":438,"column":1,"offset":15921},"end":{"line":442,"column":4,"offset":16046},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":444,"column":1,"offset":16048},"end":{"line":444,"column":78,"offset":16125},"indent":[]}}],"position":{"start":{"line":444,"column":1,"offset":16048},"end":{"line":444,"column":78,"offset":16125},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":446,"column":1,"offset":16127},"end":{"line":450,"column":4,"offset":16231},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":452,"column":1,"offset":16233},"end":{"line":452,"column":75,"offset":16307},"indent":[]}}],"position":{"start":{"line":452,"column":1,"offset":16233},"end":{"line":452,"column":75,"offset":16307},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":454,"column":1,"offset":16309},"end":{"line":458,"column":4,"offset":16382},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":460,"column":1,"offset":16384},"end":{"line":460,"column":145,"offset":16528},"indent":[]}}],"position":{"start":{"line":460,"column":1,"offset":16384},"end":{"line":460,"column":145,"offset":16528},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":462,"column":5,"offset":16534},"end":{"line":462,"column":17,"offset":16546},"indent":[]}}],"position":{"start":{"line":462,"column":1,"offset":16530},"end":{"line":462,"column":17,"offset":16546},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":464,"column":1,"offset":16548},"end":{"line":464,"column":300,"offset":16847},"indent":[]}}],"position":{"start":{"line":464,"column":1,"offset":16548},"end":{"line":464,"column":300,"offset":16847},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":466,"column":1,"offset":16849},"end":{"line":466,"column":178,"offset":17026},"indent":[]}}],"position":{"start":{"line":466,"column":1,"offset":16849},"end":{"line":466,"column":178,"offset":17026},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":468,"column":1,"offset":17028},"end":{"line":468,"column":48,"offset":17075},"indent":[]}}],"position":{"start":{"line":468,"column":1,"offset":17028},"end":{"line":468,"column":48,"offset":17075},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":470,"column":1,"offset":17077},"end":{"line":472,"column":4,"offset":17121},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":474,"column":1,"offset":17123},"end":{"line":474,"column":104,"offset":17226},"indent":[]}}],"position":{"start":{"line":474,"column":1,"offset":17123},"end":{"line":474,"column":104,"offset":17226},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":476,"column":1,"offset":17228},"end":{"line":484,"column":4,"offset":17498},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":486,"column":1,"offset":17500},"end":{"line":486,"column":28,"offset":17527},"indent":[]}}],"position":{"start":{"line":486,"column":1,"offset":17500},"end":{"line":486,"column":28,"offset":17527},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":488,"column":1,"offset":17529},"end":{"line":490,"column":4,"offset":17577},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":492,"column":1,"offset":17579},"end":{"line":492,"column":48,"offset":17626},"indent":[]}}],"position":{"start":{"line":492,"column":1,"offset":17579},"end":{"line":492,"column":48,"offset":17626},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":494,"column":1,"offset":17628},"end":{"line":496,"column":4,"offset":17650},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":498,"column":1,"offset":17652},"end":{"line":498,"column":72,"offset":17723},"indent":[]}}],"position":{"start":{"line":498,"column":1,"offset":17652},"end":{"line":498,"column":72,"offset":17723},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":500,"column":1,"offset":17725},"end":{"line":502,"column":4,"offset":17786},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":505,"column":1,"offset":17789},"end":{"line":505,"column":31,"offset":17819},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":505,"column":31,"offset":17819}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.`}

\n

{`Especially in the worl\neven on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-41e3f0e02f3884e0729d517829b6ddf0.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-41e3f0e02f3884e0729d517829b6ddf0.json new file mode 100644 index 0000000..9f1d363 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-41e3f0e02f3884e0729d517829b6ddf0.json @@ -0,0 +1 @@ +{"expireTime":9007200842068131000,"key":"gatsby-plugin-mdx-entire-payload-4f928818fb66c5435268a73497cf55be-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug-and-Play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":23,"column":5,"offset":1138},"end":{"line":23,"column":18,"offset":1151},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":18,"offset":1151},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":25,"column":1,"offset":1153},"end":{"line":25,"column":156,"offset":1308},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1153},"end":{"line":25,"column":156,"offset":1308},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS for Raspberry Pi","position":{"start":{"line":27,"column":4,"offset":1313},"end":{"line":27,"column":25,"offset":1334},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1310},"end":{"line":27,"column":25,"offset":1334},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":29,"column":1,"offset":1336},"end":{"line":29,"column":229,"offset":1564},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1336},"end":{"line":29,"column":229,"offset":1564},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":31,"column":1,"offset":1566},"end":{"line":31,"column":197,"offset":1762},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1566},"end":{"line":31,"column":197,"offset":1762},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":33,"column":5,"offset":1768},"end":{"line":33,"column":11,"offset":1774},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1764},"end":{"line":33,"column":11,"offset":1774},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":35,"column":1,"offset":1776},"end":{"line":35,"column":63,"offset":1838},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":35,"column":64,"offset":1839},"end":{"line":35,"column":85,"offset":1860},"indent":[]}}],"position":{"start":{"line":35,"column":63,"offset":1838},"end":{"line":35,"column":123,"offset":1898},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":35,"column":123,"offset":1898},"end":{"line":35,"column":124,"offset":1899},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1776},"end":{"line":35,"column":124,"offset":1899},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":37,"column":5,"offset":1905},"end":{"line":37,"column":35,"offset":1935},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1901},"end":{"line":37,"column":35,"offset":1935},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":39,"column":1,"offset":1937},"end":{"line":39,"column":228,"offset":2164},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1937},"end":{"line":39,"column":228,"offset":2164},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":41,"column":1,"offset":2166},"end":{"line":41,"column":67,"offset":2232},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":2166},"end":{"line":41,"column":67,"offset":2232},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":43,"column":1,"offset":2234},"end":{"line":43,"column":50,"offset":2283},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2234},"end":{"line":43,"column":50,"offset":2283},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":45,"column":3,"offset":2287},"end":{"line":45,"column":49,"offset":2333},"indent":[]}}],"position":{"start":{"line":45,"column":3,"offset":2287},"end":{"line":45,"column":49,"offset":2333},"indent":[]}}],"position":{"start":{"line":45,"column":3,"offset":2287},"end":{"line":45,"column":49,"offset":2333},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2285},"end":{"line":45,"column":49,"offset":2333},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":47,"column":5,"offset":2339},"end":{"line":47,"column":11,"offset":2345},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2335},"end":{"line":47,"column":11,"offset":2345},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":49,"column":1,"offset":2347},"end":{"line":49,"column":160,"offset":2506},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2347},"end":{"line":49,"column":160,"offset":2506},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":51,"column":4,"offset":2511},"end":{"line":51,"column":13,"offset":2520},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":51,"column":14,"offset":2521},"end":{"line":51,"column":28,"offset":2535},"indent":[]}}],"position":{"start":{"line":51,"column":13,"offset":2520},"end":{"line":51,"column":75,"offset":2582},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":51,"column":75,"offset":2582},"end":{"line":51,"column":76,"offset":2583},"indent":[]}}],"position":{"start":{"line":51,"column":4,"offset":2511},"end":{"line":51,"column":76,"offset":2583},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2508},"end":{"line":51,"column":76,"offset":2583},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":52,"column":4,"offset":2587},"end":{"line":52,"column":41,"offset":2624},"indent":[]}}],"position":{"start":{"line":52,"column":4,"offset":2587},"end":{"line":52,"column":41,"offset":2624},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2584},"end":{"line":52,"column":41,"offset":2624},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":53,"column":4,"offset":2628},"end":{"line":53,"column":60,"offset":2684},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2628},"end":{"line":53,"column":60,"offset":2684},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2625},"end":{"line":53,"column":60,"offset":2684},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2508},"end":{"line":53,"column":60,"offset":2684},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":55,"column":2,"offset":2687},"end":{"line":55,"column":64,"offset":2749},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2686},"end":{"line":55,"column":96,"offset":2781},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2686},"end":{"line":55,"column":96,"offset":2781},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":57,"column":1,"offset":2783},"end":{"line":57,"column":204,"offset":2986},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2783},"end":{"line":57,"column":204,"offset":2986},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":59,"column":6,"offset":2993},"end":{"line":59,"column":24,"offset":3011},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2988},"end":{"line":59,"column":24,"offset":3011},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":61,"column":1,"offset":3013},"end":{"line":61,"column":95,"offset":3107},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":61,"column":95,"offset":3107},"end":{"line":61,"column":110,"offset":3122},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":61,"column":110,"offset":3122},"end":{"line":61,"column":222,"offset":3234},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":3013},"end":{"line":61,"column":222,"offset":3234},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":63,"column":1,"offset":3236},"end":{"line":71,"column":4,"offset":3345},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":73,"column":6,"offset":3352},"end":{"line":73,"column":31,"offset":3377},"indent":[]}}],"position":{"start":{"line":73,"column":1,"offset":3347},"end":{"line":73,"column":31,"offset":3377},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":75,"column":1,"offset":3379},"end":{"line":75,"column":79,"offset":3457},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":75,"column":79,"offset":3457},"end":{"line":75,"column":95,"offset":3473},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":75,"column":95,"offset":3473},"end":{"line":75,"column":137,"offset":3515},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3379},"end":{"line":75,"column":137,"offset":3515},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":77,"column":1,"offset":3517},"end":{"line":87,"column":4,"offset":3885},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":89,"column":5,"offset":3891},"end":{"line":89,"column":30,"offset":3916},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":3887},"end":{"line":89,"column":30,"offset":3916},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":91,"column":1,"offset":3918},"end":{"line":91,"column":464,"offset":4381},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3918},"end":{"line":91,"column":464,"offset":4381},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":93,"column":1,"offset":4383},"end":{"line":93,"column":61,"offset":4443},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":4383},"end":{"line":93,"column":61,"offset":4443},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":95,"column":5,"offset":4449},"end":{"line":95,"column":28,"offset":4472},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4445},"end":{"line":95,"column":28,"offset":4472},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":97,"column":1,"offset":4474},"end":{"line":97,"column":95,"offset":4568},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":97,"column":95,"offset":4568},"end":{"line":97,"column":100,"offset":4573},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":97,"column":100,"offset":4573},"end":{"line":97,"column":101,"offset":4574},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4474},"end":{"line":97,"column":101,"offset":4574},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":99,"column":1,"offset":4576},"end":{"line":103,"column":4,"offset":4693},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":105,"column":1,"offset":4695},"end":{"line":105,"column":80,"offset":4774},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":105,"column":80,"offset":4774},"end":{"line":105,"column":101,"offset":4795},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":105,"column":101,"offset":4795},"end":{"line":105,"column":162,"offset":4856},"indent":[]}}],"position":{"start":{"line":105,"column":1,"offset":4695},"end":{"line":105,"column":162,"offset":4856},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":107,"column":1,"offset":4858},"end":{"line":110,"column":4,"offset":4947},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker for amd64, armv7, arm64","position":{"start":{"line":112,"column":4,"offset":4952},"end":{"line":112,"column":34,"offset":4982},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":4949},"end":{"line":112,"column":34,"offset":4982},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":114,"column":1,"offset":4984},"end":{"line":114,"column":339,"offset":5322},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":114,"column":340,"offset":5323},"end":{"line":114,"column":354,"offset":5337},"indent":[]}}],"position":{"start":{"line":114,"column":339,"offset":5322},"end":{"line":114,"column":390,"offset":5373},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":114,"column":390,"offset":5373},"end":{"line":114,"column":391,"offset":5374},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4984},"end":{"line":114,"column":391,"offset":5374},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":116,"column":5,"offset":5380},"end":{"line":116,"column":18,"offset":5393},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":5376},"end":{"line":116,"column":18,"offset":5393},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":118,"column":3,"offset":5397},"end":{"line":118,"column":50,"offset":5444},"indent":[]}}],"position":{"start":{"line":118,"column":3,"offset":5397},"end":{"line":118,"column":50,"offset":5444},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5395},"end":{"line":118,"column":50,"offset":5444},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":120,"column":5,"offset":5450},"end":{"line":120,"column":11,"offset":5456},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5446},"end":{"line":120,"column":11,"offset":5456},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":122,"column":1,"offset":5458},"end":{"line":122,"column":64,"offset":5521},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":122,"column":65,"offset":5522},"end":{"line":122,"column":86,"offset":5543},"indent":[]}}],"position":{"start":{"line":122,"column":64,"offset":5521},"end":{"line":122,"column":126,"offset":5583},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":122,"column":126,"offset":5583},"end":{"line":122,"column":127,"offset":5584},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5458},"end":{"line":122,"column":127,"offset":5584},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":124,"column":5,"offset":5590},"end":{"line":124,"column":26,"offset":5611},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5586},"end":{"line":124,"column":26,"offset":5611},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":126,"column":1,"offset":5613},"end":{"line":126,"column":126,"offset":5738},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5613},"end":{"line":126,"column":126,"offset":5738},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":128,"column":1,"offset":5740},"end":{"line":130,"column":4,"offset":5779},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":132,"column":1,"offset":5781},"end":{"line":132,"column":187,"offset":5967},"indent":[]}}],"position":{"start":{"line":132,"column":1,"offset":5781},"end":{"line":132,"column":187,"offset":5967},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":134,"column":1,"offset":5969},"end":{"line":136,"column":4,"offset":6047},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":138,"column":1,"offset":6049},"end":{"line":138,"column":153,"offset":6201},"indent":[]}}],"position":{"start":{"line":138,"column":1,"offset":6049},"end":{"line":138,"column":153,"offset":6201},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":140,"column":1,"offset":6203},"end":{"line":143,"column":4,"offset":6350},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":145,"column":1,"offset":6352},"end":{"line":145,"column":100,"offset":6451},"indent":[]}}],"position":{"start":{"line":145,"column":1,"offset":6352},"end":{"line":145,"column":100,"offset":6451},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":146,"column":1,"offset":6452},"end":{"line":150,"column":4,"offset":6521},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":152,"column":5,"offset":6527},"end":{"line":152,"column":12,"offset":6534},"indent":[]}}],"position":{"start":{"line":152,"column":1,"offset":6523},"end":{"line":152,"column":12,"offset":6534},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":154,"column":1,"offset":6536},"end":{"line":154,"column":64,"offset":6599},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6536},"end":{"line":154,"column":64,"offset":6599},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":155,"column":3,"offset":6602},"end":{"line":155,"column":25,"offset":6624},"indent":[]}}],"position":{"start":{"line":155,"column":3,"offset":6602},"end":{"line":155,"column":25,"offset":6624},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":6600},"end":{"line":155,"column":25,"offset":6624},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":156,"column":3,"offset":6627},"end":{"line":156,"column":59,"offset":6683},"indent":[]}}],"position":{"start":{"line":156,"column":3,"offset":6627},"end":{"line":156,"column":59,"offset":6683},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6625},"end":{"line":156,"column":59,"offset":6683},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":6600},"end":{"line":156,"column":59,"offset":6683},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":158,"column":4,"offset":6688},"end":{"line":158,"column":10,"offset":6694},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6685},"end":{"line":158,"column":10,"offset":6694},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.","position":{"start":{"line":160,"column":1,"offset":6696},"end":{"line":160,"column":102,"offset":6797},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":6696},"end":{"line":160,"column":102,"offset":6797},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Especially in the worl\n even on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.","position":{"start":{"line":162,"column":1,"offset":6799},"end":{"line":163,"column":128,"offset":6949},"indent":[1]}}],"position":{"start":{"line":162,"column":1,"offset":6799},"end":{"line":163,"column":128,"offset":6949},"indent":[1]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":166,"column":3,"offset":6954},"end":{"line":166,"column":11,"offset":6962},"indent":[]}}],"position":{"start":{"line":166,"column":1,"offset":6952},"end":{"line":166,"column":11,"offset":6962},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":168,"column":1,"offset":6964},"end":{"line":168,"column":133,"offset":7096},"indent":[]}}],"position":{"start":{"line":168,"column":1,"offset":6964},"end":{"line":168,"column":133,"offset":7096},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":170,"column":4,"offset":7101},"end":{"line":170,"column":12,"offset":7109},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7098},"end":{"line":170,"column":12,"offset":7109},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":172,"column":1,"offset":7111},"end":{"line":172,"column":193,"offset":7303},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7111},"end":{"line":172,"column":193,"offset":7303},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":174,"column":4,"offset":7308},"end":{"line":174,"column":62,"offset":7366},"indent":[]}}],"position":{"start":{"line":174,"column":4,"offset":7308},"end":{"line":174,"column":62,"offset":7366},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7305},"end":{"line":174,"column":62,"offset":7366},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":175,"column":4,"offset":7370},"end":{"line":175,"column":69,"offset":7435},"indent":[]}}],"position":{"start":{"line":175,"column":4,"offset":7370},"end":{"line":175,"column":69,"offset":7435},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7367},"end":{"line":175,"column":69,"offset":7435},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7305},"end":{"line":175,"column":69,"offset":7435},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":177,"column":1,"offset":7437},"end":{"line":177,"column":99,"offset":7535},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7437},"end":{"line":177,"column":99,"offset":7535},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":179,"column":5,"offset":7541},"end":{"line":179,"column":14,"offset":7550},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7537},"end":{"line":179,"column":14,"offset":7550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":181,"column":1,"offset":7552},"end":{"line":181,"column":71,"offset":7622},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":7552},"end":{"line":181,"column":71,"offset":7622},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":183,"column":3,"offset":7626},"end":{"line":183,"column":47,"offset":7670},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":183,"column":47,"offset":7670},"end":{"line":183,"column":79,"offset":7702},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":183,"column":79,"offset":7702},"end":{"line":183,"column":198,"offset":7821},"indent":[]}}],"position":{"start":{"line":183,"column":3,"offset":7626},"end":{"line":183,"column":198,"offset":7821},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":7624},"end":{"line":183,"column":198,"offset":7821},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":185,"column":1,"offset":7823},"end":{"line":187,"column":4,"offset":7886},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":189,"column":5,"offset":7892},"end":{"line":189,"column":14,"offset":7901},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":7888},"end":{"line":189,"column":14,"offset":7901},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":191,"column":1,"offset":7903},"end":{"line":191,"column":56,"offset":7958},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":7903},"end":{"line":191,"column":56,"offset":7958},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":192,"column":3,"offset":7961},"end":{"line":192,"column":52,"offset":8010},"indent":[]}}],"position":{"start":{"line":192,"column":3,"offset":7961},"end":{"line":192,"column":52,"offset":8010},"indent":[]}}],"position":{"start":{"line":192,"column":3,"offset":7961},"end":{"line":192,"column":52,"offset":8010},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":7959},"end":{"line":192,"column":52,"offset":8010},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":194,"column":1,"offset":8012},"end":{"line":194,"column":3,"offset":8014},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":194,"column":3,"offset":8014},"end":{"line":194,"column":9,"offset":8020},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":194,"column":9,"offset":8020},"end":{"line":194,"column":223,"offset":8234},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":8012},"end":{"line":194,"column":223,"offset":8234},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":196,"column":3,"offset":8238},"end":{"line":196,"column":159,"offset":8394},"indent":[]}}],"position":{"start":{"line":196,"column":3,"offset":8238},"end":{"line":196,"column":159,"offset":8394},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8236},"end":{"line":196,"column":159,"offset":8394},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":198,"column":1,"offset":8396},"end":{"line":201,"column":4,"offset":8573},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":203,"column":1,"offset":8575},"end":{"line":203,"column":160,"offset":8734},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":8575},"end":{"line":203,"column":160,"offset":8734},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":205,"column":3,"offset":8738},"end":{"line":205,"column":31,"offset":8766},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":205,"column":31,"offset":8766},"end":{"line":205,"column":101,"offset":8836},"indent":[]}}],"position":{"start":{"line":205,"column":3,"offset":8738},"end":{"line":205,"column":101,"offset":8836},"indent":[]}}],"position":{"start":{"line":205,"column":1,"offset":8736},"end":{"line":205,"column":101,"offset":8836},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":207,"column":1,"offset":8838},"end":{"line":210,"column":4,"offset":9010},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":212,"column":1,"offset":9012},"end":{"line":212,"column":73,"offset":9084},"indent":[]}}],"position":{"start":{"line":212,"column":1,"offset":9012},"end":{"line":212,"column":73,"offset":9084},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":215,"column":3,"offset":9089},"end":{"line":215,"column":31,"offset":9117},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":215,"column":31,"offset":9117},"end":{"line":215,"column":101,"offset":9187},"indent":[]}}],"position":{"start":{"line":215,"column":3,"offset":9089},"end":{"line":215,"column":101,"offset":9187},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":9087},"end":{"line":215,"column":101,"offset":9187},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":217,"column":1,"offset":9189},"end":{"line":220,"column":4,"offset":9361},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":222,"column":1,"offset":9363},"end":{"line":222,"column":62,"offset":9424},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":222,"column":63,"offset":9425},"end":{"line":222,"column":75,"offset":9437},"indent":[]}}],"position":{"start":{"line":222,"column":62,"offset":9424},"end":{"line":222,"column":143,"offset":9505},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":222,"column":143,"offset":9505},"end":{"line":222,"column":150,"offset":9512},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":222,"column":150,"offset":9512},"end":{"line":222,"column":169,"offset":9531},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":222,"column":169,"offset":9531},"end":{"line":222,"column":170,"offset":9532},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":9363},"end":{"line":222,"column":170,"offset":9532},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":224,"column":1,"offset":9534},"end":{"line":226,"column":4,"offset":9561},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":228,"column":1,"offset":9563},"end":{"line":228,"column":58,"offset":9620},"indent":[]}}],"position":{"start":{"line":228,"column":1,"offset":9563},"end":{"line":228,"column":58,"offset":9620},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":230,"column":1,"offset":9622},"end":{"line":233,"column":4,"offset":9692},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":235,"column":5,"offset":9698},"end":{"line":235,"column":8,"offset":9701},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":9694},"end":{"line":235,"column":8,"offset":9701},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":237,"column":1,"offset":9703},"end":{"line":237,"column":280,"offset":9982},"indent":[]}}],"position":{"start":{"line":237,"column":1,"offset":9703},"end":{"line":237,"column":280,"offset":9982},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":239,"column":1,"offset":9984},"end":{"line":239,"column":37,"offset":10020},"indent":[]}}],"position":{"start":{"line":239,"column":1,"offset":9984},"end":{"line":239,"column":37,"offset":10020},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":241,"column":1,"offset":10022},"end":{"line":243,"column":4,"offset":10195},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":245,"column":1,"offset":10197},"end":{"line":245,"column":25,"offset":10221},"indent":[]}}],"position":{"start":{"line":245,"column":1,"offset":10197},"end":{"line":245,"column":25,"offset":10221},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":247,"column":1,"offset":10223},"end":{"line":250,"column":4,"offset":10327},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":252,"column":1,"offset":10329},"end":{"line":252,"column":118,"offset":10446},"indent":[]}}],"position":{"start":{"line":252,"column":1,"offset":10329},"end":{"line":252,"column":118,"offset":10446},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":254,"column":1,"offset":10448},"end":{"line":274,"column":4,"offset":10955},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":276,"column":1,"offset":10957},"end":{"line":276,"column":14,"offset":10970},"indent":[]}}],"position":{"start":{"line":276,"column":1,"offset":10957},"end":{"line":276,"column":14,"offset":10970},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":278,"column":1,"offset":10972},"end":{"line":280,"column":4,"offset":11008},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":282,"column":1,"offset":11010},"end":{"line":282,"column":91,"offset":11100},"indent":[]}}],"position":{"start":{"line":282,"column":1,"offset":11010},"end":{"line":282,"column":91,"offset":11100},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":284,"column":1,"offset":11102},"end":{"line":292,"column":4,"offset":11475},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":294,"column":1,"offset":11477},"end":{"line":294,"column":145,"offset":11621},"indent":[]}}],"position":{"start":{"line":294,"column":1,"offset":11477},"end":{"line":294,"column":145,"offset":11621},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":296,"column":5,"offset":11627},"end":{"line":296,"column":17,"offset":11639},"indent":[]}}],"position":{"start":{"line":296,"column":1,"offset":11623},"end":{"line":296,"column":17,"offset":11639},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":298,"column":1,"offset":11641},"end":{"line":298,"column":300,"offset":11940},"indent":[]}}],"position":{"start":{"line":298,"column":1,"offset":11641},"end":{"line":298,"column":300,"offset":11940},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":300,"column":1,"offset":11942},"end":{"line":300,"column":178,"offset":12119},"indent":[]}}],"position":{"start":{"line":300,"column":1,"offset":11942},"end":{"line":300,"column":178,"offset":12119},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":302,"column":1,"offset":12121},"end":{"line":302,"column":48,"offset":12168},"indent":[]}}],"position":{"start":{"line":302,"column":1,"offset":12121},"end":{"line":302,"column":48,"offset":12168},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":304,"column":1,"offset":12170},"end":{"line":306,"column":4,"offset":12210},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":308,"column":1,"offset":12212},"end":{"line":308,"column":104,"offset":12315},"indent":[]}}],"position":{"start":{"line":308,"column":1,"offset":12212},"end":{"line":308,"column":104,"offset":12315},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":310,"column":1,"offset":12317},"end":{"line":318,"column":4,"offset":12587},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":320,"column":1,"offset":12589},"end":{"line":320,"column":28,"offset":12616},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":12589},"end":{"line":320,"column":28,"offset":12616},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":322,"column":1,"offset":12618},"end":{"line":324,"column":4,"offset":12662},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":326,"column":1,"offset":12664},"end":{"line":326,"column":48,"offset":12711},"indent":[]}}],"position":{"start":{"line":326,"column":1,"offset":12664},"end":{"line":326,"column":48,"offset":12711},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":328,"column":1,"offset":12713},"end":{"line":330,"column":4,"offset":12735},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":332,"column":1,"offset":12737},"end":{"line":332,"column":72,"offset":12808},"indent":[]}}],"position":{"start":{"line":332,"column":1,"offset":12737},"end":{"line":332,"column":72,"offset":12808},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":334,"column":1,"offset":12810},"end":{"line":336,"column":4,"offset":12867},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":338,"column":4,"offset":12872},"end":{"line":338,"column":11,"offset":12879},"indent":[]}}],"position":{"start":{"line":338,"column":1,"offset":12869},"end":{"line":338,"column":11,"offset":12879},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":340,"column":1,"offset":12881},"end":{"line":340,"column":283,"offset":13163},"indent":[]}}],"position":{"start":{"line":340,"column":1,"offset":12881},"end":{"line":340,"column":283,"offset":13163},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":342,"column":3,"offset":13167},"end":{"line":342,"column":54,"offset":13218},"indent":[]}}],"position":{"start":{"line":342,"column":3,"offset":13167},"end":{"line":342,"column":54,"offset":13218},"indent":[]}}],"position":{"start":{"line":342,"column":1,"offset":13165},"end":{"line":342,"column":54,"offset":13218},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":344,"column":5,"offset":13224},"end":{"line":344,"column":14,"offset":13233},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13220},"end":{"line":344,"column":14,"offset":13233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":346,"column":1,"offset":13235},"end":{"line":346,"column":68,"offset":13302},"indent":[]}}],"position":{"start":{"line":346,"column":1,"offset":13235},"end":{"line":346,"column":68,"offset":13302},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":348,"column":1,"offset":13304},"end":{"line":351,"column":4,"offset":13455},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":353,"column":1,"offset":13457},"end":{"line":353,"column":46,"offset":13502},"indent":[]}}],"position":{"start":{"line":353,"column":1,"offset":13457},"end":{"line":353,"column":46,"offset":13502},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":355,"column":3,"offset":13506},"end":{"line":355,"column":103,"offset":13606},"indent":[]}}],"position":{"start":{"line":355,"column":3,"offset":13506},"end":{"line":355,"column":103,"offset":13606},"indent":[]}}],"position":{"start":{"line":355,"column":1,"offset":13504},"end":{"line":355,"column":103,"offset":13606},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":357,"column":1,"offset":13608},"end":{"line":362,"column":4,"offset":13818},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":364,"column":1,"offset":13820},"end":{"line":364,"column":151,"offset":13970},"indent":[]}}],"position":{"start":{"line":364,"column":1,"offset":13820},"end":{"line":364,"column":151,"offset":13970},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":366,"column":3,"offset":13974},"end":{"line":366,"column":22,"offset":13993},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":366,"column":22,"offset":13993},"end":{"line":366,"column":26,"offset":13997},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":366,"column":26,"offset":13997},"end":{"line":366,"column":40,"offset":14011},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":366,"column":40,"offset":14011},"end":{"line":366,"column":50,"offset":14021},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":366,"column":50,"offset":14021},"end":{"line":366,"column":98,"offset":14069},"indent":[]}}],"position":{"start":{"line":366,"column":3,"offset":13974},"end":{"line":366,"column":98,"offset":14069},"indent":[]}}],"position":{"start":{"line":366,"column":1,"offset":13972},"end":{"line":366,"column":98,"offset":14069},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":368,"column":1,"offset":14071},"end":{"line":372,"column":4,"offset":14233},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":374,"column":1,"offset":14235},"end":{"line":374,"column":72,"offset":14306},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":374,"column":72,"offset":14306},"end":{"line":374,"column":84,"offset":14318},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":374,"column":84,"offset":14318},"end":{"line":374,"column":102,"offset":14336},"indent":[]}}],"position":{"start":{"line":374,"column":1,"offset":14235},"end":{"line":374,"column":102,"offset":14336},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":376,"column":1,"offset":14338},"end":{"line":379,"column":4,"offset":14412},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":381,"column":5,"offset":14418},"end":{"line":381,"column":8,"offset":14421},"indent":[]}}],"position":{"start":{"line":381,"column":1,"offset":14414},"end":{"line":381,"column":8,"offset":14421},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":383,"column":1,"offset":14423},"end":{"line":383,"column":176,"offset":14598},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14423},"end":{"line":383,"column":176,"offset":14598},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":385,"column":1,"offset":14600},"end":{"line":392,"column":4,"offset":14897},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":394,"column":1,"offset":14899},"end":{"line":394,"column":60,"offset":14958},"indent":[]}}],"position":{"start":{"line":394,"column":1,"offset":14899},"end":{"line":394,"column":60,"offset":14958},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":396,"column":1,"offset":14960},"end":{"line":400,"column":4,"offset":15086},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":402,"column":1,"offset":15088},"end":{"line":402,"column":63,"offset":15150},"indent":[]}}],"position":{"start":{"line":402,"column":1,"offset":15088},"end":{"line":402,"column":63,"offset":15150},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":404,"column":1,"offset":15152},"end":{"line":424,"column":4,"offset":15659},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":426,"column":1,"offset":15661},"end":{"line":426,"column":99,"offset":15759},"indent":[]}}],"position":{"start":{"line":426,"column":1,"offset":15661},"end":{"line":426,"column":99,"offset":15759},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":428,"column":1,"offset":15761},"end":{"line":431,"column":4,"offset":15863},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":433,"column":1,"offset":15865},"end":{"line":433,"column":37,"offset":15901},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":433,"column":37,"offset":15901},"end":{"line":433,"column":47,"offset":15911},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":433,"column":47,"offset":15911},"end":{"line":433,"column":89,"offset":15953},"indent":[]}}],"position":{"start":{"line":433,"column":1,"offset":15865},"end":{"line":433,"column":89,"offset":15953},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":435,"column":1,"offset":15955},"end":{"line":439,"column":4,"offset":16080},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":441,"column":1,"offset":16082},"end":{"line":441,"column":78,"offset":16159},"indent":[]}}],"position":{"start":{"line":441,"column":1,"offset":16082},"end":{"line":441,"column":78,"offset":16159},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":443,"column":1,"offset":16161},"end":{"line":447,"column":4,"offset":16265},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":449,"column":1,"offset":16267},"end":{"line":449,"column":75,"offset":16341},"indent":[]}}],"position":{"start":{"line":449,"column":1,"offset":16267},"end":{"line":449,"column":75,"offset":16341},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":451,"column":1,"offset":16343},"end":{"line":455,"column":4,"offset":16416},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":457,"column":1,"offset":16418},"end":{"line":457,"column":145,"offset":16562},"indent":[]}}],"position":{"start":{"line":457,"column":1,"offset":16418},"end":{"line":457,"column":145,"offset":16562},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":459,"column":5,"offset":16568},"end":{"line":459,"column":17,"offset":16580},"indent":[]}}],"position":{"start":{"line":459,"column":1,"offset":16564},"end":{"line":459,"column":17,"offset":16580},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":461,"column":1,"offset":16582},"end":{"line":461,"column":300,"offset":16881},"indent":[]}}],"position":{"start":{"line":461,"column":1,"offset":16582},"end":{"line":461,"column":300,"offset":16881},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":463,"column":1,"offset":16883},"end":{"line":463,"column":178,"offset":17060},"indent":[]}}],"position":{"start":{"line":463,"column":1,"offset":16883},"end":{"line":463,"column":178,"offset":17060},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":465,"column":1,"offset":17062},"end":{"line":465,"column":48,"offset":17109},"indent":[]}}],"position":{"start":{"line":465,"column":1,"offset":17062},"end":{"line":465,"column":48,"offset":17109},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":467,"column":1,"offset":17111},"end":{"line":469,"column":4,"offset":17155},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":471,"column":1,"offset":17157},"end":{"line":471,"column":104,"offset":17260},"indent":[]}}],"position":{"start":{"line":471,"column":1,"offset":17157},"end":{"line":471,"column":104,"offset":17260},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":473,"column":1,"offset":17262},"end":{"line":481,"column":4,"offset":17532},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":483,"column":1,"offset":17534},"end":{"line":483,"column":28,"offset":17561},"indent":[]}}],"position":{"start":{"line":483,"column":1,"offset":17534},"end":{"line":483,"column":28,"offset":17561},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":485,"column":1,"offset":17563},"end":{"line":487,"column":4,"offset":17611},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":489,"column":1,"offset":17613},"end":{"line":489,"column":48,"offset":17660},"indent":[]}}],"position":{"start":{"line":489,"column":1,"offset":17613},"end":{"line":489,"column":48,"offset":17660},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":491,"column":1,"offset":17662},"end":{"line":493,"column":4,"offset":17684},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":495,"column":1,"offset":17686},"end":{"line":495,"column":72,"offset":17757},"indent":[]}}],"position":{"start":{"line":495,"column":1,"offset":17686},"end":{"line":495,"column":72,"offset":17757},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":497,"column":1,"offset":17759},"end":{"line":499,"column":4,"offset":17820},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":502,"column":1,"offset":17823},"end":{"line":502,"column":31,"offset":17853},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":502,"column":31,"offset":17853}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug-and-Play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS for Raspberry Pi`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker for amd64, armv7, arm64`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.`}

\n

{`Especially in the worl\neven on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.`}

\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-4caca5b4ef3dce40e34bf5769d6e80f8.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-4caca5b4ef3dce40e34bf5769d6e80f8.json index 96c4c1b..3e0996b 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-4caca5b4ef3dce40e34bf5769d6e80f8.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-4caca5b4ef3dce40e34bf5769d6e80f8.json @@ -1 +1 @@ -{"expireTime":9007200841014160000,"key":"gatsby-plugin-mdx-entire-payload-02357fd739a950d3710dc9d26d509652-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Upgrade","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":10,"offset":168},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":10,"offset":168},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To upgrade your Kerberos agent to a new version you should follow the approach which fits your initial installation method. If you installed KiOS follow the KiOS upgrade procedure, if installed on Raspbian follow the Raspbian upgrade procedure, etc.","position":{"start":{"line":10,"column":1,"offset":170},"end":{"line":10,"column":250,"offset":419},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":170},"end":{"line":10,"column":250,"offset":419},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Please note that it might be possible that some new files are added or existing files were updated. To make sure everything works as expected, you should clear your browser cache.","position":{"start":{"line":12,"column":1,"offset":421},"end":{"line":12,"column":180,"offset":600},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":421},"end":{"line":12,"column":180,"offset":600},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":14,"column":4,"offset":605},"end":{"line":14,"column":8,"offset":609},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":602},"end":{"line":14,"column":8,"offset":609},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you installed KiOS, you can use the built-in upgrade method, ","position":{"start":{"line":16,"column":1,"offset":611},"end":{"line":16,"column":65,"offset":675},"indent":[]}},{"type":"inlineCode","value":"fwupdate","position":{"start":{"line":16,"column":65,"offset":675},"end":{"line":16,"column":75,"offset":685},"indent":[]}},{"type":"text","value":". The ","position":{"start":{"line":16,"column":75,"offset":685},"end":{"line":16,"column":81,"offset":691},"indent":[]}},{"type":"inlineCode","value":"fwupdate","position":{"start":{"line":16,"column":81,"offset":691},"end":{"line":16,"column":91,"offset":701},"indent":[]}},{"type":"text","value":" command is a shell script which contains a couple of functions. For example it allows you to download, extract and flash a new version of KiOS to your SD card. The process is pretty straight forward.","position":{"start":{"line":16,"column":91,"offset":701},"end":{"line":16,"column":291,"offset":901},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":611},"end":{"line":16,"column":291,"offset":901},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"First SSH or connect to KiOS first, and execute following command to see your current version.","position":{"start":{"line":18,"column":1,"offset":903},"end":{"line":18,"column":95,"offset":997},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":903},"end":{"line":18,"column":95,"offset":997},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"fwupdate current","position":{"start":{"line":20,"column":1,"offset":999},"end":{"line":22,"column":4,"offset":1027},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next look for all available versions of KiOS.","position":{"start":{"line":24,"column":1,"offset":1029},"end":{"line":24,"column":46,"offset":1074},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1029},"end":{"line":24,"column":46,"offset":1074},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"fwupdate versions","position":{"start":{"line":26,"column":1,"offset":1076},"end":{"line":28,"column":4,"offset":1105},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Select the version to which you would like to upgrade, and run following command.","position":{"start":{"line":30,"column":1,"offset":1107},"end":{"line":30,"column":82,"offset":1188},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":1107},"end":{"line":30,"column":82,"offset":1188},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"fwupdate upgrade ","position":{"start":{"line":32,"column":1,"offset":1190},"end":{"line":34,"column":4,"offset":1228},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS will reboot, and your new version will be available.","position":{"start":{"line":36,"column":1,"offset":1230},"end":{"line":36,"column":58,"offset":1287},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":1230},"end":{"line":36,"column":58,"offset":1287},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":38,"column":4,"offset":1292},"end":{"line":38,"column":12,"offset":1300},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":1289},"end":{"line":38,"column":12,"offset":1300},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install a new version of the Kerberos agent for Raspbian, there is no automated versioning process available like KiOS. To perform an upgrade you'll need to follow the ","position":{"start":{"line":40,"column":1,"offset":1302},"end":{"line":40,"column":184,"offset":1485},"indent":[]}},{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"traditional installation","position":{"start":{"line":40,"column":185,"offset":1486},"end":{"line":40,"column":209,"offset":1510},"indent":[]}}],"position":{"start":{"line":40,"column":184,"offset":1485},"end":{"line":40,"column":245,"offset":1546},"indent":[]}},{"type":"text","value":" procedure of Raspbian.","position":{"start":{"line":40,"column":245,"offset":1546},"end":{"line":40,"column":268,"offset":1569},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":1302},"end":{"line":40,"column":268,"offset":1569},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":42,"column":4,"offset":1574},"end":{"line":42,"column":10,"offset":1580},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":1571},"end":{"line":42,"column":10,"offset":1580},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When a new release is available, a new Docker image will be available on the Docker hub. You can simply delete your existing container and image, and download it again.","position":{"start":{"line":44,"column":1,"offset":1582},"end":{"line":44,"column":169,"offset":1750},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":1582},"end":{"line":44,"column":169,"offset":1750},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":47,"column":1,"offset":1753},"end":{"line":47,"column":31,"offset":1783},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":47,"column":31,"offset":1783}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Upgrade`}

\n

{`To upgrade your Kerberos agent to a new version you should follow the approach which fits your initial installation method. If you installed KiOS follow the KiOS upgrade procedure, if installed on Raspbian follow the Raspbian upgrade procedure, etc.`}

\n

{`Please note that it might be possible that some new files are added or existing files were updated. To make sure everything works as expected, you should clear your browser cache.`}

\n

{`KiOS`}

\n

{`If you installed KiOS, you can use the built-in upgrade method, `}{`fwupdate`}{`. The `}{`fwupdate`}{` command is a shell script which contains a couple of functions. For example it allows you to download, extract and flash a new version of KiOS to your SD card. The process is pretty straight forward.`}

\n

{`First SSH or connect to KiOS first, and execute following command to see your current version.`}

\n
{`fwupdate current`}
\n

{`Next look for all available versions of KiOS.`}

\n
{`fwupdate versions`}
\n

{`Select the version to which you would like to upgrade, and run following command.`}

\n
{`fwupdate upgrade `}
\n

{`KiOS will reboot, and your new version will be available.`}

\n

{`Raspbian`}

\n

{`If you want to install a new version of the Kerberos agent for Raspbian, there is no automated versioning process available like KiOS. To perform an upgrade you'll need to follow the `}{`traditional installation`}{` procedure of Raspbian.`}

\n

{`Docker`}

\n

{`When a new release is available, a new Docker image will be available on the Docker hub. You can simply delete your existing container and image, and download it again.`}

\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974264000,"key":"gatsby-plugin-mdx-entire-payload-02357fd739a950d3710dc9d26d509652-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Upgrade","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":10,"offset":168},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":10,"offset":168},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To upgrade your Kerberos agent to a new version you should follow the approach which fits your initial installation method. If you installed KiOS follow the KiOS upgrade procedure, if installed on Raspbian follow the Raspbian upgrade procedure, etc.","position":{"start":{"line":10,"column":1,"offset":170},"end":{"line":10,"column":250,"offset":419},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":170},"end":{"line":10,"column":250,"offset":419},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Please note that it might be possible that some new files are added or existing files were updated. To make sure everything works as expected, you should clear your browser cache.","position":{"start":{"line":12,"column":1,"offset":421},"end":{"line":12,"column":180,"offset":600},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":421},"end":{"line":12,"column":180,"offset":600},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":14,"column":4,"offset":605},"end":{"line":14,"column":8,"offset":609},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":602},"end":{"line":14,"column":8,"offset":609},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you installed KiOS, you can use the built-in upgrade method, ","position":{"start":{"line":16,"column":1,"offset":611},"end":{"line":16,"column":65,"offset":675},"indent":[]}},{"type":"inlineCode","value":"fwupdate","position":{"start":{"line":16,"column":65,"offset":675},"end":{"line":16,"column":75,"offset":685},"indent":[]}},{"type":"text","value":". The ","position":{"start":{"line":16,"column":75,"offset":685},"end":{"line":16,"column":81,"offset":691},"indent":[]}},{"type":"inlineCode","value":"fwupdate","position":{"start":{"line":16,"column":81,"offset":691},"end":{"line":16,"column":91,"offset":701},"indent":[]}},{"type":"text","value":" command is a shell script which contains a couple of functions. For example it allows you to download, extract and flash a new version of KiOS to your SD card. The process is pretty straight forward.","position":{"start":{"line":16,"column":91,"offset":701},"end":{"line":16,"column":291,"offset":901},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":611},"end":{"line":16,"column":291,"offset":901},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"First SSH or connect to KiOS first, and execute following command to see your current version.","position":{"start":{"line":18,"column":1,"offset":903},"end":{"line":18,"column":95,"offset":997},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":903},"end":{"line":18,"column":95,"offset":997},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"fwupdate current","position":{"start":{"line":20,"column":1,"offset":999},"end":{"line":22,"column":4,"offset":1027},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next look for all available versions of KiOS.","position":{"start":{"line":24,"column":1,"offset":1029},"end":{"line":24,"column":46,"offset":1074},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1029},"end":{"line":24,"column":46,"offset":1074},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"fwupdate versions","position":{"start":{"line":26,"column":1,"offset":1076},"end":{"line":28,"column":4,"offset":1105},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Select the version to which you would like to upgrade, and run following command.","position":{"start":{"line":30,"column":1,"offset":1107},"end":{"line":30,"column":82,"offset":1188},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":1107},"end":{"line":30,"column":82,"offset":1188},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"fwupdate upgrade ","position":{"start":{"line":32,"column":1,"offset":1190},"end":{"line":34,"column":4,"offset":1228},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS will reboot, and your new version will be available.","position":{"start":{"line":36,"column":1,"offset":1230},"end":{"line":36,"column":58,"offset":1287},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":1230},"end":{"line":36,"column":58,"offset":1287},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":38,"column":4,"offset":1292},"end":{"line":38,"column":12,"offset":1300},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":1289},"end":{"line":38,"column":12,"offset":1300},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install a new version of the Kerberos agent for Raspbian, there is no automated versioning process available like KiOS. To perform an upgrade you'll need to follow the ","position":{"start":{"line":40,"column":1,"offset":1302},"end":{"line":40,"column":184,"offset":1485},"indent":[]}},{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"traditional installation","position":{"start":{"line":40,"column":185,"offset":1486},"end":{"line":40,"column":209,"offset":1510},"indent":[]}}],"position":{"start":{"line":40,"column":184,"offset":1485},"end":{"line":40,"column":245,"offset":1546},"indent":[]}},{"type":"text","value":" procedure of Raspbian.","position":{"start":{"line":40,"column":245,"offset":1546},"end":{"line":40,"column":268,"offset":1569},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":1302},"end":{"line":40,"column":268,"offset":1569},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":42,"column":4,"offset":1574},"end":{"line":42,"column":10,"offset":1580},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":1571},"end":{"line":42,"column":10,"offset":1580},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When a new release is available, a new Docker image will be available on the Docker hub. You can simply delete your existing container and image, and download it again.","position":{"start":{"line":44,"column":1,"offset":1582},"end":{"line":44,"column":169,"offset":1750},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":1582},"end":{"line":44,"column":169,"offset":1750},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":47,"column":1,"offset":1753},"end":{"line":47,"column":31,"offset":1783},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":47,"column":31,"offset":1783}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Upgrade`}

\n

{`To upgrade your Kerberos agent to a new version you should follow the approach which fits your initial installation method. If you installed KiOS follow the KiOS upgrade procedure, if installed on Raspbian follow the Raspbian upgrade procedure, etc.`}

\n

{`Please note that it might be possible that some new files are added or existing files were updated. To make sure everything works as expected, you should clear your browser cache.`}

\n

{`KiOS`}

\n

{`If you installed KiOS, you can use the built-in upgrade method, `}{`fwupdate`}{`. The `}{`fwupdate`}{` command is a shell script which contains a couple of functions. For example it allows you to download, extract and flash a new version of KiOS to your SD card. The process is pretty straight forward.`}

\n

{`First SSH or connect to KiOS first, and execute following command to see your current version.`}

\n
{`fwupdate current`}
\n

{`Next look for all available versions of KiOS.`}

\n
{`fwupdate versions`}
\n

{`Select the version to which you would like to upgrade, and run following command.`}

\n
{`fwupdate upgrade `}
\n

{`KiOS will reboot, and your new version will be available.`}

\n

{`Raspbian`}

\n

{`If you want to install a new version of the Kerberos agent for Raspbian, there is no automated versioning process available like KiOS. To perform an upgrade you'll need to follow the `}{`traditional installation`}{` procedure of Raspbian.`}

\n

{`Docker`}

\n

{`When a new release is available, a new Docker image will be available on the Docker hub. You can simply delete your existing container and image, and download it again.`}

\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-539aed0f4600e6bb4755356ea1f96e11.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-539aed0f4600e6bb4755356ea1f96e11.json new file mode 100644 index 0000000..f5eb201 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-539aed0f4600e6bb4755356ea1f96e11.json @@ -0,0 +1 @@ +{"expireTime":9007200842068096000,"key":"gatsby-plugin-mdx-entire-payload-f3ee3bbb44af625fd6519cc56b94ee44-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug-and-Play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":23,"column":3,"offset":1136},"end":{"line":23,"column":16,"offset":1149},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":16,"offset":1149},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":25,"column":1,"offset":1151},"end":{"line":25,"column":156,"offset":1306},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1151},"end":{"line":25,"column":156,"offset":1306},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS for Raspberry Pi","position":{"start":{"line":27,"column":4,"offset":1311},"end":{"line":27,"column":25,"offset":1332},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1308},"end":{"line":27,"column":25,"offset":1332},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":29,"column":1,"offset":1334},"end":{"line":29,"column":229,"offset":1562},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1334},"end":{"line":29,"column":229,"offset":1562},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":31,"column":1,"offset":1564},"end":{"line":31,"column":197,"offset":1760},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1564},"end":{"line":31,"column":197,"offset":1760},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":33,"column":5,"offset":1766},"end":{"line":33,"column":11,"offset":1772},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1762},"end":{"line":33,"column":11,"offset":1772},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":35,"column":1,"offset":1774},"end":{"line":35,"column":63,"offset":1836},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":35,"column":64,"offset":1837},"end":{"line":35,"column":85,"offset":1858},"indent":[]}}],"position":{"start":{"line":35,"column":63,"offset":1836},"end":{"line":35,"column":123,"offset":1896},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":35,"column":123,"offset":1896},"end":{"line":35,"column":124,"offset":1897},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1774},"end":{"line":35,"column":124,"offset":1897},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":37,"column":5,"offset":1903},"end":{"line":37,"column":35,"offset":1933},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1899},"end":{"line":37,"column":35,"offset":1933},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":39,"column":1,"offset":1935},"end":{"line":39,"column":228,"offset":2162},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1935},"end":{"line":39,"column":228,"offset":2162},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":41,"column":1,"offset":2164},"end":{"line":41,"column":67,"offset":2230},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":2164},"end":{"line":41,"column":67,"offset":2230},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":43,"column":1,"offset":2232},"end":{"line":43,"column":50,"offset":2281},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2232},"end":{"line":43,"column":50,"offset":2281},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":45,"column":3,"offset":2285},"end":{"line":45,"column":49,"offset":2331},"indent":[]}}],"position":{"start":{"line":45,"column":3,"offset":2285},"end":{"line":45,"column":49,"offset":2331},"indent":[]}}],"position":{"start":{"line":45,"column":3,"offset":2285},"end":{"line":45,"column":49,"offset":2331},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2283},"end":{"line":45,"column":49,"offset":2331},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":47,"column":5,"offset":2337},"end":{"line":47,"column":11,"offset":2343},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2333},"end":{"line":47,"column":11,"offset":2343},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":49,"column":1,"offset":2345},"end":{"line":49,"column":160,"offset":2504},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2345},"end":{"line":49,"column":160,"offset":2504},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":51,"column":4,"offset":2509},"end":{"line":51,"column":13,"offset":2518},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":51,"column":14,"offset":2519},"end":{"line":51,"column":28,"offset":2533},"indent":[]}}],"position":{"start":{"line":51,"column":13,"offset":2518},"end":{"line":51,"column":75,"offset":2580},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":51,"column":75,"offset":2580},"end":{"line":51,"column":76,"offset":2581},"indent":[]}}],"position":{"start":{"line":51,"column":4,"offset":2509},"end":{"line":51,"column":76,"offset":2581},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2506},"end":{"line":51,"column":76,"offset":2581},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":52,"column":4,"offset":2585},"end":{"line":52,"column":41,"offset":2622},"indent":[]}}],"position":{"start":{"line":52,"column":4,"offset":2585},"end":{"line":52,"column":41,"offset":2622},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2582},"end":{"line":52,"column":41,"offset":2622},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":53,"column":4,"offset":2626},"end":{"line":53,"column":60,"offset":2682},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2626},"end":{"line":53,"column":60,"offset":2682},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2623},"end":{"line":53,"column":60,"offset":2682},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2506},"end":{"line":53,"column":60,"offset":2682},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":55,"column":2,"offset":2685},"end":{"line":55,"column":64,"offset":2747},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2684},"end":{"line":55,"column":96,"offset":2779},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2684},"end":{"line":55,"column":96,"offset":2779},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":57,"column":1,"offset":2781},"end":{"line":57,"column":204,"offset":2984},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2781},"end":{"line":57,"column":204,"offset":2984},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":59,"column":6,"offset":2991},"end":{"line":59,"column":24,"offset":3009},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2986},"end":{"line":59,"column":24,"offset":3009},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":61,"column":1,"offset":3011},"end":{"line":61,"column":95,"offset":3105},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":61,"column":95,"offset":3105},"end":{"line":61,"column":110,"offset":3120},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":61,"column":110,"offset":3120},"end":{"line":61,"column":222,"offset":3232},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":3011},"end":{"line":61,"column":222,"offset":3232},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":63,"column":1,"offset":3234},"end":{"line":71,"column":4,"offset":3343},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":73,"column":6,"offset":3350},"end":{"line":73,"column":31,"offset":3375},"indent":[]}}],"position":{"start":{"line":73,"column":1,"offset":3345},"end":{"line":73,"column":31,"offset":3375},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":75,"column":1,"offset":3377},"end":{"line":75,"column":79,"offset":3455},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":75,"column":79,"offset":3455},"end":{"line":75,"column":95,"offset":3471},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":75,"column":95,"offset":3471},"end":{"line":75,"column":137,"offset":3513},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3377},"end":{"line":75,"column":137,"offset":3513},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":77,"column":1,"offset":3515},"end":{"line":87,"column":4,"offset":3883},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":89,"column":5,"offset":3889},"end":{"line":89,"column":30,"offset":3914},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":3885},"end":{"line":89,"column":30,"offset":3914},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":91,"column":1,"offset":3916},"end":{"line":91,"column":464,"offset":4379},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3916},"end":{"line":91,"column":464,"offset":4379},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":93,"column":1,"offset":4381},"end":{"line":93,"column":61,"offset":4441},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":4381},"end":{"line":93,"column":61,"offset":4441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":95,"column":5,"offset":4447},"end":{"line":95,"column":28,"offset":4470},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4443},"end":{"line":95,"column":28,"offset":4470},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":97,"column":1,"offset":4472},"end":{"line":97,"column":95,"offset":4566},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":97,"column":95,"offset":4566},"end":{"line":97,"column":100,"offset":4571},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":97,"column":100,"offset":4571},"end":{"line":97,"column":101,"offset":4572},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4472},"end":{"line":97,"column":101,"offset":4572},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":99,"column":1,"offset":4574},"end":{"line":103,"column":4,"offset":4691},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":105,"column":1,"offset":4693},"end":{"line":105,"column":80,"offset":4772},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":105,"column":80,"offset":4772},"end":{"line":105,"column":101,"offset":4793},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":105,"column":101,"offset":4793},"end":{"line":105,"column":162,"offset":4854},"indent":[]}}],"position":{"start":{"line":105,"column":1,"offset":4693},"end":{"line":105,"column":162,"offset":4854},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":107,"column":1,"offset":4856},"end":{"line":110,"column":4,"offset":4945},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker for amd64, armv7, arm64","position":{"start":{"line":112,"column":4,"offset":4950},"end":{"line":112,"column":34,"offset":4980},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":4947},"end":{"line":112,"column":34,"offset":4980},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":114,"column":1,"offset":4982},"end":{"line":114,"column":339,"offset":5320},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":114,"column":340,"offset":5321},"end":{"line":114,"column":354,"offset":5335},"indent":[]}}],"position":{"start":{"line":114,"column":339,"offset":5320},"end":{"line":114,"column":390,"offset":5371},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":114,"column":390,"offset":5371},"end":{"line":114,"column":391,"offset":5372},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4982},"end":{"line":114,"column":391,"offset":5372},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":116,"column":5,"offset":5378},"end":{"line":116,"column":18,"offset":5391},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":5374},"end":{"line":116,"column":18,"offset":5391},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":118,"column":3,"offset":5395},"end":{"line":118,"column":50,"offset":5442},"indent":[]}}],"position":{"start":{"line":118,"column":3,"offset":5395},"end":{"line":118,"column":50,"offset":5442},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5393},"end":{"line":118,"column":50,"offset":5442},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":120,"column":5,"offset":5448},"end":{"line":120,"column":11,"offset":5454},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5444},"end":{"line":120,"column":11,"offset":5454},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":122,"column":1,"offset":5456},"end":{"line":122,"column":64,"offset":5519},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":122,"column":65,"offset":5520},"end":{"line":122,"column":86,"offset":5541},"indent":[]}}],"position":{"start":{"line":122,"column":64,"offset":5519},"end":{"line":122,"column":126,"offset":5581},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":122,"column":126,"offset":5581},"end":{"line":122,"column":127,"offset":5582},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5456},"end":{"line":122,"column":127,"offset":5582},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":124,"column":5,"offset":5588},"end":{"line":124,"column":26,"offset":5609},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5584},"end":{"line":124,"column":26,"offset":5609},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":126,"column":1,"offset":5611},"end":{"line":126,"column":126,"offset":5736},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5611},"end":{"line":126,"column":126,"offset":5736},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":128,"column":1,"offset":5738},"end":{"line":130,"column":4,"offset":5777},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":132,"column":1,"offset":5779},"end":{"line":132,"column":187,"offset":5965},"indent":[]}}],"position":{"start":{"line":132,"column":1,"offset":5779},"end":{"line":132,"column":187,"offset":5965},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":134,"column":1,"offset":5967},"end":{"line":136,"column":4,"offset":6045},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":138,"column":1,"offset":6047},"end":{"line":138,"column":153,"offset":6199},"indent":[]}}],"position":{"start":{"line":138,"column":1,"offset":6047},"end":{"line":138,"column":153,"offset":6199},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":140,"column":1,"offset":6201},"end":{"line":143,"column":4,"offset":6348},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":145,"column":1,"offset":6350},"end":{"line":145,"column":100,"offset":6449},"indent":[]}}],"position":{"start":{"line":145,"column":1,"offset":6350},"end":{"line":145,"column":100,"offset":6449},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":146,"column":1,"offset":6450},"end":{"line":150,"column":4,"offset":6519},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":152,"column":5,"offset":6525},"end":{"line":152,"column":12,"offset":6532},"indent":[]}}],"position":{"start":{"line":152,"column":1,"offset":6521},"end":{"line":152,"column":12,"offset":6532},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":154,"column":1,"offset":6534},"end":{"line":154,"column":64,"offset":6597},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6534},"end":{"line":154,"column":64,"offset":6597},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":155,"column":3,"offset":6600},"end":{"line":155,"column":25,"offset":6622},"indent":[]}}],"position":{"start":{"line":155,"column":3,"offset":6600},"end":{"line":155,"column":25,"offset":6622},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":6598},"end":{"line":155,"column":25,"offset":6622},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":156,"column":3,"offset":6625},"end":{"line":156,"column":59,"offset":6681},"indent":[]}}],"position":{"start":{"line":156,"column":3,"offset":6625},"end":{"line":156,"column":59,"offset":6681},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6623},"end":{"line":156,"column":59,"offset":6681},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":6598},"end":{"line":156,"column":59,"offset":6681},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":158,"column":4,"offset":6686},"end":{"line":158,"column":10,"offset":6692},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6683},"end":{"line":158,"column":10,"offset":6692},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.","position":{"start":{"line":160,"column":1,"offset":6694},"end":{"line":160,"column":102,"offset":6795},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":6694},"end":{"line":160,"column":102,"offset":6795},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Especially in the worl\n even on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.","position":{"start":{"line":162,"column":1,"offset":6797},"end":{"line":163,"column":128,"offset":6947},"indent":[1]}}],"position":{"start":{"line":162,"column":1,"offset":6797},"end":{"line":163,"column":128,"offset":6947},"indent":[1]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":166,"column":3,"offset":6952},"end":{"line":166,"column":11,"offset":6960},"indent":[]}}],"position":{"start":{"line":166,"column":1,"offset":6950},"end":{"line":166,"column":11,"offset":6960},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":168,"column":1,"offset":6962},"end":{"line":168,"column":133,"offset":7094},"indent":[]}}],"position":{"start":{"line":168,"column":1,"offset":6962},"end":{"line":168,"column":133,"offset":7094},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":170,"column":4,"offset":7099},"end":{"line":170,"column":12,"offset":7107},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7096},"end":{"line":170,"column":12,"offset":7107},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":172,"column":1,"offset":7109},"end":{"line":172,"column":193,"offset":7301},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7109},"end":{"line":172,"column":193,"offset":7301},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":174,"column":4,"offset":7306},"end":{"line":174,"column":62,"offset":7364},"indent":[]}}],"position":{"start":{"line":174,"column":4,"offset":7306},"end":{"line":174,"column":62,"offset":7364},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7303},"end":{"line":174,"column":62,"offset":7364},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":175,"column":4,"offset":7368},"end":{"line":175,"column":69,"offset":7433},"indent":[]}}],"position":{"start":{"line":175,"column":4,"offset":7368},"end":{"line":175,"column":69,"offset":7433},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7365},"end":{"line":175,"column":69,"offset":7433},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7303},"end":{"line":175,"column":69,"offset":7433},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":177,"column":1,"offset":7435},"end":{"line":177,"column":99,"offset":7533},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7435},"end":{"line":177,"column":99,"offset":7533},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":179,"column":5,"offset":7539},"end":{"line":179,"column":14,"offset":7548},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7535},"end":{"line":179,"column":14,"offset":7548},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":181,"column":1,"offset":7550},"end":{"line":181,"column":71,"offset":7620},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":7550},"end":{"line":181,"column":71,"offset":7620},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":183,"column":3,"offset":7624},"end":{"line":183,"column":47,"offset":7668},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":183,"column":47,"offset":7668},"end":{"line":183,"column":79,"offset":7700},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":183,"column":79,"offset":7700},"end":{"line":183,"column":198,"offset":7819},"indent":[]}}],"position":{"start":{"line":183,"column":3,"offset":7624},"end":{"line":183,"column":198,"offset":7819},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":7622},"end":{"line":183,"column":198,"offset":7819},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":185,"column":1,"offset":7821},"end":{"line":187,"column":4,"offset":7884},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":189,"column":5,"offset":7890},"end":{"line":189,"column":14,"offset":7899},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":7886},"end":{"line":189,"column":14,"offset":7899},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":191,"column":1,"offset":7901},"end":{"line":191,"column":56,"offset":7956},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":7901},"end":{"line":191,"column":56,"offset":7956},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":192,"column":3,"offset":7959},"end":{"line":192,"column":52,"offset":8008},"indent":[]}}],"position":{"start":{"line":192,"column":3,"offset":7959},"end":{"line":192,"column":52,"offset":8008},"indent":[]}}],"position":{"start":{"line":192,"column":3,"offset":7959},"end":{"line":192,"column":52,"offset":8008},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":7957},"end":{"line":192,"column":52,"offset":8008},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":194,"column":1,"offset":8010},"end":{"line":194,"column":3,"offset":8012},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":194,"column":3,"offset":8012},"end":{"line":194,"column":9,"offset":8018},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":194,"column":9,"offset":8018},"end":{"line":194,"column":223,"offset":8232},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":8010},"end":{"line":194,"column":223,"offset":8232},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":196,"column":3,"offset":8236},"end":{"line":196,"column":159,"offset":8392},"indent":[]}}],"position":{"start":{"line":196,"column":3,"offset":8236},"end":{"line":196,"column":159,"offset":8392},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8234},"end":{"line":196,"column":159,"offset":8392},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":198,"column":1,"offset":8394},"end":{"line":201,"column":4,"offset":8571},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":203,"column":1,"offset":8573},"end":{"line":203,"column":160,"offset":8732},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":8573},"end":{"line":203,"column":160,"offset":8732},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":205,"column":3,"offset":8736},"end":{"line":205,"column":31,"offset":8764},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":205,"column":31,"offset":8764},"end":{"line":205,"column":101,"offset":8834},"indent":[]}}],"position":{"start":{"line":205,"column":3,"offset":8736},"end":{"line":205,"column":101,"offset":8834},"indent":[]}}],"position":{"start":{"line":205,"column":1,"offset":8734},"end":{"line":205,"column":101,"offset":8834},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":207,"column":1,"offset":8836},"end":{"line":210,"column":4,"offset":9008},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":212,"column":1,"offset":9010},"end":{"line":212,"column":73,"offset":9082},"indent":[]}}],"position":{"start":{"line":212,"column":1,"offset":9010},"end":{"line":212,"column":73,"offset":9082},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":215,"column":3,"offset":9087},"end":{"line":215,"column":31,"offset":9115},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":215,"column":31,"offset":9115},"end":{"line":215,"column":101,"offset":9185},"indent":[]}}],"position":{"start":{"line":215,"column":3,"offset":9087},"end":{"line":215,"column":101,"offset":9185},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":9085},"end":{"line":215,"column":101,"offset":9185},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":217,"column":1,"offset":9187},"end":{"line":220,"column":4,"offset":9359},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":222,"column":1,"offset":9361},"end":{"line":222,"column":62,"offset":9422},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":222,"column":63,"offset":9423},"end":{"line":222,"column":75,"offset":9435},"indent":[]}}],"position":{"start":{"line":222,"column":62,"offset":9422},"end":{"line":222,"column":143,"offset":9503},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":222,"column":143,"offset":9503},"end":{"line":222,"column":150,"offset":9510},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":222,"column":150,"offset":9510},"end":{"line":222,"column":169,"offset":9529},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":222,"column":169,"offset":9529},"end":{"line":222,"column":170,"offset":9530},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":9361},"end":{"line":222,"column":170,"offset":9530},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":224,"column":1,"offset":9532},"end":{"line":226,"column":4,"offset":9559},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":228,"column":1,"offset":9561},"end":{"line":228,"column":58,"offset":9618},"indent":[]}}],"position":{"start":{"line":228,"column":1,"offset":9561},"end":{"line":228,"column":58,"offset":9618},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":230,"column":1,"offset":9620},"end":{"line":233,"column":4,"offset":9690},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":235,"column":5,"offset":9696},"end":{"line":235,"column":8,"offset":9699},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":9692},"end":{"line":235,"column":8,"offset":9699},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":237,"column":1,"offset":9701},"end":{"line":237,"column":280,"offset":9980},"indent":[]}}],"position":{"start":{"line":237,"column":1,"offset":9701},"end":{"line":237,"column":280,"offset":9980},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":239,"column":1,"offset":9982},"end":{"line":239,"column":37,"offset":10018},"indent":[]}}],"position":{"start":{"line":239,"column":1,"offset":9982},"end":{"line":239,"column":37,"offset":10018},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":241,"column":1,"offset":10020},"end":{"line":243,"column":4,"offset":10193},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":245,"column":1,"offset":10195},"end":{"line":245,"column":25,"offset":10219},"indent":[]}}],"position":{"start":{"line":245,"column":1,"offset":10195},"end":{"line":245,"column":25,"offset":10219},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":247,"column":1,"offset":10221},"end":{"line":250,"column":4,"offset":10325},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":252,"column":1,"offset":10327},"end":{"line":252,"column":118,"offset":10444},"indent":[]}}],"position":{"start":{"line":252,"column":1,"offset":10327},"end":{"line":252,"column":118,"offset":10444},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":254,"column":1,"offset":10446},"end":{"line":274,"column":4,"offset":10953},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":276,"column":1,"offset":10955},"end":{"line":276,"column":14,"offset":10968},"indent":[]}}],"position":{"start":{"line":276,"column":1,"offset":10955},"end":{"line":276,"column":14,"offset":10968},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":278,"column":1,"offset":10970},"end":{"line":280,"column":4,"offset":11006},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":282,"column":1,"offset":11008},"end":{"line":282,"column":91,"offset":11098},"indent":[]}}],"position":{"start":{"line":282,"column":1,"offset":11008},"end":{"line":282,"column":91,"offset":11098},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":284,"column":1,"offset":11100},"end":{"line":292,"column":4,"offset":11473},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":294,"column":1,"offset":11475},"end":{"line":294,"column":145,"offset":11619},"indent":[]}}],"position":{"start":{"line":294,"column":1,"offset":11475},"end":{"line":294,"column":145,"offset":11619},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":296,"column":5,"offset":11625},"end":{"line":296,"column":17,"offset":11637},"indent":[]}}],"position":{"start":{"line":296,"column":1,"offset":11621},"end":{"line":296,"column":17,"offset":11637},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":298,"column":1,"offset":11639},"end":{"line":298,"column":300,"offset":11938},"indent":[]}}],"position":{"start":{"line":298,"column":1,"offset":11639},"end":{"line":298,"column":300,"offset":11938},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":300,"column":1,"offset":11940},"end":{"line":300,"column":178,"offset":12117},"indent":[]}}],"position":{"start":{"line":300,"column":1,"offset":11940},"end":{"line":300,"column":178,"offset":12117},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":302,"column":1,"offset":12119},"end":{"line":302,"column":48,"offset":12166},"indent":[]}}],"position":{"start":{"line":302,"column":1,"offset":12119},"end":{"line":302,"column":48,"offset":12166},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":304,"column":1,"offset":12168},"end":{"line":306,"column":4,"offset":12208},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":308,"column":1,"offset":12210},"end":{"line":308,"column":104,"offset":12313},"indent":[]}}],"position":{"start":{"line":308,"column":1,"offset":12210},"end":{"line":308,"column":104,"offset":12313},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":310,"column":1,"offset":12315},"end":{"line":318,"column":4,"offset":12585},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":320,"column":1,"offset":12587},"end":{"line":320,"column":28,"offset":12614},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":12587},"end":{"line":320,"column":28,"offset":12614},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":322,"column":1,"offset":12616},"end":{"line":324,"column":4,"offset":12660},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":326,"column":1,"offset":12662},"end":{"line":326,"column":48,"offset":12709},"indent":[]}}],"position":{"start":{"line":326,"column":1,"offset":12662},"end":{"line":326,"column":48,"offset":12709},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":328,"column":1,"offset":12711},"end":{"line":330,"column":4,"offset":12733},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":332,"column":1,"offset":12735},"end":{"line":332,"column":72,"offset":12806},"indent":[]}}],"position":{"start":{"line":332,"column":1,"offset":12735},"end":{"line":332,"column":72,"offset":12806},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":334,"column":1,"offset":12808},"end":{"line":336,"column":4,"offset":12865},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":338,"column":4,"offset":12870},"end":{"line":338,"column":11,"offset":12877},"indent":[]}}],"position":{"start":{"line":338,"column":1,"offset":12867},"end":{"line":338,"column":11,"offset":12877},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":340,"column":1,"offset":12879},"end":{"line":340,"column":283,"offset":13161},"indent":[]}}],"position":{"start":{"line":340,"column":1,"offset":12879},"end":{"line":340,"column":283,"offset":13161},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":342,"column":3,"offset":13165},"end":{"line":342,"column":54,"offset":13216},"indent":[]}}],"position":{"start":{"line":342,"column":3,"offset":13165},"end":{"line":342,"column":54,"offset":13216},"indent":[]}}],"position":{"start":{"line":342,"column":1,"offset":13163},"end":{"line":342,"column":54,"offset":13216},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":344,"column":5,"offset":13222},"end":{"line":344,"column":14,"offset":13231},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13218},"end":{"line":344,"column":14,"offset":13231},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":346,"column":1,"offset":13233},"end":{"line":346,"column":68,"offset":13300},"indent":[]}}],"position":{"start":{"line":346,"column":1,"offset":13233},"end":{"line":346,"column":68,"offset":13300},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":348,"column":1,"offset":13302},"end":{"line":351,"column":4,"offset":13453},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":353,"column":1,"offset":13455},"end":{"line":353,"column":46,"offset":13500},"indent":[]}}],"position":{"start":{"line":353,"column":1,"offset":13455},"end":{"line":353,"column":46,"offset":13500},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":355,"column":3,"offset":13504},"end":{"line":355,"column":103,"offset":13604},"indent":[]}}],"position":{"start":{"line":355,"column":3,"offset":13504},"end":{"line":355,"column":103,"offset":13604},"indent":[]}}],"position":{"start":{"line":355,"column":1,"offset":13502},"end":{"line":355,"column":103,"offset":13604},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":357,"column":1,"offset":13606},"end":{"line":362,"column":4,"offset":13816},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":364,"column":1,"offset":13818},"end":{"line":364,"column":151,"offset":13968},"indent":[]}}],"position":{"start":{"line":364,"column":1,"offset":13818},"end":{"line":364,"column":151,"offset":13968},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":366,"column":3,"offset":13972},"end":{"line":366,"column":22,"offset":13991},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":366,"column":22,"offset":13991},"end":{"line":366,"column":26,"offset":13995},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":366,"column":26,"offset":13995},"end":{"line":366,"column":40,"offset":14009},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":366,"column":40,"offset":14009},"end":{"line":366,"column":50,"offset":14019},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":366,"column":50,"offset":14019},"end":{"line":366,"column":98,"offset":14067},"indent":[]}}],"position":{"start":{"line":366,"column":3,"offset":13972},"end":{"line":366,"column":98,"offset":14067},"indent":[]}}],"position":{"start":{"line":366,"column":1,"offset":13970},"end":{"line":366,"column":98,"offset":14067},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":368,"column":1,"offset":14069},"end":{"line":372,"column":4,"offset":14231},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":374,"column":1,"offset":14233},"end":{"line":374,"column":72,"offset":14304},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":374,"column":72,"offset":14304},"end":{"line":374,"column":84,"offset":14316},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":374,"column":84,"offset":14316},"end":{"line":374,"column":102,"offset":14334},"indent":[]}}],"position":{"start":{"line":374,"column":1,"offset":14233},"end":{"line":374,"column":102,"offset":14334},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":376,"column":1,"offset":14336},"end":{"line":379,"column":4,"offset":14410},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":381,"column":5,"offset":14416},"end":{"line":381,"column":8,"offset":14419},"indent":[]}}],"position":{"start":{"line":381,"column":1,"offset":14412},"end":{"line":381,"column":8,"offset":14419},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":383,"column":1,"offset":14421},"end":{"line":383,"column":176,"offset":14596},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14421},"end":{"line":383,"column":176,"offset":14596},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":385,"column":1,"offset":14598},"end":{"line":392,"column":4,"offset":14895},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":394,"column":1,"offset":14897},"end":{"line":394,"column":60,"offset":14956},"indent":[]}}],"position":{"start":{"line":394,"column":1,"offset":14897},"end":{"line":394,"column":60,"offset":14956},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":396,"column":1,"offset":14958},"end":{"line":400,"column":4,"offset":15084},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":402,"column":1,"offset":15086},"end":{"line":402,"column":63,"offset":15148},"indent":[]}}],"position":{"start":{"line":402,"column":1,"offset":15086},"end":{"line":402,"column":63,"offset":15148},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":404,"column":1,"offset":15150},"end":{"line":424,"column":4,"offset":15657},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":426,"column":1,"offset":15659},"end":{"line":426,"column":99,"offset":15757},"indent":[]}}],"position":{"start":{"line":426,"column":1,"offset":15659},"end":{"line":426,"column":99,"offset":15757},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":428,"column":1,"offset":15759},"end":{"line":431,"column":4,"offset":15861},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":433,"column":1,"offset":15863},"end":{"line":433,"column":37,"offset":15899},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":433,"column":37,"offset":15899},"end":{"line":433,"column":47,"offset":15909},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":433,"column":47,"offset":15909},"end":{"line":433,"column":89,"offset":15951},"indent":[]}}],"position":{"start":{"line":433,"column":1,"offset":15863},"end":{"line":433,"column":89,"offset":15951},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":435,"column":1,"offset":15953},"end":{"line":439,"column":4,"offset":16078},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":441,"column":1,"offset":16080},"end":{"line":441,"column":78,"offset":16157},"indent":[]}}],"position":{"start":{"line":441,"column":1,"offset":16080},"end":{"line":441,"column":78,"offset":16157},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":443,"column":1,"offset":16159},"end":{"line":447,"column":4,"offset":16263},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":449,"column":1,"offset":16265},"end":{"line":449,"column":75,"offset":16339},"indent":[]}}],"position":{"start":{"line":449,"column":1,"offset":16265},"end":{"line":449,"column":75,"offset":16339},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":451,"column":1,"offset":16341},"end":{"line":455,"column":4,"offset":16414},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":457,"column":1,"offset":16416},"end":{"line":457,"column":145,"offset":16560},"indent":[]}}],"position":{"start":{"line":457,"column":1,"offset":16416},"end":{"line":457,"column":145,"offset":16560},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":459,"column":5,"offset":16566},"end":{"line":459,"column":17,"offset":16578},"indent":[]}}],"position":{"start":{"line":459,"column":1,"offset":16562},"end":{"line":459,"column":17,"offset":16578},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":461,"column":1,"offset":16580},"end":{"line":461,"column":300,"offset":16879},"indent":[]}}],"position":{"start":{"line":461,"column":1,"offset":16580},"end":{"line":461,"column":300,"offset":16879},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":463,"column":1,"offset":16881},"end":{"line":463,"column":178,"offset":17058},"indent":[]}}],"position":{"start":{"line":463,"column":1,"offset":16881},"end":{"line":463,"column":178,"offset":17058},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":465,"column":1,"offset":17060},"end":{"line":465,"column":48,"offset":17107},"indent":[]}}],"position":{"start":{"line":465,"column":1,"offset":17060},"end":{"line":465,"column":48,"offset":17107},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":467,"column":1,"offset":17109},"end":{"line":469,"column":4,"offset":17153},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":471,"column":1,"offset":17155},"end":{"line":471,"column":104,"offset":17258},"indent":[]}}],"position":{"start":{"line":471,"column":1,"offset":17155},"end":{"line":471,"column":104,"offset":17258},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":473,"column":1,"offset":17260},"end":{"line":481,"column":4,"offset":17530},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":483,"column":1,"offset":17532},"end":{"line":483,"column":28,"offset":17559},"indent":[]}}],"position":{"start":{"line":483,"column":1,"offset":17532},"end":{"line":483,"column":28,"offset":17559},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":485,"column":1,"offset":17561},"end":{"line":487,"column":4,"offset":17609},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":489,"column":1,"offset":17611},"end":{"line":489,"column":48,"offset":17658},"indent":[]}}],"position":{"start":{"line":489,"column":1,"offset":17611},"end":{"line":489,"column":48,"offset":17658},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":491,"column":1,"offset":17660},"end":{"line":493,"column":4,"offset":17682},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":495,"column":1,"offset":17684},"end":{"line":495,"column":72,"offset":17755},"indent":[]}}],"position":{"start":{"line":495,"column":1,"offset":17684},"end":{"line":495,"column":72,"offset":17755},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":497,"column":1,"offset":17757},"end":{"line":499,"column":4,"offset":17818},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":502,"column":1,"offset":17821},"end":{"line":502,"column":31,"offset":17851},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":502,"column":31,"offset":17851}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug-and-Play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS for Raspberry Pi`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker for amd64, armv7, arm64`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.`}

\n

{`Especially in the worl\neven on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.`}

\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-587ebbe6b511a59a683e298dd2fcbdff.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-587ebbe6b511a59a683e298dd2fcbdff.json new file mode 100644 index 0000000..c710590 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-587ebbe6b511a59a683e298dd2fcbdff.json @@ -0,0 +1 @@ +{"expireTime":9007200842320127000,"key":"gatsby-plugin-mdx-entire-payload-3a5f4e6940343eafb45120711265ab78-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4645},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4647},"end":{"line":107,"column":80,"offset":4726},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4726},"end":{"line":107,"column":101,"offset":4747},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4747},"end":{"line":107,"column":162,"offset":4808},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4647},"end":{"line":107,"column":162,"offset":4808},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4810},"end":{"line":112,"column":4,"offset":4899},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4904},"end":{"line":114,"column":10,"offset":4910},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4901},"end":{"line":114,"column":10,"offset":4910},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on ","position":{"start":{"line":116,"column":1,"offset":4912},"end":{"line":116,"column":54,"offset":4965},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":55,"offset":4966},"end":{"line":116,"column":69,"offset":4980},"indent":[]}}],"position":{"start":{"line":116,"column":54,"offset":4965},"end":{"line":116,"column":105,"offset":5016},"indent":[]}},{"type":"text","value":", which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":116,"column":105,"offset":5016},"end":{"line":116,"column":376,"offset":5287},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":377,"offset":5288},"end":{"line":116,"column":391,"offset":5302},"indent":[]}}],"position":{"start":{"line":116,"column":376,"offset":5287},"end":{"line":116,"column":427,"offset":5338},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":427,"offset":5338},"end":{"line":116,"column":428,"offset":5339},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4912},"end":{"line":116,"column":428,"offset":5339},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5345},"end":{"line":118,"column":18,"offset":5358},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5341},"end":{"line":118,"column":18,"offset":5358},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5362},"end":{"line":120,"column":50,"offset":5409},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5362},"end":{"line":120,"column":50,"offset":5409},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5360},"end":{"line":120,"column":50,"offset":5409},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5415},"end":{"line":122,"column":11,"offset":5421},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5411},"end":{"line":122,"column":11,"offset":5421},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5423},"end":{"line":124,"column":64,"offset":5486},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5487},"end":{"line":124,"column":86,"offset":5508},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5486},"end":{"line":124,"column":126,"offset":5548},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5548},"end":{"line":124,"column":127,"offset":5549},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5423},"end":{"line":124,"column":127,"offset":5549},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5555},"end":{"line":126,"column":26,"offset":5576},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5551},"end":{"line":126,"column":26,"offset":5576},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5578},"end":{"line":128,"column":126,"offset":5703},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5578},"end":{"line":128,"column":126,"offset":5703},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5705},"end":{"line":132,"column":4,"offset":5744},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5746},"end":{"line":134,"column":187,"offset":5932},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5746},"end":{"line":134,"column":187,"offset":5932},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5934},"end":{"line":138,"column":4,"offset":6012},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6014},"end":{"line":140,"column":153,"offset":6166},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6014},"end":{"line":140,"column":153,"offset":6166},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6168},"end":{"line":145,"column":4,"offset":6315},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6317},"end":{"line":147,"column":100,"offset":6416},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6317},"end":{"line":147,"column":100,"offset":6416},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6417},"end":{"line":152,"column":4,"offset":6486},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6492},"end":{"line":154,"column":12,"offset":6499},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6488},"end":{"line":154,"column":12,"offset":6499},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Instead of just running the Kerberos container, you can also persist your configuration by assigning volumes. An example of mounting volumes looks like this; an overview of ","position":{"start":{"line":156,"column":1,"offset":6501},"end":{"line":156,"column":174,"offset":6674},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker/blob/master/Dockerfile#L171-L177","children":[{"type":"text","value":"the different volumes can be found here","position":{"start":{"line":156,"column":175,"offset":6675},"end":{"line":156,"column":214,"offset":6714},"indent":[]}}],"position":{"start":{"line":156,"column":174,"offset":6674},"end":{"line":156,"column":287,"offset":6787},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":156,"column":287,"offset":6787},"end":{"line":156,"column":288,"offset":6788},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6501},"end":{"line":156,"column":288,"offset":6788},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":158,"column":3,"offset":6792},"end":{"line":158,"column":25,"offset":6814},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6792},"end":{"line":158,"column":25,"offset":6814},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6790},"end":{"line":158,"column":25,"offset":6814},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":159,"column":3,"offset":6817},"end":{"line":159,"column":59,"offset":6873},"indent":[]}}],"position":{"start":{"line":159,"column":3,"offset":6817},"end":{"line":159,"column":59,"offset":6873},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":6815},"end":{"line":159,"column":59,"offset":6873},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6790},"end":{"line":159,"column":59,"offset":6873},"indent":[1]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name kerberos-camera1 \\\n-p 80:80 -p 8889:8889 \\\n-v ~/config:/etc/opt/kerberosio/config \\\n-v ~/capture:/etc/opt/kerberosio/capture \\\n-v ~/logs:/etc/opt/kerberosio/logs \\\n-v ~/webconfig:/var/www/web/config \\\n-d kerberos/kerberos","position":{"start":{"line":161,"column":1,"offset":6875},"end":{"line":169,"column":4,"offset":7124},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.","position":{"start":{"line":171,"column":1,"offset":7126},"end":{"line":171,"column":87,"offset":7212},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":7126},"end":{"line":171,"column":87,"offset":7212},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://medium.com/@cedricverst/kerberos-io-the-road-to-docker-8e048a480241","children":[{"type":"text","value":"Kerberos.io — the road to Docker","position":{"start":{"line":172,"column":4,"offset":7216},"end":{"line":172,"column":36,"offset":7248},"indent":[]}}],"position":{"start":{"line":172,"column":3,"offset":7215},"end":{"line":172,"column":114,"offset":7326},"indent":[]}}],"position":{"start":{"line":172,"column":3,"offset":7215},"end":{"line":172,"column":114,"offset":7326},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7213},"end":{"line":172,"column":114,"offset":7326},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7213},"end":{"line":172,"column":114,"offset":7326},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":175,"column":4,"offset":7332},"end":{"line":175,"column":10,"offset":7338},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7329},"end":{"line":175,"column":10,"offset":7338},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.","position":{"start":{"line":177,"column":1,"offset":7340},"end":{"line":177,"column":310,"offset":7649},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7340},"end":{"line":177,"column":310,"offset":7649},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To fill the gap, regarding the latter, we can rely on another solution called ","position":{"start":{"line":179,"column":1,"offset":7651},"end":{"line":179,"column":79,"offset":7729},"indent":[]}},{"type":"link","title":null,"url":"https://balena.io","children":[{"type":"text","value":"Balena.io","position":{"start":{"line":179,"column":80,"offset":7730},"end":{"line":179,"column":89,"offset":7739},"indent":[]}}],"position":{"start":{"line":179,"column":79,"offset":7729},"end":{"line":179,"column":109,"offset":7759},"indent":[]}},{"type":"text","value":". Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).","position":{"start":{"line":179,"column":109,"offset":7759},"end":{"line":179,"column":386,"offset":8036},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7651},"end":{"line":179,"column":386,"offset":8036},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On top of supporting a lot of boars,","position":{"start":{"line":181,"column":1,"offset":8038},"end":{"line":181,"column":37,"offset":8074},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":8038},"end":{"line":181,"column":37,"offset":8074},"indent":[]}},{"type":"thematicBreak","position":{"start":{"line":183,"column":1,"offset":8076},"end":{"line":183,"column":4,"offset":8079},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":185,"column":3,"offset":8083},"end":{"line":185,"column":11,"offset":8091},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":8081},"end":{"line":185,"column":11,"offset":8091},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":187,"column":1,"offset":8093},"end":{"line":187,"column":133,"offset":8225},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":8093},"end":{"line":187,"column":133,"offset":8225},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":189,"column":4,"offset":8230},"end":{"line":189,"column":12,"offset":8238},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":8227},"end":{"line":189,"column":12,"offset":8238},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":191,"column":1,"offset":8240},"end":{"line":191,"column":193,"offset":8432},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":8240},"end":{"line":191,"column":193,"offset":8432},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":193,"column":4,"offset":8437},"end":{"line":193,"column":62,"offset":8495},"indent":[]}}],"position":{"start":{"line":193,"column":4,"offset":8437},"end":{"line":193,"column":62,"offset":8495},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8434},"end":{"line":193,"column":62,"offset":8495},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":194,"column":4,"offset":8499},"end":{"line":194,"column":69,"offset":8564},"indent":[]}}],"position":{"start":{"line":194,"column":4,"offset":8499},"end":{"line":194,"column":69,"offset":8564},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":8496},"end":{"line":194,"column":69,"offset":8564},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8434},"end":{"line":194,"column":69,"offset":8564},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":196,"column":1,"offset":8566},"end":{"line":196,"column":99,"offset":8664},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8566},"end":{"line":196,"column":99,"offset":8664},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":198,"column":5,"offset":8670},"end":{"line":198,"column":14,"offset":8679},"indent":[]}}],"position":{"start":{"line":198,"column":1,"offset":8666},"end":{"line":198,"column":14,"offset":8679},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":200,"column":1,"offset":8681},"end":{"line":200,"column":71,"offset":8751},"indent":[]}}],"position":{"start":{"line":200,"column":1,"offset":8681},"end":{"line":200,"column":71,"offset":8751},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":202,"column":3,"offset":8755},"end":{"line":202,"column":47,"offset":8799},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":202,"column":47,"offset":8799},"end":{"line":202,"column":79,"offset":8831},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":202,"column":79,"offset":8831},"end":{"line":202,"column":198,"offset":8950},"indent":[]}}],"position":{"start":{"line":202,"column":3,"offset":8755},"end":{"line":202,"column":198,"offset":8950},"indent":[]}}],"position":{"start":{"line":202,"column":1,"offset":8753},"end":{"line":202,"column":198,"offset":8950},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":204,"column":1,"offset":8952},"end":{"line":206,"column":4,"offset":9015},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":208,"column":5,"offset":9021},"end":{"line":208,"column":14,"offset":9030},"indent":[]}}],"position":{"start":{"line":208,"column":1,"offset":9017},"end":{"line":208,"column":14,"offset":9030},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":210,"column":1,"offset":9032},"end":{"line":210,"column":56,"offset":9087},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":9032},"end":{"line":210,"column":56,"offset":9087},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":211,"column":3,"offset":9090},"end":{"line":211,"column":52,"offset":9139},"indent":[]}}],"position":{"start":{"line":211,"column":3,"offset":9090},"end":{"line":211,"column":52,"offset":9139},"indent":[]}}],"position":{"start":{"line":211,"column":3,"offset":9090},"end":{"line":211,"column":52,"offset":9139},"indent":[]}}],"position":{"start":{"line":211,"column":1,"offset":9088},"end":{"line":211,"column":52,"offset":9139},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":213,"column":1,"offset":9141},"end":{"line":213,"column":3,"offset":9143},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":213,"column":3,"offset":9143},"end":{"line":213,"column":9,"offset":9149},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":213,"column":9,"offset":9149},"end":{"line":213,"column":223,"offset":9363},"indent":[]}}],"position":{"start":{"line":213,"column":1,"offset":9141},"end":{"line":213,"column":223,"offset":9363},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":215,"column":3,"offset":9367},"end":{"line":215,"column":159,"offset":9523},"indent":[]}}],"position":{"start":{"line":215,"column":3,"offset":9367},"end":{"line":215,"column":159,"offset":9523},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":9365},"end":{"line":215,"column":159,"offset":9523},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":217,"column":1,"offset":9525},"end":{"line":220,"column":4,"offset":9702},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":222,"column":1,"offset":9704},"end":{"line":222,"column":160,"offset":9863},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":9704},"end":{"line":222,"column":160,"offset":9863},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":224,"column":3,"offset":9867},"end":{"line":224,"column":31,"offset":9895},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":224,"column":31,"offset":9895},"end":{"line":224,"column":101,"offset":9965},"indent":[]}}],"position":{"start":{"line":224,"column":3,"offset":9867},"end":{"line":224,"column":101,"offset":9965},"indent":[]}}],"position":{"start":{"line":224,"column":1,"offset":9865},"end":{"line":224,"column":101,"offset":9965},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":226,"column":1,"offset":9967},"end":{"line":229,"column":4,"offset":10139},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":231,"column":1,"offset":10141},"end":{"line":231,"column":73,"offset":10213},"indent":[]}}],"position":{"start":{"line":231,"column":1,"offset":10141},"end":{"line":231,"column":73,"offset":10213},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":234,"column":3,"offset":10218},"end":{"line":234,"column":31,"offset":10246},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":234,"column":31,"offset":10246},"end":{"line":234,"column":101,"offset":10316},"indent":[]}}],"position":{"start":{"line":234,"column":3,"offset":10218},"end":{"line":234,"column":101,"offset":10316},"indent":[]}}],"position":{"start":{"line":234,"column":1,"offset":10216},"end":{"line":234,"column":101,"offset":10316},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":236,"column":1,"offset":10318},"end":{"line":239,"column":4,"offset":10490},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":241,"column":1,"offset":10492},"end":{"line":241,"column":62,"offset":10553},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":241,"column":63,"offset":10554},"end":{"line":241,"column":75,"offset":10566},"indent":[]}}],"position":{"start":{"line":241,"column":62,"offset":10553},"end":{"line":241,"column":143,"offset":10634},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":241,"column":143,"offset":10634},"end":{"line":241,"column":150,"offset":10641},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":241,"column":150,"offset":10641},"end":{"line":241,"column":169,"offset":10660},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":241,"column":169,"offset":10660},"end":{"line":241,"column":170,"offset":10661},"indent":[]}}],"position":{"start":{"line":241,"column":1,"offset":10492},"end":{"line":241,"column":170,"offset":10661},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":243,"column":1,"offset":10663},"end":{"line":245,"column":4,"offset":10690},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":247,"column":1,"offset":10692},"end":{"line":247,"column":58,"offset":10749},"indent":[]}}],"position":{"start":{"line":247,"column":1,"offset":10692},"end":{"line":247,"column":58,"offset":10749},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":249,"column":1,"offset":10751},"end":{"line":252,"column":4,"offset":10821},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":254,"column":5,"offset":10827},"end":{"line":254,"column":8,"offset":10830},"indent":[]}}],"position":{"start":{"line":254,"column":1,"offset":10823},"end":{"line":254,"column":8,"offset":10830},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":256,"column":1,"offset":10832},"end":{"line":256,"column":280,"offset":11111},"indent":[]}}],"position":{"start":{"line":256,"column":1,"offset":10832},"end":{"line":256,"column":280,"offset":11111},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":258,"column":1,"offset":11113},"end":{"line":258,"column":37,"offset":11149},"indent":[]}}],"position":{"start":{"line":258,"column":1,"offset":11113},"end":{"line":258,"column":37,"offset":11149},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":260,"column":1,"offset":11151},"end":{"line":262,"column":4,"offset":11324},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":264,"column":1,"offset":11326},"end":{"line":264,"column":25,"offset":11350},"indent":[]}}],"position":{"start":{"line":264,"column":1,"offset":11326},"end":{"line":264,"column":25,"offset":11350},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":266,"column":1,"offset":11352},"end":{"line":269,"column":4,"offset":11456},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":271,"column":1,"offset":11458},"end":{"line":271,"column":118,"offset":11575},"indent":[]}}],"position":{"start":{"line":271,"column":1,"offset":11458},"end":{"line":271,"column":118,"offset":11575},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":273,"column":1,"offset":11577},"end":{"line":293,"column":4,"offset":12084},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":295,"column":1,"offset":12086},"end":{"line":295,"column":14,"offset":12099},"indent":[]}}],"position":{"start":{"line":295,"column":1,"offset":12086},"end":{"line":295,"column":14,"offset":12099},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":297,"column":1,"offset":12101},"end":{"line":299,"column":4,"offset":12137},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":301,"column":1,"offset":12139},"end":{"line":301,"column":91,"offset":12229},"indent":[]}}],"position":{"start":{"line":301,"column":1,"offset":12139},"end":{"line":301,"column":91,"offset":12229},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":303,"column":1,"offset":12231},"end":{"line":311,"column":4,"offset":12604},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":313,"column":1,"offset":12606},"end":{"line":313,"column":145,"offset":12750},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":12606},"end":{"line":313,"column":145,"offset":12750},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":315,"column":5,"offset":12756},"end":{"line":315,"column":17,"offset":12768},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12752},"end":{"line":315,"column":17,"offset":12768},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":317,"column":1,"offset":12770},"end":{"line":317,"column":300,"offset":13069},"indent":[]}}],"position":{"start":{"line":317,"column":1,"offset":12770},"end":{"line":317,"column":300,"offset":13069},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":319,"column":1,"offset":13071},"end":{"line":319,"column":178,"offset":13248},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":13071},"end":{"line":319,"column":178,"offset":13248},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":321,"column":1,"offset":13250},"end":{"line":321,"column":48,"offset":13297},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":13250},"end":{"line":321,"column":48,"offset":13297},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":323,"column":1,"offset":13299},"end":{"line":325,"column":4,"offset":13339},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":327,"column":1,"offset":13341},"end":{"line":327,"column":104,"offset":13444},"indent":[]}}],"position":{"start":{"line":327,"column":1,"offset":13341},"end":{"line":327,"column":104,"offset":13444},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":329,"column":1,"offset":13446},"end":{"line":337,"column":4,"offset":13716},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":339,"column":1,"offset":13718},"end":{"line":339,"column":28,"offset":13745},"indent":[]}}],"position":{"start":{"line":339,"column":1,"offset":13718},"end":{"line":339,"column":28,"offset":13745},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":341,"column":1,"offset":13747},"end":{"line":343,"column":4,"offset":13791},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":345,"column":1,"offset":13793},"end":{"line":345,"column":48,"offset":13840},"indent":[]}}],"position":{"start":{"line":345,"column":1,"offset":13793},"end":{"line":345,"column":48,"offset":13840},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":347,"column":1,"offset":13842},"end":{"line":349,"column":4,"offset":13864},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":351,"column":1,"offset":13866},"end":{"line":351,"column":72,"offset":13937},"indent":[]}}],"position":{"start":{"line":351,"column":1,"offset":13866},"end":{"line":351,"column":72,"offset":13937},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":353,"column":1,"offset":13939},"end":{"line":355,"column":4,"offset":13996},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":357,"column":4,"offset":14001},"end":{"line":357,"column":11,"offset":14008},"indent":[]}}],"position":{"start":{"line":357,"column":1,"offset":13998},"end":{"line":357,"column":11,"offset":14008},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":359,"column":1,"offset":14010},"end":{"line":359,"column":283,"offset":14292},"indent":[]}}],"position":{"start":{"line":359,"column":1,"offset":14010},"end":{"line":359,"column":283,"offset":14292},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":361,"column":3,"offset":14296},"end":{"line":361,"column":54,"offset":14347},"indent":[]}}],"position":{"start":{"line":361,"column":3,"offset":14296},"end":{"line":361,"column":54,"offset":14347},"indent":[]}}],"position":{"start":{"line":361,"column":1,"offset":14294},"end":{"line":361,"column":54,"offset":14347},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":363,"column":5,"offset":14353},"end":{"line":363,"column":14,"offset":14362},"indent":[]}}],"position":{"start":{"line":363,"column":1,"offset":14349},"end":{"line":363,"column":14,"offset":14362},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":365,"column":1,"offset":14364},"end":{"line":365,"column":68,"offset":14431},"indent":[]}}],"position":{"start":{"line":365,"column":1,"offset":14364},"end":{"line":365,"column":68,"offset":14431},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":367,"column":1,"offset":14433},"end":{"line":370,"column":4,"offset":14584},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":372,"column":1,"offset":14586},"end":{"line":372,"column":46,"offset":14631},"indent":[]}}],"position":{"start":{"line":372,"column":1,"offset":14586},"end":{"line":372,"column":46,"offset":14631},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":374,"column":3,"offset":14635},"end":{"line":374,"column":103,"offset":14735},"indent":[]}}],"position":{"start":{"line":374,"column":3,"offset":14635},"end":{"line":374,"column":103,"offset":14735},"indent":[]}}],"position":{"start":{"line":374,"column":1,"offset":14633},"end":{"line":374,"column":103,"offset":14735},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":376,"column":1,"offset":14737},"end":{"line":381,"column":4,"offset":14947},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":383,"column":1,"offset":14949},"end":{"line":383,"column":151,"offset":15099},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14949},"end":{"line":383,"column":151,"offset":15099},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":385,"column":3,"offset":15103},"end":{"line":385,"column":22,"offset":15122},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":385,"column":22,"offset":15122},"end":{"line":385,"column":26,"offset":15126},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":385,"column":26,"offset":15126},"end":{"line":385,"column":40,"offset":15140},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":385,"column":40,"offset":15140},"end":{"line":385,"column":50,"offset":15150},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":385,"column":50,"offset":15150},"end":{"line":385,"column":98,"offset":15198},"indent":[]}}],"position":{"start":{"line":385,"column":3,"offset":15103},"end":{"line":385,"column":98,"offset":15198},"indent":[]}}],"position":{"start":{"line":385,"column":1,"offset":15101},"end":{"line":385,"column":98,"offset":15198},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":387,"column":1,"offset":15200},"end":{"line":391,"column":4,"offset":15362},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":393,"column":1,"offset":15364},"end":{"line":393,"column":72,"offset":15435},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":393,"column":72,"offset":15435},"end":{"line":393,"column":84,"offset":15447},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":393,"column":84,"offset":15447},"end":{"line":393,"column":102,"offset":15465},"indent":[]}}],"position":{"start":{"line":393,"column":1,"offset":15364},"end":{"line":393,"column":102,"offset":15465},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":395,"column":1,"offset":15467},"end":{"line":398,"column":4,"offset":15541},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":400,"column":5,"offset":15547},"end":{"line":400,"column":8,"offset":15550},"indent":[]}}],"position":{"start":{"line":400,"column":1,"offset":15543},"end":{"line":400,"column":8,"offset":15550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":402,"column":1,"offset":15552},"end":{"line":402,"column":176,"offset":15727},"indent":[]}}],"position":{"start":{"line":402,"column":1,"offset":15552},"end":{"line":402,"column":176,"offset":15727},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":404,"column":1,"offset":15729},"end":{"line":411,"column":4,"offset":16026},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":413,"column":1,"offset":16028},"end":{"line":413,"column":60,"offset":16087},"indent":[]}}],"position":{"start":{"line":413,"column":1,"offset":16028},"end":{"line":413,"column":60,"offset":16087},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":415,"column":1,"offset":16089},"end":{"line":419,"column":4,"offset":16215},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":421,"column":1,"offset":16217},"end":{"line":421,"column":63,"offset":16279},"indent":[]}}],"position":{"start":{"line":421,"column":1,"offset":16217},"end":{"line":421,"column":63,"offset":16279},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":423,"column":1,"offset":16281},"end":{"line":443,"column":4,"offset":16788},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":445,"column":1,"offset":16790},"end":{"line":445,"column":99,"offset":16888},"indent":[]}}],"position":{"start":{"line":445,"column":1,"offset":16790},"end":{"line":445,"column":99,"offset":16888},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":447,"column":1,"offset":16890},"end":{"line":450,"column":4,"offset":16992},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":452,"column":1,"offset":16994},"end":{"line":452,"column":37,"offset":17030},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":452,"column":37,"offset":17030},"end":{"line":452,"column":47,"offset":17040},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":452,"column":47,"offset":17040},"end":{"line":452,"column":89,"offset":17082},"indent":[]}}],"position":{"start":{"line":452,"column":1,"offset":16994},"end":{"line":452,"column":89,"offset":17082},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":454,"column":1,"offset":17084},"end":{"line":458,"column":4,"offset":17209},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":460,"column":1,"offset":17211},"end":{"line":460,"column":78,"offset":17288},"indent":[]}}],"position":{"start":{"line":460,"column":1,"offset":17211},"end":{"line":460,"column":78,"offset":17288},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":462,"column":1,"offset":17290},"end":{"line":466,"column":4,"offset":17394},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":468,"column":1,"offset":17396},"end":{"line":468,"column":75,"offset":17470},"indent":[]}}],"position":{"start":{"line":468,"column":1,"offset":17396},"end":{"line":468,"column":75,"offset":17470},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":470,"column":1,"offset":17472},"end":{"line":474,"column":4,"offset":17545},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":476,"column":1,"offset":17547},"end":{"line":476,"column":145,"offset":17691},"indent":[]}}],"position":{"start":{"line":476,"column":1,"offset":17547},"end":{"line":476,"column":145,"offset":17691},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":478,"column":5,"offset":17697},"end":{"line":478,"column":17,"offset":17709},"indent":[]}}],"position":{"start":{"line":478,"column":1,"offset":17693},"end":{"line":478,"column":17,"offset":17709},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":480,"column":1,"offset":17711},"end":{"line":480,"column":300,"offset":18010},"indent":[]}}],"position":{"start":{"line":480,"column":1,"offset":17711},"end":{"line":480,"column":300,"offset":18010},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":482,"column":1,"offset":18012},"end":{"line":482,"column":178,"offset":18189},"indent":[]}}],"position":{"start":{"line":482,"column":1,"offset":18012},"end":{"line":482,"column":178,"offset":18189},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":484,"column":1,"offset":18191},"end":{"line":484,"column":48,"offset":18238},"indent":[]}}],"position":{"start":{"line":484,"column":1,"offset":18191},"end":{"line":484,"column":48,"offset":18238},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":486,"column":1,"offset":18240},"end":{"line":488,"column":4,"offset":18284},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":490,"column":1,"offset":18286},"end":{"line":490,"column":104,"offset":18389},"indent":[]}}],"position":{"start":{"line":490,"column":1,"offset":18286},"end":{"line":490,"column":104,"offset":18389},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":492,"column":1,"offset":18391},"end":{"line":500,"column":4,"offset":18661},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":502,"column":1,"offset":18663},"end":{"line":502,"column":28,"offset":18690},"indent":[]}}],"position":{"start":{"line":502,"column":1,"offset":18663},"end":{"line":502,"column":28,"offset":18690},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":504,"column":1,"offset":18692},"end":{"line":506,"column":4,"offset":18740},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":508,"column":1,"offset":18742},"end":{"line":508,"column":48,"offset":18789},"indent":[]}}],"position":{"start":{"line":508,"column":1,"offset":18742},"end":{"line":508,"column":48,"offset":18789},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":510,"column":1,"offset":18791},"end":{"line":512,"column":4,"offset":18813},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":514,"column":1,"offset":18815},"end":{"line":514,"column":72,"offset":18886},"indent":[]}}],"position":{"start":{"line":514,"column":1,"offset":18815},"end":{"line":514,"column":72,"offset":18886},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":516,"column":1,"offset":18888},"end":{"line":518,"column":4,"offset":18949},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":521,"column":1,"offset":18952},"end":{"line":521,"column":31,"offset":18982},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":521,"column":31,"offset":18982}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on `}{`the Docker hub`}{`, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`Instead of just running the Kerberos container, you can also persist your configuration by assigning volumes. An example of mounting volumes looks like this; an overview of `}{`the different volumes can be found here`}{`.`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`kerberos`}{`-`}{`camera1`}{` \\\\`}{`\n`}{`-`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/config:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`config`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/capture:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`capture`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/logs:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`logs`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/webconfig:/`}{`var`}{`/`}{`www`}{`/web/config \\\\`}{`\n`}{`-`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.`}

\n \n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.`}

\n

{`To fill the gap, regarding the latter, we can rely on another solution called `}{`Balena.io`}{`. Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).`}

\n

{`On top of supporting a lot of boars,`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-5a2db5ceca4a34135dfe60553b644651.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-5a2db5ceca4a34135dfe60553b644651.json new file mode 100644 index 0000000..7ec1585 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-5a2db5ceca4a34135dfe60553b644651.json @@ -0,0 +1 @@ +{"expireTime":9007200841982889000,"key":"gatsby-plugin-mdx-entire-payload-5b248ad8afcf4de9102c3097f6a68bfa-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Plug-and-Play","position":{"start":{"line":14,"column":4,"offset":446},"end":{"line":14,"column":17,"offset":459},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":17,"offset":459},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":464},"end":{"line":15,"column":9,"offset":468},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":463},"end":{"line":15,"column":41,"offset":500},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":500},"end":{"line":15,"column":116,"offset":575},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":463},"end":{"line":15,"column":116,"offset":575},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":460},"end":{"line":15,"column":116,"offset":575},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":580},"end":{"line":16,"column":11,"offset":586},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":579},"end":{"line":16,"column":45,"offset":620},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":620},"end":{"line":16,"column":121,"offset":696},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":579},"end":{"line":16,"column":121,"offset":696},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":576},"end":{"line":16,"column":121,"offset":696},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":701},"end":{"line":17,"column":11,"offset":707},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":700},"end":{"line":17,"column":45,"offset":741},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":741},"end":{"line":17,"column":103,"offset":799},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":700},"end":{"line":17,"column":103,"offset":799},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":697},"end":{"line":17,"column":103,"offset":799},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":460},"end":{"line":17,"column":103,"offset":799},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":4,"offset":804},"end":{"line":19,"column":12,"offset":812},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":801},"end":{"line":19,"column":12,"offset":812},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":817},"end":{"line":20,"column":13,"offset":825},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":816},"end":{"line":20,"column":49,"offset":861},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":861},"end":{"line":20,"column":139,"offset":951},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":816},"end":{"line":20,"column":139,"offset":951},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":813},"end":{"line":20,"column":139,"offset":951},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":956},"end":{"line":21,"column":12,"offset":963},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":955},"end":{"line":21,"column":47,"offset":998},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":998},"end":{"line":21,"column":179,"offset":1130},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":955},"end":{"line":21,"column":179,"offset":1130},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":952},"end":{"line":21,"column":179,"offset":1130},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":813},"end":{"line":21,"column":179,"offset":1130},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":23,"column":4,"offset":1135},"end":{"line":23,"column":8,"offset":1139},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":1132},"end":{"line":23,"column":8,"offset":1139},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":25,"column":1,"offset":1141},"end":{"line":25,"column":229,"offset":1369},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1141},"end":{"line":25,"column":229,"offset":1369},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":27,"column":1,"offset":1371},"end":{"line":27,"column":197,"offset":1567},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1371},"end":{"line":27,"column":197,"offset":1567},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":29,"column":5,"offset":1573},"end":{"line":29,"column":11,"offset":1579},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1569},"end":{"line":29,"column":11,"offset":1579},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":31,"column":1,"offset":1581},"end":{"line":31,"column":63,"offset":1643},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":31,"column":64,"offset":1644},"end":{"line":31,"column":85,"offset":1665},"indent":[]}}],"position":{"start":{"line":31,"column":63,"offset":1643},"end":{"line":31,"column":123,"offset":1703},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":31,"column":123,"offset":1703},"end":{"line":31,"column":124,"offset":1704},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1581},"end":{"line":31,"column":124,"offset":1704},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos installer","position":{"start":{"line":33,"column":5,"offset":1710},"end":{"line":33,"column":23,"offset":1728},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1706},"end":{"line":33,"column":23,"offset":1728},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":35,"column":1,"offset":1730},"end":{"line":35,"column":228,"offset":1957},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1730},"end":{"line":35,"column":228,"offset":1957},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":37,"column":1,"offset":1959},"end":{"line":37,"column":67,"offset":2025},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1959},"end":{"line":37,"column":67,"offset":2025},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":39,"column":1,"offset":2027},"end":{"line":39,"column":50,"offset":2076},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":2027},"end":{"line":39,"column":50,"offset":2076},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":41,"column":3,"offset":2080},"end":{"line":41,"column":49,"offset":2126},"indent":[]}}],"position":{"start":{"line":41,"column":3,"offset":2080},"end":{"line":41,"column":49,"offset":2126},"indent":[]}}],"position":{"start":{"line":41,"column":3,"offset":2080},"end":{"line":41,"column":49,"offset":2126},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":2078},"end":{"line":41,"column":49,"offset":2126},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":43,"column":5,"offset":2132},"end":{"line":43,"column":11,"offset":2138},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2128},"end":{"line":43,"column":11,"offset":2138},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":45,"column":1,"offset":2140},"end":{"line":45,"column":160,"offset":2299},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2140},"end":{"line":45,"column":160,"offset":2299},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":47,"column":4,"offset":2304},"end":{"line":47,"column":13,"offset":2313},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":47,"column":14,"offset":2314},"end":{"line":47,"column":28,"offset":2328},"indent":[]}}],"position":{"start":{"line":47,"column":13,"offset":2313},"end":{"line":47,"column":75,"offset":2375},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":47,"column":75,"offset":2375},"end":{"line":47,"column":76,"offset":2376},"indent":[]}}],"position":{"start":{"line":47,"column":4,"offset":2304},"end":{"line":47,"column":76,"offset":2376},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2301},"end":{"line":47,"column":76,"offset":2376},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":48,"column":4,"offset":2380},"end":{"line":48,"column":41,"offset":2417},"indent":[]}}],"position":{"start":{"line":48,"column":4,"offset":2380},"end":{"line":48,"column":41,"offset":2417},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2377},"end":{"line":48,"column":41,"offset":2417},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":49,"column":4,"offset":2421},"end":{"line":49,"column":60,"offset":2477},"indent":[]}}],"position":{"start":{"line":49,"column":4,"offset":2421},"end":{"line":49,"column":60,"offset":2477},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2418},"end":{"line":49,"column":60,"offset":2477},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2301},"end":{"line":49,"column":60,"offset":2477},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":51,"column":2,"offset":2480},"end":{"line":51,"column":64,"offset":2542},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2479},"end":{"line":51,"column":96,"offset":2574},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2479},"end":{"line":51,"column":96,"offset":2574},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":53,"column":1,"offset":2576},"end":{"line":53,"column":204,"offset":2779},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2576},"end":{"line":53,"column":204,"offset":2779},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":55,"column":6,"offset":2786},"end":{"line":55,"column":24,"offset":2804},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2781},"end":{"line":55,"column":24,"offset":2804},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":57,"column":1,"offset":2806},"end":{"line":57,"column":95,"offset":2900},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":57,"column":95,"offset":2900},"end":{"line":57,"column":110,"offset":2915},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":57,"column":110,"offset":2915},"end":{"line":57,"column":222,"offset":3027},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2806},"end":{"line":57,"column":222,"offset":3027},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":59,"column":1,"offset":3029},"end":{"line":67,"column":4,"offset":3138},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":69,"column":6,"offset":3145},"end":{"line":69,"column":31,"offset":3170},"indent":[]}}],"position":{"start":{"line":69,"column":1,"offset":3140},"end":{"line":69,"column":31,"offset":3170},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":71,"column":1,"offset":3172},"end":{"line":71,"column":79,"offset":3250},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":71,"column":79,"offset":3250},"end":{"line":71,"column":95,"offset":3266},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":71,"column":95,"offset":3266},"end":{"line":71,"column":137,"offset":3308},"indent":[]}}],"position":{"start":{"line":71,"column":1,"offset":3172},"end":{"line":71,"column":137,"offset":3308},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":73,"column":1,"offset":3310},"end":{"line":83,"column":4,"offset":3678},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":85,"column":5,"offset":3684},"end":{"line":85,"column":30,"offset":3709},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":3680},"end":{"line":85,"column":30,"offset":3709},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":87,"column":1,"offset":3711},"end":{"line":87,"column":464,"offset":4174},"indent":[]}}],"position":{"start":{"line":87,"column":1,"offset":3711},"end":{"line":87,"column":464,"offset":4174},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":89,"column":1,"offset":4176},"end":{"line":89,"column":61,"offset":4236},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":4176},"end":{"line":89,"column":61,"offset":4236},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":4242},"end":{"line":91,"column":28,"offset":4265},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":4238},"end":{"line":91,"column":28,"offset":4265},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":93,"column":1,"offset":4267},"end":{"line":93,"column":95,"offset":4361},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":93,"column":95,"offset":4361},"end":{"line":93,"column":100,"offset":4366},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":93,"column":100,"offset":4366},"end":{"line":93,"column":101,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":4267},"end":{"line":93,"column":101,"offset":4367},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":99,"column":4,"offset":4486},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":101,"column":1,"offset":4488},"end":{"line":101,"column":80,"offset":4567},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":101,"column":80,"offset":4567},"end":{"line":101,"column":101,"offset":4588},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":101,"column":101,"offset":4588},"end":{"line":101,"column":162,"offset":4649},"indent":[]}}],"position":{"start":{"line":101,"column":1,"offset":4488},"end":{"line":101,"column":162,"offset":4649},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":103,"column":1,"offset":4651},"end":{"line":106,"column":4,"offset":4740},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":108,"column":4,"offset":4745},"end":{"line":108,"column":12,"offset":4753},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":4742},"end":{"line":108,"column":12,"offset":4753},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":110,"column":1,"offset":4755},"end":{"line":110,"column":193,"offset":4947},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4755},"end":{"line":110,"column":193,"offset":4947},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":112,"column":4,"offset":4952},"end":{"line":112,"column":62,"offset":5010},"indent":[]}}],"position":{"start":{"line":112,"column":4,"offset":4952},"end":{"line":112,"column":62,"offset":5010},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":4949},"end":{"line":112,"column":62,"offset":5010},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":113,"column":4,"offset":5014},"end":{"line":113,"column":69,"offset":5079},"indent":[]}}],"position":{"start":{"line":113,"column":4,"offset":5014},"end":{"line":113,"column":69,"offset":5079},"indent":[]}}],"position":{"start":{"line":113,"column":1,"offset":5011},"end":{"line":113,"column":69,"offset":5079},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":4949},"end":{"line":113,"column":69,"offset":5079},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":115,"column":1,"offset":5081},"end":{"line":115,"column":99,"offset":5179},"indent":[]}}],"position":{"start":{"line":115,"column":1,"offset":5081},"end":{"line":115,"column":99,"offset":5179},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":117,"column":5,"offset":5185},"end":{"line":117,"column":14,"offset":5194},"indent":[]}}],"position":{"start":{"line":117,"column":1,"offset":5181},"end":{"line":117,"column":14,"offset":5194},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":119,"column":1,"offset":5196},"end":{"line":119,"column":71,"offset":5266},"indent":[]}}],"position":{"start":{"line":119,"column":1,"offset":5196},"end":{"line":119,"column":71,"offset":5266},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":121,"column":3,"offset":5270},"end":{"line":121,"column":47,"offset":5314},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":121,"column":47,"offset":5314},"end":{"line":121,"column":79,"offset":5346},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":121,"column":79,"offset":5346},"end":{"line":121,"column":198,"offset":5465},"indent":[]}}],"position":{"start":{"line":121,"column":3,"offset":5270},"end":{"line":121,"column":198,"offset":5465},"indent":[]}}],"position":{"start":{"line":121,"column":1,"offset":5268},"end":{"line":121,"column":198,"offset":5465},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":123,"column":1,"offset":5467},"end":{"line":125,"column":4,"offset":5530},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":127,"column":5,"offset":5536},"end":{"line":127,"column":14,"offset":5545},"indent":[]}}],"position":{"start":{"line":127,"column":1,"offset":5532},"end":{"line":127,"column":14,"offset":5545},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":129,"column":1,"offset":5547},"end":{"line":129,"column":56,"offset":5602},"indent":[]}}],"position":{"start":{"line":129,"column":1,"offset":5547},"end":{"line":129,"column":56,"offset":5602},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":130,"column":3,"offset":5605},"end":{"line":130,"column":52,"offset":5654},"indent":[]}}],"position":{"start":{"line":130,"column":3,"offset":5605},"end":{"line":130,"column":52,"offset":5654},"indent":[]}}],"position":{"start":{"line":130,"column":3,"offset":5605},"end":{"line":130,"column":52,"offset":5654},"indent":[]}}],"position":{"start":{"line":130,"column":1,"offset":5603},"end":{"line":130,"column":52,"offset":5654},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":132,"column":1,"offset":5656},"end":{"line":132,"column":3,"offset":5658},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":132,"column":3,"offset":5658},"end":{"line":132,"column":9,"offset":5664},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":132,"column":9,"offset":5664},"end":{"line":132,"column":223,"offset":5878},"indent":[]}}],"position":{"start":{"line":132,"column":1,"offset":5656},"end":{"line":132,"column":223,"offset":5878},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":134,"column":3,"offset":5882},"end":{"line":134,"column":159,"offset":6038},"indent":[]}}],"position":{"start":{"line":134,"column":3,"offset":5882},"end":{"line":134,"column":159,"offset":6038},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5880},"end":{"line":134,"column":159,"offset":6038},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":136,"column":1,"offset":6040},"end":{"line":139,"column":4,"offset":6217},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":141,"column":1,"offset":6219},"end":{"line":141,"column":160,"offset":6378},"indent":[]}}],"position":{"start":{"line":141,"column":1,"offset":6219},"end":{"line":141,"column":160,"offset":6378},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":143,"column":3,"offset":6382},"end":{"line":143,"column":31,"offset":6410},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":143,"column":31,"offset":6410},"end":{"line":143,"column":101,"offset":6480},"indent":[]}}],"position":{"start":{"line":143,"column":3,"offset":6382},"end":{"line":143,"column":101,"offset":6480},"indent":[]}}],"position":{"start":{"line":143,"column":1,"offset":6380},"end":{"line":143,"column":101,"offset":6480},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":145,"column":1,"offset":6482},"end":{"line":148,"column":4,"offset":6654},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":150,"column":1,"offset":6656},"end":{"line":150,"column":73,"offset":6728},"indent":[]}}],"position":{"start":{"line":150,"column":1,"offset":6656},"end":{"line":150,"column":73,"offset":6728},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":153,"column":3,"offset":6733},"end":{"line":153,"column":31,"offset":6761},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":153,"column":31,"offset":6761},"end":{"line":153,"column":101,"offset":6831},"indent":[]}}],"position":{"start":{"line":153,"column":3,"offset":6733},"end":{"line":153,"column":101,"offset":6831},"indent":[]}}],"position":{"start":{"line":153,"column":1,"offset":6731},"end":{"line":153,"column":101,"offset":6831},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":155,"column":1,"offset":6833},"end":{"line":158,"column":4,"offset":7005},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":160,"column":1,"offset":7007},"end":{"line":160,"column":62,"offset":7068},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":160,"column":63,"offset":7069},"end":{"line":160,"column":75,"offset":7081},"indent":[]}}],"position":{"start":{"line":160,"column":62,"offset":7068},"end":{"line":160,"column":143,"offset":7149},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":160,"column":143,"offset":7149},"end":{"line":160,"column":150,"offset":7156},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":160,"column":150,"offset":7156},"end":{"line":160,"column":169,"offset":7175},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":160,"column":169,"offset":7175},"end":{"line":160,"column":170,"offset":7176},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":7007},"end":{"line":160,"column":170,"offset":7176},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":162,"column":1,"offset":7178},"end":{"line":164,"column":4,"offset":7205},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":166,"column":1,"offset":7207},"end":{"line":166,"column":58,"offset":7264},"indent":[]}}],"position":{"start":{"line":166,"column":1,"offset":7207},"end":{"line":166,"column":58,"offset":7264},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":168,"column":1,"offset":7266},"end":{"line":171,"column":4,"offset":7336},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":173,"column":5,"offset":7342},"end":{"line":173,"column":8,"offset":7345},"indent":[]}}],"position":{"start":{"line":173,"column":1,"offset":7338},"end":{"line":173,"column":8,"offset":7345},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":175,"column":1,"offset":7347},"end":{"line":175,"column":280,"offset":7626},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7347},"end":{"line":175,"column":280,"offset":7626},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":177,"column":1,"offset":7628},"end":{"line":177,"column":37,"offset":7664},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7628},"end":{"line":177,"column":37,"offset":7664},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":179,"column":1,"offset":7666},"end":{"line":181,"column":4,"offset":7839},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":183,"column":1,"offset":7841},"end":{"line":183,"column":25,"offset":7865},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":7841},"end":{"line":183,"column":25,"offset":7865},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":185,"column":1,"offset":7867},"end":{"line":188,"column":4,"offset":7971},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":190,"column":1,"offset":7973},"end":{"line":190,"column":118,"offset":8090},"indent":[]}}],"position":{"start":{"line":190,"column":1,"offset":7973},"end":{"line":190,"column":118,"offset":8090},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":192,"column":1,"offset":8092},"end":{"line":212,"column":4,"offset":8599},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":214,"column":1,"offset":8601},"end":{"line":214,"column":14,"offset":8614},"indent":[]}}],"position":{"start":{"line":214,"column":1,"offset":8601},"end":{"line":214,"column":14,"offset":8614},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":216,"column":1,"offset":8616},"end":{"line":218,"column":4,"offset":8652},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":220,"column":1,"offset":8654},"end":{"line":220,"column":91,"offset":8744},"indent":[]}}],"position":{"start":{"line":220,"column":1,"offset":8654},"end":{"line":220,"column":91,"offset":8744},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":222,"column":1,"offset":8746},"end":{"line":230,"column":4,"offset":9119},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":232,"column":1,"offset":9121},"end":{"line":232,"column":145,"offset":9265},"indent":[]}}],"position":{"start":{"line":232,"column":1,"offset":9121},"end":{"line":232,"column":145,"offset":9265},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":234,"column":5,"offset":9271},"end":{"line":234,"column":17,"offset":9283},"indent":[]}}],"position":{"start":{"line":234,"column":1,"offset":9267},"end":{"line":234,"column":17,"offset":9283},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":236,"column":1,"offset":9285},"end":{"line":236,"column":300,"offset":9584},"indent":[]}}],"position":{"start":{"line":236,"column":1,"offset":9285},"end":{"line":236,"column":300,"offset":9584},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":238,"column":1,"offset":9586},"end":{"line":238,"column":178,"offset":9763},"indent":[]}}],"position":{"start":{"line":238,"column":1,"offset":9586},"end":{"line":238,"column":178,"offset":9763},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":240,"column":1,"offset":9765},"end":{"line":240,"column":48,"offset":9812},"indent":[]}}],"position":{"start":{"line":240,"column":1,"offset":9765},"end":{"line":240,"column":48,"offset":9812},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":242,"column":1,"offset":9814},"end":{"line":244,"column":4,"offset":9854},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":246,"column":1,"offset":9856},"end":{"line":246,"column":104,"offset":9959},"indent":[]}}],"position":{"start":{"line":246,"column":1,"offset":9856},"end":{"line":246,"column":104,"offset":9959},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":248,"column":1,"offset":9961},"end":{"line":256,"column":4,"offset":10231},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":258,"column":1,"offset":10233},"end":{"line":258,"column":28,"offset":10260},"indent":[]}}],"position":{"start":{"line":258,"column":1,"offset":10233},"end":{"line":258,"column":28,"offset":10260},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":260,"column":1,"offset":10262},"end":{"line":262,"column":4,"offset":10306},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":264,"column":1,"offset":10308},"end":{"line":264,"column":48,"offset":10355},"indent":[]}}],"position":{"start":{"line":264,"column":1,"offset":10308},"end":{"line":264,"column":48,"offset":10355},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":266,"column":1,"offset":10357},"end":{"line":268,"column":4,"offset":10379},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":270,"column":1,"offset":10381},"end":{"line":270,"column":72,"offset":10452},"indent":[]}}],"position":{"start":{"line":270,"column":1,"offset":10381},"end":{"line":270,"column":72,"offset":10452},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":272,"column":1,"offset":10454},"end":{"line":274,"column":4,"offset":10511},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":276,"column":4,"offset":10516},"end":{"line":276,"column":10,"offset":10522},"indent":[]}}],"position":{"start":{"line":276,"column":1,"offset":10513},"end":{"line":276,"column":10,"offset":10522},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":278,"column":1,"offset":10524},"end":{"line":278,"column":337,"offset":10860},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":278,"column":338,"offset":10861},"end":{"line":278,"column":352,"offset":10875},"indent":[]}}],"position":{"start":{"line":278,"column":337,"offset":10860},"end":{"line":278,"column":388,"offset":10911},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":278,"column":388,"offset":10911},"end":{"line":278,"column":389,"offset":10912},"indent":[]}}],"position":{"start":{"line":278,"column":1,"offset":10524},"end":{"line":278,"column":389,"offset":10912},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":280,"column":5,"offset":10918},"end":{"line":280,"column":18,"offset":10931},"indent":[]}}],"position":{"start":{"line":280,"column":1,"offset":10914},"end":{"line":280,"column":18,"offset":10931},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":282,"column":3,"offset":10935},"end":{"line":282,"column":50,"offset":10982},"indent":[]}}],"position":{"start":{"line":282,"column":3,"offset":10935},"end":{"line":282,"column":50,"offset":10982},"indent":[]}}],"position":{"start":{"line":282,"column":1,"offset":10933},"end":{"line":282,"column":50,"offset":10982},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":284,"column":5,"offset":10988},"end":{"line":284,"column":11,"offset":10994},"indent":[]}}],"position":{"start":{"line":284,"column":1,"offset":10984},"end":{"line":284,"column":11,"offset":10994},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":286,"column":1,"offset":10996},"end":{"line":286,"column":64,"offset":11059},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":286,"column":65,"offset":11060},"end":{"line":286,"column":86,"offset":11081},"indent":[]}}],"position":{"start":{"line":286,"column":64,"offset":11059},"end":{"line":286,"column":126,"offset":11121},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":286,"column":126,"offset":11121},"end":{"line":286,"column":127,"offset":11122},"indent":[]}}],"position":{"start":{"line":286,"column":1,"offset":10996},"end":{"line":286,"column":127,"offset":11122},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":288,"column":5,"offset":11128},"end":{"line":288,"column":26,"offset":11149},"indent":[]}}],"position":{"start":{"line":288,"column":1,"offset":11124},"end":{"line":288,"column":26,"offset":11149},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":290,"column":1,"offset":11151},"end":{"line":290,"column":126,"offset":11276},"indent":[]}}],"position":{"start":{"line":290,"column":1,"offset":11151},"end":{"line":290,"column":126,"offset":11276},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":292,"column":1,"offset":11278},"end":{"line":294,"column":4,"offset":11317},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":296,"column":1,"offset":11319},"end":{"line":296,"column":187,"offset":11505},"indent":[]}}],"position":{"start":{"line":296,"column":1,"offset":11319},"end":{"line":296,"column":187,"offset":11505},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":298,"column":1,"offset":11507},"end":{"line":300,"column":4,"offset":11585},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":302,"column":1,"offset":11587},"end":{"line":302,"column":153,"offset":11739},"indent":[]}}],"position":{"start":{"line":302,"column":1,"offset":11587},"end":{"line":302,"column":153,"offset":11739},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":304,"column":1,"offset":11741},"end":{"line":307,"column":4,"offset":11888},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":309,"column":1,"offset":11890},"end":{"line":309,"column":100,"offset":11989},"indent":[]}}],"position":{"start":{"line":309,"column":1,"offset":11890},"end":{"line":309,"column":100,"offset":11989},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":310,"column":1,"offset":11990},"end":{"line":314,"column":4,"offset":12059},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":316,"column":5,"offset":12065},"end":{"line":316,"column":12,"offset":12072},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12061},"end":{"line":316,"column":12,"offset":12072},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":318,"column":1,"offset":12074},"end":{"line":318,"column":64,"offset":12137},"indent":[]}}],"position":{"start":{"line":318,"column":1,"offset":12074},"end":{"line":318,"column":64,"offset":12137},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":319,"column":3,"offset":12140},"end":{"line":319,"column":25,"offset":12162},"indent":[]}}],"position":{"start":{"line":319,"column":3,"offset":12140},"end":{"line":319,"column":25,"offset":12162},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":12138},"end":{"line":319,"column":25,"offset":12162},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":320,"column":3,"offset":12165},"end":{"line":320,"column":59,"offset":12221},"indent":[]}}],"position":{"start":{"line":320,"column":3,"offset":12165},"end":{"line":320,"column":59,"offset":12221},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":12163},"end":{"line":320,"column":59,"offset":12221},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":12138},"end":{"line":320,"column":59,"offset":12221},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":322,"column":4,"offset":12226},"end":{"line":322,"column":10,"offset":12232},"indent":[]}}],"position":{"start":{"line":322,"column":1,"offset":12223},"end":{"line":322,"column":10,"offset":12232},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos as a Docker container is great, and makes it possible to run Kerberos everywhere, even on a Raspberry Pi or any other tiny PC. However some you might need more control and flexibility. This is where Balena comes into the picture.","position":{"start":{"line":324,"column":1,"offset":12234},"end":{"line":324,"column":247,"offset":12480},"indent":[]}}],"position":{"start":{"line":324,"column":1,"offset":12234},"end":{"line":324,"column":247,"offset":12480},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":327,"column":4,"offset":12486},"end":{"line":327,"column":11,"offset":12493},"indent":[]}}],"position":{"start":{"line":327,"column":1,"offset":12483},"end":{"line":327,"column":11,"offset":12493},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":329,"column":1,"offset":12495},"end":{"line":329,"column":283,"offset":12777},"indent":[]}}],"position":{"start":{"line":329,"column":1,"offset":12495},"end":{"line":329,"column":283,"offset":12777},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":331,"column":3,"offset":12781},"end":{"line":331,"column":54,"offset":12832},"indent":[]}}],"position":{"start":{"line":331,"column":3,"offset":12781},"end":{"line":331,"column":54,"offset":12832},"indent":[]}}],"position":{"start":{"line":331,"column":1,"offset":12779},"end":{"line":331,"column":54,"offset":12832},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":333,"column":5,"offset":12838},"end":{"line":333,"column":14,"offset":12847},"indent":[]}}],"position":{"start":{"line":333,"column":1,"offset":12834},"end":{"line":333,"column":14,"offset":12847},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":335,"column":1,"offset":12849},"end":{"line":335,"column":68,"offset":12916},"indent":[]}}],"position":{"start":{"line":335,"column":1,"offset":12849},"end":{"line":335,"column":68,"offset":12916},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":337,"column":1,"offset":12918},"end":{"line":340,"column":4,"offset":13069},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":342,"column":1,"offset":13071},"end":{"line":342,"column":46,"offset":13116},"indent":[]}}],"position":{"start":{"line":342,"column":1,"offset":13071},"end":{"line":342,"column":46,"offset":13116},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":344,"column":3,"offset":13120},"end":{"line":344,"column":103,"offset":13220},"indent":[]}}],"position":{"start":{"line":344,"column":3,"offset":13120},"end":{"line":344,"column":103,"offset":13220},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13118},"end":{"line":344,"column":103,"offset":13220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":346,"column":1,"offset":13222},"end":{"line":351,"column":4,"offset":13432},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":353,"column":1,"offset":13434},"end":{"line":353,"column":151,"offset":13584},"indent":[]}}],"position":{"start":{"line":353,"column":1,"offset":13434},"end":{"line":353,"column":151,"offset":13584},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":355,"column":3,"offset":13588},"end":{"line":355,"column":22,"offset":13607},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":355,"column":22,"offset":13607},"end":{"line":355,"column":26,"offset":13611},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":355,"column":26,"offset":13611},"end":{"line":355,"column":40,"offset":13625},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":355,"column":40,"offset":13625},"end":{"line":355,"column":50,"offset":13635},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":355,"column":50,"offset":13635},"end":{"line":355,"column":98,"offset":13683},"indent":[]}}],"position":{"start":{"line":355,"column":3,"offset":13588},"end":{"line":355,"column":98,"offset":13683},"indent":[]}}],"position":{"start":{"line":355,"column":1,"offset":13586},"end":{"line":355,"column":98,"offset":13683},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":357,"column":1,"offset":13685},"end":{"line":361,"column":4,"offset":13847},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":363,"column":1,"offset":13849},"end":{"line":363,"column":72,"offset":13920},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":363,"column":72,"offset":13920},"end":{"line":363,"column":84,"offset":13932},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":363,"column":84,"offset":13932},"end":{"line":363,"column":102,"offset":13950},"indent":[]}}],"position":{"start":{"line":363,"column":1,"offset":13849},"end":{"line":363,"column":102,"offset":13950},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":365,"column":1,"offset":13952},"end":{"line":368,"column":4,"offset":14026},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":370,"column":5,"offset":14032},"end":{"line":370,"column":8,"offset":14035},"indent":[]}}],"position":{"start":{"line":370,"column":1,"offset":14028},"end":{"line":370,"column":8,"offset":14035},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":372,"column":1,"offset":14037},"end":{"line":372,"column":176,"offset":14212},"indent":[]}}],"position":{"start":{"line":372,"column":1,"offset":14037},"end":{"line":372,"column":176,"offset":14212},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":374,"column":1,"offset":14214},"end":{"line":381,"column":4,"offset":14511},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":383,"column":1,"offset":14513},"end":{"line":383,"column":60,"offset":14572},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14513},"end":{"line":383,"column":60,"offset":14572},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":385,"column":1,"offset":14574},"end":{"line":389,"column":4,"offset":14700},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":391,"column":1,"offset":14702},"end":{"line":391,"column":63,"offset":14764},"indent":[]}}],"position":{"start":{"line":391,"column":1,"offset":14702},"end":{"line":391,"column":63,"offset":14764},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":393,"column":1,"offset":14766},"end":{"line":413,"column":4,"offset":15273},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":415,"column":1,"offset":15275},"end":{"line":415,"column":99,"offset":15373},"indent":[]}}],"position":{"start":{"line":415,"column":1,"offset":15275},"end":{"line":415,"column":99,"offset":15373},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":417,"column":1,"offset":15375},"end":{"line":420,"column":4,"offset":15477},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":422,"column":1,"offset":15479},"end":{"line":422,"column":37,"offset":15515},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":422,"column":37,"offset":15515},"end":{"line":422,"column":47,"offset":15525},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":422,"column":47,"offset":15525},"end":{"line":422,"column":89,"offset":15567},"indent":[]}}],"position":{"start":{"line":422,"column":1,"offset":15479},"end":{"line":422,"column":89,"offset":15567},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":424,"column":1,"offset":15569},"end":{"line":428,"column":4,"offset":15694},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":430,"column":1,"offset":15696},"end":{"line":430,"column":78,"offset":15773},"indent":[]}}],"position":{"start":{"line":430,"column":1,"offset":15696},"end":{"line":430,"column":78,"offset":15773},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":432,"column":1,"offset":15775},"end":{"line":436,"column":4,"offset":15879},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":438,"column":1,"offset":15881},"end":{"line":438,"column":75,"offset":15955},"indent":[]}}],"position":{"start":{"line":438,"column":1,"offset":15881},"end":{"line":438,"column":75,"offset":15955},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":440,"column":1,"offset":15957},"end":{"line":444,"column":4,"offset":16030},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":446,"column":1,"offset":16032},"end":{"line":446,"column":145,"offset":16176},"indent":[]}}],"position":{"start":{"line":446,"column":1,"offset":16032},"end":{"line":446,"column":145,"offset":16176},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":448,"column":5,"offset":16182},"end":{"line":448,"column":17,"offset":16194},"indent":[]}}],"position":{"start":{"line":448,"column":1,"offset":16178},"end":{"line":448,"column":17,"offset":16194},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":450,"column":1,"offset":16196},"end":{"line":450,"column":300,"offset":16495},"indent":[]}}],"position":{"start":{"line":450,"column":1,"offset":16196},"end":{"line":450,"column":300,"offset":16495},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":452,"column":1,"offset":16497},"end":{"line":452,"column":178,"offset":16674},"indent":[]}}],"position":{"start":{"line":452,"column":1,"offset":16497},"end":{"line":452,"column":178,"offset":16674},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":454,"column":1,"offset":16676},"end":{"line":454,"column":48,"offset":16723},"indent":[]}}],"position":{"start":{"line":454,"column":1,"offset":16676},"end":{"line":454,"column":48,"offset":16723},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":456,"column":1,"offset":16725},"end":{"line":458,"column":4,"offset":16769},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":460,"column":1,"offset":16771},"end":{"line":460,"column":104,"offset":16874},"indent":[]}}],"position":{"start":{"line":460,"column":1,"offset":16771},"end":{"line":460,"column":104,"offset":16874},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":462,"column":1,"offset":16876},"end":{"line":470,"column":4,"offset":17146},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":472,"column":1,"offset":17148},"end":{"line":472,"column":28,"offset":17175},"indent":[]}}],"position":{"start":{"line":472,"column":1,"offset":17148},"end":{"line":472,"column":28,"offset":17175},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":474,"column":1,"offset":17177},"end":{"line":476,"column":4,"offset":17225},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":478,"column":1,"offset":17227},"end":{"line":478,"column":48,"offset":17274},"indent":[]}}],"position":{"start":{"line":478,"column":1,"offset":17227},"end":{"line":478,"column":48,"offset":17274},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":480,"column":1,"offset":17276},"end":{"line":482,"column":4,"offset":17298},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":484,"column":1,"offset":17300},"end":{"line":484,"column":72,"offset":17371},"indent":[]}}],"position":{"start":{"line":484,"column":1,"offset":17300},"end":{"line":484,"column":72,"offset":17371},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":486,"column":1,"offset":17373},"end":{"line":488,"column":4,"offset":17434},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":491,"column":1,"offset":17437},"end":{"line":491,"column":31,"offset":17467},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":491,"column":31,"offset":17467}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug-and-Play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Docker`}

\n

{`A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos as a Docker container is great, and makes it possible to run Kerberos everywhere, even on a Raspberry Pi or any other tiny PC. However some you might need more control and flexibility. This is where Balena comes into the picture.`}

\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-5d712ae2876bdd0cb73a797f6724f8d4.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-5d712ae2876bdd0cb73a797f6724f8d4.json new file mode 100644 index 0000000..b5d0bc9 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-5d712ae2876bdd0cb73a797f6724f8d4.json @@ -0,0 +1 @@ +{"expireTime":9007200842319938000,"key":"gatsby-plugin-mdx-entire-payload-5c556af4ceea7fcd65d02a34ec523800-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4679},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":80,"offset":4760},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4760},"end":{"line":107,"column":101,"offset":4781},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4781},"end":{"line":107,"column":162,"offset":4842},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":162,"offset":4842},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4844},"end":{"line":112,"column":4,"offset":4933},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4938},"end":{"line":114,"column":10,"offset":4944},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4935},"end":{"line":114,"column":10,"offset":4944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":339,"offset":5284},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":340,"offset":5285},"end":{"line":116,"column":354,"offset":5299},"indent":[]}}],"position":{"start":{"line":116,"column":339,"offset":5284},"end":{"line":116,"column":390,"offset":5335},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":390,"offset":5335},"end":{"line":116,"column":391,"offset":5336},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":391,"offset":5336},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5342},"end":{"line":118,"column":18,"offset":5355},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5338},"end":{"line":118,"column":18,"offset":5355},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5357},"end":{"line":120,"column":50,"offset":5406},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5412},"end":{"line":122,"column":11,"offset":5418},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5408},"end":{"line":122,"column":11,"offset":5418},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":64,"offset":5483},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5484},"end":{"line":124,"column":86,"offset":5505},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5483},"end":{"line":124,"column":126,"offset":5545},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5545},"end":{"line":124,"column":127,"offset":5546},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":127,"offset":5546},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5552},"end":{"line":126,"column":26,"offset":5573},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5548},"end":{"line":126,"column":26,"offset":5573},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5702},"end":{"line":132,"column":4,"offset":5741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5931},"end":{"line":138,"column":4,"offset":6009},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6165},"end":{"line":145,"column":4,"offset":6312},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6414},"end":{"line":152,"column":4,"offset":6483},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6489},"end":{"line":154,"column":12,"offset":6496},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6485},"end":{"line":154,"column":12,"offset":6496},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Instead of just running the Kerberos container, you can also persist your configuration by assigning volumes. An example of mounting volumes looks like this; an overview of ","position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":174,"offset":6671},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker/blob/master/Dockerfile#L171-L177","children":[{"type":"text","value":"the different volumes can be found here","position":{"start":{"line":156,"column":175,"offset":6672},"end":{"line":156,"column":214,"offset":6711},"indent":[]}}],"position":{"start":{"line":156,"column":174,"offset":6671},"end":{"line":156,"column":287,"offset":6784},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":156,"column":287,"offset":6784},"end":{"line":156,"column":288,"offset":6785},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":288,"offset":6785},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":158,"column":3,"offset":6789},"end":{"line":158,"column":25,"offset":6811},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6789},"end":{"line":158,"column":25,"offset":6811},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6787},"end":{"line":158,"column":25,"offset":6811},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":159,"column":3,"offset":6814},"end":{"line":159,"column":59,"offset":6870},"indent":[]}}],"position":{"start":{"line":159,"column":3,"offset":6814},"end":{"line":159,"column":59,"offset":6870},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":6812},"end":{"line":159,"column":59,"offset":6870},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6787},"end":{"line":159,"column":59,"offset":6870},"indent":[1]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name kerberos-camera1 \\\n-p 80:80 -p 8889:8889 \\\n-v ~/config:/etc/opt/kerberosio/config \\\n-v ~/capture:/etc/opt/kerberosio/capture \\\n-v ~/logs:/etc/opt/kerberosio/logs \\\n-v ~/webconfig:/var/www/web/config \\\n-d kerberos/kerberos","position":{"start":{"line":161,"column":1,"offset":6872},"end":{"line":169,"column":4,"offset":7121},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.","position":{"start":{"line":171,"column":1,"offset":7123},"end":{"line":171,"column":87,"offset":7209},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":7123},"end":{"line":171,"column":87,"offset":7209},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://medium.com/@cedricverst/kerberos-io-the-road-to-docker-8e048a480241","children":[{"type":"text","value":"Kerberos.io — the road to Docker","position":{"start":{"line":172,"column":4,"offset":7213},"end":{"line":172,"column":36,"offset":7245},"indent":[]}}],"position":{"start":{"line":172,"column":3,"offset":7212},"end":{"line":172,"column":114,"offset":7323},"indent":[]}}],"position":{"start":{"line":172,"column":3,"offset":7212},"end":{"line":172,"column":114,"offset":7323},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7210},"end":{"line":172,"column":114,"offset":7323},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7210},"end":{"line":172,"column":114,"offset":7323},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":175,"column":4,"offset":7329},"end":{"line":175,"column":10,"offset":7335},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7326},"end":{"line":175,"column":10,"offset":7335},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.","position":{"start":{"line":177,"column":1,"offset":7337},"end":{"line":177,"column":310,"offset":7646},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7337},"end":{"line":177,"column":310,"offset":7646},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To fill the gap, regarding the latter, we can rely on another solution called ","position":{"start":{"line":179,"column":1,"offset":7648},"end":{"line":179,"column":79,"offset":7726},"indent":[]}},{"type":"link","title":null,"url":"https://balena.io","children":[{"type":"text","value":"Balena.io","position":{"start":{"line":179,"column":80,"offset":7727},"end":{"line":179,"column":89,"offset":7736},"indent":[]}}],"position":{"start":{"line":179,"column":79,"offset":7726},"end":{"line":179,"column":109,"offset":7756},"indent":[]}},{"type":"text","value":". Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).","position":{"start":{"line":179,"column":109,"offset":7756},"end":{"line":179,"column":386,"offset":8033},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7648},"end":{"line":179,"column":386,"offset":8033},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On top of supporting a lot of boars,","position":{"start":{"line":181,"column":1,"offset":8035},"end":{"line":181,"column":37,"offset":8071},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":8035},"end":{"line":181,"column":37,"offset":8071},"indent":[]}},{"type":"thematicBreak","position":{"start":{"line":183,"column":1,"offset":8073},"end":{"line":183,"column":4,"offset":8076},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":185,"column":3,"offset":8080},"end":{"line":185,"column":11,"offset":8088},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":8078},"end":{"line":185,"column":11,"offset":8088},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":187,"column":1,"offset":8090},"end":{"line":187,"column":133,"offset":8222},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":8090},"end":{"line":187,"column":133,"offset":8222},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":189,"column":4,"offset":8227},"end":{"line":189,"column":12,"offset":8235},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":8224},"end":{"line":189,"column":12,"offset":8235},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":191,"column":1,"offset":8237},"end":{"line":191,"column":193,"offset":8429},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":8237},"end":{"line":191,"column":193,"offset":8429},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":193,"column":4,"offset":8434},"end":{"line":193,"column":62,"offset":8492},"indent":[]}}],"position":{"start":{"line":193,"column":4,"offset":8434},"end":{"line":193,"column":62,"offset":8492},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8431},"end":{"line":193,"column":62,"offset":8492},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":194,"column":4,"offset":8496},"end":{"line":194,"column":69,"offset":8561},"indent":[]}}],"position":{"start":{"line":194,"column":4,"offset":8496},"end":{"line":194,"column":69,"offset":8561},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":8493},"end":{"line":194,"column":69,"offset":8561},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8431},"end":{"line":194,"column":69,"offset":8561},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":196,"column":1,"offset":8563},"end":{"line":196,"column":99,"offset":8661},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8563},"end":{"line":196,"column":99,"offset":8661},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":198,"column":5,"offset":8667},"end":{"line":198,"column":14,"offset":8676},"indent":[]}}],"position":{"start":{"line":198,"column":1,"offset":8663},"end":{"line":198,"column":14,"offset":8676},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":200,"column":1,"offset":8678},"end":{"line":200,"column":71,"offset":8748},"indent":[]}}],"position":{"start":{"line":200,"column":1,"offset":8678},"end":{"line":200,"column":71,"offset":8748},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":202,"column":3,"offset":8752},"end":{"line":202,"column":47,"offset":8796},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":202,"column":47,"offset":8796},"end":{"line":202,"column":79,"offset":8828},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":202,"column":79,"offset":8828},"end":{"line":202,"column":198,"offset":8947},"indent":[]}}],"position":{"start":{"line":202,"column":3,"offset":8752},"end":{"line":202,"column":198,"offset":8947},"indent":[]}}],"position":{"start":{"line":202,"column":1,"offset":8750},"end":{"line":202,"column":198,"offset":8947},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":204,"column":1,"offset":8949},"end":{"line":206,"column":4,"offset":9012},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":208,"column":5,"offset":9018},"end":{"line":208,"column":14,"offset":9027},"indent":[]}}],"position":{"start":{"line":208,"column":1,"offset":9014},"end":{"line":208,"column":14,"offset":9027},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":210,"column":1,"offset":9029},"end":{"line":210,"column":56,"offset":9084},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":9029},"end":{"line":210,"column":56,"offset":9084},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":211,"column":3,"offset":9087},"end":{"line":211,"column":52,"offset":9136},"indent":[]}}],"position":{"start":{"line":211,"column":3,"offset":9087},"end":{"line":211,"column":52,"offset":9136},"indent":[]}}],"position":{"start":{"line":211,"column":3,"offset":9087},"end":{"line":211,"column":52,"offset":9136},"indent":[]}}],"position":{"start":{"line":211,"column":1,"offset":9085},"end":{"line":211,"column":52,"offset":9136},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":213,"column":1,"offset":9138},"end":{"line":213,"column":3,"offset":9140},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":213,"column":3,"offset":9140},"end":{"line":213,"column":9,"offset":9146},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":213,"column":9,"offset":9146},"end":{"line":213,"column":223,"offset":9360},"indent":[]}}],"position":{"start":{"line":213,"column":1,"offset":9138},"end":{"line":213,"column":223,"offset":9360},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":215,"column":3,"offset":9364},"end":{"line":215,"column":159,"offset":9520},"indent":[]}}],"position":{"start":{"line":215,"column":3,"offset":9364},"end":{"line":215,"column":159,"offset":9520},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":9362},"end":{"line":215,"column":159,"offset":9520},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":217,"column":1,"offset":9522},"end":{"line":220,"column":4,"offset":9699},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":222,"column":1,"offset":9701},"end":{"line":222,"column":160,"offset":9860},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":9701},"end":{"line":222,"column":160,"offset":9860},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":224,"column":3,"offset":9864},"end":{"line":224,"column":31,"offset":9892},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":224,"column":31,"offset":9892},"end":{"line":224,"column":101,"offset":9962},"indent":[]}}],"position":{"start":{"line":224,"column":3,"offset":9864},"end":{"line":224,"column":101,"offset":9962},"indent":[]}}],"position":{"start":{"line":224,"column":1,"offset":9862},"end":{"line":224,"column":101,"offset":9962},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":226,"column":1,"offset":9964},"end":{"line":229,"column":4,"offset":10136},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":231,"column":1,"offset":10138},"end":{"line":231,"column":73,"offset":10210},"indent":[]}}],"position":{"start":{"line":231,"column":1,"offset":10138},"end":{"line":231,"column":73,"offset":10210},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":234,"column":3,"offset":10215},"end":{"line":234,"column":31,"offset":10243},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":234,"column":31,"offset":10243},"end":{"line":234,"column":101,"offset":10313},"indent":[]}}],"position":{"start":{"line":234,"column":3,"offset":10215},"end":{"line":234,"column":101,"offset":10313},"indent":[]}}],"position":{"start":{"line":234,"column":1,"offset":10213},"end":{"line":234,"column":101,"offset":10313},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":236,"column":1,"offset":10315},"end":{"line":239,"column":4,"offset":10487},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":241,"column":1,"offset":10489},"end":{"line":241,"column":62,"offset":10550},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":241,"column":63,"offset":10551},"end":{"line":241,"column":75,"offset":10563},"indent":[]}}],"position":{"start":{"line":241,"column":62,"offset":10550},"end":{"line":241,"column":143,"offset":10631},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":241,"column":143,"offset":10631},"end":{"line":241,"column":150,"offset":10638},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":241,"column":150,"offset":10638},"end":{"line":241,"column":169,"offset":10657},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":241,"column":169,"offset":10657},"end":{"line":241,"column":170,"offset":10658},"indent":[]}}],"position":{"start":{"line":241,"column":1,"offset":10489},"end":{"line":241,"column":170,"offset":10658},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":243,"column":1,"offset":10660},"end":{"line":245,"column":4,"offset":10687},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":247,"column":1,"offset":10689},"end":{"line":247,"column":58,"offset":10746},"indent":[]}}],"position":{"start":{"line":247,"column":1,"offset":10689},"end":{"line":247,"column":58,"offset":10746},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":249,"column":1,"offset":10748},"end":{"line":252,"column":4,"offset":10818},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":254,"column":5,"offset":10824},"end":{"line":254,"column":8,"offset":10827},"indent":[]}}],"position":{"start":{"line":254,"column":1,"offset":10820},"end":{"line":254,"column":8,"offset":10827},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":256,"column":1,"offset":10829},"end":{"line":256,"column":280,"offset":11108},"indent":[]}}],"position":{"start":{"line":256,"column":1,"offset":10829},"end":{"line":256,"column":280,"offset":11108},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":258,"column":1,"offset":11110},"end":{"line":258,"column":37,"offset":11146},"indent":[]}}],"position":{"start":{"line":258,"column":1,"offset":11110},"end":{"line":258,"column":37,"offset":11146},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":260,"column":1,"offset":11148},"end":{"line":262,"column":4,"offset":11321},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":264,"column":1,"offset":11323},"end":{"line":264,"column":25,"offset":11347},"indent":[]}}],"position":{"start":{"line":264,"column":1,"offset":11323},"end":{"line":264,"column":25,"offset":11347},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":266,"column":1,"offset":11349},"end":{"line":269,"column":4,"offset":11453},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":271,"column":1,"offset":11455},"end":{"line":271,"column":118,"offset":11572},"indent":[]}}],"position":{"start":{"line":271,"column":1,"offset":11455},"end":{"line":271,"column":118,"offset":11572},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":273,"column":1,"offset":11574},"end":{"line":293,"column":4,"offset":12081},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":295,"column":1,"offset":12083},"end":{"line":295,"column":14,"offset":12096},"indent":[]}}],"position":{"start":{"line":295,"column":1,"offset":12083},"end":{"line":295,"column":14,"offset":12096},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":297,"column":1,"offset":12098},"end":{"line":299,"column":4,"offset":12134},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":301,"column":1,"offset":12136},"end":{"line":301,"column":91,"offset":12226},"indent":[]}}],"position":{"start":{"line":301,"column":1,"offset":12136},"end":{"line":301,"column":91,"offset":12226},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":303,"column":1,"offset":12228},"end":{"line":311,"column":4,"offset":12601},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":313,"column":1,"offset":12603},"end":{"line":313,"column":145,"offset":12747},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":12603},"end":{"line":313,"column":145,"offset":12747},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":315,"column":5,"offset":12753},"end":{"line":315,"column":17,"offset":12765},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12749},"end":{"line":315,"column":17,"offset":12765},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":317,"column":1,"offset":12767},"end":{"line":317,"column":300,"offset":13066},"indent":[]}}],"position":{"start":{"line":317,"column":1,"offset":12767},"end":{"line":317,"column":300,"offset":13066},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":319,"column":1,"offset":13068},"end":{"line":319,"column":178,"offset":13245},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":13068},"end":{"line":319,"column":178,"offset":13245},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":321,"column":1,"offset":13247},"end":{"line":321,"column":48,"offset":13294},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":13247},"end":{"line":321,"column":48,"offset":13294},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":323,"column":1,"offset":13296},"end":{"line":325,"column":4,"offset":13336},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":327,"column":1,"offset":13338},"end":{"line":327,"column":104,"offset":13441},"indent":[]}}],"position":{"start":{"line":327,"column":1,"offset":13338},"end":{"line":327,"column":104,"offset":13441},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":329,"column":1,"offset":13443},"end":{"line":337,"column":4,"offset":13713},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":339,"column":1,"offset":13715},"end":{"line":339,"column":28,"offset":13742},"indent":[]}}],"position":{"start":{"line":339,"column":1,"offset":13715},"end":{"line":339,"column":28,"offset":13742},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":341,"column":1,"offset":13744},"end":{"line":343,"column":4,"offset":13788},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":345,"column":1,"offset":13790},"end":{"line":345,"column":48,"offset":13837},"indent":[]}}],"position":{"start":{"line":345,"column":1,"offset":13790},"end":{"line":345,"column":48,"offset":13837},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":347,"column":1,"offset":13839},"end":{"line":349,"column":4,"offset":13861},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":351,"column":1,"offset":13863},"end":{"line":351,"column":72,"offset":13934},"indent":[]}}],"position":{"start":{"line":351,"column":1,"offset":13863},"end":{"line":351,"column":72,"offset":13934},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":353,"column":1,"offset":13936},"end":{"line":355,"column":4,"offset":13993},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":357,"column":4,"offset":13998},"end":{"line":357,"column":11,"offset":14005},"indent":[]}}],"position":{"start":{"line":357,"column":1,"offset":13995},"end":{"line":357,"column":11,"offset":14005},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":359,"column":1,"offset":14007},"end":{"line":359,"column":283,"offset":14289},"indent":[]}}],"position":{"start":{"line":359,"column":1,"offset":14007},"end":{"line":359,"column":283,"offset":14289},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":361,"column":3,"offset":14293},"end":{"line":361,"column":54,"offset":14344},"indent":[]}}],"position":{"start":{"line":361,"column":3,"offset":14293},"end":{"line":361,"column":54,"offset":14344},"indent":[]}}],"position":{"start":{"line":361,"column":1,"offset":14291},"end":{"line":361,"column":54,"offset":14344},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":363,"column":5,"offset":14350},"end":{"line":363,"column":14,"offset":14359},"indent":[]}}],"position":{"start":{"line":363,"column":1,"offset":14346},"end":{"line":363,"column":14,"offset":14359},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":365,"column":1,"offset":14361},"end":{"line":365,"column":68,"offset":14428},"indent":[]}}],"position":{"start":{"line":365,"column":1,"offset":14361},"end":{"line":365,"column":68,"offset":14428},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":367,"column":1,"offset":14430},"end":{"line":370,"column":4,"offset":14581},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":372,"column":1,"offset":14583},"end":{"line":372,"column":46,"offset":14628},"indent":[]}}],"position":{"start":{"line":372,"column":1,"offset":14583},"end":{"line":372,"column":46,"offset":14628},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":374,"column":3,"offset":14632},"end":{"line":374,"column":103,"offset":14732},"indent":[]}}],"position":{"start":{"line":374,"column":3,"offset":14632},"end":{"line":374,"column":103,"offset":14732},"indent":[]}}],"position":{"start":{"line":374,"column":1,"offset":14630},"end":{"line":374,"column":103,"offset":14732},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":376,"column":1,"offset":14734},"end":{"line":381,"column":4,"offset":14944},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":383,"column":1,"offset":14946},"end":{"line":383,"column":151,"offset":15096},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14946},"end":{"line":383,"column":151,"offset":15096},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":385,"column":3,"offset":15100},"end":{"line":385,"column":22,"offset":15119},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":385,"column":22,"offset":15119},"end":{"line":385,"column":26,"offset":15123},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":385,"column":26,"offset":15123},"end":{"line":385,"column":40,"offset":15137},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":385,"column":40,"offset":15137},"end":{"line":385,"column":50,"offset":15147},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":385,"column":50,"offset":15147},"end":{"line":385,"column":98,"offset":15195},"indent":[]}}],"position":{"start":{"line":385,"column":3,"offset":15100},"end":{"line":385,"column":98,"offset":15195},"indent":[]}}],"position":{"start":{"line":385,"column":1,"offset":15098},"end":{"line":385,"column":98,"offset":15195},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":387,"column":1,"offset":15197},"end":{"line":391,"column":4,"offset":15359},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":393,"column":1,"offset":15361},"end":{"line":393,"column":72,"offset":15432},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":393,"column":72,"offset":15432},"end":{"line":393,"column":84,"offset":15444},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":393,"column":84,"offset":15444},"end":{"line":393,"column":102,"offset":15462},"indent":[]}}],"position":{"start":{"line":393,"column":1,"offset":15361},"end":{"line":393,"column":102,"offset":15462},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":395,"column":1,"offset":15464},"end":{"line":398,"column":4,"offset":15538},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":400,"column":5,"offset":15544},"end":{"line":400,"column":8,"offset":15547},"indent":[]}}],"position":{"start":{"line":400,"column":1,"offset":15540},"end":{"line":400,"column":8,"offset":15547},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":402,"column":1,"offset":15549},"end":{"line":402,"column":176,"offset":15724},"indent":[]}}],"position":{"start":{"line":402,"column":1,"offset":15549},"end":{"line":402,"column":176,"offset":15724},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":404,"column":1,"offset":15726},"end":{"line":411,"column":4,"offset":16023},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":413,"column":1,"offset":16025},"end":{"line":413,"column":60,"offset":16084},"indent":[]}}],"position":{"start":{"line":413,"column":1,"offset":16025},"end":{"line":413,"column":60,"offset":16084},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":415,"column":1,"offset":16086},"end":{"line":419,"column":4,"offset":16212},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":421,"column":1,"offset":16214},"end":{"line":421,"column":63,"offset":16276},"indent":[]}}],"position":{"start":{"line":421,"column":1,"offset":16214},"end":{"line":421,"column":63,"offset":16276},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":423,"column":1,"offset":16278},"end":{"line":443,"column":4,"offset":16785},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":445,"column":1,"offset":16787},"end":{"line":445,"column":99,"offset":16885},"indent":[]}}],"position":{"start":{"line":445,"column":1,"offset":16787},"end":{"line":445,"column":99,"offset":16885},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":447,"column":1,"offset":16887},"end":{"line":450,"column":4,"offset":16989},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":452,"column":1,"offset":16991},"end":{"line":452,"column":37,"offset":17027},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":452,"column":37,"offset":17027},"end":{"line":452,"column":47,"offset":17037},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":452,"column":47,"offset":17037},"end":{"line":452,"column":89,"offset":17079},"indent":[]}}],"position":{"start":{"line":452,"column":1,"offset":16991},"end":{"line":452,"column":89,"offset":17079},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":454,"column":1,"offset":17081},"end":{"line":458,"column":4,"offset":17206},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":460,"column":1,"offset":17208},"end":{"line":460,"column":78,"offset":17285},"indent":[]}}],"position":{"start":{"line":460,"column":1,"offset":17208},"end":{"line":460,"column":78,"offset":17285},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":462,"column":1,"offset":17287},"end":{"line":466,"column":4,"offset":17391},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":468,"column":1,"offset":17393},"end":{"line":468,"column":75,"offset":17467},"indent":[]}}],"position":{"start":{"line":468,"column":1,"offset":17393},"end":{"line":468,"column":75,"offset":17467},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":470,"column":1,"offset":17469},"end":{"line":474,"column":4,"offset":17542},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":476,"column":1,"offset":17544},"end":{"line":476,"column":145,"offset":17688},"indent":[]}}],"position":{"start":{"line":476,"column":1,"offset":17544},"end":{"line":476,"column":145,"offset":17688},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":478,"column":5,"offset":17694},"end":{"line":478,"column":17,"offset":17706},"indent":[]}}],"position":{"start":{"line":478,"column":1,"offset":17690},"end":{"line":478,"column":17,"offset":17706},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":480,"column":1,"offset":17708},"end":{"line":480,"column":300,"offset":18007},"indent":[]}}],"position":{"start":{"line":480,"column":1,"offset":17708},"end":{"line":480,"column":300,"offset":18007},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":482,"column":1,"offset":18009},"end":{"line":482,"column":178,"offset":18186},"indent":[]}}],"position":{"start":{"line":482,"column":1,"offset":18009},"end":{"line":482,"column":178,"offset":18186},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":484,"column":1,"offset":18188},"end":{"line":484,"column":48,"offset":18235},"indent":[]}}],"position":{"start":{"line":484,"column":1,"offset":18188},"end":{"line":484,"column":48,"offset":18235},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":486,"column":1,"offset":18237},"end":{"line":488,"column":4,"offset":18281},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":490,"column":1,"offset":18283},"end":{"line":490,"column":104,"offset":18386},"indent":[]}}],"position":{"start":{"line":490,"column":1,"offset":18283},"end":{"line":490,"column":104,"offset":18386},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":492,"column":1,"offset":18388},"end":{"line":500,"column":4,"offset":18658},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":502,"column":1,"offset":18660},"end":{"line":502,"column":28,"offset":18687},"indent":[]}}],"position":{"start":{"line":502,"column":1,"offset":18660},"end":{"line":502,"column":28,"offset":18687},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":504,"column":1,"offset":18689},"end":{"line":506,"column":4,"offset":18737},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":508,"column":1,"offset":18739},"end":{"line":508,"column":48,"offset":18786},"indent":[]}}],"position":{"start":{"line":508,"column":1,"offset":18739},"end":{"line":508,"column":48,"offset":18786},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":510,"column":1,"offset":18788},"end":{"line":512,"column":4,"offset":18810},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":514,"column":1,"offset":18812},"end":{"line":514,"column":72,"offset":18883},"indent":[]}}],"position":{"start":{"line":514,"column":1,"offset":18812},"end":{"line":514,"column":72,"offset":18883},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":516,"column":1,"offset":18885},"end":{"line":518,"column":4,"offset":18946},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":521,"column":1,"offset":18949},"end":{"line":521,"column":31,"offset":18979},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":521,"column":31,"offset":18979}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`Instead of just running the Kerberos container, you can also persist your configuration by assigning volumes. An example of mounting volumes looks like this; an overview of `}{`the different volumes can be found here`}{`.`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`kerberos`}{`-`}{`camera1`}{` \\\\`}{`\n`}{`-`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/config:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`config`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/capture:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`capture`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/logs:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`logs`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/webconfig:/`}{`var`}{`/`}{`www`}{`/web/config \\\\`}{`\n`}{`-`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.`}

\n \n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.`}

\n

{`To fill the gap, regarding the latter, we can rely on another solution called `}{`Balena.io`}{`. Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).`}

\n

{`On top of supporting a lot of boars,`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-5e5fc51818b1c919d294dfe9e2e6ea4c.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-5e5fc51818b1c919d294dfe9e2e6ea4c.json new file mode 100644 index 0000000..c7b477f --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-5e5fc51818b1c919d294dfe9e2e6ea4c.json @@ -0,0 +1 @@ +{"expireTime":9007200842068384000,"key":"gatsby-plugin-mdx-entire-payload-3d32a884cd0e39f5f1c43eb836de6036-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4679},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":80,"offset":4760},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4760},"end":{"line":107,"column":101,"offset":4781},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4781},"end":{"line":107,"column":162,"offset":4842},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":162,"offset":4842},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4844},"end":{"line":112,"column":4,"offset":4933},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4938},"end":{"line":114,"column":10,"offset":4944},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4935},"end":{"line":114,"column":10,"offset":4944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":339,"offset":5284},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":340,"offset":5285},"end":{"line":116,"column":354,"offset":5299},"indent":[]}}],"position":{"start":{"line":116,"column":339,"offset":5284},"end":{"line":116,"column":390,"offset":5335},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":390,"offset":5335},"end":{"line":116,"column":391,"offset":5336},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":391,"offset":5336},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5342},"end":{"line":118,"column":18,"offset":5355},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5338},"end":{"line":118,"column":18,"offset":5355},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5357},"end":{"line":120,"column":50,"offset":5406},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5412},"end":{"line":122,"column":11,"offset":5418},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5408},"end":{"line":122,"column":11,"offset":5418},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":64,"offset":5483},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5484},"end":{"line":124,"column":86,"offset":5505},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5483},"end":{"line":124,"column":126,"offset":5545},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5545},"end":{"line":124,"column":127,"offset":5546},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":127,"offset":5546},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5552},"end":{"line":126,"column":26,"offset":5573},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5548},"end":{"line":126,"column":26,"offset":5573},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5702},"end":{"line":132,"column":4,"offset":5741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5931},"end":{"line":138,"column":4,"offset":6009},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6165},"end":{"line":145,"column":4,"offset":6312},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6414},"end":{"line":152,"column":4,"offset":6483},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6489},"end":{"line":154,"column":12,"offset":6496},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6485},"end":{"line":154,"column":12,"offset":6496},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":157,"column":25,"offset":6586},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6587},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":158,"column":59,"offset":6645},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":160,"column":4,"offset":6650},"end":{"line":160,"column":10,"offset":6656},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":6647},"end":{"line":160,"column":10,"offset":6656},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.","position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":102,"offset":6759},"indent":[]}}],"position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":102,"offset":6759},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Especially in the worl\n even on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.","position":{"start":{"line":164,"column":1,"offset":6761},"end":{"line":165,"column":128,"offset":6911},"indent":[1]}}],"position":{"start":{"line":164,"column":1,"offset":6761},"end":{"line":165,"column":128,"offset":6911},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":167,"column":4,"offset":6916},"end":{"line":167,"column":12,"offset":6924},"indent":[]}}],"position":{"start":{"line":167,"column":1,"offset":6913},"end":{"line":167,"column":12,"offset":6924},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":169,"column":1,"offset":6926},"end":{"line":169,"column":133,"offset":7058},"indent":[]}}],"position":{"start":{"line":169,"column":1,"offset":6926},"end":{"line":169,"column":133,"offset":7058},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":171,"column":4,"offset":7063},"end":{"line":171,"column":12,"offset":7071},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":7060},"end":{"line":171,"column":12,"offset":7071},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":173,"column":1,"offset":7073},"end":{"line":173,"column":193,"offset":7265},"indent":[]}}],"position":{"start":{"line":173,"column":1,"offset":7073},"end":{"line":173,"column":193,"offset":7265},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":175,"column":4,"offset":7270},"end":{"line":175,"column":62,"offset":7328},"indent":[]}}],"position":{"start":{"line":175,"column":4,"offset":7270},"end":{"line":175,"column":62,"offset":7328},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7267},"end":{"line":175,"column":62,"offset":7328},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":176,"column":4,"offset":7332},"end":{"line":176,"column":69,"offset":7397},"indent":[]}}],"position":{"start":{"line":176,"column":4,"offset":7332},"end":{"line":176,"column":69,"offset":7397},"indent":[]}}],"position":{"start":{"line":176,"column":1,"offset":7329},"end":{"line":176,"column":69,"offset":7397},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7267},"end":{"line":176,"column":69,"offset":7397},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":178,"column":1,"offset":7399},"end":{"line":178,"column":99,"offset":7497},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7399},"end":{"line":178,"column":99,"offset":7497},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":180,"column":5,"offset":7503},"end":{"line":180,"column":14,"offset":7512},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7499},"end":{"line":180,"column":14,"offset":7512},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":182,"column":1,"offset":7514},"end":{"line":182,"column":71,"offset":7584},"indent":[]}}],"position":{"start":{"line":182,"column":1,"offset":7514},"end":{"line":182,"column":71,"offset":7584},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":184,"column":3,"offset":7588},"end":{"line":184,"column":47,"offset":7632},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":184,"column":47,"offset":7632},"end":{"line":184,"column":79,"offset":7664},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":184,"column":79,"offset":7664},"end":{"line":184,"column":198,"offset":7783},"indent":[]}}],"position":{"start":{"line":184,"column":3,"offset":7588},"end":{"line":184,"column":198,"offset":7783},"indent":[]}}],"position":{"start":{"line":184,"column":1,"offset":7586},"end":{"line":184,"column":198,"offset":7783},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":186,"column":1,"offset":7785},"end":{"line":188,"column":4,"offset":7848},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":190,"column":5,"offset":7854},"end":{"line":190,"column":14,"offset":7863},"indent":[]}}],"position":{"start":{"line":190,"column":1,"offset":7850},"end":{"line":190,"column":14,"offset":7863},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":192,"column":1,"offset":7865},"end":{"line":192,"column":56,"offset":7920},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":7865},"end":{"line":192,"column":56,"offset":7920},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":193,"column":3,"offset":7923},"end":{"line":193,"column":52,"offset":7972},"indent":[]}}],"position":{"start":{"line":193,"column":3,"offset":7923},"end":{"line":193,"column":52,"offset":7972},"indent":[]}}],"position":{"start":{"line":193,"column":3,"offset":7923},"end":{"line":193,"column":52,"offset":7972},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":7921},"end":{"line":193,"column":52,"offset":7972},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":195,"column":1,"offset":7974},"end":{"line":195,"column":3,"offset":7976},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":195,"column":3,"offset":7976},"end":{"line":195,"column":9,"offset":7982},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":195,"column":9,"offset":7982},"end":{"line":195,"column":223,"offset":8196},"indent":[]}}],"position":{"start":{"line":195,"column":1,"offset":7974},"end":{"line":195,"column":223,"offset":8196},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":197,"column":3,"offset":8200},"end":{"line":197,"column":159,"offset":8356},"indent":[]}}],"position":{"start":{"line":197,"column":3,"offset":8200},"end":{"line":197,"column":159,"offset":8356},"indent":[]}}],"position":{"start":{"line":197,"column":1,"offset":8198},"end":{"line":197,"column":159,"offset":8356},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":199,"column":1,"offset":8358},"end":{"line":202,"column":4,"offset":8535},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":204,"column":1,"offset":8537},"end":{"line":204,"column":160,"offset":8696},"indent":[]}}],"position":{"start":{"line":204,"column":1,"offset":8537},"end":{"line":204,"column":160,"offset":8696},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":206,"column":3,"offset":8700},"end":{"line":206,"column":31,"offset":8728},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":206,"column":31,"offset":8728},"end":{"line":206,"column":101,"offset":8798},"indent":[]}}],"position":{"start":{"line":206,"column":3,"offset":8700},"end":{"line":206,"column":101,"offset":8798},"indent":[]}}],"position":{"start":{"line":206,"column":1,"offset":8698},"end":{"line":206,"column":101,"offset":8798},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":208,"column":1,"offset":8800},"end":{"line":211,"column":4,"offset":8972},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":213,"column":1,"offset":8974},"end":{"line":213,"column":73,"offset":9046},"indent":[]}}],"position":{"start":{"line":213,"column":1,"offset":8974},"end":{"line":213,"column":73,"offset":9046},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":216,"column":3,"offset":9051},"end":{"line":216,"column":31,"offset":9079},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":216,"column":31,"offset":9079},"end":{"line":216,"column":101,"offset":9149},"indent":[]}}],"position":{"start":{"line":216,"column":3,"offset":9051},"end":{"line":216,"column":101,"offset":9149},"indent":[]}}],"position":{"start":{"line":216,"column":1,"offset":9049},"end":{"line":216,"column":101,"offset":9149},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":218,"column":1,"offset":9151},"end":{"line":221,"column":4,"offset":9323},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":223,"column":1,"offset":9325},"end":{"line":223,"column":62,"offset":9386},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":223,"column":63,"offset":9387},"end":{"line":223,"column":75,"offset":9399},"indent":[]}}],"position":{"start":{"line":223,"column":62,"offset":9386},"end":{"line":223,"column":143,"offset":9467},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":223,"column":143,"offset":9467},"end":{"line":223,"column":150,"offset":9474},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":223,"column":150,"offset":9474},"end":{"line":223,"column":169,"offset":9493},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":223,"column":169,"offset":9493},"end":{"line":223,"column":170,"offset":9494},"indent":[]}}],"position":{"start":{"line":223,"column":1,"offset":9325},"end":{"line":223,"column":170,"offset":9494},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":225,"column":1,"offset":9496},"end":{"line":227,"column":4,"offset":9523},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":229,"column":1,"offset":9525},"end":{"line":229,"column":58,"offset":9582},"indent":[]}}],"position":{"start":{"line":229,"column":1,"offset":9525},"end":{"line":229,"column":58,"offset":9582},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":231,"column":1,"offset":9584},"end":{"line":234,"column":4,"offset":9654},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":236,"column":5,"offset":9660},"end":{"line":236,"column":8,"offset":9663},"indent":[]}}],"position":{"start":{"line":236,"column":1,"offset":9656},"end":{"line":236,"column":8,"offset":9663},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":238,"column":1,"offset":9665},"end":{"line":238,"column":280,"offset":9944},"indent":[]}}],"position":{"start":{"line":238,"column":1,"offset":9665},"end":{"line":238,"column":280,"offset":9944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":240,"column":1,"offset":9946},"end":{"line":240,"column":37,"offset":9982},"indent":[]}}],"position":{"start":{"line":240,"column":1,"offset":9946},"end":{"line":240,"column":37,"offset":9982},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":242,"column":1,"offset":9984},"end":{"line":244,"column":4,"offset":10157},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":246,"column":1,"offset":10159},"end":{"line":246,"column":25,"offset":10183},"indent":[]}}],"position":{"start":{"line":246,"column":1,"offset":10159},"end":{"line":246,"column":25,"offset":10183},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":248,"column":1,"offset":10185},"end":{"line":251,"column":4,"offset":10289},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":253,"column":1,"offset":10291},"end":{"line":253,"column":118,"offset":10408},"indent":[]}}],"position":{"start":{"line":253,"column":1,"offset":10291},"end":{"line":253,"column":118,"offset":10408},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":255,"column":1,"offset":10410},"end":{"line":275,"column":4,"offset":10917},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":277,"column":1,"offset":10919},"end":{"line":277,"column":14,"offset":10932},"indent":[]}}],"position":{"start":{"line":277,"column":1,"offset":10919},"end":{"line":277,"column":14,"offset":10932},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":279,"column":1,"offset":10934},"end":{"line":281,"column":4,"offset":10970},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":283,"column":1,"offset":10972},"end":{"line":283,"column":91,"offset":11062},"indent":[]}}],"position":{"start":{"line":283,"column":1,"offset":10972},"end":{"line":283,"column":91,"offset":11062},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":285,"column":1,"offset":11064},"end":{"line":293,"column":4,"offset":11437},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":295,"column":1,"offset":11439},"end":{"line":295,"column":145,"offset":11583},"indent":[]}}],"position":{"start":{"line":295,"column":1,"offset":11439},"end":{"line":295,"column":145,"offset":11583},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":297,"column":5,"offset":11589},"end":{"line":297,"column":17,"offset":11601},"indent":[]}}],"position":{"start":{"line":297,"column":1,"offset":11585},"end":{"line":297,"column":17,"offset":11601},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":299,"column":1,"offset":11603},"end":{"line":299,"column":300,"offset":11902},"indent":[]}}],"position":{"start":{"line":299,"column":1,"offset":11603},"end":{"line":299,"column":300,"offset":11902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":301,"column":1,"offset":11904},"end":{"line":301,"column":178,"offset":12081},"indent":[]}}],"position":{"start":{"line":301,"column":1,"offset":11904},"end":{"line":301,"column":178,"offset":12081},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":303,"column":1,"offset":12083},"end":{"line":303,"column":48,"offset":12130},"indent":[]}}],"position":{"start":{"line":303,"column":1,"offset":12083},"end":{"line":303,"column":48,"offset":12130},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":305,"column":1,"offset":12132},"end":{"line":307,"column":4,"offset":12172},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":309,"column":1,"offset":12174},"end":{"line":309,"column":104,"offset":12277},"indent":[]}}],"position":{"start":{"line":309,"column":1,"offset":12174},"end":{"line":309,"column":104,"offset":12277},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":311,"column":1,"offset":12279},"end":{"line":319,"column":4,"offset":12549},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":321,"column":1,"offset":12551},"end":{"line":321,"column":28,"offset":12578},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":12551},"end":{"line":321,"column":28,"offset":12578},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":323,"column":1,"offset":12580},"end":{"line":325,"column":4,"offset":12624},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":327,"column":1,"offset":12626},"end":{"line":327,"column":48,"offset":12673},"indent":[]}}],"position":{"start":{"line":327,"column":1,"offset":12626},"end":{"line":327,"column":48,"offset":12673},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":329,"column":1,"offset":12675},"end":{"line":331,"column":4,"offset":12697},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":333,"column":1,"offset":12699},"end":{"line":333,"column":72,"offset":12770},"indent":[]}}],"position":{"start":{"line":333,"column":1,"offset":12699},"end":{"line":333,"column":72,"offset":12770},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":335,"column":1,"offset":12772},"end":{"line":337,"column":4,"offset":12829},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":339,"column":4,"offset":12834},"end":{"line":339,"column":11,"offset":12841},"indent":[]}}],"position":{"start":{"line":339,"column":1,"offset":12831},"end":{"line":339,"column":11,"offset":12841},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":341,"column":1,"offset":12843},"end":{"line":341,"column":283,"offset":13125},"indent":[]}}],"position":{"start":{"line":341,"column":1,"offset":12843},"end":{"line":341,"column":283,"offset":13125},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":343,"column":3,"offset":13129},"end":{"line":343,"column":54,"offset":13180},"indent":[]}}],"position":{"start":{"line":343,"column":3,"offset":13129},"end":{"line":343,"column":54,"offset":13180},"indent":[]}}],"position":{"start":{"line":343,"column":1,"offset":13127},"end":{"line":343,"column":54,"offset":13180},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":345,"column":5,"offset":13186},"end":{"line":345,"column":14,"offset":13195},"indent":[]}}],"position":{"start":{"line":345,"column":1,"offset":13182},"end":{"line":345,"column":14,"offset":13195},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":347,"column":1,"offset":13197},"end":{"line":347,"column":68,"offset":13264},"indent":[]}}],"position":{"start":{"line":347,"column":1,"offset":13197},"end":{"line":347,"column":68,"offset":13264},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":349,"column":1,"offset":13266},"end":{"line":352,"column":4,"offset":13417},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":354,"column":1,"offset":13419},"end":{"line":354,"column":46,"offset":13464},"indent":[]}}],"position":{"start":{"line":354,"column":1,"offset":13419},"end":{"line":354,"column":46,"offset":13464},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":356,"column":3,"offset":13468},"end":{"line":356,"column":103,"offset":13568},"indent":[]}}],"position":{"start":{"line":356,"column":3,"offset":13468},"end":{"line":356,"column":103,"offset":13568},"indent":[]}}],"position":{"start":{"line":356,"column":1,"offset":13466},"end":{"line":356,"column":103,"offset":13568},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":358,"column":1,"offset":13570},"end":{"line":363,"column":4,"offset":13780},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":365,"column":1,"offset":13782},"end":{"line":365,"column":151,"offset":13932},"indent":[]}}],"position":{"start":{"line":365,"column":1,"offset":13782},"end":{"line":365,"column":151,"offset":13932},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":367,"column":3,"offset":13936},"end":{"line":367,"column":22,"offset":13955},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":367,"column":22,"offset":13955},"end":{"line":367,"column":26,"offset":13959},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":367,"column":26,"offset":13959},"end":{"line":367,"column":40,"offset":13973},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":367,"column":40,"offset":13973},"end":{"line":367,"column":50,"offset":13983},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":367,"column":50,"offset":13983},"end":{"line":367,"column":98,"offset":14031},"indent":[]}}],"position":{"start":{"line":367,"column":3,"offset":13936},"end":{"line":367,"column":98,"offset":14031},"indent":[]}}],"position":{"start":{"line":367,"column":1,"offset":13934},"end":{"line":367,"column":98,"offset":14031},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":369,"column":1,"offset":14033},"end":{"line":373,"column":4,"offset":14195},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":375,"column":1,"offset":14197},"end":{"line":375,"column":72,"offset":14268},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":375,"column":72,"offset":14268},"end":{"line":375,"column":84,"offset":14280},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":375,"column":84,"offset":14280},"end":{"line":375,"column":102,"offset":14298},"indent":[]}}],"position":{"start":{"line":375,"column":1,"offset":14197},"end":{"line":375,"column":102,"offset":14298},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":377,"column":1,"offset":14300},"end":{"line":380,"column":4,"offset":14374},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":382,"column":5,"offset":14380},"end":{"line":382,"column":8,"offset":14383},"indent":[]}}],"position":{"start":{"line":382,"column":1,"offset":14376},"end":{"line":382,"column":8,"offset":14383},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":384,"column":1,"offset":14385},"end":{"line":384,"column":176,"offset":14560},"indent":[]}}],"position":{"start":{"line":384,"column":1,"offset":14385},"end":{"line":384,"column":176,"offset":14560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":386,"column":1,"offset":14562},"end":{"line":393,"column":4,"offset":14859},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":395,"column":1,"offset":14861},"end":{"line":395,"column":60,"offset":14920},"indent":[]}}],"position":{"start":{"line":395,"column":1,"offset":14861},"end":{"line":395,"column":60,"offset":14920},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":397,"column":1,"offset":14922},"end":{"line":401,"column":4,"offset":15048},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":403,"column":1,"offset":15050},"end":{"line":403,"column":63,"offset":15112},"indent":[]}}],"position":{"start":{"line":403,"column":1,"offset":15050},"end":{"line":403,"column":63,"offset":15112},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":405,"column":1,"offset":15114},"end":{"line":425,"column":4,"offset":15621},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":427,"column":1,"offset":15623},"end":{"line":427,"column":99,"offset":15721},"indent":[]}}],"position":{"start":{"line":427,"column":1,"offset":15623},"end":{"line":427,"column":99,"offset":15721},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":429,"column":1,"offset":15723},"end":{"line":432,"column":4,"offset":15825},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":434,"column":1,"offset":15827},"end":{"line":434,"column":37,"offset":15863},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":434,"column":37,"offset":15863},"end":{"line":434,"column":47,"offset":15873},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":434,"column":47,"offset":15873},"end":{"line":434,"column":89,"offset":15915},"indent":[]}}],"position":{"start":{"line":434,"column":1,"offset":15827},"end":{"line":434,"column":89,"offset":15915},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":436,"column":1,"offset":15917},"end":{"line":440,"column":4,"offset":16042},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":442,"column":1,"offset":16044},"end":{"line":442,"column":78,"offset":16121},"indent":[]}}],"position":{"start":{"line":442,"column":1,"offset":16044},"end":{"line":442,"column":78,"offset":16121},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":444,"column":1,"offset":16123},"end":{"line":448,"column":4,"offset":16227},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":450,"column":1,"offset":16229},"end":{"line":450,"column":75,"offset":16303},"indent":[]}}],"position":{"start":{"line":450,"column":1,"offset":16229},"end":{"line":450,"column":75,"offset":16303},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":452,"column":1,"offset":16305},"end":{"line":456,"column":4,"offset":16378},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":458,"column":1,"offset":16380},"end":{"line":458,"column":145,"offset":16524},"indent":[]}}],"position":{"start":{"line":458,"column":1,"offset":16380},"end":{"line":458,"column":145,"offset":16524},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":460,"column":5,"offset":16530},"end":{"line":460,"column":17,"offset":16542},"indent":[]}}],"position":{"start":{"line":460,"column":1,"offset":16526},"end":{"line":460,"column":17,"offset":16542},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":462,"column":1,"offset":16544},"end":{"line":462,"column":300,"offset":16843},"indent":[]}}],"position":{"start":{"line":462,"column":1,"offset":16544},"end":{"line":462,"column":300,"offset":16843},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":464,"column":1,"offset":16845},"end":{"line":464,"column":178,"offset":17022},"indent":[]}}],"position":{"start":{"line":464,"column":1,"offset":16845},"end":{"line":464,"column":178,"offset":17022},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":466,"column":1,"offset":17024},"end":{"line":466,"column":48,"offset":17071},"indent":[]}}],"position":{"start":{"line":466,"column":1,"offset":17024},"end":{"line":466,"column":48,"offset":17071},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":468,"column":1,"offset":17073},"end":{"line":470,"column":4,"offset":17117},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":472,"column":1,"offset":17119},"end":{"line":472,"column":104,"offset":17222},"indent":[]}}],"position":{"start":{"line":472,"column":1,"offset":17119},"end":{"line":472,"column":104,"offset":17222},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":474,"column":1,"offset":17224},"end":{"line":482,"column":4,"offset":17494},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":484,"column":1,"offset":17496},"end":{"line":484,"column":28,"offset":17523},"indent":[]}}],"position":{"start":{"line":484,"column":1,"offset":17496},"end":{"line":484,"column":28,"offset":17523},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":486,"column":1,"offset":17525},"end":{"line":488,"column":4,"offset":17573},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":490,"column":1,"offset":17575},"end":{"line":490,"column":48,"offset":17622},"indent":[]}}],"position":{"start":{"line":490,"column":1,"offset":17575},"end":{"line":490,"column":48,"offset":17622},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":492,"column":1,"offset":17624},"end":{"line":494,"column":4,"offset":17646},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":496,"column":1,"offset":17648},"end":{"line":496,"column":72,"offset":17719},"indent":[]}}],"position":{"start":{"line":496,"column":1,"offset":17648},"end":{"line":496,"column":72,"offset":17719},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":498,"column":1,"offset":17721},"end":{"line":500,"column":4,"offset":17782},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":503,"column":1,"offset":17785},"end":{"line":503,"column":31,"offset":17815},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":503,"column":31,"offset":17815}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.`}

\n

{`Especially in the worl\neven on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.`}

\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-6115286b5fc0e2f7dc8d6a8998860d99.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-6115286b5fc0e2f7dc8d6a8998860d99.json new file mode 100644 index 0000000..50a079f --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-6115286b5fc0e2f7dc8d6a8998860d99.json @@ -0,0 +1 @@ +{"expireTime":9007200842320140000,"key":"gatsby-plugin-mdx-entire-payload-99dbb9441b8ed864dbb1d897eed7858c-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4645},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4647},"end":{"line":107,"column":80,"offset":4726},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4726},"end":{"line":107,"column":101,"offset":4747},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4747},"end":{"line":107,"column":162,"offset":4808},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4647},"end":{"line":107,"column":162,"offset":4808},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4810},"end":{"line":112,"column":4,"offset":4899},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4904},"end":{"line":114,"column":10,"offset":4910},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4901},"end":{"line":114,"column":10,"offset":4910},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on ","position":{"start":{"line":116,"column":1,"offset":4912},"end":{"line":116,"column":54,"offset":4965},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":55,"offset":4966},"end":{"line":116,"column":69,"offset":4980},"indent":[]}}],"position":{"start":{"line":116,"column":54,"offset":4965},"end":{"line":116,"column":105,"offset":5016},"indent":[]}},{"type":"text","value":", which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All DDocker images can be found on ","position":{"start":{"line":116,"column":105,"offset":5016},"end":{"line":116,"column":377,"offset":5288},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":378,"offset":5289},"end":{"line":116,"column":392,"offset":5303},"indent":[]}}],"position":{"start":{"line":116,"column":377,"offset":5288},"end":{"line":116,"column":428,"offset":5339},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":428,"offset":5339},"end":{"line":116,"column":429,"offset":5340},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4912},"end":{"line":116,"column":429,"offset":5340},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5346},"end":{"line":118,"column":18,"offset":5359},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5342},"end":{"line":118,"column":18,"offset":5359},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5363},"end":{"line":120,"column":50,"offset":5410},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5363},"end":{"line":120,"column":50,"offset":5410},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5361},"end":{"line":120,"column":50,"offset":5410},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5416},"end":{"line":122,"column":11,"offset":5422},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5412},"end":{"line":122,"column":11,"offset":5422},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5424},"end":{"line":124,"column":64,"offset":5487},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5488},"end":{"line":124,"column":86,"offset":5509},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5487},"end":{"line":124,"column":126,"offset":5549},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5549},"end":{"line":124,"column":127,"offset":5550},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5424},"end":{"line":124,"column":127,"offset":5550},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5556},"end":{"line":126,"column":26,"offset":5577},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5552},"end":{"line":126,"column":26,"offset":5577},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5579},"end":{"line":128,"column":126,"offset":5704},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5579},"end":{"line":128,"column":126,"offset":5704},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5706},"end":{"line":132,"column":4,"offset":5745},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5747},"end":{"line":134,"column":187,"offset":5933},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5747},"end":{"line":134,"column":187,"offset":5933},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5935},"end":{"line":138,"column":4,"offset":6013},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6015},"end":{"line":140,"column":153,"offset":6167},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6015},"end":{"line":140,"column":153,"offset":6167},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6169},"end":{"line":145,"column":4,"offset":6316},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6318},"end":{"line":147,"column":100,"offset":6417},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6318},"end":{"line":147,"column":100,"offset":6417},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6418},"end":{"line":152,"column":4,"offset":6487},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6493},"end":{"line":154,"column":12,"offset":6500},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6489},"end":{"line":154,"column":12,"offset":6500},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Instead of just running the Kerberos container, you can also persist your configuration by assigning volumes. An example of mounting volumes looks like this; an overview of ","position":{"start":{"line":156,"column":1,"offset":6502},"end":{"line":156,"column":174,"offset":6675},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker/blob/master/Dockerfile#L171-L177","children":[{"type":"text","value":"the different volumes can be found here","position":{"start":{"line":156,"column":175,"offset":6676},"end":{"line":156,"column":214,"offset":6715},"indent":[]}}],"position":{"start":{"line":156,"column":174,"offset":6675},"end":{"line":156,"column":287,"offset":6788},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":156,"column":287,"offset":6788},"end":{"line":156,"column":288,"offset":6789},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6502},"end":{"line":156,"column":288,"offset":6789},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":158,"column":3,"offset":6793},"end":{"line":158,"column":25,"offset":6815},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6793},"end":{"line":158,"column":25,"offset":6815},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6791},"end":{"line":158,"column":25,"offset":6815},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":159,"column":3,"offset":6818},"end":{"line":159,"column":59,"offset":6874},"indent":[]}}],"position":{"start":{"line":159,"column":3,"offset":6818},"end":{"line":159,"column":59,"offset":6874},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":6816},"end":{"line":159,"column":59,"offset":6874},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6791},"end":{"line":159,"column":59,"offset":6874},"indent":[1]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name kerberos-camera1 \\\n-p 80:80 -p 8889:8889 \\\n-v ~/config:/etc/opt/kerberosio/config \\\n-v ~/capture:/etc/opt/kerberosio/capture \\\n-v ~/logs:/etc/opt/kerberosio/logs \\\n-v ~/webconfig:/var/www/web/config \\\n-d kerberos/kerberos","position":{"start":{"line":161,"column":1,"offset":6876},"end":{"line":169,"column":4,"offset":7125},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.","position":{"start":{"line":171,"column":1,"offset":7127},"end":{"line":171,"column":87,"offset":7213},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":7127},"end":{"line":171,"column":87,"offset":7213},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://medium.com/@cedricverst/kerberos-io-the-road-to-docker-8e048a480241","children":[{"type":"text","value":"Kerberos.io — the road to Docker","position":{"start":{"line":172,"column":4,"offset":7217},"end":{"line":172,"column":36,"offset":7249},"indent":[]}}],"position":{"start":{"line":172,"column":3,"offset":7216},"end":{"line":172,"column":114,"offset":7327},"indent":[]}}],"position":{"start":{"line":172,"column":3,"offset":7216},"end":{"line":172,"column":114,"offset":7327},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7214},"end":{"line":172,"column":114,"offset":7327},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7214},"end":{"line":172,"column":114,"offset":7327},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":175,"column":4,"offset":7333},"end":{"line":175,"column":10,"offset":7339},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7330},"end":{"line":175,"column":10,"offset":7339},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.","position":{"start":{"line":177,"column":1,"offset":7341},"end":{"line":177,"column":310,"offset":7650},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7341},"end":{"line":177,"column":310,"offset":7650},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To fill the gap, regarding the latter, we can rely on another solution called ","position":{"start":{"line":179,"column":1,"offset":7652},"end":{"line":179,"column":79,"offset":7730},"indent":[]}},{"type":"link","title":null,"url":"https://balena.io","children":[{"type":"text","value":"Balena.io","position":{"start":{"line":179,"column":80,"offset":7731},"end":{"line":179,"column":89,"offset":7740},"indent":[]}}],"position":{"start":{"line":179,"column":79,"offset":7730},"end":{"line":179,"column":109,"offset":7760},"indent":[]}},{"type":"text","value":". Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).","position":{"start":{"line":179,"column":109,"offset":7760},"end":{"line":179,"column":386,"offset":8037},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7652},"end":{"line":179,"column":386,"offset":8037},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On top of supporting a lot of boars,","position":{"start":{"line":181,"column":1,"offset":8039},"end":{"line":181,"column":37,"offset":8075},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":8039},"end":{"line":181,"column":37,"offset":8075},"indent":[]}},{"type":"thematicBreak","position":{"start":{"line":183,"column":1,"offset":8077},"end":{"line":183,"column":4,"offset":8080},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":185,"column":3,"offset":8084},"end":{"line":185,"column":11,"offset":8092},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":8082},"end":{"line":185,"column":11,"offset":8092},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":187,"column":1,"offset":8094},"end":{"line":187,"column":133,"offset":8226},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":8094},"end":{"line":187,"column":133,"offset":8226},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":189,"column":4,"offset":8231},"end":{"line":189,"column":12,"offset":8239},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":8228},"end":{"line":189,"column":12,"offset":8239},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":191,"column":1,"offset":8241},"end":{"line":191,"column":193,"offset":8433},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":8241},"end":{"line":191,"column":193,"offset":8433},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":193,"column":4,"offset":8438},"end":{"line":193,"column":62,"offset":8496},"indent":[]}}],"position":{"start":{"line":193,"column":4,"offset":8438},"end":{"line":193,"column":62,"offset":8496},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8435},"end":{"line":193,"column":62,"offset":8496},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":194,"column":4,"offset":8500},"end":{"line":194,"column":69,"offset":8565},"indent":[]}}],"position":{"start":{"line":194,"column":4,"offset":8500},"end":{"line":194,"column":69,"offset":8565},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":8497},"end":{"line":194,"column":69,"offset":8565},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8435},"end":{"line":194,"column":69,"offset":8565},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":196,"column":1,"offset":8567},"end":{"line":196,"column":99,"offset":8665},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8567},"end":{"line":196,"column":99,"offset":8665},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":198,"column":5,"offset":8671},"end":{"line":198,"column":14,"offset":8680},"indent":[]}}],"position":{"start":{"line":198,"column":1,"offset":8667},"end":{"line":198,"column":14,"offset":8680},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":200,"column":1,"offset":8682},"end":{"line":200,"column":71,"offset":8752},"indent":[]}}],"position":{"start":{"line":200,"column":1,"offset":8682},"end":{"line":200,"column":71,"offset":8752},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":202,"column":3,"offset":8756},"end":{"line":202,"column":47,"offset":8800},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":202,"column":47,"offset":8800},"end":{"line":202,"column":79,"offset":8832},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":202,"column":79,"offset":8832},"end":{"line":202,"column":198,"offset":8951},"indent":[]}}],"position":{"start":{"line":202,"column":3,"offset":8756},"end":{"line":202,"column":198,"offset":8951},"indent":[]}}],"position":{"start":{"line":202,"column":1,"offset":8754},"end":{"line":202,"column":198,"offset":8951},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":204,"column":1,"offset":8953},"end":{"line":206,"column":4,"offset":9016},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":208,"column":5,"offset":9022},"end":{"line":208,"column":14,"offset":9031},"indent":[]}}],"position":{"start":{"line":208,"column":1,"offset":9018},"end":{"line":208,"column":14,"offset":9031},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":210,"column":1,"offset":9033},"end":{"line":210,"column":56,"offset":9088},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":9033},"end":{"line":210,"column":56,"offset":9088},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":211,"column":3,"offset":9091},"end":{"line":211,"column":52,"offset":9140},"indent":[]}}],"position":{"start":{"line":211,"column":3,"offset":9091},"end":{"line":211,"column":52,"offset":9140},"indent":[]}}],"position":{"start":{"line":211,"column":3,"offset":9091},"end":{"line":211,"column":52,"offset":9140},"indent":[]}}],"position":{"start":{"line":211,"column":1,"offset":9089},"end":{"line":211,"column":52,"offset":9140},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":213,"column":1,"offset":9142},"end":{"line":213,"column":3,"offset":9144},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":213,"column":3,"offset":9144},"end":{"line":213,"column":9,"offset":9150},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":213,"column":9,"offset":9150},"end":{"line":213,"column":223,"offset":9364},"indent":[]}}],"position":{"start":{"line":213,"column":1,"offset":9142},"end":{"line":213,"column":223,"offset":9364},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":215,"column":3,"offset":9368},"end":{"line":215,"column":159,"offset":9524},"indent":[]}}],"position":{"start":{"line":215,"column":3,"offset":9368},"end":{"line":215,"column":159,"offset":9524},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":9366},"end":{"line":215,"column":159,"offset":9524},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":217,"column":1,"offset":9526},"end":{"line":220,"column":4,"offset":9703},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":222,"column":1,"offset":9705},"end":{"line":222,"column":160,"offset":9864},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":9705},"end":{"line":222,"column":160,"offset":9864},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":224,"column":3,"offset":9868},"end":{"line":224,"column":31,"offset":9896},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":224,"column":31,"offset":9896},"end":{"line":224,"column":101,"offset":9966},"indent":[]}}],"position":{"start":{"line":224,"column":3,"offset":9868},"end":{"line":224,"column":101,"offset":9966},"indent":[]}}],"position":{"start":{"line":224,"column":1,"offset":9866},"end":{"line":224,"column":101,"offset":9966},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":226,"column":1,"offset":9968},"end":{"line":229,"column":4,"offset":10140},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":231,"column":1,"offset":10142},"end":{"line":231,"column":73,"offset":10214},"indent":[]}}],"position":{"start":{"line":231,"column":1,"offset":10142},"end":{"line":231,"column":73,"offset":10214},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":234,"column":3,"offset":10219},"end":{"line":234,"column":31,"offset":10247},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":234,"column":31,"offset":10247},"end":{"line":234,"column":101,"offset":10317},"indent":[]}}],"position":{"start":{"line":234,"column":3,"offset":10219},"end":{"line":234,"column":101,"offset":10317},"indent":[]}}],"position":{"start":{"line":234,"column":1,"offset":10217},"end":{"line":234,"column":101,"offset":10317},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":236,"column":1,"offset":10319},"end":{"line":239,"column":4,"offset":10491},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":241,"column":1,"offset":10493},"end":{"line":241,"column":62,"offset":10554},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":241,"column":63,"offset":10555},"end":{"line":241,"column":75,"offset":10567},"indent":[]}}],"position":{"start":{"line":241,"column":62,"offset":10554},"end":{"line":241,"column":143,"offset":10635},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":241,"column":143,"offset":10635},"end":{"line":241,"column":150,"offset":10642},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":241,"column":150,"offset":10642},"end":{"line":241,"column":169,"offset":10661},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":241,"column":169,"offset":10661},"end":{"line":241,"column":170,"offset":10662},"indent":[]}}],"position":{"start":{"line":241,"column":1,"offset":10493},"end":{"line":241,"column":170,"offset":10662},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":243,"column":1,"offset":10664},"end":{"line":245,"column":4,"offset":10691},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":247,"column":1,"offset":10693},"end":{"line":247,"column":58,"offset":10750},"indent":[]}}],"position":{"start":{"line":247,"column":1,"offset":10693},"end":{"line":247,"column":58,"offset":10750},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":249,"column":1,"offset":10752},"end":{"line":252,"column":4,"offset":10822},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":254,"column":5,"offset":10828},"end":{"line":254,"column":8,"offset":10831},"indent":[]}}],"position":{"start":{"line":254,"column":1,"offset":10824},"end":{"line":254,"column":8,"offset":10831},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":256,"column":1,"offset":10833},"end":{"line":256,"column":280,"offset":11112},"indent":[]}}],"position":{"start":{"line":256,"column":1,"offset":10833},"end":{"line":256,"column":280,"offset":11112},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":258,"column":1,"offset":11114},"end":{"line":258,"column":37,"offset":11150},"indent":[]}}],"position":{"start":{"line":258,"column":1,"offset":11114},"end":{"line":258,"column":37,"offset":11150},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":260,"column":1,"offset":11152},"end":{"line":262,"column":4,"offset":11325},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":264,"column":1,"offset":11327},"end":{"line":264,"column":25,"offset":11351},"indent":[]}}],"position":{"start":{"line":264,"column":1,"offset":11327},"end":{"line":264,"column":25,"offset":11351},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":266,"column":1,"offset":11353},"end":{"line":269,"column":4,"offset":11457},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":271,"column":1,"offset":11459},"end":{"line":271,"column":118,"offset":11576},"indent":[]}}],"position":{"start":{"line":271,"column":1,"offset":11459},"end":{"line":271,"column":118,"offset":11576},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":273,"column":1,"offset":11578},"end":{"line":293,"column":4,"offset":12085},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":295,"column":1,"offset":12087},"end":{"line":295,"column":14,"offset":12100},"indent":[]}}],"position":{"start":{"line":295,"column":1,"offset":12087},"end":{"line":295,"column":14,"offset":12100},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":297,"column":1,"offset":12102},"end":{"line":299,"column":4,"offset":12138},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":301,"column":1,"offset":12140},"end":{"line":301,"column":91,"offset":12230},"indent":[]}}],"position":{"start":{"line":301,"column":1,"offset":12140},"end":{"line":301,"column":91,"offset":12230},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":303,"column":1,"offset":12232},"end":{"line":311,"column":4,"offset":12605},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":313,"column":1,"offset":12607},"end":{"line":313,"column":145,"offset":12751},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":12607},"end":{"line":313,"column":145,"offset":12751},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":315,"column":5,"offset":12757},"end":{"line":315,"column":17,"offset":12769},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12753},"end":{"line":315,"column":17,"offset":12769},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":317,"column":1,"offset":12771},"end":{"line":317,"column":300,"offset":13070},"indent":[]}}],"position":{"start":{"line":317,"column":1,"offset":12771},"end":{"line":317,"column":300,"offset":13070},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":319,"column":1,"offset":13072},"end":{"line":319,"column":178,"offset":13249},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":13072},"end":{"line":319,"column":178,"offset":13249},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":321,"column":1,"offset":13251},"end":{"line":321,"column":48,"offset":13298},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":13251},"end":{"line":321,"column":48,"offset":13298},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":323,"column":1,"offset":13300},"end":{"line":325,"column":4,"offset":13340},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":327,"column":1,"offset":13342},"end":{"line":327,"column":104,"offset":13445},"indent":[]}}],"position":{"start":{"line":327,"column":1,"offset":13342},"end":{"line":327,"column":104,"offset":13445},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":329,"column":1,"offset":13447},"end":{"line":337,"column":4,"offset":13717},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":339,"column":1,"offset":13719},"end":{"line":339,"column":28,"offset":13746},"indent":[]}}],"position":{"start":{"line":339,"column":1,"offset":13719},"end":{"line":339,"column":28,"offset":13746},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":341,"column":1,"offset":13748},"end":{"line":343,"column":4,"offset":13792},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":345,"column":1,"offset":13794},"end":{"line":345,"column":48,"offset":13841},"indent":[]}}],"position":{"start":{"line":345,"column":1,"offset":13794},"end":{"line":345,"column":48,"offset":13841},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":347,"column":1,"offset":13843},"end":{"line":349,"column":4,"offset":13865},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":351,"column":1,"offset":13867},"end":{"line":351,"column":72,"offset":13938},"indent":[]}}],"position":{"start":{"line":351,"column":1,"offset":13867},"end":{"line":351,"column":72,"offset":13938},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":353,"column":1,"offset":13940},"end":{"line":355,"column":4,"offset":13997},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":357,"column":4,"offset":14002},"end":{"line":357,"column":11,"offset":14009},"indent":[]}}],"position":{"start":{"line":357,"column":1,"offset":13999},"end":{"line":357,"column":11,"offset":14009},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":359,"column":1,"offset":14011},"end":{"line":359,"column":283,"offset":14293},"indent":[]}}],"position":{"start":{"line":359,"column":1,"offset":14011},"end":{"line":359,"column":283,"offset":14293},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":361,"column":3,"offset":14297},"end":{"line":361,"column":54,"offset":14348},"indent":[]}}],"position":{"start":{"line":361,"column":3,"offset":14297},"end":{"line":361,"column":54,"offset":14348},"indent":[]}}],"position":{"start":{"line":361,"column":1,"offset":14295},"end":{"line":361,"column":54,"offset":14348},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":363,"column":5,"offset":14354},"end":{"line":363,"column":14,"offset":14363},"indent":[]}}],"position":{"start":{"line":363,"column":1,"offset":14350},"end":{"line":363,"column":14,"offset":14363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":365,"column":1,"offset":14365},"end":{"line":365,"column":68,"offset":14432},"indent":[]}}],"position":{"start":{"line":365,"column":1,"offset":14365},"end":{"line":365,"column":68,"offset":14432},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":367,"column":1,"offset":14434},"end":{"line":370,"column":4,"offset":14585},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":372,"column":1,"offset":14587},"end":{"line":372,"column":46,"offset":14632},"indent":[]}}],"position":{"start":{"line":372,"column":1,"offset":14587},"end":{"line":372,"column":46,"offset":14632},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":374,"column":3,"offset":14636},"end":{"line":374,"column":103,"offset":14736},"indent":[]}}],"position":{"start":{"line":374,"column":3,"offset":14636},"end":{"line":374,"column":103,"offset":14736},"indent":[]}}],"position":{"start":{"line":374,"column":1,"offset":14634},"end":{"line":374,"column":103,"offset":14736},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":376,"column":1,"offset":14738},"end":{"line":381,"column":4,"offset":14948},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":383,"column":1,"offset":14950},"end":{"line":383,"column":151,"offset":15100},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14950},"end":{"line":383,"column":151,"offset":15100},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":385,"column":3,"offset":15104},"end":{"line":385,"column":22,"offset":15123},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":385,"column":22,"offset":15123},"end":{"line":385,"column":26,"offset":15127},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":385,"column":26,"offset":15127},"end":{"line":385,"column":40,"offset":15141},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":385,"column":40,"offset":15141},"end":{"line":385,"column":50,"offset":15151},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":385,"column":50,"offset":15151},"end":{"line":385,"column":98,"offset":15199},"indent":[]}}],"position":{"start":{"line":385,"column":3,"offset":15104},"end":{"line":385,"column":98,"offset":15199},"indent":[]}}],"position":{"start":{"line":385,"column":1,"offset":15102},"end":{"line":385,"column":98,"offset":15199},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":387,"column":1,"offset":15201},"end":{"line":391,"column":4,"offset":15363},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":393,"column":1,"offset":15365},"end":{"line":393,"column":72,"offset":15436},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":393,"column":72,"offset":15436},"end":{"line":393,"column":84,"offset":15448},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":393,"column":84,"offset":15448},"end":{"line":393,"column":102,"offset":15466},"indent":[]}}],"position":{"start":{"line":393,"column":1,"offset":15365},"end":{"line":393,"column":102,"offset":15466},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":395,"column":1,"offset":15468},"end":{"line":398,"column":4,"offset":15542},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":400,"column":5,"offset":15548},"end":{"line":400,"column":8,"offset":15551},"indent":[]}}],"position":{"start":{"line":400,"column":1,"offset":15544},"end":{"line":400,"column":8,"offset":15551},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":402,"column":1,"offset":15553},"end":{"line":402,"column":176,"offset":15728},"indent":[]}}],"position":{"start":{"line":402,"column":1,"offset":15553},"end":{"line":402,"column":176,"offset":15728},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":404,"column":1,"offset":15730},"end":{"line":411,"column":4,"offset":16027},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":413,"column":1,"offset":16029},"end":{"line":413,"column":60,"offset":16088},"indent":[]}}],"position":{"start":{"line":413,"column":1,"offset":16029},"end":{"line":413,"column":60,"offset":16088},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":415,"column":1,"offset":16090},"end":{"line":419,"column":4,"offset":16216},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":421,"column":1,"offset":16218},"end":{"line":421,"column":63,"offset":16280},"indent":[]}}],"position":{"start":{"line":421,"column":1,"offset":16218},"end":{"line":421,"column":63,"offset":16280},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":423,"column":1,"offset":16282},"end":{"line":443,"column":4,"offset":16789},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":445,"column":1,"offset":16791},"end":{"line":445,"column":99,"offset":16889},"indent":[]}}],"position":{"start":{"line":445,"column":1,"offset":16791},"end":{"line":445,"column":99,"offset":16889},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":447,"column":1,"offset":16891},"end":{"line":450,"column":4,"offset":16993},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":452,"column":1,"offset":16995},"end":{"line":452,"column":37,"offset":17031},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":452,"column":37,"offset":17031},"end":{"line":452,"column":47,"offset":17041},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":452,"column":47,"offset":17041},"end":{"line":452,"column":89,"offset":17083},"indent":[]}}],"position":{"start":{"line":452,"column":1,"offset":16995},"end":{"line":452,"column":89,"offset":17083},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":454,"column":1,"offset":17085},"end":{"line":458,"column":4,"offset":17210},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":460,"column":1,"offset":17212},"end":{"line":460,"column":78,"offset":17289},"indent":[]}}],"position":{"start":{"line":460,"column":1,"offset":17212},"end":{"line":460,"column":78,"offset":17289},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":462,"column":1,"offset":17291},"end":{"line":466,"column":4,"offset":17395},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":468,"column":1,"offset":17397},"end":{"line":468,"column":75,"offset":17471},"indent":[]}}],"position":{"start":{"line":468,"column":1,"offset":17397},"end":{"line":468,"column":75,"offset":17471},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":470,"column":1,"offset":17473},"end":{"line":474,"column":4,"offset":17546},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":476,"column":1,"offset":17548},"end":{"line":476,"column":145,"offset":17692},"indent":[]}}],"position":{"start":{"line":476,"column":1,"offset":17548},"end":{"line":476,"column":145,"offset":17692},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":478,"column":5,"offset":17698},"end":{"line":478,"column":17,"offset":17710},"indent":[]}}],"position":{"start":{"line":478,"column":1,"offset":17694},"end":{"line":478,"column":17,"offset":17710},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":480,"column":1,"offset":17712},"end":{"line":480,"column":300,"offset":18011},"indent":[]}}],"position":{"start":{"line":480,"column":1,"offset":17712},"end":{"line":480,"column":300,"offset":18011},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":482,"column":1,"offset":18013},"end":{"line":482,"column":178,"offset":18190},"indent":[]}}],"position":{"start":{"line":482,"column":1,"offset":18013},"end":{"line":482,"column":178,"offset":18190},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":484,"column":1,"offset":18192},"end":{"line":484,"column":48,"offset":18239},"indent":[]}}],"position":{"start":{"line":484,"column":1,"offset":18192},"end":{"line":484,"column":48,"offset":18239},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":486,"column":1,"offset":18241},"end":{"line":488,"column":4,"offset":18285},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":490,"column":1,"offset":18287},"end":{"line":490,"column":104,"offset":18390},"indent":[]}}],"position":{"start":{"line":490,"column":1,"offset":18287},"end":{"line":490,"column":104,"offset":18390},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":492,"column":1,"offset":18392},"end":{"line":500,"column":4,"offset":18662},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":502,"column":1,"offset":18664},"end":{"line":502,"column":28,"offset":18691},"indent":[]}}],"position":{"start":{"line":502,"column":1,"offset":18664},"end":{"line":502,"column":28,"offset":18691},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":504,"column":1,"offset":18693},"end":{"line":506,"column":4,"offset":18741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":508,"column":1,"offset":18743},"end":{"line":508,"column":48,"offset":18790},"indent":[]}}],"position":{"start":{"line":508,"column":1,"offset":18743},"end":{"line":508,"column":48,"offset":18790},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":510,"column":1,"offset":18792},"end":{"line":512,"column":4,"offset":18814},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":514,"column":1,"offset":18816},"end":{"line":514,"column":72,"offset":18887},"indent":[]}}],"position":{"start":{"line":514,"column":1,"offset":18816},"end":{"line":514,"column":72,"offset":18887},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":516,"column":1,"offset":18889},"end":{"line":518,"column":4,"offset":18950},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":521,"column":1,"offset":18953},"end":{"line":521,"column":31,"offset":18983},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":521,"column":31,"offset":18983}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on `}{`the Docker hub`}{`, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All DDocker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`Instead of just running the Kerberos container, you can also persist your configuration by assigning volumes. An example of mounting volumes looks like this; an overview of `}{`the different volumes can be found here`}{`.`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`kerberos`}{`-`}{`camera1`}{` \\\\`}{`\n`}{`-`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/config:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`config`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/capture:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`capture`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/logs:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`logs`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/webconfig:/`}{`var`}{`/`}{`www`}{`/web/config \\\\`}{`\n`}{`-`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.`}

\n \n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.`}

\n

{`To fill the gap, regarding the latter, we can rely on another solution called `}{`Balena.io`}{`. Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).`}

\n

{`On top of supporting a lot of boars,`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-646cb4d61844566a08621a365fbacccd.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-646cb4d61844566a08621a365fbacccd.json index f812c6c..e39264e 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-646cb4d61844566a08621a365fbacccd.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-646cb4d61844566a08621a365fbacccd.json @@ -1 +1 @@ -{"expireTime":9007200841014157000,"key":"gatsby-plugin-mdx-entire-payload-4da389145f8f15af33f600ed3ffce972-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Kerberos.io","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":14,"offset":172},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":14,"offset":172},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The ","position":{"start":{"line":10,"column":1,"offset":174},"end":{"line":10,"column":5,"offset":178},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Kerberos(dot)io","position":{"start":{"line":10,"column":7,"offset":180},"end":{"line":10,"column":22,"offset":195},"indent":[]}}],"position":{"start":{"line":10,"column":5,"offset":178},"end":{"line":10,"column":24,"offset":197},"indent":[]}},{"type":"text","value":" project, is a video surveillance solution, which was initiated back in 2014. Over the years it has evolved into a trusted, stable and feature-rich video surveillance system. To set the expectations, watch the video below to understand what it can and can't do. If you want to install Kerberos(dot)io, it's recommended to have a look ","position":{"start":{"line":10,"column":24,"offset":197},"end":{"line":10,"column":358,"offset":531},"indent":[]}},{"type":"link","title":null,"url":"/architectures","children":[{"type":"text","value":"at the architectures page","position":{"start":{"line":10,"column":359,"offset":532},"end":{"line":10,"column":384,"offset":557},"indent":[]}}],"position":{"start":{"line":10,"column":358,"offset":531},"end":{"line":10,"column":401,"offset":574},"indent":[]}},{"type":"text","value":" to find the best solution for your usecase.","position":{"start":{"line":10,"column":401,"offset":574},"end":{"line":10,"column":445,"offset":618},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":174},"end":{"line":10,"column":445,"offset":618},"indent":[]}},{"type":"jsx","value":"
","position":{"start":{"line":12,"column":1,"offset":620},"end":{"line":12,"column":186,"offset":805},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"The name: Kerberos.io","position":{"start":{"line":14,"column":4,"offset":810},"end":{"line":14,"column":25,"offset":831},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":807},"end":{"line":14,"column":25,"offset":831},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Many people are confused, and don't understand why this project is called Kerberos(dot)io. If you've been in the IT world for a while you will notice that Kerberos is already used for the authentication protocol ","position":{"start":{"line":16,"column":1,"offset":833},"end":{"line":16,"column":213,"offset":1045},"indent":[]}},{"type":"link","title":null,"url":"https://en.wikipedia.org/wiki/Kerberos_(protocol)","children":[{"type":"text","value":"Kerberos","position":{"start":{"line":16,"column":214,"offset":1046},"end":{"line":16,"column":222,"offset":1054},"indent":[]}}],"position":{"start":{"line":16,"column":213,"offset":1045},"end":{"line":16,"column":274,"offset":1106},"indent":[]}},{"type":"text","value":".\nWe believe that the name Kerberos(dot)io makes sense for this project as well, with a strong emphasize on the suffix ","position":{"start":{"line":16,"column":274,"offset":1106},"end":{"line":17,"column":118,"offset":1225},"indent":[1]}},{"type":"strong","children":[{"type":"text","value":".io","position":{"start":{"line":17,"column":120,"offset":1227},"end":{"line":17,"column":123,"offset":1230},"indent":[]}}],"position":{"start":{"line":17,"column":118,"offset":1225},"end":{"line":17,"column":125,"offset":1232},"indent":[]}},{"type":"text","value":", which stands for input and output devices (e.g. any type of camera). Kerberos(dot)io can be seen as a kind of security protocol driven by hardware devices such as surveillance cameras. To make writing easier we will from now on, refer to Kerberos instead of Kerberos(dot)io.","position":{"start":{"line":17,"column":125,"offset":1232},"end":{"line":17,"column":401,"offset":1508},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":833},"end":{"line":17,"column":401,"offset":1508},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Why Kerberos","position":{"start":{"line":19,"column":4,"offset":1513},"end":{"line":19,"column":16,"offset":1525},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":1510},"end":{"line":19,"column":16,"offset":1525},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"As burglary is very common, we believe that video surveillance is a trivial tool in our daily lifes which helps us to feel a little bit more secure. Responding to this need, a lot of companies have started developing their own video surveillance software in the past few years.","position":{"start":{"line":21,"column":1,"offset":1527},"end":{"line":21,"column":278,"offset":1804},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":1527},"end":{"line":21,"column":278,"offset":1804},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Nowadays we have a myriad of expensive cameras, recorders, and software solutions which are mainly outdated and difficult to install and use. Kerberos goal is to solve these problems and to provide every human being or enterprise in this world to have their own ecological, affordable, easy-to-use and innovative surveillance solution. Read more about our strategy here.","position":{"start":{"line":23,"column":1,"offset":1806},"end":{"line":23,"column":371,"offset":2176},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":1806},"end":{"line":23,"column":371,"offset":2176},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"What is Kerberos","position":{"start":{"line":25,"column":4,"offset":2181},"end":{"line":25,"column":20,"offset":2197},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":2178},"end":{"line":25,"column":20,"offset":2197},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos is a video surveillance solution, that uses computer vision algorithms to detect changes, and that can trigger actions (notifications, api, etc). It comes in two flavors, Kerberos Open Source and Kerberos Enterprise. Kerberos can be deployed to any Linux OS, Docker, or cluster such as Kubernetes.","position":{"start":{"line":27,"column":1,"offset":2199},"end":{"line":27,"column":307,"offset":2505},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":2199},"end":{"line":27,"column":307,"offset":2505},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"The Kerberos agent","position":{"start":{"line":29,"column":4,"offset":2510},"end":{"line":29,"column":22,"offset":2528},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":2507},"end":{"line":29,"column":22,"offset":2528},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When you install Kerberos Open Source or Kerberos Enterprise we will refer to it as a Kerberos agent. A Kerberos agent, is a software solution that processes the video stream of a single surveillance camera, makes and visualises recordings and takes actions (for example sending notifications).","position":{"start":{"line":31,"column":1,"offset":2530},"end":{"line":31,"column":295,"offset":2824},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":2530},"end":{"line":31,"column":295,"offset":2824},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"How does it work","position":{"start":{"line":33,"column":4,"offset":2829},"end":{"line":33,"column":20,"offset":2845},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":2826},"end":{"line":33,"column":20,"offset":2845},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Kerberos agent comes in two flavors, Open Source and Enterprise. Both versions have a web interface (front-end) and a video processing engine (back-end). The front-end allows a user to modify specific settings and watch recordings in a easy-to-use interface. The back-end is a solution that processes the camera feed with computer vision algorithms to detect motion, and makes recordings and/or execute specific actions. Kerberos supports any type of IP-camera (RTSP/ONVIF), USB (V4L2) and the popular Raspberry Pi camera.","position":{"start":{"line":35,"column":1,"offset":2847},"end":{"line":35,"column":527,"offset":3373},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":2847},"end":{"line":35,"column":527,"offset":3373},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Depending on the flavor you choose, you will have to install different components, but the idea as described above remains the same. If you would like to learn more dive deeper in the related sections: ","position":{"start":{"line":37,"column":1,"offset":3375},"end":{"line":37,"column":203,"offset":3577},"indent":[]}},{"type":"link","title":null,"url":"/opensource/introduction","children":[{"type":"text","value":"Open Source","position":{"start":{"line":37,"column":204,"offset":3578},"end":{"line":37,"column":215,"offset":3589},"indent":[]}}],"position":{"start":{"line":37,"column":203,"offset":3577},"end":{"line":37,"column":242,"offset":3616},"indent":[]}},{"type":"text","value":", ","position":{"start":{"line":37,"column":242,"offset":3616},"end":{"line":37,"column":244,"offset":3618},"indent":[]}},{"type":"link","title":null,"url":"/enterprise/introduction","children":[{"type":"text","value":"Enterprise","position":{"start":{"line":37,"column":245,"offset":3619},"end":{"line":37,"column":255,"offset":3629},"indent":[]}}],"position":{"start":{"line":37,"column":244,"offset":3618},"end":{"line":37,"column":282,"offset":3656},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":282,"offset":3656},"end":{"line":37,"column":283,"offset":3657},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":3375},"end":{"line":37,"column":283,"offset":3657},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Open Source vs Enterprise","position":{"start":{"line":39,"column":4,"offset":3662},"end":{"line":39,"column":29,"offset":3687},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":3659},"end":{"line":39,"column":29,"offset":3687},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Kerberos project started as an Open Source project, with a main focus on low-cost devices such as the Raspberry Pi. Later on the Open Source version was bundled inside the Docker technology so that it was easier to distribute. Anyone can use the Open Source version for personal usage.","position":{"start":{"line":41,"column":1,"offset":3689},"end":{"line":41,"column":290,"offset":3978},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":3689},"end":{"line":41,"column":290,"offset":3978},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Enterprises are more demanding, and have a lot of surveillance cameras, therefore they need a scalable surveillance system. The ","position":{"start":{"line":43,"column":1,"offset":3980},"end":{"line":43,"column":129,"offset":4108},"indent":[]}},{"type":"link","title":null,"url":"/enterprise/introduction","children":[{"type":"text","value":"Enterprise edition","position":{"start":{"line":43,"column":130,"offset":4109},"end":{"line":43,"column":148,"offset":4127},"indent":[]}}],"position":{"start":{"line":43,"column":129,"offset":4108},"end":{"line":43,"column":175,"offset":4154},"indent":[]}},{"type":"text","value":" of Kerberos is a licensed service which allows you to operate a video surveillance cluster (Kubernetes) on-premise or in the cloud (AWS/GCP/Azure).","position":{"start":{"line":43,"column":175,"offset":4154},"end":{"line":43,"column":323,"offset":4302},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":3980},"end":{"line":43,"column":323,"offset":4302},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Open Source and Enterprise edition are significantly different from a source code point of view. The ","position":{"start":{"line":45,"column":1,"offset":4304},"end":{"line":45,"column":106,"offset":4409},"indent":[]}},{"type":"link","title":null,"url":"/enterprise/introduction","children":[{"type":"text","value":"Enterprise edition","position":{"start":{"line":45,"column":107,"offset":4410},"end":{"line":45,"column":125,"offset":4428},"indent":[]}}],"position":{"start":{"line":45,"column":106,"offset":4409},"end":{"line":45,"column":152,"offset":4455},"indent":[]}},{"type":"text","value":" is a complete rewrite of the Open Source version, and got all the best practices we discovered over the years implemented. Both version are and will remain updated in the future.","position":{"start":{"line":45,"column":152,"offset":4455},"end":{"line":45,"column":331,"offset":4634},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":4304},"end":{"line":45,"column":331,"offset":4634},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Cloud","position":{"start":{"line":47,"column":4,"offset":4639},"end":{"line":47,"column":9,"offset":4644},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":4636},"end":{"line":47,"column":9,"offset":4644},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When installing a Kerberos agent inside your local network, it's possible to review your activity by using the agent's web interface. By its nature, you will not be able to access the web interface from the cloud (outside your local network). On top of that, the Kerberos agent doesn't come with a consolidated overview. This means that you will need to open multiple web interfaces, one for each connected surveillance camera. To simplify and resolve all of these challenges, ","position":{"start":{"line":49,"column":1,"offset":4646},"end":{"line":49,"column":478,"offset":5123},"indent":[]}},{"type":"link","title":null,"url":"/cloud","children":[{"type":"text","value":"Kerberos Cloud","position":{"start":{"line":49,"column":479,"offset":5124},"end":{"line":49,"column":493,"offset":5138},"indent":[]}}],"position":{"start":{"line":49,"column":478,"offset":5123},"end":{"line":49,"column":502,"offset":5147},"indent":[]}},{"type":"text","value":" was developed. Read more about the ","position":{"start":{"line":49,"column":502,"offset":5147},"end":{"line":49,"column":538,"offset":5183},"indent":[]}},{"type":"link","title":null,"url":"/cloud","children":[{"type":"text","value":"different features and functions of Kerberos Cloud here","position":{"start":{"line":49,"column":539,"offset":5184},"end":{"line":49,"column":594,"offset":5239},"indent":[]}}],"position":{"start":{"line":49,"column":538,"offset":5183},"end":{"line":49,"column":603,"offset":5248},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":49,"column":603,"offset":5248},"end":{"line":49,"column":604,"offset":5249},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":4646},"end":{"line":49,"column":604,"offset":5249},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":52,"column":1,"offset":5252},"end":{"line":52,"column":31,"offset":5282},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":52,"column":31,"offset":5282}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Kerberos.io`}

\n

{`The `}{`Kerberos(dot)io`}{` project, is a video surveillance solution, which was initiated back in 2014. Over the years it has evolved into a trusted, stable and feature-rich video surveillance system. To set the expectations, watch the video below to understand what it can and can't do. If you want to install Kerberos(dot)io, it's recommended to have a look `}{`at the architectures page`}{` to find the best solution for your usecase.`}

\n
\n

{`The name: Kerberos.io`}

\n

{`Many people are confused, and don't understand why this project is called Kerberos(dot)io. If you've been in the IT world for a while you will notice that Kerberos is already used for the authentication protocol `}{`Kerberos`}{`.\nWe believe that the name Kerberos(dot)io makes sense for this project as well, with a strong emphasize on the suffix `}{`.io`}{`, which stands for input and output devices (e.g. any type of camera). Kerberos(dot)io can be seen as a kind of security protocol driven by hardware devices such as surveillance cameras. To make writing easier we will from now on, refer to Kerberos instead of Kerberos(dot)io.`}

\n

{`Why Kerberos`}

\n

{`As burglary is very common, we believe that video surveillance is a trivial tool in our daily lifes which helps us to feel a little bit more secure. Responding to this need, a lot of companies have started developing their own video surveillance software in the past few years.`}

\n

{`Nowadays we have a myriad of expensive cameras, recorders, and software solutions which are mainly outdated and difficult to install and use. Kerberos goal is to solve these problems and to provide every human being or enterprise in this world to have their own ecological, affordable, easy-to-use and innovative surveillance solution. Read more about our strategy here.`}

\n

{`What is Kerberos`}

\n

{`Kerberos is a video surveillance solution, that uses computer vision algorithms to detect changes, and that can trigger actions (notifications, api, etc). It comes in two flavors, Kerberos Open Source and Kerberos Enterprise. Kerberos can be deployed to any Linux OS, Docker, or cluster such as Kubernetes.`}

\n

{`The Kerberos agent`}

\n

{`When you install Kerberos Open Source or Kerberos Enterprise we will refer to it as a Kerberos agent. A Kerberos agent, is a software solution that processes the video stream of a single surveillance camera, makes and visualises recordings and takes actions (for example sending notifications).`}

\n

{`How does it work`}

\n

{`The Kerberos agent comes in two flavors, Open Source and Enterprise. Both versions have a web interface (front-end) and a video processing engine (back-end). The front-end allows a user to modify specific settings and watch recordings in a easy-to-use interface. The back-end is a solution that processes the camera feed with computer vision algorithms to detect motion, and makes recordings and/or execute specific actions. Kerberos supports any type of IP-camera (RTSP/ONVIF), USB (V4L2) and the popular Raspberry Pi camera.`}

\n

{`Depending on the flavor you choose, you will have to install different components, but the idea as described above remains the same. If you would like to learn more dive deeper in the related sections: `}{`Open Source`}{`, `}{`Enterprise`}{`.`}

\n

{`Open Source vs Enterprise`}

\n

{`The Kerberos project started as an Open Source project, with a main focus on low-cost devices such as the Raspberry Pi. Later on the Open Source version was bundled inside the Docker technology so that it was easier to distribute. Anyone can use the Open Source version for personal usage.`}

\n

{`Enterprises are more demanding, and have a lot of surveillance cameras, therefore they need a scalable surveillance system. The `}{`Enterprise edition`}{` of Kerberos is a licensed service which allows you to operate a video surveillance cluster (Kubernetes) on-premise or in the cloud (AWS/GCP/Azure).`}

\n

{`The Open Source and Enterprise edition are significantly different from a source code point of view. The `}{`Enterprise edition`}{` is a complete rewrite of the Open Source version, and got all the best practices we discovered over the years implemented. Both version are and will remain updated in the future.`}

\n

{`Cloud`}

\n

{`When installing a Kerberos agent inside your local network, it's possible to review your activity by using the agent's web interface. By its nature, you will not be able to access the web interface from the cloud (outside your local network). On top of that, the Kerberos agent doesn't come with a consolidated overview. This means that you will need to open multiple web interfaces, one for each connected surveillance camera. To simplify and resolve all of these challenges, `}{`Kerberos Cloud`}{` was developed. Read more about the `}{`different features and functions of Kerberos Cloud here`}{`.`}

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974263000,"key":"gatsby-plugin-mdx-entire-payload-4da389145f8f15af33f600ed3ffce972-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Kerberos.io","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":14,"offset":172},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":14,"offset":172},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The ","position":{"start":{"line":10,"column":1,"offset":174},"end":{"line":10,"column":5,"offset":178},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Kerberos(dot)io","position":{"start":{"line":10,"column":7,"offset":180},"end":{"line":10,"column":22,"offset":195},"indent":[]}}],"position":{"start":{"line":10,"column":5,"offset":178},"end":{"line":10,"column":24,"offset":197},"indent":[]}},{"type":"text","value":" project, is a video surveillance solution, which was initiated back in 2014. Over the years it has evolved into a trusted, stable and feature-rich video surveillance system. To set the expectations, watch the video below to understand what it can and can't do. If you want to install Kerberos(dot)io, it's recommended to have a look ","position":{"start":{"line":10,"column":24,"offset":197},"end":{"line":10,"column":358,"offset":531},"indent":[]}},{"type":"link","title":null,"url":"/architectures","children":[{"type":"text","value":"at the architectures page","position":{"start":{"line":10,"column":359,"offset":532},"end":{"line":10,"column":384,"offset":557},"indent":[]}}],"position":{"start":{"line":10,"column":358,"offset":531},"end":{"line":10,"column":401,"offset":574},"indent":[]}},{"type":"text","value":" to find the best solution for your usecase.","position":{"start":{"line":10,"column":401,"offset":574},"end":{"line":10,"column":445,"offset":618},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":174},"end":{"line":10,"column":445,"offset":618},"indent":[]}},{"type":"jsx","value":"
","position":{"start":{"line":12,"column":1,"offset":620},"end":{"line":12,"column":186,"offset":805},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"The name: Kerberos.io","position":{"start":{"line":14,"column":4,"offset":810},"end":{"line":14,"column":25,"offset":831},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":807},"end":{"line":14,"column":25,"offset":831},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Many people are confused, and don't understand why this project is called Kerberos(dot)io. If you've been in the IT world for a while you will notice that Kerberos is already used for the authentication protocol ","position":{"start":{"line":16,"column":1,"offset":833},"end":{"line":16,"column":213,"offset":1045},"indent":[]}},{"type":"link","title":null,"url":"https://en.wikipedia.org/wiki/Kerberos_(protocol)","children":[{"type":"text","value":"Kerberos","position":{"start":{"line":16,"column":214,"offset":1046},"end":{"line":16,"column":222,"offset":1054},"indent":[]}}],"position":{"start":{"line":16,"column":213,"offset":1045},"end":{"line":16,"column":274,"offset":1106},"indent":[]}},{"type":"text","value":".\nWe believe that the name Kerberos(dot)io makes sense for this project as well, with a strong emphasize on the suffix ","position":{"start":{"line":16,"column":274,"offset":1106},"end":{"line":17,"column":118,"offset":1225},"indent":[1]}},{"type":"strong","children":[{"type":"text","value":".io","position":{"start":{"line":17,"column":120,"offset":1227},"end":{"line":17,"column":123,"offset":1230},"indent":[]}}],"position":{"start":{"line":17,"column":118,"offset":1225},"end":{"line":17,"column":125,"offset":1232},"indent":[]}},{"type":"text","value":", which stands for input and output devices (e.g. any type of camera). Kerberos(dot)io can be seen as a kind of security protocol driven by hardware devices such as surveillance cameras. To make writing easier we will from now on, refer to Kerberos instead of Kerberos(dot)io.","position":{"start":{"line":17,"column":125,"offset":1232},"end":{"line":17,"column":401,"offset":1508},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":833},"end":{"line":17,"column":401,"offset":1508},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Why Kerberos","position":{"start":{"line":19,"column":4,"offset":1513},"end":{"line":19,"column":16,"offset":1525},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":1510},"end":{"line":19,"column":16,"offset":1525},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"As burglary is very common, we believe that video surveillance is a trivial tool in our daily lifes which helps us to feel a little bit more secure. Responding to this need, a lot of companies have started developing their own video surveillance software in the past few years.","position":{"start":{"line":21,"column":1,"offset":1527},"end":{"line":21,"column":278,"offset":1804},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":1527},"end":{"line":21,"column":278,"offset":1804},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Nowadays we have a myriad of expensive cameras, recorders, and software solutions which are mainly outdated and difficult to install and use. Kerberos goal is to solve these problems and to provide every human being or enterprise in this world to have their own ecological, affordable, easy-to-use and innovative surveillance solution. Read more about our strategy here.","position":{"start":{"line":23,"column":1,"offset":1806},"end":{"line":23,"column":371,"offset":2176},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":1806},"end":{"line":23,"column":371,"offset":2176},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"What is Kerberos","position":{"start":{"line":25,"column":4,"offset":2181},"end":{"line":25,"column":20,"offset":2197},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":2178},"end":{"line":25,"column":20,"offset":2197},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos is a video surveillance solution, that uses computer vision algorithms to detect changes, and that can trigger actions (notifications, api, etc). It comes in two flavors, Kerberos Open Source and Kerberos Enterprise. Kerberos can be deployed to any Linux OS, Docker, or cluster such as Kubernetes.","position":{"start":{"line":27,"column":1,"offset":2199},"end":{"line":27,"column":307,"offset":2505},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":2199},"end":{"line":27,"column":307,"offset":2505},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"The Kerberos agent","position":{"start":{"line":29,"column":4,"offset":2510},"end":{"line":29,"column":22,"offset":2528},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":2507},"end":{"line":29,"column":22,"offset":2528},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When you install Kerberos Open Source or Kerberos Enterprise we will refer to it as a Kerberos agent. A Kerberos agent, is a software solution that processes the video stream of a single surveillance camera, makes and visualises recordings and takes actions (for example sending notifications).","position":{"start":{"line":31,"column":1,"offset":2530},"end":{"line":31,"column":295,"offset":2824},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":2530},"end":{"line":31,"column":295,"offset":2824},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"How does it work","position":{"start":{"line":33,"column":4,"offset":2829},"end":{"line":33,"column":20,"offset":2845},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":2826},"end":{"line":33,"column":20,"offset":2845},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Kerberos agent comes in two flavors, Open Source and Enterprise. Both versions have a web interface (front-end) and a video processing engine (back-end). The front-end allows a user to modify specific settings and watch recordings in a easy-to-use interface. The back-end is a solution that processes the camera feed with computer vision algorithms to detect motion, and makes recordings and/or execute specific actions. Kerberos supports any type of IP-camera (RTSP/ONVIF), USB (V4L2) and the popular Raspberry Pi camera.","position":{"start":{"line":35,"column":1,"offset":2847},"end":{"line":35,"column":527,"offset":3373},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":2847},"end":{"line":35,"column":527,"offset":3373},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Depending on the flavor you choose, you will have to install different components, but the idea as described above remains the same. If you would like to learn more dive deeper in the related sections: ","position":{"start":{"line":37,"column":1,"offset":3375},"end":{"line":37,"column":203,"offset":3577},"indent":[]}},{"type":"link","title":null,"url":"/opensource/introduction","children":[{"type":"text","value":"Open Source","position":{"start":{"line":37,"column":204,"offset":3578},"end":{"line":37,"column":215,"offset":3589},"indent":[]}}],"position":{"start":{"line":37,"column":203,"offset":3577},"end":{"line":37,"column":242,"offset":3616},"indent":[]}},{"type":"text","value":", ","position":{"start":{"line":37,"column":242,"offset":3616},"end":{"line":37,"column":244,"offset":3618},"indent":[]}},{"type":"link","title":null,"url":"/enterprise/introduction","children":[{"type":"text","value":"Enterprise","position":{"start":{"line":37,"column":245,"offset":3619},"end":{"line":37,"column":255,"offset":3629},"indent":[]}}],"position":{"start":{"line":37,"column":244,"offset":3618},"end":{"line":37,"column":282,"offset":3656},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":282,"offset":3656},"end":{"line":37,"column":283,"offset":3657},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":3375},"end":{"line":37,"column":283,"offset":3657},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Open Source vs Enterprise","position":{"start":{"line":39,"column":4,"offset":3662},"end":{"line":39,"column":29,"offset":3687},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":3659},"end":{"line":39,"column":29,"offset":3687},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Kerberos project started as an Open Source project, with a main focus on low-cost devices such as the Raspberry Pi. Later on the Open Source version was bundled inside the Docker technology so that it was easier to distribute. Anyone can use the Open Source version for personal usage.","position":{"start":{"line":41,"column":1,"offset":3689},"end":{"line":41,"column":290,"offset":3978},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":3689},"end":{"line":41,"column":290,"offset":3978},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Enterprises are more demanding, and have a lot of surveillance cameras, therefore they need a scalable surveillance system. The ","position":{"start":{"line":43,"column":1,"offset":3980},"end":{"line":43,"column":129,"offset":4108},"indent":[]}},{"type":"link","title":null,"url":"/enterprise/introduction","children":[{"type":"text","value":"Enterprise edition","position":{"start":{"line":43,"column":130,"offset":4109},"end":{"line":43,"column":148,"offset":4127},"indent":[]}}],"position":{"start":{"line":43,"column":129,"offset":4108},"end":{"line":43,"column":175,"offset":4154},"indent":[]}},{"type":"text","value":" of Kerberos is a licensed service which allows you to operate a video surveillance cluster (Kubernetes) on-premise or in the cloud (AWS/GCP/Azure).","position":{"start":{"line":43,"column":175,"offset":4154},"end":{"line":43,"column":323,"offset":4302},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":3980},"end":{"line":43,"column":323,"offset":4302},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Open Source and Enterprise edition are significantly different from a source code point of view. The ","position":{"start":{"line":45,"column":1,"offset":4304},"end":{"line":45,"column":106,"offset":4409},"indent":[]}},{"type":"link","title":null,"url":"/enterprise/introduction","children":[{"type":"text","value":"Enterprise edition","position":{"start":{"line":45,"column":107,"offset":4410},"end":{"line":45,"column":125,"offset":4428},"indent":[]}}],"position":{"start":{"line":45,"column":106,"offset":4409},"end":{"line":45,"column":152,"offset":4455},"indent":[]}},{"type":"text","value":" is a complete rewrite of the Open Source version, and got all the best practices we discovered over the years implemented. Both version are and will remain updated in the future.","position":{"start":{"line":45,"column":152,"offset":4455},"end":{"line":45,"column":331,"offset":4634},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":4304},"end":{"line":45,"column":331,"offset":4634},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Cloud","position":{"start":{"line":47,"column":4,"offset":4639},"end":{"line":47,"column":9,"offset":4644},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":4636},"end":{"line":47,"column":9,"offset":4644},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When installing a Kerberos agent inside your local network, it's possible to review your activity by using the agent's web interface. By its nature, you will not be able to access the web interface from the cloud (outside your local network). On top of that, the Kerberos agent doesn't come with a consolidated overview. This means that you will need to open multiple web interfaces, one for each connected surveillance camera. To simplify and resolve all of these challenges, ","position":{"start":{"line":49,"column":1,"offset":4646},"end":{"line":49,"column":478,"offset":5123},"indent":[]}},{"type":"link","title":null,"url":"/cloud","children":[{"type":"text","value":"Kerberos Cloud","position":{"start":{"line":49,"column":479,"offset":5124},"end":{"line":49,"column":493,"offset":5138},"indent":[]}}],"position":{"start":{"line":49,"column":478,"offset":5123},"end":{"line":49,"column":502,"offset":5147},"indent":[]}},{"type":"text","value":" was developed. Read more about the ","position":{"start":{"line":49,"column":502,"offset":5147},"end":{"line":49,"column":538,"offset":5183},"indent":[]}},{"type":"link","title":null,"url":"/cloud","children":[{"type":"text","value":"different features and functions of Kerberos Cloud here","position":{"start":{"line":49,"column":539,"offset":5184},"end":{"line":49,"column":594,"offset":5239},"indent":[]}}],"position":{"start":{"line":49,"column":538,"offset":5183},"end":{"line":49,"column":603,"offset":5248},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":49,"column":603,"offset":5248},"end":{"line":49,"column":604,"offset":5249},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":4646},"end":{"line":49,"column":604,"offset":5249},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":52,"column":1,"offset":5252},"end":{"line":52,"column":31,"offset":5282},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":52,"column":31,"offset":5282}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Kerberos.io`}

\n

{`The `}{`Kerberos(dot)io`}{` project, is a video surveillance solution, which was initiated back in 2014. Over the years it has evolved into a trusted, stable and feature-rich video surveillance system. To set the expectations, watch the video below to understand what it can and can't do. If you want to install Kerberos(dot)io, it's recommended to have a look `}{`at the architectures page`}{` to find the best solution for your usecase.`}

\n
\n

{`The name: Kerberos.io`}

\n

{`Many people are confused, and don't understand why this project is called Kerberos(dot)io. If you've been in the IT world for a while you will notice that Kerberos is already used for the authentication protocol `}{`Kerberos`}{`.\nWe believe that the name Kerberos(dot)io makes sense for this project as well, with a strong emphasize on the suffix `}{`.io`}{`, which stands for input and output devices (e.g. any type of camera). Kerberos(dot)io can be seen as a kind of security protocol driven by hardware devices such as surveillance cameras. To make writing easier we will from now on, refer to Kerberos instead of Kerberos(dot)io.`}

\n

{`Why Kerberos`}

\n

{`As burglary is very common, we believe that video surveillance is a trivial tool in our daily lifes which helps us to feel a little bit more secure. Responding to this need, a lot of companies have started developing their own video surveillance software in the past few years.`}

\n

{`Nowadays we have a myriad of expensive cameras, recorders, and software solutions which are mainly outdated and difficult to install and use. Kerberos goal is to solve these problems and to provide every human being or enterprise in this world to have their own ecological, affordable, easy-to-use and innovative surveillance solution. Read more about our strategy here.`}

\n

{`What is Kerberos`}

\n

{`Kerberos is a video surveillance solution, that uses computer vision algorithms to detect changes, and that can trigger actions (notifications, api, etc). It comes in two flavors, Kerberos Open Source and Kerberos Enterprise. Kerberos can be deployed to any Linux OS, Docker, or cluster such as Kubernetes.`}

\n

{`The Kerberos agent`}

\n

{`When you install Kerberos Open Source or Kerberos Enterprise we will refer to it as a Kerberos agent. A Kerberos agent, is a software solution that processes the video stream of a single surveillance camera, makes and visualises recordings and takes actions (for example sending notifications).`}

\n

{`How does it work`}

\n

{`The Kerberos agent comes in two flavors, Open Source and Enterprise. Both versions have a web interface (front-end) and a video processing engine (back-end). The front-end allows a user to modify specific settings and watch recordings in a easy-to-use interface. The back-end is a solution that processes the camera feed with computer vision algorithms to detect motion, and makes recordings and/or execute specific actions. Kerberos supports any type of IP-camera (RTSP/ONVIF), USB (V4L2) and the popular Raspberry Pi camera.`}

\n

{`Depending on the flavor you choose, you will have to install different components, but the idea as described above remains the same. If you would like to learn more dive deeper in the related sections: `}{`Open Source`}{`, `}{`Enterprise`}{`.`}

\n

{`Open Source vs Enterprise`}

\n

{`The Kerberos project started as an Open Source project, with a main focus on low-cost devices such as the Raspberry Pi. Later on the Open Source version was bundled inside the Docker technology so that it was easier to distribute. Anyone can use the Open Source version for personal usage.`}

\n

{`Enterprises are more demanding, and have a lot of surveillance cameras, therefore they need a scalable surveillance system. The `}{`Enterprise edition`}{` of Kerberos is a licensed service which allows you to operate a video surveillance cluster (Kubernetes) on-premise or in the cloud (AWS/GCP/Azure).`}

\n

{`The Open Source and Enterprise edition are significantly different from a source code point of view. The `}{`Enterprise edition`}{` is a complete rewrite of the Open Source version, and got all the best practices we discovered over the years implemented. Both version are and will remain updated in the future.`}

\n

{`Cloud`}

\n

{`When installing a Kerberos agent inside your local network, it's possible to review your activity by using the agent's web interface. By its nature, you will not be able to access the web interface from the cloud (outside your local network). On top of that, the Kerberos agent doesn't come with a consolidated overview. This means that you will need to open multiple web interfaces, one for each connected surveillance camera. To simplify and resolve all of these challenges, `}{`Kerberos Cloud`}{` was developed. Read more about the `}{`different features and functions of Kerberos Cloud here`}{`.`}

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-65439ff883bcb2669dd4fcb155646686.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-65439ff883bcb2669dd4fcb155646686.json index e21b971..c795b1c 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-65439ff883bcb2669dd4fcb155646686.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-65439ff883bcb2669dd4fcb155646686.json @@ -1 +1 @@ -{"expireTime":9007200841014163000,"key":"gatsby-plugin-mdx-entire-payload-7e099ff5f2afa09bb9a54d66cb1f9503-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Introduction","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Start by installing a Kubernetes cluster. This can be done on one of the hyperscalers (","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":88,"offset":322},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"AWS","position":{"start":{"line":12,"column":90,"offset":324},"end":{"line":12,"column":93,"offset":327},"indent":[]}}],"position":{"start":{"line":12,"column":88,"offset":322},"end":{"line":12,"column":95,"offset":329},"indent":[]}},{"type":"text","value":", ","position":{"start":{"line":12,"column":95,"offset":329},"end":{"line":12,"column":97,"offset":331},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"GCP","position":{"start":{"line":12,"column":99,"offset":333},"end":{"line":12,"column":102,"offset":336},"indent":[]}}],"position":{"start":{"line":12,"column":97,"offset":331},"end":{"line":12,"column":104,"offset":338},"indent":[]}},{"type":"text","value":" or ","position":{"start":{"line":12,"column":104,"offset":338},"end":{"line":12,"column":108,"offset":342},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Azure","position":{"start":{"line":12,"column":110,"offset":344},"end":{"line":12,"column":115,"offset":349},"indent":[]}}],"position":{"start":{"line":12,"column":108,"offset":342},"end":{"line":12,"column":117,"offset":351},"indent":[]}},{"type":"text","value":"),\ncloud providers (Digital Ocean, Scaleway, etc) or on-premise in your own private network.","position":{"start":{"line":12,"column":117,"offset":351},"end":{"line":13,"column":90,"offset":443},"indent":[1]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":13,"column":90,"offset":443},"indent":[1]}},{"type":"jsx","value":"
\n
\n

","position":{"start":{"line":15,"column":1,"offset":445},"end":{"line":17,"column":11,"offset":647},"indent":[1,1]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":19,"column":3,"offset":651},"end":{"line":19,"column":15,"offset":663},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":649},"end":{"line":19,"column":15,"offset":663},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before setting up Kerberos Enterprise, some configuration needs to happen. First thing that we need to do is setting up the RBAC permissions (Role Based Access Control). We need to enable this to be able to query specific endpoints from the Kubernetes API. By default these endpoints are locked, so we need to unlock them.","position":{"start":{"line":21,"column":1,"offset":665},"end":{"line":21,"column":323,"offset":987},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":665},"end":{"line":21,"column":323,"offset":987},"indent":[]}},{"type":"jsx","value":"
\n
\n

","position":{"start":{"line":23,"column":1,"offset":989},"end":{"line":25,"column":11,"offset":1191},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"First clone the configrations from our Github repo.","position":{"start":{"line":27,"column":1,"offset":1193},"end":{"line":27,"column":52,"offset":1244},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1193},"end":{"line":27,"column":52,"offset":1244},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"git clone https://github.com/kerberos-io/enterprise\ncd enterprise-factory","position":{"start":{"line":29,"column":1,"offset":1246},"end":{"line":30,"column":26,"offset":1327},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"Next go into the directory and execute the first Kubernetes configuration file ","position":{"start":{"line":32,"column":1,"offset":1329},"end":{"line":32,"column":80,"offset":1408},"indent":[]}},{"type":"inlineCode","value":"clusterrole.yaml","position":{"start":{"line":32,"column":80,"offset":1408},"end":{"line":32,"column":98,"offset":1426},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":32,"column":98,"offset":1426},"end":{"line":32,"column":99,"offset":1427},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":1329},"end":{"line":32,"column":99,"offset":1427},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"kubectl create -f ./yaml/factory/clusterrole.yaml","position":{"start":{"line":34,"column":1,"offset":1429},"end":{"line":34,"column":54,"offset":1482},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This will make several actions inside your cluster available. We need this to be able to create deployments from the factory web app.","position":{"start":{"line":36,"column":1,"offset":1484},"end":{"line":36,"column":134,"offset":1617},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":1484},"end":{"line":36,"column":134,"offset":1617},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Helm","position":{"start":{"line":38,"column":4,"offset":1622},"end":{"line":38,"column":8,"offset":1626},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":1619},"end":{"line":38,"column":8,"offset":1626},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Next we will install a couple of dependencies which are required for Kerberos Enterprise. ","position":{"start":{"line":40,"column":1,"offset":1628},"end":{"line":40,"column":91,"offset":1718},"indent":[]}},{"type":"link","title":null,"url":"https://helm.sh/","children":[{"type":"strong","children":[{"type":"text","value":"Helm","position":{"start":{"line":40,"column":94,"offset":1721},"end":{"line":40,"column":98,"offset":1725},"indent":[]}}],"position":{"start":{"line":40,"column":92,"offset":1719},"end":{"line":40,"column":100,"offset":1727},"indent":[]}}],"position":{"start":{"line":40,"column":91,"offset":1718},"end":{"line":40,"column":119,"offset":1746},"indent":[]}},{"type":"text","value":" is a package manager for Kubernetes, it helps you setting up services more easily (this could be a MQTT broker, a database, etc).\nInstead of writing yaml files for every service we need, we use so called ","position":{"start":{"line":40,"column":119,"offset":1746},"end":{"line":41,"column":75,"offset":1951},"indent":[1]}},{"type":"strong","children":[{"type":"text","value":"Charts","position":{"start":{"line":41,"column":77,"offset":1953},"end":{"line":41,"column":83,"offset":1959},"indent":[]}}],"position":{"start":{"line":41,"column":75,"offset":1951},"end":{"line":41,"column":85,"offset":1961},"indent":[]}},{"type":"text","value":" (libraries), that you can reuse and configure the,\nwith the appropriate settings.","position":{"start":{"line":41,"column":85,"offset":1961},"end":{"line":42,"column":31,"offset":2043},"indent":[1]}}],"position":{"start":{"line":40,"column":1,"offset":1628},"end":{"line":42,"column":31,"offset":2043},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Use one of the preferred OS package managers to install the Helm client:","position":{"start":{"line":44,"column":1,"offset":2045},"end":{"line":44,"column":73,"offset":2117},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":2045},"end":{"line":44,"column":73,"offset":2117},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"brew install helm\n\nchoco install kubernetes-helm\n\nscoop install helm\n\ngofish install helm","position":{"start":{"line":46,"column":1,"offset":2119},"end":{"line":52,"column":24,"offset":2224},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Initiate helm","position":{"start":{"line":54,"column":5,"offset":2230},"end":{"line":54,"column":18,"offset":2243},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2226},"end":{"line":54,"column":18,"offset":2243},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When you've installed the Helm client, we need to use it to initiate Helm (also called the Tiller service) inside your cluster.\nTiller is what they call the server component of Helm.","position":{"start":{"line":56,"column":1,"offset":2245},"end":{"line":57,"column":55,"offset":2427},"indent":[1]}}],"position":{"start":{"line":56,"column":1,"offset":2245},"end":{"line":57,"column":55,"offset":2427},"indent":[1]}},{"type":"code","lang":null,"meta":null,"value":"kubectl create serviceaccount tiller --namespace kube-system\nkubectl create -f ./yaml/factory/tiller-clusterrolebinding.yaml\nhelm init --service-account tiller","position":{"start":{"line":59,"column":1,"offset":2429},"end":{"line":61,"column":39,"offset":2600},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now you have installed ","position":{"start":{"line":63,"column":1,"offset":2602},"end":{"line":63,"column":24,"offset":2625},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Helm","position":{"start":{"line":63,"column":26,"offset":2627},"end":{"line":63,"column":30,"offset":2631},"indent":[]}}],"position":{"start":{"line":63,"column":24,"offset":2625},"end":{"line":63,"column":32,"offset":2633},"indent":[]}},{"type":"text","value":" inside your cluster we can move on by installing the dependencies.","position":{"start":{"line":63,"column":32,"offset":2633},"end":{"line":63,"column":99,"offset":2700},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2602},"end":{"line":63,"column":99,"offset":2700},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Traefik","position":{"start":{"line":65,"column":4,"offset":2705},"end":{"line":65,"column":11,"offset":2712},"indent":[]}}],"position":{"start":{"line":65,"column":1,"offset":2702},"end":{"line":65,"column":11,"offset":2712},"indent":[]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://containo.us/traefik/","children":[{"type":"strong","children":[{"type":"text","value":"Traefik","position":{"start":{"line":67,"column":4,"offset":2717},"end":{"line":67,"column":11,"offset":2724},"indent":[]}}],"position":{"start":{"line":67,"column":2,"offset":2715},"end":{"line":67,"column":13,"offset":2726},"indent":[]}}],"position":{"start":{"line":67,"column":1,"offset":2714},"end":{"line":67,"column":44,"offset":2757},"indent":[]}},{"type":"text","value":" is a reverse proxy and load balancer which allows you to\nexpose your deployments more easily. Kerberos uses Traefik to expose it's APIs more easily.","position":{"start":{"line":67,"column":44,"offset":2757},"end":{"line":68,"column":92,"offset":2906},"indent":[1]}}],"position":{"start":{"line":67,"column":1,"offset":2714},"end":{"line":68,"column":92,"offset":2906},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"By executing following helm command, we will install traefik and link it to a specific DNS name. Open the traefik values file, ","position":{"start":{"line":70,"column":1,"offset":2908},"end":{"line":70,"column":128,"offset":3035},"indent":[]}},{"type":"inlineCode","value":"yaml/traefik/values.yaml","position":{"start":{"line":70,"column":128,"offset":3035},"end":{"line":70,"column":154,"offset":3061},"indent":[]}},{"type":"text","value":", and update the DNS name to your own domain.","position":{"start":{"line":70,"column":154,"offset":3061},"end":{"line":70,"column":199,"offset":3106},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":2908},"end":{"line":70,"column":199,"offset":3106},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":" dashboard:\n enabled: true\n--> domain: traefik.domain.com\n serviceType: NodePort\n rbac:\n enabled: true","position":{"start":{"line":72,"column":1,"offset":3108},"end":{"line":77,"column":26,"offset":3259},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Execute the ","position":{"start":{"line":79,"column":1,"offset":3261},"end":{"line":79,"column":13,"offset":3273},"indent":[]}},{"type":"inlineCode","value":"helm install","position":{"start":{"line":79,"column":13,"offset":3273},"end":{"line":79,"column":27,"offset":3287},"indent":[]}},{"type":"text","value":" command.","position":{"start":{"line":79,"column":27,"offset":3287},"end":{"line":79,"column":36,"offset":3296},"indent":[]}}],"position":{"start":{"line":79,"column":1,"offset":3261},"end":{"line":79,"column":36,"offset":3296},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"helm install --name traefik -f ./yaml/traefik/values.yaml stable/traefik","position":{"start":{"line":81,"column":1,"offset":3298},"end":{"line":81,"column":77,"offset":3374},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"After installation you should have an IP attached to traefik service, look for it by executing the ","position":{"start":{"line":83,"column":1,"offset":3376},"end":{"line":83,"column":100,"offset":3475},"indent":[]}},{"type":"inlineCode","value":"get service","position":{"start":{"line":83,"column":100,"offset":3475},"end":{"line":83,"column":113,"offset":3488},"indent":[]}},{"type":"text","value":" command. You will see the ip address in the ","position":{"start":{"line":83,"column":113,"offset":3488},"end":{"line":83,"column":158,"offset":3533},"indent":[]}},{"type":"inlineCode","value":"EXTERNAL-IP","position":{"start":{"line":83,"column":158,"offset":3533},"end":{"line":83,"column":171,"offset":3546},"indent":[]}},{"type":"text","value":" attribute.","position":{"start":{"line":83,"column":171,"offset":3546},"end":{"line":83,"column":182,"offset":3557},"indent":[]}}],"position":{"start":{"line":83,"column":1,"offset":3376},"end":{"line":83,"column":182,"offset":3557},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"kubectl get svc\n\n NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE\n kubernetes ClusterIP 10.0.0.1 443/TCP 36h\n--> traefik LoadBalancer 10.0.27.93 40.114.168.96 443:31623/TCP,80:31804/TCP 35h\n traefik-dashboard NodePort 10.0.252.6 80:31146/TCP 35h","position":{"start":{"line":85,"column":1,"offset":3559},"end":{"line":90,"column":115,"offset":4039},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your DNS provider and link the domain you've configured in the first step ","position":{"start":{"line":92,"column":1,"offset":4041},"end":{"line":92,"column":81,"offset":4121},"indent":[]}},{"type":"inlineCode","value":"traefik.domain.com","position":{"start":{"line":92,"column":81,"offset":4121},"end":{"line":92,"column":101,"offset":4141},"indent":[]}},{"type":"text","value":" to the IP address of the ","position":{"start":{"line":92,"column":101,"offset":4141},"end":{"line":92,"column":127,"offset":4167},"indent":[]}},{"type":"inlineCode","value":"EXTERNAL-IP","position":{"start":{"line":92,"column":127,"offset":4167},"end":{"line":92,"column":140,"offset":4180},"indent":[]}},{"type":"text","value":" attribute.","position":{"start":{"line":92,"column":140,"offset":4180},"end":{"line":92,"column":151,"offset":4191},"indent":[]}}],"position":{"start":{"line":92,"column":1,"offset":4041},"end":{"line":92,"column":151,"offset":4191},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When browsing to ","position":{"start":{"line":94,"column":1,"offset":4193},"end":{"line":94,"column":18,"offset":4210},"indent":[]}},{"type":"inlineCode","value":"traefik.domain.com","position":{"start":{"line":94,"column":18,"offset":4210},"end":{"line":94,"column":38,"offset":4230},"indent":[]}},{"type":"text","value":", you should see the traefik dashboard showing up.","position":{"start":{"line":94,"column":38,"offset":4230},"end":{"line":94,"column":88,"offset":4280},"indent":[]}}],"position":{"start":{"line":94,"column":1,"offset":4193},"end":{"line":94,"column":88,"offset":4280},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"MongoDB","position":{"start":{"line":96,"column":4,"offset":4285},"end":{"line":96,"column":11,"offset":4292},"indent":[]}}],"position":{"start":{"line":96,"column":1,"offset":4282},"end":{"line":96,"column":11,"offset":4292},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Enterprise generates configurations for every surveillance camera that you want to monitor. These configuration files\nare stored centrally in a MongoDB database. Therefore we use Helm to install a MongoDB instance inside your cluster.","position":{"start":{"line":98,"column":1,"offset":4294},"end":{"line":99,"column":117,"offset":4537},"indent":[1]}}],"position":{"start":{"line":98,"column":1,"offset":4294},"end":{"line":99,"column":117,"offset":4537},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"Have a look into the ","position":{"start":{"line":101,"column":1,"offset":4539},"end":{"line":101,"column":22,"offset":4560},"indent":[]}},{"type":"inlineCode","value":"yaml/mongodb/values.yaml","position":{"start":{"line":101,"column":22,"offset":4560},"end":{"line":101,"column":48,"offset":4586},"indent":[]}},{"type":"text","value":" file, you will find plenty of configurations for your mongodb instance. You will also find the attribute where you can change the root password of mongodb.","position":{"start":{"line":101,"column":48,"offset":4586},"end":{"line":101,"column":204,"offset":4742},"indent":[]}}],"position":{"start":{"line":101,"column":1,"offset":4539},"end":{"line":101,"column":204,"offset":4742},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"helm repo add bitnami https://charts.bitnami.com/bitnami\nhelm install --name mongodb bitnami/mongodb --values ./yaml/mongodb/values.yaml","position":{"start":{"line":104,"column":1,"offset":4745},"end":{"line":105,"column":84,"offset":4889},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Factory","position":{"start":{"line":108,"column":4,"offset":4895},"end":{"line":108,"column":11,"offset":4902},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":4892},"end":{"line":108,"column":11,"offset":4902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The last step is to install the factory service. Kerberos Enterprise is managed through an application which we call the ","position":{"start":{"line":110,"column":1,"offset":4904},"end":{"line":110,"column":122,"offset":5025},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Factory","position":{"start":{"line":110,"column":124,"offset":5027},"end":{"line":110,"column":131,"offset":5034},"indent":[]}}],"position":{"start":{"line":110,"column":122,"offset":5025},"end":{"line":110,"column":133,"offset":5036},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":110,"column":133,"offset":5036},"end":{"line":110,"column":134,"offset":5037},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4904},"end":{"line":110,"column":134,"offset":5037},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Factory is responsible for initiating\nthe deployments inside your cluster. These deployments is what we also call (similar to the Open Source version) the machinery.","position":{"start":{"line":112,"column":1,"offset":5039},"end":{"line":113,"column":128,"offset":5208},"indent":[1]}}],"position":{"start":{"line":112,"column":1,"offset":5039},"end":{"line":113,"column":128,"offset":5208},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"The Factory comes as a web interface which provides you with a tool to update your machineries easily, monitor them, etc. The Factory is the central portal for managing Kerberos Enterprise inside your cluster.","position":{"start":{"line":115,"column":1,"offset":5210},"end":{"line":115,"column":210,"offset":5419},"indent":[]}}],"position":{"start":{"line":115,"column":1,"offset":5210},"end":{"line":115,"column":210,"offset":5419},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before installing the Factory service, open the ","position":{"start":{"line":117,"column":1,"offset":5421},"end":{"line":117,"column":49,"offset":5469},"indent":[]}},{"type":"inlineCode","value":"yaml/factory/kubernetes.yaml","position":{"start":{"line":117,"column":49,"offset":5469},"end":{"line":117,"column":79,"offset":5499},"indent":[]}},{"type":"text","value":" configuration file. At the bottom file you will find two endpoints, similar to the traefik config file. Update the domain names to your own domain, and add these to your DNS server (pointing to the same IP as the traefik EXTERNAL-IP).","position":{"start":{"line":117,"column":79,"offset":5499},"end":{"line":117,"column":314,"offset":5734},"indent":[]}}],"position":{"start":{"line":117,"column":1,"offset":5421},"end":{"line":117,"column":314,"offset":5734},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":" spec:\n rules:\n--> - host: factory.domain.com\n http:\n paths:\n - path: /\n backend:\n serviceName: factory\n servicePort: 80\n--> - host: api.factory.domain.com\n http:\n paths:\n - path: /\n backend:\n serviceName: factory\n servicePort: 8081","position":{"start":{"line":119,"column":1,"offset":5736},"end":{"line":134,"column":36,"offset":6168},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have corrected the DNS names, install the Factory service inside your cluster.","position":{"start":{"line":136,"column":1,"offset":6170},"end":{"line":136,"column":88,"offset":6257},"indent":[]}}],"position":{"start":{"line":136,"column":1,"offset":6170},"end":{"line":136,"column":88,"offset":6257},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"kubectl apply -f ./yaml/factory/kubernetes.yaml","position":{"start":{"line":138,"column":1,"offset":6259},"end":{"line":138,"column":52,"offset":6310},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Test out configuration","position":{"start":{"line":141,"column":3,"offset":6315},"end":{"line":141,"column":25,"offset":6337},"indent":[]}}],"position":{"start":{"line":141,"column":1,"offset":6313},"end":{"line":141,"column":25,"offset":6337},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If everything worked out as expected, you should now have following services in your cluster:","position":{"start":{"line":143,"column":1,"offset":6339},"end":{"line":143,"column":94,"offset":6432},"indent":[]}}],"position":{"start":{"line":143,"column":1,"offset":6339},"end":{"line":143,"column":94,"offset":6432},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"MongoDB","position":{"start":{"line":145,"column":5,"offset":6438},"end":{"line":145,"column":12,"offset":6445},"indent":[]}}],"position":{"start":{"line":145,"column":5,"offset":6438},"end":{"line":145,"column":12,"offset":6445},"indent":[]}}],"position":{"start":{"line":145,"column":1,"offset":6434},"end":{"line":145,"column":12,"offset":6445},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Traefik","position":{"start":{"line":146,"column":5,"offset":6450},"end":{"line":146,"column":12,"offset":6457},"indent":[]}}],"position":{"start":{"line":146,"column":5,"offset":6450},"end":{"line":146,"column":12,"offset":6457},"indent":[]}}],"position":{"start":{"line":146,"column":1,"offset":6446},"end":{"line":146,"column":12,"offset":6457},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Factory","position":{"start":{"line":147,"column":5,"offset":6462},"end":{"line":147,"column":12,"offset":6469},"indent":[]}}],"position":{"start":{"line":147,"column":5,"offset":6462},"end":{"line":147,"column":12,"offset":6469},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6458},"end":{"line":147,"column":12,"offset":6469},"indent":[]}}],"position":{"start":{"line":145,"column":1,"offset":6434},"end":{"line":147,"column":12,"offset":6469},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"It should look like this.","position":{"start":{"line":149,"column":1,"offset":6471},"end":{"line":149,"column":26,"offset":6496},"indent":[]}}],"position":{"start":{"line":149,"column":1,"offset":6471},"end":{"line":149,"column":26,"offset":6496},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"$ kubectl get pods\nNAME READY STATUS RESTARTS AGE\nfactory-6f5c877d7c-hf77p 1/1 Running 0 2d11h\nmongodb-55566dc65c-xgmns 2/2 Running 0 4d13h\ntraefik-7d566ccc47-mwslb 1/1 Running 0 4d12h","position":{"start":{"line":151,"column":1,"offset":6498},"end":{"line":155,"column":73,"offset":6810},"indent":[1,1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Access the system","position":{"start":{"line":157,"column":4,"offset":6815},"end":{"line":157,"column":21,"offset":6832},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6812},"end":{"line":157,"column":21,"offset":6832},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is configured correctly your cluster and DNS, you should be able to setup the Factory application. By navigating to the Factory domain ","position":{"start":{"line":159,"column":1,"offset":6834},"end":{"line":159,"column":152,"offset":6985},"indent":[]}},{"type":"inlineCode","value":"factory.domain.com","position":{"start":{"line":159,"column":152,"offset":6985},"end":{"line":159,"column":172,"offset":7005},"indent":[]}},{"type":"text","value":" in your browser you will see the Factory login page showing up.","position":{"start":{"line":159,"column":172,"offset":7005},"end":{"line":159,"column":236,"offset":7069},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":6834},"end":{"line":159,"column":236,"offset":7069},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-loginpage.png","alt":"Factory","position":{"start":{"line":161,"column":1,"offset":7071},"end":{"line":161,"column":71,"offset":7141},"indent":[]}}],"position":{"start":{"line":161,"column":1,"offset":7071},"end":{"line":161,"column":71,"offset":7141},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":164,"column":1,"offset":7144},"end":{"line":164,"column":31,"offset":7174},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":164,"column":31,"offset":7174}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Introduction`}

\n

{`Start by installing a Kubernetes cluster. This can be done on one of the hyperscalers (`}{`AWS`}{`, `}{`GCP`}{` or `}{`Azure`}{`),\ncloud providers (Digital Ocean, Scaleway, etc) or on-premise in your own private network.`}

\n
\n
\n

\n

{`Installation`}

\n

{`Before setting up Kerberos Enterprise, some configuration needs to happen. First thing that we need to do is setting up the RBAC permissions (Role Based Access Control). We need to enable this to be able to query specific endpoints from the Kubernetes API. By default these endpoints are locked, so we need to unlock them.`}

\n
\n
\n

\n

{`First clone the configrations from our Github repo.`}

\n
{`git clone https://github.com/kerberos-io/enterprise`}{`\n`}{`cd enterprise-factory`}
\n

{`Next go into the directory and execute the first Kubernetes configuration file `}{`clusterrole.yaml`}{`.`}

\n
{`kubectl create -f ./yaml/factory/clusterrole.yaml`}
\n

{`This will make several actions inside your cluster available. We need this to be able to create deployments from the factory web app.`}

\n

{`Helm`}

\n

{`Next we will install a couple of dependencies which are required for Kerberos Enterprise. `}{`Helm`}{` is a package manager for Kubernetes, it helps you setting up services more easily (this could be a MQTT broker, a database, etc).\nInstead of writing yaml files for every service we need, we use so called `}{`Charts`}{` (libraries), that you can reuse and configure the,\nwith the appropriate settings.`}

\n

{`Use one of the preferred OS package managers to install the Helm client:`}

\n
{`brew install helm`}{`\n`}{`\n`}{`choco install kubernetes-helm`}{`\n`}{`\n`}{`scoop install helm`}{`\n`}{`\n`}{`gofish install helm`}
\n

{`Initiate helm`}

\n

{`When you've installed the Helm client, we need to use it to initiate Helm (also called the Tiller service) inside your cluster.\nTiller is what they call the server component of Helm.`}

\n
{`kubectl create serviceaccount tiller --namespace kube-system`}{`\n`}{`kubectl create -f ./yaml/factory/tiller-clusterrolebinding.yaml`}{`\n`}{`helm init --service-account tiller`}
\n

{`Now you have installed `}{`Helm`}{` inside your cluster we can move on by installing the dependencies.`}

\n

{`Traefik`}

\n

{`Traefik`}{` is a reverse proxy and load balancer which allows you to\nexpose your deployments more easily. Kerberos uses Traefik to expose it's APIs more easily.`}

\n

{`By executing following helm command, we will install traefik and link it to a specific DNS name. Open the traefik values file, `}{`yaml/traefik/values.yaml`}{`, and update the DNS name to your own domain.`}

\n
{`    dashboard:`}{`\n`}{`      enabled: true`}{`\n`}{`-->   domain: traefik.domain.com`}{`\n`}{`      serviceType: NodePort`}{`\n`}{`    rbac:`}{`\n`}{`        enabled: true`}
\n

{`Execute the `}{`helm install`}{` command.`}

\n
{`helm install --name traefik -f ./yaml/traefik/values.yaml stable/traefik`}
\n

{`After installation you should have an IP attached to traefik service, look for it by executing the `}{`get service`}{` command. You will see the ip address in the `}{`EXTERNAL-IP`}{` attribute.`}

\n
{`kubectl get svc`}{`\n`}{`\n`}{`    NAME                        TYPE           CLUSTER-IP     EXTERNAL-IP     PORT(S)                      AGE`}{`\n`}{`    kubernetes                  ClusterIP      10.0.0.1                 443/TCP                      36h`}{`\n`}{`--> traefik                     LoadBalancer   10.0.27.93     40.114.168.96   443:31623/TCP,80:31804/TCP   35h`}{`\n`}{`    traefik-dashboard           NodePort       10.0.252.6               80:31146/TCP                 35h`}
\n

{`Go to your DNS provider and link the domain you've configured in the first step `}{`traefik.domain.com`}{` to the IP address of the `}{`EXTERNAL-IP`}{` attribute.`}

\n

{`When browsing to `}{`traefik.domain.com`}{`, you should see the traefik dashboard showing up.`}

\n

{`MongoDB`}

\n

{`Kerberos Enterprise generates configurations for every surveillance camera that you want to monitor. These configuration files\nare stored centrally in a MongoDB database. Therefore we use Helm to install a MongoDB instance inside your cluster.`}

\n

{`Have a look into the `}{`yaml/mongodb/values.yaml`}{` file, you will find plenty of configurations for your mongodb instance. You will also find the attribute where you can change the root password of mongodb.`}

\n
{`helm repo add bitnami https://charts.bitnami.com/bitnami`}{`\n`}{`helm install --name mongodb bitnami/mongodb --values ./yaml/mongodb/values.yaml`}
\n

{`Factory`}

\n

{`The last step is to install the factory service. Kerberos Enterprise is managed through an application which we call the `}{`Factory`}{`.`}

\n

{`The Factory is responsible for initiating\nthe deployments inside your cluster. These deployments is what we also call (similar to the Open Source version) the machinery.`}

\n

{`The Factory comes as a web interface which provides you with a tool to update your machineries easily, monitor them, etc. The Factory is the central portal for managing Kerberos Enterprise inside your cluster.`}

\n

{`Before installing the Factory service, open the `}{`yaml/factory/kubernetes.yaml`}{` configuration file. At the bottom file you will find two endpoints, similar to the traefik config file. Update the domain names to your own domain, and add these to your DNS server (pointing to the same IP as the traefik EXTERNAL-IP).`}

\n
{`    spec:`}{`\n`}{`      rules:`}{`\n`}{`-->   - host: factory.domain.com`}{`\n`}{`        http:`}{`\n`}{`          paths:`}{`\n`}{`          - path: /`}{`\n`}{`            backend:`}{`\n`}{`              serviceName: factory`}{`\n`}{`              servicePort: 80`}{`\n`}{`-->   - host: api.factory.domain.com`}{`\n`}{`        http:`}{`\n`}{`          paths:`}{`\n`}{`          - path: /`}{`\n`}{`            backend:`}{`\n`}{`              serviceName: factory`}{`\n`}{`              servicePort: 8081`}
\n

{`Once you have corrected the DNS names, install the Factory service inside your cluster.`}

\n
{`kubectl apply -f ./yaml/factory/kubernetes.yaml`}
\n

{`Test out configuration`}

\n

{`If everything worked out as expected, you should now have following services in your cluster:`}

\n
    \n
  • {`MongoDB`}
  • \n
  • {`Traefik`}
  • \n
  • {`Factory`}
  • \n
\n

{`It should look like this.`}

\n
{`$ kubectl get pods`}{`\n`}{`NAME                              READY   STATUS    RESTARTS   AGE`}{`\n`}{`factory-6f5c877d7c-hf77p          1/1     Running   0          2d11h`}{`\n`}{`mongodb-55566dc65c-xgmns          2/2     Running   0          4d13h`}{`\n`}{`traefik-7d566ccc47-mwslb          1/1     Running   0          4d12h`}
\n

{`Access the system`}

\n

{`Once everything is configured correctly your cluster and DNS, you should be able to setup the Factory application. By navigating to the Factory domain `}{`factory.domain.com`}{` in your browser you will see the Factory login page showing up.`}

\n

\"Factory\"

\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974265000,"key":"gatsby-plugin-mdx-entire-payload-7e099ff5f2afa09bb9a54d66cb1f9503-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Introduction","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Start by installing a Kubernetes cluster. This can be done on one of the hyperscalers (","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":88,"offset":322},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"AWS","position":{"start":{"line":12,"column":90,"offset":324},"end":{"line":12,"column":93,"offset":327},"indent":[]}}],"position":{"start":{"line":12,"column":88,"offset":322},"end":{"line":12,"column":95,"offset":329},"indent":[]}},{"type":"text","value":", ","position":{"start":{"line":12,"column":95,"offset":329},"end":{"line":12,"column":97,"offset":331},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"GCP","position":{"start":{"line":12,"column":99,"offset":333},"end":{"line":12,"column":102,"offset":336},"indent":[]}}],"position":{"start":{"line":12,"column":97,"offset":331},"end":{"line":12,"column":104,"offset":338},"indent":[]}},{"type":"text","value":" or ","position":{"start":{"line":12,"column":104,"offset":338},"end":{"line":12,"column":108,"offset":342},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Azure","position":{"start":{"line":12,"column":110,"offset":344},"end":{"line":12,"column":115,"offset":349},"indent":[]}}],"position":{"start":{"line":12,"column":108,"offset":342},"end":{"line":12,"column":117,"offset":351},"indent":[]}},{"type":"text","value":"),\ncloud providers (Digital Ocean, Scaleway, etc) or on-premise in your own private network.","position":{"start":{"line":12,"column":117,"offset":351},"end":{"line":13,"column":90,"offset":443},"indent":[1]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":13,"column":90,"offset":443},"indent":[1]}},{"type":"jsx","value":"
\n
\n

","position":{"start":{"line":15,"column":1,"offset":445},"end":{"line":17,"column":11,"offset":647},"indent":[1,1]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":19,"column":3,"offset":651},"end":{"line":19,"column":15,"offset":663},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":649},"end":{"line":19,"column":15,"offset":663},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before setting up Kerberos Enterprise, some configuration needs to happen. First thing that we need to do is setting up the RBAC permissions (Role Based Access Control). We need to enable this to be able to query specific endpoints from the Kubernetes API. By default these endpoints are locked, so we need to unlock them.","position":{"start":{"line":21,"column":1,"offset":665},"end":{"line":21,"column":323,"offset":987},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":665},"end":{"line":21,"column":323,"offset":987},"indent":[]}},{"type":"jsx","value":"
\n
\n

","position":{"start":{"line":23,"column":1,"offset":989},"end":{"line":25,"column":11,"offset":1191},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"First clone the configrations from our Github repo.","position":{"start":{"line":27,"column":1,"offset":1193},"end":{"line":27,"column":52,"offset":1244},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1193},"end":{"line":27,"column":52,"offset":1244},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"git clone https://github.com/kerberos-io/enterprise\ncd enterprise-factory","position":{"start":{"line":29,"column":1,"offset":1246},"end":{"line":30,"column":26,"offset":1327},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"Next go into the directory and execute the first Kubernetes configuration file ","position":{"start":{"line":32,"column":1,"offset":1329},"end":{"line":32,"column":80,"offset":1408},"indent":[]}},{"type":"inlineCode","value":"clusterrole.yaml","position":{"start":{"line":32,"column":80,"offset":1408},"end":{"line":32,"column":98,"offset":1426},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":32,"column":98,"offset":1426},"end":{"line":32,"column":99,"offset":1427},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":1329},"end":{"line":32,"column":99,"offset":1427},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"kubectl create -f ./yaml/factory/clusterrole.yaml","position":{"start":{"line":34,"column":1,"offset":1429},"end":{"line":34,"column":54,"offset":1482},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This will make several actions inside your cluster available. We need this to be able to create deployments from the factory web app.","position":{"start":{"line":36,"column":1,"offset":1484},"end":{"line":36,"column":134,"offset":1617},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":1484},"end":{"line":36,"column":134,"offset":1617},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Helm","position":{"start":{"line":38,"column":4,"offset":1622},"end":{"line":38,"column":8,"offset":1626},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":1619},"end":{"line":38,"column":8,"offset":1626},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Next we will install a couple of dependencies which are required for Kerberos Enterprise. ","position":{"start":{"line":40,"column":1,"offset":1628},"end":{"line":40,"column":91,"offset":1718},"indent":[]}},{"type":"link","title":null,"url":"https://helm.sh/","children":[{"type":"strong","children":[{"type":"text","value":"Helm","position":{"start":{"line":40,"column":94,"offset":1721},"end":{"line":40,"column":98,"offset":1725},"indent":[]}}],"position":{"start":{"line":40,"column":92,"offset":1719},"end":{"line":40,"column":100,"offset":1727},"indent":[]}}],"position":{"start":{"line":40,"column":91,"offset":1718},"end":{"line":40,"column":119,"offset":1746},"indent":[]}},{"type":"text","value":" is a package manager for Kubernetes, it helps you setting up services more easily (this could be a MQTT broker, a database, etc).\nInstead of writing yaml files for every service we need, we use so called ","position":{"start":{"line":40,"column":119,"offset":1746},"end":{"line":41,"column":75,"offset":1951},"indent":[1]}},{"type":"strong","children":[{"type":"text","value":"Charts","position":{"start":{"line":41,"column":77,"offset":1953},"end":{"line":41,"column":83,"offset":1959},"indent":[]}}],"position":{"start":{"line":41,"column":75,"offset":1951},"end":{"line":41,"column":85,"offset":1961},"indent":[]}},{"type":"text","value":" (libraries), that you can reuse and configure the,\nwith the appropriate settings.","position":{"start":{"line":41,"column":85,"offset":1961},"end":{"line":42,"column":31,"offset":2043},"indent":[1]}}],"position":{"start":{"line":40,"column":1,"offset":1628},"end":{"line":42,"column":31,"offset":2043},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Use one of the preferred OS package managers to install the Helm client:","position":{"start":{"line":44,"column":1,"offset":2045},"end":{"line":44,"column":73,"offset":2117},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":2045},"end":{"line":44,"column":73,"offset":2117},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"brew install helm\n\nchoco install kubernetes-helm\n\nscoop install helm\n\ngofish install helm","position":{"start":{"line":46,"column":1,"offset":2119},"end":{"line":52,"column":24,"offset":2224},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Initiate helm","position":{"start":{"line":54,"column":5,"offset":2230},"end":{"line":54,"column":18,"offset":2243},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2226},"end":{"line":54,"column":18,"offset":2243},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When you've installed the Helm client, we need to use it to initiate Helm (also called the Tiller service) inside your cluster.\nTiller is what they call the server component of Helm.","position":{"start":{"line":56,"column":1,"offset":2245},"end":{"line":57,"column":55,"offset":2427},"indent":[1]}}],"position":{"start":{"line":56,"column":1,"offset":2245},"end":{"line":57,"column":55,"offset":2427},"indent":[1]}},{"type":"code","lang":null,"meta":null,"value":"kubectl create serviceaccount tiller --namespace kube-system\nkubectl create -f ./yaml/factory/tiller-clusterrolebinding.yaml\nhelm init --service-account tiller","position":{"start":{"line":59,"column":1,"offset":2429},"end":{"line":61,"column":39,"offset":2600},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now you have installed ","position":{"start":{"line":63,"column":1,"offset":2602},"end":{"line":63,"column":24,"offset":2625},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Helm","position":{"start":{"line":63,"column":26,"offset":2627},"end":{"line":63,"column":30,"offset":2631},"indent":[]}}],"position":{"start":{"line":63,"column":24,"offset":2625},"end":{"line":63,"column":32,"offset":2633},"indent":[]}},{"type":"text","value":" inside your cluster we can move on by installing the dependencies.","position":{"start":{"line":63,"column":32,"offset":2633},"end":{"line":63,"column":99,"offset":2700},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2602},"end":{"line":63,"column":99,"offset":2700},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Traefik","position":{"start":{"line":65,"column":4,"offset":2705},"end":{"line":65,"column":11,"offset":2712},"indent":[]}}],"position":{"start":{"line":65,"column":1,"offset":2702},"end":{"line":65,"column":11,"offset":2712},"indent":[]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://containo.us/traefik/","children":[{"type":"strong","children":[{"type":"text","value":"Traefik","position":{"start":{"line":67,"column":4,"offset":2717},"end":{"line":67,"column":11,"offset":2724},"indent":[]}}],"position":{"start":{"line":67,"column":2,"offset":2715},"end":{"line":67,"column":13,"offset":2726},"indent":[]}}],"position":{"start":{"line":67,"column":1,"offset":2714},"end":{"line":67,"column":44,"offset":2757},"indent":[]}},{"type":"text","value":" is a reverse proxy and load balancer which allows you to\nexpose your deployments more easily. Kerberos uses Traefik to expose it's APIs more easily.","position":{"start":{"line":67,"column":44,"offset":2757},"end":{"line":68,"column":92,"offset":2906},"indent":[1]}}],"position":{"start":{"line":67,"column":1,"offset":2714},"end":{"line":68,"column":92,"offset":2906},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"By executing following helm command, we will install traefik and link it to a specific DNS name. Open the traefik values file, ","position":{"start":{"line":70,"column":1,"offset":2908},"end":{"line":70,"column":128,"offset":3035},"indent":[]}},{"type":"inlineCode","value":"yaml/traefik/values.yaml","position":{"start":{"line":70,"column":128,"offset":3035},"end":{"line":70,"column":154,"offset":3061},"indent":[]}},{"type":"text","value":", and update the DNS name to your own domain.","position":{"start":{"line":70,"column":154,"offset":3061},"end":{"line":70,"column":199,"offset":3106},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":2908},"end":{"line":70,"column":199,"offset":3106},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":" dashboard:\n enabled: true\n--> domain: traefik.domain.com\n serviceType: NodePort\n rbac:\n enabled: true","position":{"start":{"line":72,"column":1,"offset":3108},"end":{"line":77,"column":26,"offset":3259},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Execute the ","position":{"start":{"line":79,"column":1,"offset":3261},"end":{"line":79,"column":13,"offset":3273},"indent":[]}},{"type":"inlineCode","value":"helm install","position":{"start":{"line":79,"column":13,"offset":3273},"end":{"line":79,"column":27,"offset":3287},"indent":[]}},{"type":"text","value":" command.","position":{"start":{"line":79,"column":27,"offset":3287},"end":{"line":79,"column":36,"offset":3296},"indent":[]}}],"position":{"start":{"line":79,"column":1,"offset":3261},"end":{"line":79,"column":36,"offset":3296},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"helm install --name traefik -f ./yaml/traefik/values.yaml stable/traefik","position":{"start":{"line":81,"column":1,"offset":3298},"end":{"line":81,"column":77,"offset":3374},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"After installation you should have an IP attached to traefik service, look for it by executing the ","position":{"start":{"line":83,"column":1,"offset":3376},"end":{"line":83,"column":100,"offset":3475},"indent":[]}},{"type":"inlineCode","value":"get service","position":{"start":{"line":83,"column":100,"offset":3475},"end":{"line":83,"column":113,"offset":3488},"indent":[]}},{"type":"text","value":" command. You will see the ip address in the ","position":{"start":{"line":83,"column":113,"offset":3488},"end":{"line":83,"column":158,"offset":3533},"indent":[]}},{"type":"inlineCode","value":"EXTERNAL-IP","position":{"start":{"line":83,"column":158,"offset":3533},"end":{"line":83,"column":171,"offset":3546},"indent":[]}},{"type":"text","value":" attribute.","position":{"start":{"line":83,"column":171,"offset":3546},"end":{"line":83,"column":182,"offset":3557},"indent":[]}}],"position":{"start":{"line":83,"column":1,"offset":3376},"end":{"line":83,"column":182,"offset":3557},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"kubectl get svc\n\n NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE\n kubernetes ClusterIP 10.0.0.1 443/TCP 36h\n--> traefik LoadBalancer 10.0.27.93 40.114.168.96 443:31623/TCP,80:31804/TCP 35h\n traefik-dashboard NodePort 10.0.252.6 80:31146/TCP 35h","position":{"start":{"line":85,"column":1,"offset":3559},"end":{"line":90,"column":115,"offset":4039},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your DNS provider and link the domain you've configured in the first step ","position":{"start":{"line":92,"column":1,"offset":4041},"end":{"line":92,"column":81,"offset":4121},"indent":[]}},{"type":"inlineCode","value":"traefik.domain.com","position":{"start":{"line":92,"column":81,"offset":4121},"end":{"line":92,"column":101,"offset":4141},"indent":[]}},{"type":"text","value":" to the IP address of the ","position":{"start":{"line":92,"column":101,"offset":4141},"end":{"line":92,"column":127,"offset":4167},"indent":[]}},{"type":"inlineCode","value":"EXTERNAL-IP","position":{"start":{"line":92,"column":127,"offset":4167},"end":{"line":92,"column":140,"offset":4180},"indent":[]}},{"type":"text","value":" attribute.","position":{"start":{"line":92,"column":140,"offset":4180},"end":{"line":92,"column":151,"offset":4191},"indent":[]}}],"position":{"start":{"line":92,"column":1,"offset":4041},"end":{"line":92,"column":151,"offset":4191},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When browsing to ","position":{"start":{"line":94,"column":1,"offset":4193},"end":{"line":94,"column":18,"offset":4210},"indent":[]}},{"type":"inlineCode","value":"traefik.domain.com","position":{"start":{"line":94,"column":18,"offset":4210},"end":{"line":94,"column":38,"offset":4230},"indent":[]}},{"type":"text","value":", you should see the traefik dashboard showing up.","position":{"start":{"line":94,"column":38,"offset":4230},"end":{"line":94,"column":88,"offset":4280},"indent":[]}}],"position":{"start":{"line":94,"column":1,"offset":4193},"end":{"line":94,"column":88,"offset":4280},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"MongoDB","position":{"start":{"line":96,"column":4,"offset":4285},"end":{"line":96,"column":11,"offset":4292},"indent":[]}}],"position":{"start":{"line":96,"column":1,"offset":4282},"end":{"line":96,"column":11,"offset":4292},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Enterprise generates configurations for every surveillance camera that you want to monitor. These configuration files\nare stored centrally in a MongoDB database. Therefore we use Helm to install a MongoDB instance inside your cluster.","position":{"start":{"line":98,"column":1,"offset":4294},"end":{"line":99,"column":117,"offset":4537},"indent":[1]}}],"position":{"start":{"line":98,"column":1,"offset":4294},"end":{"line":99,"column":117,"offset":4537},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"Have a look into the ","position":{"start":{"line":101,"column":1,"offset":4539},"end":{"line":101,"column":22,"offset":4560},"indent":[]}},{"type":"inlineCode","value":"yaml/mongodb/values.yaml","position":{"start":{"line":101,"column":22,"offset":4560},"end":{"line":101,"column":48,"offset":4586},"indent":[]}},{"type":"text","value":" file, you will find plenty of configurations for your mongodb instance. You will also find the attribute where you can change the root password of mongodb.","position":{"start":{"line":101,"column":48,"offset":4586},"end":{"line":101,"column":204,"offset":4742},"indent":[]}}],"position":{"start":{"line":101,"column":1,"offset":4539},"end":{"line":101,"column":204,"offset":4742},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"helm repo add bitnami https://charts.bitnami.com/bitnami\nhelm install --name mongodb bitnami/mongodb --values ./yaml/mongodb/values.yaml","position":{"start":{"line":104,"column":1,"offset":4745},"end":{"line":105,"column":84,"offset":4889},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Factory","position":{"start":{"line":108,"column":4,"offset":4895},"end":{"line":108,"column":11,"offset":4902},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":4892},"end":{"line":108,"column":11,"offset":4902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The last step is to install the factory service. Kerberos Enterprise is managed through an application which we call the ","position":{"start":{"line":110,"column":1,"offset":4904},"end":{"line":110,"column":122,"offset":5025},"indent":[]}},{"type":"strong","children":[{"type":"text","value":"Factory","position":{"start":{"line":110,"column":124,"offset":5027},"end":{"line":110,"column":131,"offset":5034},"indent":[]}}],"position":{"start":{"line":110,"column":122,"offset":5025},"end":{"line":110,"column":133,"offset":5036},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":110,"column":133,"offset":5036},"end":{"line":110,"column":134,"offset":5037},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4904},"end":{"line":110,"column":134,"offset":5037},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Factory is responsible for initiating\nthe deployments inside your cluster. These deployments is what we also call (similar to the Open Source version) the machinery.","position":{"start":{"line":112,"column":1,"offset":5039},"end":{"line":113,"column":128,"offset":5208},"indent":[1]}}],"position":{"start":{"line":112,"column":1,"offset":5039},"end":{"line":113,"column":128,"offset":5208},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"The Factory comes as a web interface which provides you with a tool to update your machineries easily, monitor them, etc. The Factory is the central portal for managing Kerberos Enterprise inside your cluster.","position":{"start":{"line":115,"column":1,"offset":5210},"end":{"line":115,"column":210,"offset":5419},"indent":[]}}],"position":{"start":{"line":115,"column":1,"offset":5210},"end":{"line":115,"column":210,"offset":5419},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before installing the Factory service, open the ","position":{"start":{"line":117,"column":1,"offset":5421},"end":{"line":117,"column":49,"offset":5469},"indent":[]}},{"type":"inlineCode","value":"yaml/factory/kubernetes.yaml","position":{"start":{"line":117,"column":49,"offset":5469},"end":{"line":117,"column":79,"offset":5499},"indent":[]}},{"type":"text","value":" configuration file. At the bottom file you will find two endpoints, similar to the traefik config file. Update the domain names to your own domain, and add these to your DNS server (pointing to the same IP as the traefik EXTERNAL-IP).","position":{"start":{"line":117,"column":79,"offset":5499},"end":{"line":117,"column":314,"offset":5734},"indent":[]}}],"position":{"start":{"line":117,"column":1,"offset":5421},"end":{"line":117,"column":314,"offset":5734},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":" spec:\n rules:\n--> - host: factory.domain.com\n http:\n paths:\n - path: /\n backend:\n serviceName: factory\n servicePort: 80\n--> - host: api.factory.domain.com\n http:\n paths:\n - path: /\n backend:\n serviceName: factory\n servicePort: 8081","position":{"start":{"line":119,"column":1,"offset":5736},"end":{"line":134,"column":36,"offset":6168},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have corrected the DNS names, install the Factory service inside your cluster.","position":{"start":{"line":136,"column":1,"offset":6170},"end":{"line":136,"column":88,"offset":6257},"indent":[]}}],"position":{"start":{"line":136,"column":1,"offset":6170},"end":{"line":136,"column":88,"offset":6257},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"kubectl apply -f ./yaml/factory/kubernetes.yaml","position":{"start":{"line":138,"column":1,"offset":6259},"end":{"line":138,"column":52,"offset":6310},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Test out configuration","position":{"start":{"line":141,"column":3,"offset":6315},"end":{"line":141,"column":25,"offset":6337},"indent":[]}}],"position":{"start":{"line":141,"column":1,"offset":6313},"end":{"line":141,"column":25,"offset":6337},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If everything worked out as expected, you should now have following services in your cluster:","position":{"start":{"line":143,"column":1,"offset":6339},"end":{"line":143,"column":94,"offset":6432},"indent":[]}}],"position":{"start":{"line":143,"column":1,"offset":6339},"end":{"line":143,"column":94,"offset":6432},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"MongoDB","position":{"start":{"line":145,"column":5,"offset":6438},"end":{"line":145,"column":12,"offset":6445},"indent":[]}}],"position":{"start":{"line":145,"column":5,"offset":6438},"end":{"line":145,"column":12,"offset":6445},"indent":[]}}],"position":{"start":{"line":145,"column":1,"offset":6434},"end":{"line":145,"column":12,"offset":6445},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Traefik","position":{"start":{"line":146,"column":5,"offset":6450},"end":{"line":146,"column":12,"offset":6457},"indent":[]}}],"position":{"start":{"line":146,"column":5,"offset":6450},"end":{"line":146,"column":12,"offset":6457},"indent":[]}}],"position":{"start":{"line":146,"column":1,"offset":6446},"end":{"line":146,"column":12,"offset":6457},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Factory","position":{"start":{"line":147,"column":5,"offset":6462},"end":{"line":147,"column":12,"offset":6469},"indent":[]}}],"position":{"start":{"line":147,"column":5,"offset":6462},"end":{"line":147,"column":12,"offset":6469},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6458},"end":{"line":147,"column":12,"offset":6469},"indent":[]}}],"position":{"start":{"line":145,"column":1,"offset":6434},"end":{"line":147,"column":12,"offset":6469},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"It should look like this.","position":{"start":{"line":149,"column":1,"offset":6471},"end":{"line":149,"column":26,"offset":6496},"indent":[]}}],"position":{"start":{"line":149,"column":1,"offset":6471},"end":{"line":149,"column":26,"offset":6496},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"$ kubectl get pods\nNAME READY STATUS RESTARTS AGE\nfactory-6f5c877d7c-hf77p 1/1 Running 0 2d11h\nmongodb-55566dc65c-xgmns 2/2 Running 0 4d13h\ntraefik-7d566ccc47-mwslb 1/1 Running 0 4d12h","position":{"start":{"line":151,"column":1,"offset":6498},"end":{"line":155,"column":73,"offset":6810},"indent":[1,1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Access the system","position":{"start":{"line":157,"column":4,"offset":6815},"end":{"line":157,"column":21,"offset":6832},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6812},"end":{"line":157,"column":21,"offset":6832},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is configured correctly your cluster and DNS, you should be able to setup the Factory application. By navigating to the Factory domain ","position":{"start":{"line":159,"column":1,"offset":6834},"end":{"line":159,"column":152,"offset":6985},"indent":[]}},{"type":"inlineCode","value":"factory.domain.com","position":{"start":{"line":159,"column":152,"offset":6985},"end":{"line":159,"column":172,"offset":7005},"indent":[]}},{"type":"text","value":" in your browser you will see the Factory login page showing up.","position":{"start":{"line":159,"column":172,"offset":7005},"end":{"line":159,"column":236,"offset":7069},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":6834},"end":{"line":159,"column":236,"offset":7069},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/factory/kerberos-factory-loginpage.png","alt":"Factory","position":{"start":{"line":161,"column":1,"offset":7071},"end":{"line":161,"column":71,"offset":7141},"indent":[]}}],"position":{"start":{"line":161,"column":1,"offset":7071},"end":{"line":161,"column":71,"offset":7141},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":164,"column":1,"offset":7144},"end":{"line":164,"column":31,"offset":7174},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":164,"column":31,"offset":7174}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Introduction`}

\n

{`Start by installing a Kubernetes cluster. This can be done on one of the hyperscalers (`}{`AWS`}{`, `}{`GCP`}{` or `}{`Azure`}{`),\ncloud providers (Digital Ocean, Scaleway, etc) or on-premise in your own private network.`}

\n
\n
\n

\n

{`Installation`}

\n

{`Before setting up Kerberos Enterprise, some configuration needs to happen. First thing that we need to do is setting up the RBAC permissions (Role Based Access Control). We need to enable this to be able to query specific endpoints from the Kubernetes API. By default these endpoints are locked, so we need to unlock them.`}

\n
\n
\n

\n

{`First clone the configrations from our Github repo.`}

\n
{`git clone https://github.com/kerberos-io/enterprise`}{`\n`}{`cd enterprise-factory`}
\n

{`Next go into the directory and execute the first Kubernetes configuration file `}{`clusterrole.yaml`}{`.`}

\n
{`kubectl create -f ./yaml/factory/clusterrole.yaml`}
\n

{`This will make several actions inside your cluster available. We need this to be able to create deployments from the factory web app.`}

\n

{`Helm`}

\n

{`Next we will install a couple of dependencies which are required for Kerberos Enterprise. `}{`Helm`}{` is a package manager for Kubernetes, it helps you setting up services more easily (this could be a MQTT broker, a database, etc).\nInstead of writing yaml files for every service we need, we use so called `}{`Charts`}{` (libraries), that you can reuse and configure the,\nwith the appropriate settings.`}

\n

{`Use one of the preferred OS package managers to install the Helm client:`}

\n
{`brew install helm`}{`\n`}{`\n`}{`choco install kubernetes-helm`}{`\n`}{`\n`}{`scoop install helm`}{`\n`}{`\n`}{`gofish install helm`}
\n

{`Initiate helm`}

\n

{`When you've installed the Helm client, we need to use it to initiate Helm (also called the Tiller service) inside your cluster.\nTiller is what they call the server component of Helm.`}

\n
{`kubectl create serviceaccount tiller --namespace kube-system`}{`\n`}{`kubectl create -f ./yaml/factory/tiller-clusterrolebinding.yaml`}{`\n`}{`helm init --service-account tiller`}
\n

{`Now you have installed `}{`Helm`}{` inside your cluster we can move on by installing the dependencies.`}

\n

{`Traefik`}

\n

{`Traefik`}{` is a reverse proxy and load balancer which allows you to\nexpose your deployments more easily. Kerberos uses Traefik to expose it's APIs more easily.`}

\n

{`By executing following helm command, we will install traefik and link it to a specific DNS name. Open the traefik values file, `}{`yaml/traefik/values.yaml`}{`, and update the DNS name to your own domain.`}

\n
{`    dashboard:`}{`\n`}{`      enabled: true`}{`\n`}{`-->   domain: traefik.domain.com`}{`\n`}{`      serviceType: NodePort`}{`\n`}{`    rbac:`}{`\n`}{`        enabled: true`}
\n

{`Execute the `}{`helm install`}{` command.`}

\n
{`helm install --name traefik -f ./yaml/traefik/values.yaml stable/traefik`}
\n

{`After installation you should have an IP attached to traefik service, look for it by executing the `}{`get service`}{` command. You will see the ip address in the `}{`EXTERNAL-IP`}{` attribute.`}

\n
{`kubectl get svc`}{`\n`}{`\n`}{`    NAME                        TYPE           CLUSTER-IP     EXTERNAL-IP     PORT(S)                      AGE`}{`\n`}{`    kubernetes                  ClusterIP      10.0.0.1                 443/TCP                      36h`}{`\n`}{`--> traefik                     LoadBalancer   10.0.27.93     40.114.168.96   443:31623/TCP,80:31804/TCP   35h`}{`\n`}{`    traefik-dashboard           NodePort       10.0.252.6               80:31146/TCP                 35h`}
\n

{`Go to your DNS provider and link the domain you've configured in the first step `}{`traefik.domain.com`}{` to the IP address of the `}{`EXTERNAL-IP`}{` attribute.`}

\n

{`When browsing to `}{`traefik.domain.com`}{`, you should see the traefik dashboard showing up.`}

\n

{`MongoDB`}

\n

{`Kerberos Enterprise generates configurations for every surveillance camera that you want to monitor. These configuration files\nare stored centrally in a MongoDB database. Therefore we use Helm to install a MongoDB instance inside your cluster.`}

\n

{`Have a look into the `}{`yaml/mongodb/values.yaml`}{` file, you will find plenty of configurations for your mongodb instance. You will also find the attribute where you can change the root password of mongodb.`}

\n
{`helm repo add bitnami https://charts.bitnami.com/bitnami`}{`\n`}{`helm install --name mongodb bitnami/mongodb --values ./yaml/mongodb/values.yaml`}
\n

{`Factory`}

\n

{`The last step is to install the factory service. Kerberos Enterprise is managed through an application which we call the `}{`Factory`}{`.`}

\n

{`The Factory is responsible for initiating\nthe deployments inside your cluster. These deployments is what we also call (similar to the Open Source version) the machinery.`}

\n

{`The Factory comes as a web interface which provides you with a tool to update your machineries easily, monitor them, etc. The Factory is the central portal for managing Kerberos Enterprise inside your cluster.`}

\n

{`Before installing the Factory service, open the `}{`yaml/factory/kubernetes.yaml`}{` configuration file. At the bottom file you will find two endpoints, similar to the traefik config file. Update the domain names to your own domain, and add these to your DNS server (pointing to the same IP as the traefik EXTERNAL-IP).`}

\n
{`    spec:`}{`\n`}{`      rules:`}{`\n`}{`-->   - host: factory.domain.com`}{`\n`}{`        http:`}{`\n`}{`          paths:`}{`\n`}{`          - path: /`}{`\n`}{`            backend:`}{`\n`}{`              serviceName: factory`}{`\n`}{`              servicePort: 80`}{`\n`}{`-->   - host: api.factory.domain.com`}{`\n`}{`        http:`}{`\n`}{`          paths:`}{`\n`}{`          - path: /`}{`\n`}{`            backend:`}{`\n`}{`              serviceName: factory`}{`\n`}{`              servicePort: 8081`}
\n

{`Once you have corrected the DNS names, install the Factory service inside your cluster.`}

\n
{`kubectl apply -f ./yaml/factory/kubernetes.yaml`}
\n

{`Test out configuration`}

\n

{`If everything worked out as expected, you should now have following services in your cluster:`}

\n
    \n
  • {`MongoDB`}
  • \n
  • {`Traefik`}
  • \n
  • {`Factory`}
  • \n
\n

{`It should look like this.`}

\n
{`$ kubectl get pods`}{`\n`}{`NAME                              READY   STATUS    RESTARTS   AGE`}{`\n`}{`factory-6f5c877d7c-hf77p          1/1     Running   0          2d11h`}{`\n`}{`mongodb-55566dc65c-xgmns          2/2     Running   0          4d13h`}{`\n`}{`traefik-7d566ccc47-mwslb          1/1     Running   0          4d12h`}
\n

{`Access the system`}

\n

{`Once everything is configured correctly your cluster and DNS, you should be able to setup the Factory application. By navigating to the Factory domain `}{`factory.domain.com`}{` in your browser you will see the Factory login page showing up.`}

\n

\"Factory\"

\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-66f83e093accc4831e0aea1e3a1af16b.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-66f83e093accc4831e0aea1e3a1af16b.json new file mode 100644 index 0000000..bb8d9a3 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-66f83e093accc4831e0aea1e3a1af16b.json @@ -0,0 +1 @@ +{"expireTime":9007200842319761000,"key":"gatsby-plugin-mdx-entire-payload-2e5da7b3e737a392b1c320c46971fd3d-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4679},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":80,"offset":4760},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4760},"end":{"line":107,"column":101,"offset":4781},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4781},"end":{"line":107,"column":162,"offset":4842},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":162,"offset":4842},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4844},"end":{"line":112,"column":4,"offset":4933},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4938},"end":{"line":114,"column":10,"offset":4944},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4935},"end":{"line":114,"column":10,"offset":4944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":339,"offset":5284},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":340,"offset":5285},"end":{"line":116,"column":354,"offset":5299},"indent":[]}}],"position":{"start":{"line":116,"column":339,"offset":5284},"end":{"line":116,"column":390,"offset":5335},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":390,"offset":5335},"end":{"line":116,"column":391,"offset":5336},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":391,"offset":5336},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5342},"end":{"line":118,"column":18,"offset":5355},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5338},"end":{"line":118,"column":18,"offset":5355},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5357},"end":{"line":120,"column":50,"offset":5406},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5412},"end":{"line":122,"column":11,"offset":5418},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5408},"end":{"line":122,"column":11,"offset":5418},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":64,"offset":5483},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5484},"end":{"line":124,"column":86,"offset":5505},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5483},"end":{"line":124,"column":126,"offset":5545},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5545},"end":{"line":124,"column":127,"offset":5546},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":127,"offset":5546},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5552},"end":{"line":126,"column":26,"offset":5573},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5548},"end":{"line":126,"column":26,"offset":5573},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5702},"end":{"line":132,"column":4,"offset":5741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5931},"end":{"line":138,"column":4,"offset":6009},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6165},"end":{"line":145,"column":4,"offset":6312},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6414},"end":{"line":152,"column":4,"offset":6483},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6489},"end":{"line":154,"column":12,"offset":6496},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6485},"end":{"line":154,"column":12,"offset":6496},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example:","position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":65,"offset":6562},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":65,"offset":6562},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":157,"column":3,"offset":6565},"end":{"line":157,"column":25,"offset":6587},"indent":[]}}],"position":{"start":{"line":157,"column":3,"offset":6565},"end":{"line":157,"column":25,"offset":6587},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6563},"end":{"line":157,"column":25,"offset":6587},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":158,"column":3,"offset":6590},"end":{"line":158,"column":59,"offset":6646},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6590},"end":{"line":158,"column":59,"offset":6646},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6588},"end":{"line":158,"column":59,"offset":6646},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6563},"end":{"line":158,"column":59,"offset":6646},"indent":[1]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name kerberos-camera1 \\\n-p 80:80 -p 8889:8889 \\\n-v ~/config:/etc/opt/kerberosio/config \\\n-v ~/capture:/etc/opt/kerberosio/capture \\\n-v ~/logs:/etc/opt/kerberosio/logs \\https://medium.com/@cedricverst/kerberos-io-the-road-to-docker-8e048a480241\n-v ~/webconfig:/var/www/web/config \\\n-d kerberos/kerberos","position":{"start":{"line":160,"column":1,"offset":6648},"end":{"line":168,"column":4,"offset":6972},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.","position":{"start":{"line":170,"column":1,"offset":6974},"end":{"line":170,"column":87,"offset":7060},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":6974},"end":{"line":170,"column":87,"offset":7060},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://medium.com/@cedricverst/kerberos-io-the-road-to-docker-8e048a480241","children":[{"type":"text","value":"Kerberos.io — the road to Docker","position":{"start":{"line":171,"column":4,"offset":7064},"end":{"line":171,"column":36,"offset":7096},"indent":[]}}],"position":{"start":{"line":171,"column":3,"offset":7063},"end":{"line":171,"column":114,"offset":7174},"indent":[]}}],"position":{"start":{"line":171,"column":3,"offset":7063},"end":{"line":171,"column":114,"offset":7174},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":7061},"end":{"line":171,"column":114,"offset":7174},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":7061},"end":{"line":171,"column":114,"offset":7174},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":174,"column":4,"offset":7180},"end":{"line":174,"column":10,"offset":7186},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7177},"end":{"line":174,"column":10,"offset":7186},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.","position":{"start":{"line":176,"column":1,"offset":7188},"end":{"line":176,"column":310,"offset":7497},"indent":[]}}],"position":{"start":{"line":176,"column":1,"offset":7188},"end":{"line":176,"column":310,"offset":7497},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To fill the gap, regarding the latter, we can rely on another solution called ","position":{"start":{"line":178,"column":1,"offset":7499},"end":{"line":178,"column":79,"offset":7577},"indent":[]}},{"type":"link","title":null,"url":"https://balena.io","children":[{"type":"text","value":"Balena.io","position":{"start":{"line":178,"column":80,"offset":7578},"end":{"line":178,"column":89,"offset":7587},"indent":[]}}],"position":{"start":{"line":178,"column":79,"offset":7577},"end":{"line":178,"column":109,"offset":7607},"indent":[]}},{"type":"text","value":". Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).","position":{"start":{"line":178,"column":109,"offset":7607},"end":{"line":178,"column":386,"offset":7884},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7499},"end":{"line":178,"column":386,"offset":7884},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On top of supporting a lot of boars,","position":{"start":{"line":180,"column":1,"offset":7886},"end":{"line":180,"column":37,"offset":7922},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7886},"end":{"line":180,"column":37,"offset":7922},"indent":[]}},{"type":"thematicBreak","position":{"start":{"line":182,"column":1,"offset":7924},"end":{"line":182,"column":4,"offset":7927},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":184,"column":3,"offset":7931},"end":{"line":184,"column":11,"offset":7939},"indent":[]}}],"position":{"start":{"line":184,"column":1,"offset":7929},"end":{"line":184,"column":11,"offset":7939},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":186,"column":1,"offset":7941},"end":{"line":186,"column":133,"offset":8073},"indent":[]}}],"position":{"start":{"line":186,"column":1,"offset":7941},"end":{"line":186,"column":133,"offset":8073},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":188,"column":4,"offset":8078},"end":{"line":188,"column":12,"offset":8086},"indent":[]}}],"position":{"start":{"line":188,"column":1,"offset":8075},"end":{"line":188,"column":12,"offset":8086},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":190,"column":1,"offset":8088},"end":{"line":190,"column":193,"offset":8280},"indent":[]}}],"position":{"start":{"line":190,"column":1,"offset":8088},"end":{"line":190,"column":193,"offset":8280},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":192,"column":4,"offset":8285},"end":{"line":192,"column":62,"offset":8343},"indent":[]}}],"position":{"start":{"line":192,"column":4,"offset":8285},"end":{"line":192,"column":62,"offset":8343},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":8282},"end":{"line":192,"column":62,"offset":8343},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":193,"column":4,"offset":8347},"end":{"line":193,"column":69,"offset":8412},"indent":[]}}],"position":{"start":{"line":193,"column":4,"offset":8347},"end":{"line":193,"column":69,"offset":8412},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8344},"end":{"line":193,"column":69,"offset":8412},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":8282},"end":{"line":193,"column":69,"offset":8412},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":195,"column":1,"offset":8414},"end":{"line":195,"column":99,"offset":8512},"indent":[]}}],"position":{"start":{"line":195,"column":1,"offset":8414},"end":{"line":195,"column":99,"offset":8512},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":197,"column":5,"offset":8518},"end":{"line":197,"column":14,"offset":8527},"indent":[]}}],"position":{"start":{"line":197,"column":1,"offset":8514},"end":{"line":197,"column":14,"offset":8527},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":199,"column":1,"offset":8529},"end":{"line":199,"column":71,"offset":8599},"indent":[]}}],"position":{"start":{"line":199,"column":1,"offset":8529},"end":{"line":199,"column":71,"offset":8599},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":201,"column":3,"offset":8603},"end":{"line":201,"column":47,"offset":8647},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":201,"column":47,"offset":8647},"end":{"line":201,"column":79,"offset":8679},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":201,"column":79,"offset":8679},"end":{"line":201,"column":198,"offset":8798},"indent":[]}}],"position":{"start":{"line":201,"column":3,"offset":8603},"end":{"line":201,"column":198,"offset":8798},"indent":[]}}],"position":{"start":{"line":201,"column":1,"offset":8601},"end":{"line":201,"column":198,"offset":8798},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":203,"column":1,"offset":8800},"end":{"line":205,"column":4,"offset":8863},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":207,"column":5,"offset":8869},"end":{"line":207,"column":14,"offset":8878},"indent":[]}}],"position":{"start":{"line":207,"column":1,"offset":8865},"end":{"line":207,"column":14,"offset":8878},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":209,"column":1,"offset":8880},"end":{"line":209,"column":56,"offset":8935},"indent":[]}}],"position":{"start":{"line":209,"column":1,"offset":8880},"end":{"line":209,"column":56,"offset":8935},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":210,"column":3,"offset":8938},"end":{"line":210,"column":52,"offset":8987},"indent":[]}}],"position":{"start":{"line":210,"column":3,"offset":8938},"end":{"line":210,"column":52,"offset":8987},"indent":[]}}],"position":{"start":{"line":210,"column":3,"offset":8938},"end":{"line":210,"column":52,"offset":8987},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":8936},"end":{"line":210,"column":52,"offset":8987},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":212,"column":1,"offset":8989},"end":{"line":212,"column":3,"offset":8991},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":212,"column":3,"offset":8991},"end":{"line":212,"column":9,"offset":8997},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":212,"column":9,"offset":8997},"end":{"line":212,"column":223,"offset":9211},"indent":[]}}],"position":{"start":{"line":212,"column":1,"offset":8989},"end":{"line":212,"column":223,"offset":9211},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":214,"column":3,"offset":9215},"end":{"line":214,"column":159,"offset":9371},"indent":[]}}],"position":{"start":{"line":214,"column":3,"offset":9215},"end":{"line":214,"column":159,"offset":9371},"indent":[]}}],"position":{"start":{"line":214,"column":1,"offset":9213},"end":{"line":214,"column":159,"offset":9371},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":216,"column":1,"offset":9373},"end":{"line":219,"column":4,"offset":9550},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":221,"column":1,"offset":9552},"end":{"line":221,"column":160,"offset":9711},"indent":[]}}],"position":{"start":{"line":221,"column":1,"offset":9552},"end":{"line":221,"column":160,"offset":9711},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":223,"column":3,"offset":9715},"end":{"line":223,"column":31,"offset":9743},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":223,"column":31,"offset":9743},"end":{"line":223,"column":101,"offset":9813},"indent":[]}}],"position":{"start":{"line":223,"column":3,"offset":9715},"end":{"line":223,"column":101,"offset":9813},"indent":[]}}],"position":{"start":{"line":223,"column":1,"offset":9713},"end":{"line":223,"column":101,"offset":9813},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":225,"column":1,"offset":9815},"end":{"line":228,"column":4,"offset":9987},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":230,"column":1,"offset":9989},"end":{"line":230,"column":73,"offset":10061},"indent":[]}}],"position":{"start":{"line":230,"column":1,"offset":9989},"end":{"line":230,"column":73,"offset":10061},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":233,"column":3,"offset":10066},"end":{"line":233,"column":31,"offset":10094},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":233,"column":31,"offset":10094},"end":{"line":233,"column":101,"offset":10164},"indent":[]}}],"position":{"start":{"line":233,"column":3,"offset":10066},"end":{"line":233,"column":101,"offset":10164},"indent":[]}}],"position":{"start":{"line":233,"column":1,"offset":10064},"end":{"line":233,"column":101,"offset":10164},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":235,"column":1,"offset":10166},"end":{"line":238,"column":4,"offset":10338},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":240,"column":1,"offset":10340},"end":{"line":240,"column":62,"offset":10401},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":240,"column":63,"offset":10402},"end":{"line":240,"column":75,"offset":10414},"indent":[]}}],"position":{"start":{"line":240,"column":62,"offset":10401},"end":{"line":240,"column":143,"offset":10482},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":240,"column":143,"offset":10482},"end":{"line":240,"column":150,"offset":10489},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":240,"column":150,"offset":10489},"end":{"line":240,"column":169,"offset":10508},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":240,"column":169,"offset":10508},"end":{"line":240,"column":170,"offset":10509},"indent":[]}}],"position":{"start":{"line":240,"column":1,"offset":10340},"end":{"line":240,"column":170,"offset":10509},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":242,"column":1,"offset":10511},"end":{"line":244,"column":4,"offset":10538},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":246,"column":1,"offset":10540},"end":{"line":246,"column":58,"offset":10597},"indent":[]}}],"position":{"start":{"line":246,"column":1,"offset":10540},"end":{"line":246,"column":58,"offset":10597},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":248,"column":1,"offset":10599},"end":{"line":251,"column":4,"offset":10669},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":253,"column":5,"offset":10675},"end":{"line":253,"column":8,"offset":10678},"indent":[]}}],"position":{"start":{"line":253,"column":1,"offset":10671},"end":{"line":253,"column":8,"offset":10678},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":255,"column":1,"offset":10680},"end":{"line":255,"column":280,"offset":10959},"indent":[]}}],"position":{"start":{"line":255,"column":1,"offset":10680},"end":{"line":255,"column":280,"offset":10959},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":257,"column":1,"offset":10961},"end":{"line":257,"column":37,"offset":10997},"indent":[]}}],"position":{"start":{"line":257,"column":1,"offset":10961},"end":{"line":257,"column":37,"offset":10997},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":259,"column":1,"offset":10999},"end":{"line":261,"column":4,"offset":11172},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":263,"column":1,"offset":11174},"end":{"line":263,"column":25,"offset":11198},"indent":[]}}],"position":{"start":{"line":263,"column":1,"offset":11174},"end":{"line":263,"column":25,"offset":11198},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":265,"column":1,"offset":11200},"end":{"line":268,"column":4,"offset":11304},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":270,"column":1,"offset":11306},"end":{"line":270,"column":118,"offset":11423},"indent":[]}}],"position":{"start":{"line":270,"column":1,"offset":11306},"end":{"line":270,"column":118,"offset":11423},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":272,"column":1,"offset":11425},"end":{"line":292,"column":4,"offset":11932},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":294,"column":1,"offset":11934},"end":{"line":294,"column":14,"offset":11947},"indent":[]}}],"position":{"start":{"line":294,"column":1,"offset":11934},"end":{"line":294,"column":14,"offset":11947},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":296,"column":1,"offset":11949},"end":{"line":298,"column":4,"offset":11985},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":300,"column":1,"offset":11987},"end":{"line":300,"column":91,"offset":12077},"indent":[]}}],"position":{"start":{"line":300,"column":1,"offset":11987},"end":{"line":300,"column":91,"offset":12077},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":302,"column":1,"offset":12079},"end":{"line":310,"column":4,"offset":12452},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":312,"column":1,"offset":12454},"end":{"line":312,"column":145,"offset":12598},"indent":[]}}],"position":{"start":{"line":312,"column":1,"offset":12454},"end":{"line":312,"column":145,"offset":12598},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":314,"column":5,"offset":12604},"end":{"line":314,"column":17,"offset":12616},"indent":[]}}],"position":{"start":{"line":314,"column":1,"offset":12600},"end":{"line":314,"column":17,"offset":12616},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":316,"column":1,"offset":12618},"end":{"line":316,"column":300,"offset":12917},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12618},"end":{"line":316,"column":300,"offset":12917},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":318,"column":1,"offset":12919},"end":{"line":318,"column":178,"offset":13096},"indent":[]}}],"position":{"start":{"line":318,"column":1,"offset":12919},"end":{"line":318,"column":178,"offset":13096},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":320,"column":1,"offset":13098},"end":{"line":320,"column":48,"offset":13145},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":13098},"end":{"line":320,"column":48,"offset":13145},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":322,"column":1,"offset":13147},"end":{"line":324,"column":4,"offset":13187},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":326,"column":1,"offset":13189},"end":{"line":326,"column":104,"offset":13292},"indent":[]}}],"position":{"start":{"line":326,"column":1,"offset":13189},"end":{"line":326,"column":104,"offset":13292},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":328,"column":1,"offset":13294},"end":{"line":336,"column":4,"offset":13564},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":338,"column":1,"offset":13566},"end":{"line":338,"column":28,"offset":13593},"indent":[]}}],"position":{"start":{"line":338,"column":1,"offset":13566},"end":{"line":338,"column":28,"offset":13593},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":340,"column":1,"offset":13595},"end":{"line":342,"column":4,"offset":13639},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":344,"column":1,"offset":13641},"end":{"line":344,"column":48,"offset":13688},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13641},"end":{"line":344,"column":48,"offset":13688},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":346,"column":1,"offset":13690},"end":{"line":348,"column":4,"offset":13712},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":350,"column":1,"offset":13714},"end":{"line":350,"column":72,"offset":13785},"indent":[]}}],"position":{"start":{"line":350,"column":1,"offset":13714},"end":{"line":350,"column":72,"offset":13785},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":352,"column":1,"offset":13787},"end":{"line":354,"column":4,"offset":13844},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":356,"column":4,"offset":13849},"end":{"line":356,"column":11,"offset":13856},"indent":[]}}],"position":{"start":{"line":356,"column":1,"offset":13846},"end":{"line":356,"column":11,"offset":13856},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":358,"column":1,"offset":13858},"end":{"line":358,"column":283,"offset":14140},"indent":[]}}],"position":{"start":{"line":358,"column":1,"offset":13858},"end":{"line":358,"column":283,"offset":14140},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":360,"column":3,"offset":14144},"end":{"line":360,"column":54,"offset":14195},"indent":[]}}],"position":{"start":{"line":360,"column":3,"offset":14144},"end":{"line":360,"column":54,"offset":14195},"indent":[]}}],"position":{"start":{"line":360,"column":1,"offset":14142},"end":{"line":360,"column":54,"offset":14195},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":362,"column":5,"offset":14201},"end":{"line":362,"column":14,"offset":14210},"indent":[]}}],"position":{"start":{"line":362,"column":1,"offset":14197},"end":{"line":362,"column":14,"offset":14210},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":364,"column":1,"offset":14212},"end":{"line":364,"column":68,"offset":14279},"indent":[]}}],"position":{"start":{"line":364,"column":1,"offset":14212},"end":{"line":364,"column":68,"offset":14279},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":366,"column":1,"offset":14281},"end":{"line":369,"column":4,"offset":14432},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":371,"column":1,"offset":14434},"end":{"line":371,"column":46,"offset":14479},"indent":[]}}],"position":{"start":{"line":371,"column":1,"offset":14434},"end":{"line":371,"column":46,"offset":14479},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":373,"column":3,"offset":14483},"end":{"line":373,"column":103,"offset":14583},"indent":[]}}],"position":{"start":{"line":373,"column":3,"offset":14483},"end":{"line":373,"column":103,"offset":14583},"indent":[]}}],"position":{"start":{"line":373,"column":1,"offset":14481},"end":{"line":373,"column":103,"offset":14583},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":375,"column":1,"offset":14585},"end":{"line":380,"column":4,"offset":14795},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":382,"column":1,"offset":14797},"end":{"line":382,"column":151,"offset":14947},"indent":[]}}],"position":{"start":{"line":382,"column":1,"offset":14797},"end":{"line":382,"column":151,"offset":14947},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":384,"column":3,"offset":14951},"end":{"line":384,"column":22,"offset":14970},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":384,"column":22,"offset":14970},"end":{"line":384,"column":26,"offset":14974},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":384,"column":26,"offset":14974},"end":{"line":384,"column":40,"offset":14988},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":384,"column":40,"offset":14988},"end":{"line":384,"column":50,"offset":14998},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":384,"column":50,"offset":14998},"end":{"line":384,"column":98,"offset":15046},"indent":[]}}],"position":{"start":{"line":384,"column":3,"offset":14951},"end":{"line":384,"column":98,"offset":15046},"indent":[]}}],"position":{"start":{"line":384,"column":1,"offset":14949},"end":{"line":384,"column":98,"offset":15046},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":386,"column":1,"offset":15048},"end":{"line":390,"column":4,"offset":15210},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":392,"column":1,"offset":15212},"end":{"line":392,"column":72,"offset":15283},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":392,"column":72,"offset":15283},"end":{"line":392,"column":84,"offset":15295},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":392,"column":84,"offset":15295},"end":{"line":392,"column":102,"offset":15313},"indent":[]}}],"position":{"start":{"line":392,"column":1,"offset":15212},"end":{"line":392,"column":102,"offset":15313},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":394,"column":1,"offset":15315},"end":{"line":397,"column":4,"offset":15389},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":399,"column":5,"offset":15395},"end":{"line":399,"column":8,"offset":15398},"indent":[]}}],"position":{"start":{"line":399,"column":1,"offset":15391},"end":{"line":399,"column":8,"offset":15398},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":401,"column":1,"offset":15400},"end":{"line":401,"column":176,"offset":15575},"indent":[]}}],"position":{"start":{"line":401,"column":1,"offset":15400},"end":{"line":401,"column":176,"offset":15575},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":403,"column":1,"offset":15577},"end":{"line":410,"column":4,"offset":15874},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":412,"column":1,"offset":15876},"end":{"line":412,"column":60,"offset":15935},"indent":[]}}],"position":{"start":{"line":412,"column":1,"offset":15876},"end":{"line":412,"column":60,"offset":15935},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":414,"column":1,"offset":15937},"end":{"line":418,"column":4,"offset":16063},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":420,"column":1,"offset":16065},"end":{"line":420,"column":63,"offset":16127},"indent":[]}}],"position":{"start":{"line":420,"column":1,"offset":16065},"end":{"line":420,"column":63,"offset":16127},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":422,"column":1,"offset":16129},"end":{"line":442,"column":4,"offset":16636},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":444,"column":1,"offset":16638},"end":{"line":444,"column":99,"offset":16736},"indent":[]}}],"position":{"start":{"line":444,"column":1,"offset":16638},"end":{"line":444,"column":99,"offset":16736},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":446,"column":1,"offset":16738},"end":{"line":449,"column":4,"offset":16840},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":451,"column":1,"offset":16842},"end":{"line":451,"column":37,"offset":16878},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":451,"column":37,"offset":16878},"end":{"line":451,"column":47,"offset":16888},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":451,"column":47,"offset":16888},"end":{"line":451,"column":89,"offset":16930},"indent":[]}}],"position":{"start":{"line":451,"column":1,"offset":16842},"end":{"line":451,"column":89,"offset":16930},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":453,"column":1,"offset":16932},"end":{"line":457,"column":4,"offset":17057},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":459,"column":1,"offset":17059},"end":{"line":459,"column":78,"offset":17136},"indent":[]}}],"position":{"start":{"line":459,"column":1,"offset":17059},"end":{"line":459,"column":78,"offset":17136},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":461,"column":1,"offset":17138},"end":{"line":465,"column":4,"offset":17242},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":467,"column":1,"offset":17244},"end":{"line":467,"column":75,"offset":17318},"indent":[]}}],"position":{"start":{"line":467,"column":1,"offset":17244},"end":{"line":467,"column":75,"offset":17318},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":469,"column":1,"offset":17320},"end":{"line":473,"column":4,"offset":17393},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":475,"column":1,"offset":17395},"end":{"line":475,"column":145,"offset":17539},"indent":[]}}],"position":{"start":{"line":475,"column":1,"offset":17395},"end":{"line":475,"column":145,"offset":17539},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":477,"column":5,"offset":17545},"end":{"line":477,"column":17,"offset":17557},"indent":[]}}],"position":{"start":{"line":477,"column":1,"offset":17541},"end":{"line":477,"column":17,"offset":17557},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":479,"column":1,"offset":17559},"end":{"line":479,"column":300,"offset":17858},"indent":[]}}],"position":{"start":{"line":479,"column":1,"offset":17559},"end":{"line":479,"column":300,"offset":17858},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":481,"column":1,"offset":17860},"end":{"line":481,"column":178,"offset":18037},"indent":[]}}],"position":{"start":{"line":481,"column":1,"offset":17860},"end":{"line":481,"column":178,"offset":18037},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":483,"column":1,"offset":18039},"end":{"line":483,"column":48,"offset":18086},"indent":[]}}],"position":{"start":{"line":483,"column":1,"offset":18039},"end":{"line":483,"column":48,"offset":18086},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":485,"column":1,"offset":18088},"end":{"line":487,"column":4,"offset":18132},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":489,"column":1,"offset":18134},"end":{"line":489,"column":104,"offset":18237},"indent":[]}}],"position":{"start":{"line":489,"column":1,"offset":18134},"end":{"line":489,"column":104,"offset":18237},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":491,"column":1,"offset":18239},"end":{"line":499,"column":4,"offset":18509},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":501,"column":1,"offset":18511},"end":{"line":501,"column":28,"offset":18538},"indent":[]}}],"position":{"start":{"line":501,"column":1,"offset":18511},"end":{"line":501,"column":28,"offset":18538},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":503,"column":1,"offset":18540},"end":{"line":505,"column":4,"offset":18588},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":507,"column":1,"offset":18590},"end":{"line":507,"column":48,"offset":18637},"indent":[]}}],"position":{"start":{"line":507,"column":1,"offset":18590},"end":{"line":507,"column":48,"offset":18637},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":509,"column":1,"offset":18639},"end":{"line":511,"column":4,"offset":18661},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":513,"column":1,"offset":18663},"end":{"line":513,"column":72,"offset":18734},"indent":[]}}],"position":{"start":{"line":513,"column":1,"offset":18663},"end":{"line":513,"column":72,"offset":18734},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":515,"column":1,"offset":18736},"end":{"line":517,"column":4,"offset":18797},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":520,"column":1,"offset":18800},"end":{"line":520,"column":31,"offset":18830},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":520,"column":31,"offset":18830}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example:`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`kerberos`}{`-`}{`camera1`}{` \\\\`}{`\n`}{`-`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/config:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`config`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/capture:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`capture`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/logs:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`logs`}{` \\\\https:`}{`//medium.com/@cedricverst/kerberos-io-the-road-to-docker-8e048a480241`}{`\n`}{`-`}{`v`}{` ~/webconfig:/`}{`var`}{`/`}{`www`}{`/web/config \\\\`}{`\n`}{`-`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.`}

\n \n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.`}

\n

{`To fill the gap, regarding the latter, we can rely on another solution called `}{`Balena.io`}{`. Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).`}

\n

{`On top of supporting a lot of boars,`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-708d54cc04f36632d6530d30f6b9e4d2.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-708d54cc04f36632d6530d30f6b9e4d2.json new file mode 100644 index 0000000..be5706f --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-708d54cc04f36632d6530d30f6b9e4d2.json @@ -0,0 +1 @@ +{"expireTime":9007200842069025000,"key":"gatsby-plugin-mdx-entire-payload-c9339b5a981eb9589efd71404ea0502a-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4679},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":80,"offset":4760},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4760},"end":{"line":107,"column":101,"offset":4781},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4781},"end":{"line":107,"column":162,"offset":4842},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":162,"offset":4842},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4844},"end":{"line":112,"column":4,"offset":4933},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4938},"end":{"line":114,"column":10,"offset":4944},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4935},"end":{"line":114,"column":10,"offset":4944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":339,"offset":5284},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":340,"offset":5285},"end":{"line":116,"column":354,"offset":5299},"indent":[]}}],"position":{"start":{"line":116,"column":339,"offset":5284},"end":{"line":116,"column":390,"offset":5335},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":390,"offset":5335},"end":{"line":116,"column":391,"offset":5336},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":391,"offset":5336},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5342},"end":{"line":118,"column":18,"offset":5355},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5338},"end":{"line":118,"column":18,"offset":5355},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5357},"end":{"line":120,"column":50,"offset":5406},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5412},"end":{"line":122,"column":11,"offset":5418},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5408},"end":{"line":122,"column":11,"offset":5418},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":64,"offset":5483},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5484},"end":{"line":124,"column":86,"offset":5505},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5483},"end":{"line":124,"column":126,"offset":5545},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5545},"end":{"line":124,"column":127,"offset":5546},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":127,"offset":5546},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5552},"end":{"line":126,"column":26,"offset":5573},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5548},"end":{"line":126,"column":26,"offset":5573},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5702},"end":{"line":132,"column":4,"offset":5741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5931},"end":{"line":138,"column":4,"offset":6009},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6165},"end":{"line":145,"column":4,"offset":6312},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6414},"end":{"line":152,"column":4,"offset":6483},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6489},"end":{"line":154,"column":12,"offset":6496},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6485},"end":{"line":154,"column":12,"offset":6496},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":157,"column":25,"offset":6586},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6587},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":158,"column":59,"offset":6645},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":160,"column":4,"offset":6650},"end":{"line":160,"column":10,"offset":6656},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":6647},"end":{"line":160,"column":10,"offset":6656},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.","position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":310,"offset":6967},"indent":[]}}],"position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":310,"offset":6967},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To fill the gap, regarding the latter, we can rely on another solution called ","position":{"start":{"line":164,"column":1,"offset":6969},"end":{"line":164,"column":79,"offset":7047},"indent":[]}},{"type":"link","title":null,"url":"https://balena.io","children":[{"type":"text","value":"Balena.io","position":{"start":{"line":164,"column":80,"offset":7048},"end":{"line":164,"column":89,"offset":7057},"indent":[]}}],"position":{"start":{"line":164,"column":79,"offset":7047},"end":{"line":164,"column":109,"offset":7077},"indent":[]}},{"type":"text","value":". Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).","position":{"start":{"line":164,"column":109,"offset":7077},"end":{"line":164,"column":386,"offset":7354},"indent":[]}}],"position":{"start":{"line":164,"column":1,"offset":6969},"end":{"line":164,"column":386,"offset":7354},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On top of supporting a lot of boars,","position":{"start":{"line":166,"column":1,"offset":7356},"end":{"line":166,"column":37,"offset":7392},"indent":[]}}],"position":{"start":{"line":166,"column":1,"offset":7356},"end":{"line":166,"column":37,"offset":7392},"indent":[]}},{"type":"thematicBreak","position":{"start":{"line":168,"column":1,"offset":7394},"end":{"line":168,"column":4,"offset":7397},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":170,"column":3,"offset":7401},"end":{"line":170,"column":11,"offset":7409},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7399},"end":{"line":170,"column":11,"offset":7409},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":172,"column":1,"offset":7411},"end":{"line":172,"column":133,"offset":7543},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7411},"end":{"line":172,"column":133,"offset":7543},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":174,"column":4,"offset":7548},"end":{"line":174,"column":12,"offset":7556},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7545},"end":{"line":174,"column":12,"offset":7556},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":176,"column":1,"offset":7558},"end":{"line":176,"column":193,"offset":7750},"indent":[]}}],"position":{"start":{"line":176,"column":1,"offset":7558},"end":{"line":176,"column":193,"offset":7750},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":178,"column":4,"offset":7755},"end":{"line":178,"column":62,"offset":7813},"indent":[]}}],"position":{"start":{"line":178,"column":4,"offset":7755},"end":{"line":178,"column":62,"offset":7813},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7752},"end":{"line":178,"column":62,"offset":7813},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":179,"column":4,"offset":7817},"end":{"line":179,"column":69,"offset":7882},"indent":[]}}],"position":{"start":{"line":179,"column":4,"offset":7817},"end":{"line":179,"column":69,"offset":7882},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7814},"end":{"line":179,"column":69,"offset":7882},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7752},"end":{"line":179,"column":69,"offset":7882},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":181,"column":1,"offset":7884},"end":{"line":181,"column":99,"offset":7982},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":7884},"end":{"line":181,"column":99,"offset":7982},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":183,"column":5,"offset":7988},"end":{"line":183,"column":14,"offset":7997},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":7984},"end":{"line":183,"column":14,"offset":7997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":185,"column":1,"offset":7999},"end":{"line":185,"column":71,"offset":8069},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":7999},"end":{"line":185,"column":71,"offset":8069},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":187,"column":3,"offset":8073},"end":{"line":187,"column":47,"offset":8117},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":187,"column":47,"offset":8117},"end":{"line":187,"column":79,"offset":8149},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":187,"column":79,"offset":8149},"end":{"line":187,"column":198,"offset":8268},"indent":[]}}],"position":{"start":{"line":187,"column":3,"offset":8073},"end":{"line":187,"column":198,"offset":8268},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":8071},"end":{"line":187,"column":198,"offset":8268},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":189,"column":1,"offset":8270},"end":{"line":191,"column":4,"offset":8333},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":193,"column":5,"offset":8339},"end":{"line":193,"column":14,"offset":8348},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8335},"end":{"line":193,"column":14,"offset":8348},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":195,"column":1,"offset":8350},"end":{"line":195,"column":56,"offset":8405},"indent":[]}}],"position":{"start":{"line":195,"column":1,"offset":8350},"end":{"line":195,"column":56,"offset":8405},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":196,"column":3,"offset":8408},"end":{"line":196,"column":52,"offset":8457},"indent":[]}}],"position":{"start":{"line":196,"column":3,"offset":8408},"end":{"line":196,"column":52,"offset":8457},"indent":[]}}],"position":{"start":{"line":196,"column":3,"offset":8408},"end":{"line":196,"column":52,"offset":8457},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8406},"end":{"line":196,"column":52,"offset":8457},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":198,"column":1,"offset":8459},"end":{"line":198,"column":3,"offset":8461},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":198,"column":3,"offset":8461},"end":{"line":198,"column":9,"offset":8467},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":198,"column":9,"offset":8467},"end":{"line":198,"column":223,"offset":8681},"indent":[]}}],"position":{"start":{"line":198,"column":1,"offset":8459},"end":{"line":198,"column":223,"offset":8681},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":200,"column":3,"offset":8685},"end":{"line":200,"column":159,"offset":8841},"indent":[]}}],"position":{"start":{"line":200,"column":3,"offset":8685},"end":{"line":200,"column":159,"offset":8841},"indent":[]}}],"position":{"start":{"line":200,"column":1,"offset":8683},"end":{"line":200,"column":159,"offset":8841},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":202,"column":1,"offset":8843},"end":{"line":205,"column":4,"offset":9020},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":207,"column":1,"offset":9022},"end":{"line":207,"column":160,"offset":9181},"indent":[]}}],"position":{"start":{"line":207,"column":1,"offset":9022},"end":{"line":207,"column":160,"offset":9181},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":209,"column":3,"offset":9185},"end":{"line":209,"column":31,"offset":9213},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":209,"column":31,"offset":9213},"end":{"line":209,"column":101,"offset":9283},"indent":[]}}],"position":{"start":{"line":209,"column":3,"offset":9185},"end":{"line":209,"column":101,"offset":9283},"indent":[]}}],"position":{"start":{"line":209,"column":1,"offset":9183},"end":{"line":209,"column":101,"offset":9283},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":211,"column":1,"offset":9285},"end":{"line":214,"column":4,"offset":9457},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":216,"column":1,"offset":9459},"end":{"line":216,"column":73,"offset":9531},"indent":[]}}],"position":{"start":{"line":216,"column":1,"offset":9459},"end":{"line":216,"column":73,"offset":9531},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":219,"column":3,"offset":9536},"end":{"line":219,"column":31,"offset":9564},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":219,"column":31,"offset":9564},"end":{"line":219,"column":101,"offset":9634},"indent":[]}}],"position":{"start":{"line":219,"column":3,"offset":9536},"end":{"line":219,"column":101,"offset":9634},"indent":[]}}],"position":{"start":{"line":219,"column":1,"offset":9534},"end":{"line":219,"column":101,"offset":9634},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":221,"column":1,"offset":9636},"end":{"line":224,"column":4,"offset":9808},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":226,"column":1,"offset":9810},"end":{"line":226,"column":62,"offset":9871},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":226,"column":63,"offset":9872},"end":{"line":226,"column":75,"offset":9884},"indent":[]}}],"position":{"start":{"line":226,"column":62,"offset":9871},"end":{"line":226,"column":143,"offset":9952},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":226,"column":143,"offset":9952},"end":{"line":226,"column":150,"offset":9959},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":226,"column":150,"offset":9959},"end":{"line":226,"column":169,"offset":9978},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":226,"column":169,"offset":9978},"end":{"line":226,"column":170,"offset":9979},"indent":[]}}],"position":{"start":{"line":226,"column":1,"offset":9810},"end":{"line":226,"column":170,"offset":9979},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":228,"column":1,"offset":9981},"end":{"line":230,"column":4,"offset":10008},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":232,"column":1,"offset":10010},"end":{"line":232,"column":58,"offset":10067},"indent":[]}}],"position":{"start":{"line":232,"column":1,"offset":10010},"end":{"line":232,"column":58,"offset":10067},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":234,"column":1,"offset":10069},"end":{"line":237,"column":4,"offset":10139},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":239,"column":5,"offset":10145},"end":{"line":239,"column":8,"offset":10148},"indent":[]}}],"position":{"start":{"line":239,"column":1,"offset":10141},"end":{"line":239,"column":8,"offset":10148},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":241,"column":1,"offset":10150},"end":{"line":241,"column":280,"offset":10429},"indent":[]}}],"position":{"start":{"line":241,"column":1,"offset":10150},"end":{"line":241,"column":280,"offset":10429},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":243,"column":1,"offset":10431},"end":{"line":243,"column":37,"offset":10467},"indent":[]}}],"position":{"start":{"line":243,"column":1,"offset":10431},"end":{"line":243,"column":37,"offset":10467},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":245,"column":1,"offset":10469},"end":{"line":247,"column":4,"offset":10642},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":249,"column":1,"offset":10644},"end":{"line":249,"column":25,"offset":10668},"indent":[]}}],"position":{"start":{"line":249,"column":1,"offset":10644},"end":{"line":249,"column":25,"offset":10668},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":251,"column":1,"offset":10670},"end":{"line":254,"column":4,"offset":10774},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":256,"column":1,"offset":10776},"end":{"line":256,"column":118,"offset":10893},"indent":[]}}],"position":{"start":{"line":256,"column":1,"offset":10776},"end":{"line":256,"column":118,"offset":10893},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":258,"column":1,"offset":10895},"end":{"line":278,"column":4,"offset":11402},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":280,"column":1,"offset":11404},"end":{"line":280,"column":14,"offset":11417},"indent":[]}}],"position":{"start":{"line":280,"column":1,"offset":11404},"end":{"line":280,"column":14,"offset":11417},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":282,"column":1,"offset":11419},"end":{"line":284,"column":4,"offset":11455},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":286,"column":1,"offset":11457},"end":{"line":286,"column":91,"offset":11547},"indent":[]}}],"position":{"start":{"line":286,"column":1,"offset":11457},"end":{"line":286,"column":91,"offset":11547},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":288,"column":1,"offset":11549},"end":{"line":296,"column":4,"offset":11922},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":298,"column":1,"offset":11924},"end":{"line":298,"column":145,"offset":12068},"indent":[]}}],"position":{"start":{"line":298,"column":1,"offset":11924},"end":{"line":298,"column":145,"offset":12068},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":300,"column":5,"offset":12074},"end":{"line":300,"column":17,"offset":12086},"indent":[]}}],"position":{"start":{"line":300,"column":1,"offset":12070},"end":{"line":300,"column":17,"offset":12086},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":302,"column":1,"offset":12088},"end":{"line":302,"column":300,"offset":12387},"indent":[]}}],"position":{"start":{"line":302,"column":1,"offset":12088},"end":{"line":302,"column":300,"offset":12387},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":304,"column":1,"offset":12389},"end":{"line":304,"column":178,"offset":12566},"indent":[]}}],"position":{"start":{"line":304,"column":1,"offset":12389},"end":{"line":304,"column":178,"offset":12566},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":306,"column":1,"offset":12568},"end":{"line":306,"column":48,"offset":12615},"indent":[]}}],"position":{"start":{"line":306,"column":1,"offset":12568},"end":{"line":306,"column":48,"offset":12615},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":308,"column":1,"offset":12617},"end":{"line":310,"column":4,"offset":12657},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":312,"column":1,"offset":12659},"end":{"line":312,"column":104,"offset":12762},"indent":[]}}],"position":{"start":{"line":312,"column":1,"offset":12659},"end":{"line":312,"column":104,"offset":12762},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":314,"column":1,"offset":12764},"end":{"line":322,"column":4,"offset":13034},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":324,"column":1,"offset":13036},"end":{"line":324,"column":28,"offset":13063},"indent":[]}}],"position":{"start":{"line":324,"column":1,"offset":13036},"end":{"line":324,"column":28,"offset":13063},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":326,"column":1,"offset":13065},"end":{"line":328,"column":4,"offset":13109},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":330,"column":1,"offset":13111},"end":{"line":330,"column":48,"offset":13158},"indent":[]}}],"position":{"start":{"line":330,"column":1,"offset":13111},"end":{"line":330,"column":48,"offset":13158},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":332,"column":1,"offset":13160},"end":{"line":334,"column":4,"offset":13182},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":336,"column":1,"offset":13184},"end":{"line":336,"column":72,"offset":13255},"indent":[]}}],"position":{"start":{"line":336,"column":1,"offset":13184},"end":{"line":336,"column":72,"offset":13255},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":338,"column":1,"offset":13257},"end":{"line":340,"column":4,"offset":13314},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":342,"column":4,"offset":13319},"end":{"line":342,"column":11,"offset":13326},"indent":[]}}],"position":{"start":{"line":342,"column":1,"offset":13316},"end":{"line":342,"column":11,"offset":13326},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":344,"column":1,"offset":13328},"end":{"line":344,"column":283,"offset":13610},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13328},"end":{"line":344,"column":283,"offset":13610},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":346,"column":3,"offset":13614},"end":{"line":346,"column":54,"offset":13665},"indent":[]}}],"position":{"start":{"line":346,"column":3,"offset":13614},"end":{"line":346,"column":54,"offset":13665},"indent":[]}}],"position":{"start":{"line":346,"column":1,"offset":13612},"end":{"line":346,"column":54,"offset":13665},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":348,"column":5,"offset":13671},"end":{"line":348,"column":14,"offset":13680},"indent":[]}}],"position":{"start":{"line":348,"column":1,"offset":13667},"end":{"line":348,"column":14,"offset":13680},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":350,"column":1,"offset":13682},"end":{"line":350,"column":68,"offset":13749},"indent":[]}}],"position":{"start":{"line":350,"column":1,"offset":13682},"end":{"line":350,"column":68,"offset":13749},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":352,"column":1,"offset":13751},"end":{"line":355,"column":4,"offset":13902},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":357,"column":1,"offset":13904},"end":{"line":357,"column":46,"offset":13949},"indent":[]}}],"position":{"start":{"line":357,"column":1,"offset":13904},"end":{"line":357,"column":46,"offset":13949},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":359,"column":3,"offset":13953},"end":{"line":359,"column":103,"offset":14053},"indent":[]}}],"position":{"start":{"line":359,"column":3,"offset":13953},"end":{"line":359,"column":103,"offset":14053},"indent":[]}}],"position":{"start":{"line":359,"column":1,"offset":13951},"end":{"line":359,"column":103,"offset":14053},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":361,"column":1,"offset":14055},"end":{"line":366,"column":4,"offset":14265},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":368,"column":1,"offset":14267},"end":{"line":368,"column":151,"offset":14417},"indent":[]}}],"position":{"start":{"line":368,"column":1,"offset":14267},"end":{"line":368,"column":151,"offset":14417},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":370,"column":3,"offset":14421},"end":{"line":370,"column":22,"offset":14440},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":370,"column":22,"offset":14440},"end":{"line":370,"column":26,"offset":14444},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":370,"column":26,"offset":14444},"end":{"line":370,"column":40,"offset":14458},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":370,"column":40,"offset":14458},"end":{"line":370,"column":50,"offset":14468},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":370,"column":50,"offset":14468},"end":{"line":370,"column":98,"offset":14516},"indent":[]}}],"position":{"start":{"line":370,"column":3,"offset":14421},"end":{"line":370,"column":98,"offset":14516},"indent":[]}}],"position":{"start":{"line":370,"column":1,"offset":14419},"end":{"line":370,"column":98,"offset":14516},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":372,"column":1,"offset":14518},"end":{"line":376,"column":4,"offset":14680},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":378,"column":1,"offset":14682},"end":{"line":378,"column":72,"offset":14753},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":378,"column":72,"offset":14753},"end":{"line":378,"column":84,"offset":14765},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":378,"column":84,"offset":14765},"end":{"line":378,"column":102,"offset":14783},"indent":[]}}],"position":{"start":{"line":378,"column":1,"offset":14682},"end":{"line":378,"column":102,"offset":14783},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":380,"column":1,"offset":14785},"end":{"line":383,"column":4,"offset":14859},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":385,"column":5,"offset":14865},"end":{"line":385,"column":8,"offset":14868},"indent":[]}}],"position":{"start":{"line":385,"column":1,"offset":14861},"end":{"line":385,"column":8,"offset":14868},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":387,"column":1,"offset":14870},"end":{"line":387,"column":176,"offset":15045},"indent":[]}}],"position":{"start":{"line":387,"column":1,"offset":14870},"end":{"line":387,"column":176,"offset":15045},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":389,"column":1,"offset":15047},"end":{"line":396,"column":4,"offset":15344},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":398,"column":1,"offset":15346},"end":{"line":398,"column":60,"offset":15405},"indent":[]}}],"position":{"start":{"line":398,"column":1,"offset":15346},"end":{"line":398,"column":60,"offset":15405},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":400,"column":1,"offset":15407},"end":{"line":404,"column":4,"offset":15533},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":406,"column":1,"offset":15535},"end":{"line":406,"column":63,"offset":15597},"indent":[]}}],"position":{"start":{"line":406,"column":1,"offset":15535},"end":{"line":406,"column":63,"offset":15597},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":408,"column":1,"offset":15599},"end":{"line":428,"column":4,"offset":16106},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":430,"column":1,"offset":16108},"end":{"line":430,"column":99,"offset":16206},"indent":[]}}],"position":{"start":{"line":430,"column":1,"offset":16108},"end":{"line":430,"column":99,"offset":16206},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":432,"column":1,"offset":16208},"end":{"line":435,"column":4,"offset":16310},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":437,"column":1,"offset":16312},"end":{"line":437,"column":37,"offset":16348},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":437,"column":37,"offset":16348},"end":{"line":437,"column":47,"offset":16358},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":437,"column":47,"offset":16358},"end":{"line":437,"column":89,"offset":16400},"indent":[]}}],"position":{"start":{"line":437,"column":1,"offset":16312},"end":{"line":437,"column":89,"offset":16400},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":439,"column":1,"offset":16402},"end":{"line":443,"column":4,"offset":16527},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":445,"column":1,"offset":16529},"end":{"line":445,"column":78,"offset":16606},"indent":[]}}],"position":{"start":{"line":445,"column":1,"offset":16529},"end":{"line":445,"column":78,"offset":16606},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":447,"column":1,"offset":16608},"end":{"line":451,"column":4,"offset":16712},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":453,"column":1,"offset":16714},"end":{"line":453,"column":75,"offset":16788},"indent":[]}}],"position":{"start":{"line":453,"column":1,"offset":16714},"end":{"line":453,"column":75,"offset":16788},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":455,"column":1,"offset":16790},"end":{"line":459,"column":4,"offset":16863},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":461,"column":1,"offset":16865},"end":{"line":461,"column":145,"offset":17009},"indent":[]}}],"position":{"start":{"line":461,"column":1,"offset":16865},"end":{"line":461,"column":145,"offset":17009},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":463,"column":5,"offset":17015},"end":{"line":463,"column":17,"offset":17027},"indent":[]}}],"position":{"start":{"line":463,"column":1,"offset":17011},"end":{"line":463,"column":17,"offset":17027},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":465,"column":1,"offset":17029},"end":{"line":465,"column":300,"offset":17328},"indent":[]}}],"position":{"start":{"line":465,"column":1,"offset":17029},"end":{"line":465,"column":300,"offset":17328},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":467,"column":1,"offset":17330},"end":{"line":467,"column":178,"offset":17507},"indent":[]}}],"position":{"start":{"line":467,"column":1,"offset":17330},"end":{"line":467,"column":178,"offset":17507},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":469,"column":1,"offset":17509},"end":{"line":469,"column":48,"offset":17556},"indent":[]}}],"position":{"start":{"line":469,"column":1,"offset":17509},"end":{"line":469,"column":48,"offset":17556},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":471,"column":1,"offset":17558},"end":{"line":473,"column":4,"offset":17602},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":475,"column":1,"offset":17604},"end":{"line":475,"column":104,"offset":17707},"indent":[]}}],"position":{"start":{"line":475,"column":1,"offset":17604},"end":{"line":475,"column":104,"offset":17707},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":477,"column":1,"offset":17709},"end":{"line":485,"column":4,"offset":17979},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":487,"column":1,"offset":17981},"end":{"line":487,"column":28,"offset":18008},"indent":[]}}],"position":{"start":{"line":487,"column":1,"offset":17981},"end":{"line":487,"column":28,"offset":18008},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":489,"column":1,"offset":18010},"end":{"line":491,"column":4,"offset":18058},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":493,"column":1,"offset":18060},"end":{"line":493,"column":48,"offset":18107},"indent":[]}}],"position":{"start":{"line":493,"column":1,"offset":18060},"end":{"line":493,"column":48,"offset":18107},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":495,"column":1,"offset":18109},"end":{"line":497,"column":4,"offset":18131},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":499,"column":1,"offset":18133},"end":{"line":499,"column":72,"offset":18204},"indent":[]}}],"position":{"start":{"line":499,"column":1,"offset":18133},"end":{"line":499,"column":72,"offset":18204},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":501,"column":1,"offset":18206},"end":{"line":503,"column":4,"offset":18267},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":506,"column":1,"offset":18270},"end":{"line":506,"column":31,"offset":18300},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":506,"column":31,"offset":18300}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.`}

\n

{`To fill the gap, regarding the latter, we can rely on another solution called `}{`Balena.io`}{`. Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).`}

\n

{`On top of supporting a lot of boars,`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-94847925d58c4478a42fd8efb20158a8.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-94847925d58c4478a42fd8efb20158a8.json new file mode 100644 index 0000000..a80b5e8 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-94847925d58c4478a42fd8efb20158a8.json @@ -0,0 +1 @@ +{"expireTime":9007200842067995000,"key":"gatsby-plugin-mdx-entire-payload-5c27c3e66982d4f3edd0e63bf1664086-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug-and-Play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":23,"column":3,"offset":1136},"end":{"line":23,"column":16,"offset":1149},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":16,"offset":1149},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":25,"column":1,"offset":1151},"end":{"line":25,"column":156,"offset":1306},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1151},"end":{"line":25,"column":156,"offset":1306},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS for Raspberry Pi","position":{"start":{"line":27,"column":4,"offset":1311},"end":{"line":27,"column":25,"offset":1332},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1308},"end":{"line":27,"column":25,"offset":1332},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":29,"column":1,"offset":1334},"end":{"line":29,"column":229,"offset":1562},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1334},"end":{"line":29,"column":229,"offset":1562},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":31,"column":1,"offset":1564},"end":{"line":31,"column":197,"offset":1760},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1564},"end":{"line":31,"column":197,"offset":1760},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":33,"column":5,"offset":1766},"end":{"line":33,"column":11,"offset":1772},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1762},"end":{"line":33,"column":11,"offset":1772},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":35,"column":1,"offset":1774},"end":{"line":35,"column":63,"offset":1836},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":35,"column":64,"offset":1837},"end":{"line":35,"column":85,"offset":1858},"indent":[]}}],"position":{"start":{"line":35,"column":63,"offset":1836},"end":{"line":35,"column":123,"offset":1896},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":35,"column":123,"offset":1896},"end":{"line":35,"column":124,"offset":1897},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1774},"end":{"line":35,"column":124,"offset":1897},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos installer","position":{"start":{"line":37,"column":5,"offset":1903},"end":{"line":37,"column":23,"offset":1921},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1899},"end":{"line":37,"column":23,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":39,"column":1,"offset":1923},"end":{"line":39,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1923},"end":{"line":39,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":41,"column":1,"offset":2152},"end":{"line":41,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":2152},"end":{"line":41,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":43,"column":1,"offset":2220},"end":{"line":43,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2220},"end":{"line":43,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":45,"column":3,"offset":2273},"end":{"line":45,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":45,"column":3,"offset":2273},"end":{"line":45,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":45,"column":3,"offset":2273},"end":{"line":45,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2271},"end":{"line":45,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":47,"column":5,"offset":2325},"end":{"line":47,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2321},"end":{"line":47,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":49,"column":1,"offset":2333},"end":{"line":49,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2333},"end":{"line":49,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":51,"column":4,"offset":2497},"end":{"line":51,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":51,"column":14,"offset":2507},"end":{"line":51,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":51,"column":13,"offset":2506},"end":{"line":51,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":51,"column":75,"offset":2568},"end":{"line":51,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":51,"column":4,"offset":2497},"end":{"line":51,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2494},"end":{"line":51,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":52,"column":4,"offset":2573},"end":{"line":52,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":52,"column":4,"offset":2573},"end":{"line":52,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2570},"end":{"line":52,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":53,"column":4,"offset":2614},"end":{"line":53,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2614},"end":{"line":53,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2611},"end":{"line":53,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2494},"end":{"line":53,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":55,"column":2,"offset":2673},"end":{"line":55,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2672},"end":{"line":55,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2672},"end":{"line":55,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":57,"column":1,"offset":2769},"end":{"line":57,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2769},"end":{"line":57,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":59,"column":6,"offset":2979},"end":{"line":59,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2974},"end":{"line":59,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":61,"column":1,"offset":2999},"end":{"line":61,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":61,"column":95,"offset":3093},"end":{"line":61,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":61,"column":110,"offset":3108},"end":{"line":61,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2999},"end":{"line":61,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":63,"column":1,"offset":3222},"end":{"line":71,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":73,"column":6,"offset":3338},"end":{"line":73,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":73,"column":1,"offset":3333},"end":{"line":73,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":75,"column":1,"offset":3365},"end":{"line":75,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":75,"column":79,"offset":3443},"end":{"line":75,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":75,"column":95,"offset":3459},"end":{"line":75,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3365},"end":{"line":75,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":77,"column":1,"offset":3503},"end":{"line":87,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":89,"column":5,"offset":3877},"end":{"line":89,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":3873},"end":{"line":89,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":91,"column":1,"offset":3904},"end":{"line":91,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3904},"end":{"line":91,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":93,"column":1,"offset":4369},"end":{"line":93,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":4369},"end":{"line":93,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":95,"column":5,"offset":4435},"end":{"line":95,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4431},"end":{"line":95,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":97,"column":1,"offset":4460},"end":{"line":97,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":97,"column":95,"offset":4554},"end":{"line":97,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":97,"column":100,"offset":4559},"end":{"line":97,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4460},"end":{"line":97,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":99,"column":1,"offset":4562},"end":{"line":103,"column":4,"offset":4679},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":105,"column":1,"offset":4681},"end":{"line":105,"column":80,"offset":4760},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":105,"column":80,"offset":4760},"end":{"line":105,"column":101,"offset":4781},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":105,"column":101,"offset":4781},"end":{"line":105,"column":162,"offset":4842},"indent":[]}}],"position":{"start":{"line":105,"column":1,"offset":4681},"end":{"line":105,"column":162,"offset":4842},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":107,"column":1,"offset":4844},"end":{"line":110,"column":4,"offset":4933},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":112,"column":4,"offset":4938},"end":{"line":112,"column":10,"offset":4944},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":4935},"end":{"line":112,"column":10,"offset":4944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":114,"column":1,"offset":4946},"end":{"line":114,"column":337,"offset":5282},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":114,"column":338,"offset":5283},"end":{"line":114,"column":352,"offset":5297},"indent":[]}}],"position":{"start":{"line":114,"column":337,"offset":5282},"end":{"line":114,"column":388,"offset":5333},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":114,"column":388,"offset":5333},"end":{"line":114,"column":389,"offset":5334},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4946},"end":{"line":114,"column":389,"offset":5334},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":116,"column":5,"offset":5340},"end":{"line":116,"column":18,"offset":5353},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":5336},"end":{"line":116,"column":18,"offset":5353},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":118,"column":3,"offset":5357},"end":{"line":118,"column":50,"offset":5404},"indent":[]}}],"position":{"start":{"line":118,"column":3,"offset":5357},"end":{"line":118,"column":50,"offset":5404},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5355},"end":{"line":118,"column":50,"offset":5404},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":120,"column":5,"offset":5410},"end":{"line":120,"column":11,"offset":5416},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5406},"end":{"line":120,"column":11,"offset":5416},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":122,"column":1,"offset":5418},"end":{"line":122,"column":64,"offset":5481},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":122,"column":65,"offset":5482},"end":{"line":122,"column":86,"offset":5503},"indent":[]}}],"position":{"start":{"line":122,"column":64,"offset":5481},"end":{"line":122,"column":126,"offset":5543},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":122,"column":126,"offset":5543},"end":{"line":122,"column":127,"offset":5544},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5418},"end":{"line":122,"column":127,"offset":5544},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":124,"column":5,"offset":5550},"end":{"line":124,"column":26,"offset":5571},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5546},"end":{"line":124,"column":26,"offset":5571},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":126,"column":1,"offset":5573},"end":{"line":126,"column":126,"offset":5698},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5573},"end":{"line":126,"column":126,"offset":5698},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":128,"column":1,"offset":5700},"end":{"line":130,"column":4,"offset":5739},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":132,"column":1,"offset":5741},"end":{"line":132,"column":187,"offset":5927},"indent":[]}}],"position":{"start":{"line":132,"column":1,"offset":5741},"end":{"line":132,"column":187,"offset":5927},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":134,"column":1,"offset":5929},"end":{"line":136,"column":4,"offset":6007},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":138,"column":1,"offset":6009},"end":{"line":138,"column":153,"offset":6161},"indent":[]}}],"position":{"start":{"line":138,"column":1,"offset":6009},"end":{"line":138,"column":153,"offset":6161},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":140,"column":1,"offset":6163},"end":{"line":143,"column":4,"offset":6310},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":145,"column":1,"offset":6312},"end":{"line":145,"column":100,"offset":6411},"indent":[]}}],"position":{"start":{"line":145,"column":1,"offset":6312},"end":{"line":145,"column":100,"offset":6411},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":146,"column":1,"offset":6412},"end":{"line":150,"column":4,"offset":6481},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":152,"column":5,"offset":6487},"end":{"line":152,"column":12,"offset":6494},"indent":[]}}],"position":{"start":{"line":152,"column":1,"offset":6483},"end":{"line":152,"column":12,"offset":6494},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":154,"column":1,"offset":6496},"end":{"line":154,"column":64,"offset":6559},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6496},"end":{"line":154,"column":64,"offset":6559},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":155,"column":3,"offset":6562},"end":{"line":155,"column":25,"offset":6584},"indent":[]}}],"position":{"start":{"line":155,"column":3,"offset":6562},"end":{"line":155,"column":25,"offset":6584},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":6560},"end":{"line":155,"column":25,"offset":6584},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":156,"column":3,"offset":6587},"end":{"line":156,"column":59,"offset":6643},"indent":[]}}],"position":{"start":{"line":156,"column":3,"offset":6587},"end":{"line":156,"column":59,"offset":6643},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6585},"end":{"line":156,"column":59,"offset":6643},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":6560},"end":{"line":156,"column":59,"offset":6643},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":158,"column":4,"offset":6648},"end":{"line":158,"column":10,"offset":6654},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6645},"end":{"line":158,"column":10,"offset":6654},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.","position":{"start":{"line":160,"column":1,"offset":6656},"end":{"line":160,"column":102,"offset":6757},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":6656},"end":{"line":160,"column":102,"offset":6757},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Especially in the worl\n even on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.","position":{"start":{"line":162,"column":1,"offset":6759},"end":{"line":163,"column":128,"offset":6909},"indent":[1]}}],"position":{"start":{"line":162,"column":1,"offset":6759},"end":{"line":163,"column":128,"offset":6909},"indent":[1]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":166,"column":3,"offset":6914},"end":{"line":166,"column":11,"offset":6922},"indent":[]}}],"position":{"start":{"line":166,"column":1,"offset":6912},"end":{"line":166,"column":11,"offset":6922},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":168,"column":1,"offset":6924},"end":{"line":168,"column":133,"offset":7056},"indent":[]}}],"position":{"start":{"line":168,"column":1,"offset":6924},"end":{"line":168,"column":133,"offset":7056},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":170,"column":4,"offset":7061},"end":{"line":170,"column":12,"offset":7069},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7058},"end":{"line":170,"column":12,"offset":7069},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":172,"column":1,"offset":7071},"end":{"line":172,"column":193,"offset":7263},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7071},"end":{"line":172,"column":193,"offset":7263},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":174,"column":4,"offset":7268},"end":{"line":174,"column":62,"offset":7326},"indent":[]}}],"position":{"start":{"line":174,"column":4,"offset":7268},"end":{"line":174,"column":62,"offset":7326},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7265},"end":{"line":174,"column":62,"offset":7326},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":175,"column":4,"offset":7330},"end":{"line":175,"column":69,"offset":7395},"indent":[]}}],"position":{"start":{"line":175,"column":4,"offset":7330},"end":{"line":175,"column":69,"offset":7395},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7327},"end":{"line":175,"column":69,"offset":7395},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7265},"end":{"line":175,"column":69,"offset":7395},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":177,"column":1,"offset":7397},"end":{"line":177,"column":99,"offset":7495},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7397},"end":{"line":177,"column":99,"offset":7495},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":179,"column":5,"offset":7501},"end":{"line":179,"column":14,"offset":7510},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7497},"end":{"line":179,"column":14,"offset":7510},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":181,"column":1,"offset":7512},"end":{"line":181,"column":71,"offset":7582},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":7512},"end":{"line":181,"column":71,"offset":7582},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":183,"column":3,"offset":7586},"end":{"line":183,"column":47,"offset":7630},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":183,"column":47,"offset":7630},"end":{"line":183,"column":79,"offset":7662},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":183,"column":79,"offset":7662},"end":{"line":183,"column":198,"offset":7781},"indent":[]}}],"position":{"start":{"line":183,"column":3,"offset":7586},"end":{"line":183,"column":198,"offset":7781},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":7584},"end":{"line":183,"column":198,"offset":7781},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":185,"column":1,"offset":7783},"end":{"line":187,"column":4,"offset":7846},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":189,"column":5,"offset":7852},"end":{"line":189,"column":14,"offset":7861},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":7848},"end":{"line":189,"column":14,"offset":7861},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":191,"column":1,"offset":7863},"end":{"line":191,"column":56,"offset":7918},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":7863},"end":{"line":191,"column":56,"offset":7918},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":192,"column":3,"offset":7921},"end":{"line":192,"column":52,"offset":7970},"indent":[]}}],"position":{"start":{"line":192,"column":3,"offset":7921},"end":{"line":192,"column":52,"offset":7970},"indent":[]}}],"position":{"start":{"line":192,"column":3,"offset":7921},"end":{"line":192,"column":52,"offset":7970},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":7919},"end":{"line":192,"column":52,"offset":7970},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":194,"column":1,"offset":7972},"end":{"line":194,"column":3,"offset":7974},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":194,"column":3,"offset":7974},"end":{"line":194,"column":9,"offset":7980},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":194,"column":9,"offset":7980},"end":{"line":194,"column":223,"offset":8194},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":7972},"end":{"line":194,"column":223,"offset":8194},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":196,"column":3,"offset":8198},"end":{"line":196,"column":159,"offset":8354},"indent":[]}}],"position":{"start":{"line":196,"column":3,"offset":8198},"end":{"line":196,"column":159,"offset":8354},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8196},"end":{"line":196,"column":159,"offset":8354},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":198,"column":1,"offset":8356},"end":{"line":201,"column":4,"offset":8533},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":203,"column":1,"offset":8535},"end":{"line":203,"column":160,"offset":8694},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":8535},"end":{"line":203,"column":160,"offset":8694},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":205,"column":3,"offset":8698},"end":{"line":205,"column":31,"offset":8726},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":205,"column":31,"offset":8726},"end":{"line":205,"column":101,"offset":8796},"indent":[]}}],"position":{"start":{"line":205,"column":3,"offset":8698},"end":{"line":205,"column":101,"offset":8796},"indent":[]}}],"position":{"start":{"line":205,"column":1,"offset":8696},"end":{"line":205,"column":101,"offset":8796},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":207,"column":1,"offset":8798},"end":{"line":210,"column":4,"offset":8970},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":212,"column":1,"offset":8972},"end":{"line":212,"column":73,"offset":9044},"indent":[]}}],"position":{"start":{"line":212,"column":1,"offset":8972},"end":{"line":212,"column":73,"offset":9044},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":215,"column":3,"offset":9049},"end":{"line":215,"column":31,"offset":9077},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":215,"column":31,"offset":9077},"end":{"line":215,"column":101,"offset":9147},"indent":[]}}],"position":{"start":{"line":215,"column":3,"offset":9049},"end":{"line":215,"column":101,"offset":9147},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":9047},"end":{"line":215,"column":101,"offset":9147},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":217,"column":1,"offset":9149},"end":{"line":220,"column":4,"offset":9321},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":222,"column":1,"offset":9323},"end":{"line":222,"column":62,"offset":9384},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":222,"column":63,"offset":9385},"end":{"line":222,"column":75,"offset":9397},"indent":[]}}],"position":{"start":{"line":222,"column":62,"offset":9384},"end":{"line":222,"column":143,"offset":9465},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":222,"column":143,"offset":9465},"end":{"line":222,"column":150,"offset":9472},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":222,"column":150,"offset":9472},"end":{"line":222,"column":169,"offset":9491},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":222,"column":169,"offset":9491},"end":{"line":222,"column":170,"offset":9492},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":9323},"end":{"line":222,"column":170,"offset":9492},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":224,"column":1,"offset":9494},"end":{"line":226,"column":4,"offset":9521},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":228,"column":1,"offset":9523},"end":{"line":228,"column":58,"offset":9580},"indent":[]}}],"position":{"start":{"line":228,"column":1,"offset":9523},"end":{"line":228,"column":58,"offset":9580},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":230,"column":1,"offset":9582},"end":{"line":233,"column":4,"offset":9652},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":235,"column":5,"offset":9658},"end":{"line":235,"column":8,"offset":9661},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":9654},"end":{"line":235,"column":8,"offset":9661},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":237,"column":1,"offset":9663},"end":{"line":237,"column":280,"offset":9942},"indent":[]}}],"position":{"start":{"line":237,"column":1,"offset":9663},"end":{"line":237,"column":280,"offset":9942},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":239,"column":1,"offset":9944},"end":{"line":239,"column":37,"offset":9980},"indent":[]}}],"position":{"start":{"line":239,"column":1,"offset":9944},"end":{"line":239,"column":37,"offset":9980},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":241,"column":1,"offset":9982},"end":{"line":243,"column":4,"offset":10155},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":245,"column":1,"offset":10157},"end":{"line":245,"column":25,"offset":10181},"indent":[]}}],"position":{"start":{"line":245,"column":1,"offset":10157},"end":{"line":245,"column":25,"offset":10181},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":247,"column":1,"offset":10183},"end":{"line":250,"column":4,"offset":10287},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":252,"column":1,"offset":10289},"end":{"line":252,"column":118,"offset":10406},"indent":[]}}],"position":{"start":{"line":252,"column":1,"offset":10289},"end":{"line":252,"column":118,"offset":10406},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":254,"column":1,"offset":10408},"end":{"line":274,"column":4,"offset":10915},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":276,"column":1,"offset":10917},"end":{"line":276,"column":14,"offset":10930},"indent":[]}}],"position":{"start":{"line":276,"column":1,"offset":10917},"end":{"line":276,"column":14,"offset":10930},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":278,"column":1,"offset":10932},"end":{"line":280,"column":4,"offset":10968},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":282,"column":1,"offset":10970},"end":{"line":282,"column":91,"offset":11060},"indent":[]}}],"position":{"start":{"line":282,"column":1,"offset":10970},"end":{"line":282,"column":91,"offset":11060},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":284,"column":1,"offset":11062},"end":{"line":292,"column":4,"offset":11435},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":294,"column":1,"offset":11437},"end":{"line":294,"column":145,"offset":11581},"indent":[]}}],"position":{"start":{"line":294,"column":1,"offset":11437},"end":{"line":294,"column":145,"offset":11581},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":296,"column":5,"offset":11587},"end":{"line":296,"column":17,"offset":11599},"indent":[]}}],"position":{"start":{"line":296,"column":1,"offset":11583},"end":{"line":296,"column":17,"offset":11599},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":298,"column":1,"offset":11601},"end":{"line":298,"column":300,"offset":11900},"indent":[]}}],"position":{"start":{"line":298,"column":1,"offset":11601},"end":{"line":298,"column":300,"offset":11900},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":300,"column":1,"offset":11902},"end":{"line":300,"column":178,"offset":12079},"indent":[]}}],"position":{"start":{"line":300,"column":1,"offset":11902},"end":{"line":300,"column":178,"offset":12079},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":302,"column":1,"offset":12081},"end":{"line":302,"column":48,"offset":12128},"indent":[]}}],"position":{"start":{"line":302,"column":1,"offset":12081},"end":{"line":302,"column":48,"offset":12128},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":304,"column":1,"offset":12130},"end":{"line":306,"column":4,"offset":12170},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":308,"column":1,"offset":12172},"end":{"line":308,"column":104,"offset":12275},"indent":[]}}],"position":{"start":{"line":308,"column":1,"offset":12172},"end":{"line":308,"column":104,"offset":12275},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":310,"column":1,"offset":12277},"end":{"line":318,"column":4,"offset":12547},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":320,"column":1,"offset":12549},"end":{"line":320,"column":28,"offset":12576},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":12549},"end":{"line":320,"column":28,"offset":12576},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":322,"column":1,"offset":12578},"end":{"line":324,"column":4,"offset":12622},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":326,"column":1,"offset":12624},"end":{"line":326,"column":48,"offset":12671},"indent":[]}}],"position":{"start":{"line":326,"column":1,"offset":12624},"end":{"line":326,"column":48,"offset":12671},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":328,"column":1,"offset":12673},"end":{"line":330,"column":4,"offset":12695},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":332,"column":1,"offset":12697},"end":{"line":332,"column":72,"offset":12768},"indent":[]}}],"position":{"start":{"line":332,"column":1,"offset":12697},"end":{"line":332,"column":72,"offset":12768},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":334,"column":1,"offset":12770},"end":{"line":336,"column":4,"offset":12827},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":338,"column":4,"offset":12832},"end":{"line":338,"column":11,"offset":12839},"indent":[]}}],"position":{"start":{"line":338,"column":1,"offset":12829},"end":{"line":338,"column":11,"offset":12839},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":340,"column":1,"offset":12841},"end":{"line":340,"column":283,"offset":13123},"indent":[]}}],"position":{"start":{"line":340,"column":1,"offset":12841},"end":{"line":340,"column":283,"offset":13123},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":342,"column":3,"offset":13127},"end":{"line":342,"column":54,"offset":13178},"indent":[]}}],"position":{"start":{"line":342,"column":3,"offset":13127},"end":{"line":342,"column":54,"offset":13178},"indent":[]}}],"position":{"start":{"line":342,"column":1,"offset":13125},"end":{"line":342,"column":54,"offset":13178},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":344,"column":5,"offset":13184},"end":{"line":344,"column":14,"offset":13193},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13180},"end":{"line":344,"column":14,"offset":13193},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":346,"column":1,"offset":13195},"end":{"line":346,"column":68,"offset":13262},"indent":[]}}],"position":{"start":{"line":346,"column":1,"offset":13195},"end":{"line":346,"column":68,"offset":13262},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":348,"column":1,"offset":13264},"end":{"line":351,"column":4,"offset":13415},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":353,"column":1,"offset":13417},"end":{"line":353,"column":46,"offset":13462},"indent":[]}}],"position":{"start":{"line":353,"column":1,"offset":13417},"end":{"line":353,"column":46,"offset":13462},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":355,"column":3,"offset":13466},"end":{"line":355,"column":103,"offset":13566},"indent":[]}}],"position":{"start":{"line":355,"column":3,"offset":13466},"end":{"line":355,"column":103,"offset":13566},"indent":[]}}],"position":{"start":{"line":355,"column":1,"offset":13464},"end":{"line":355,"column":103,"offset":13566},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":357,"column":1,"offset":13568},"end":{"line":362,"column":4,"offset":13778},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":364,"column":1,"offset":13780},"end":{"line":364,"column":151,"offset":13930},"indent":[]}}],"position":{"start":{"line":364,"column":1,"offset":13780},"end":{"line":364,"column":151,"offset":13930},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":366,"column":3,"offset":13934},"end":{"line":366,"column":22,"offset":13953},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":366,"column":22,"offset":13953},"end":{"line":366,"column":26,"offset":13957},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":366,"column":26,"offset":13957},"end":{"line":366,"column":40,"offset":13971},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":366,"column":40,"offset":13971},"end":{"line":366,"column":50,"offset":13981},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":366,"column":50,"offset":13981},"end":{"line":366,"column":98,"offset":14029},"indent":[]}}],"position":{"start":{"line":366,"column":3,"offset":13934},"end":{"line":366,"column":98,"offset":14029},"indent":[]}}],"position":{"start":{"line":366,"column":1,"offset":13932},"end":{"line":366,"column":98,"offset":14029},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":368,"column":1,"offset":14031},"end":{"line":372,"column":4,"offset":14193},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":374,"column":1,"offset":14195},"end":{"line":374,"column":72,"offset":14266},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":374,"column":72,"offset":14266},"end":{"line":374,"column":84,"offset":14278},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":374,"column":84,"offset":14278},"end":{"line":374,"column":102,"offset":14296},"indent":[]}}],"position":{"start":{"line":374,"column":1,"offset":14195},"end":{"line":374,"column":102,"offset":14296},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":376,"column":1,"offset":14298},"end":{"line":379,"column":4,"offset":14372},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":381,"column":5,"offset":14378},"end":{"line":381,"column":8,"offset":14381},"indent":[]}}],"position":{"start":{"line":381,"column":1,"offset":14374},"end":{"line":381,"column":8,"offset":14381},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":383,"column":1,"offset":14383},"end":{"line":383,"column":176,"offset":14558},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14383},"end":{"line":383,"column":176,"offset":14558},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":385,"column":1,"offset":14560},"end":{"line":392,"column":4,"offset":14857},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":394,"column":1,"offset":14859},"end":{"line":394,"column":60,"offset":14918},"indent":[]}}],"position":{"start":{"line":394,"column":1,"offset":14859},"end":{"line":394,"column":60,"offset":14918},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":396,"column":1,"offset":14920},"end":{"line":400,"column":4,"offset":15046},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":402,"column":1,"offset":15048},"end":{"line":402,"column":63,"offset":15110},"indent":[]}}],"position":{"start":{"line":402,"column":1,"offset":15048},"end":{"line":402,"column":63,"offset":15110},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":404,"column":1,"offset":15112},"end":{"line":424,"column":4,"offset":15619},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":426,"column":1,"offset":15621},"end":{"line":426,"column":99,"offset":15719},"indent":[]}}],"position":{"start":{"line":426,"column":1,"offset":15621},"end":{"line":426,"column":99,"offset":15719},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":428,"column":1,"offset":15721},"end":{"line":431,"column":4,"offset":15823},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":433,"column":1,"offset":15825},"end":{"line":433,"column":37,"offset":15861},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":433,"column":37,"offset":15861},"end":{"line":433,"column":47,"offset":15871},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":433,"column":47,"offset":15871},"end":{"line":433,"column":89,"offset":15913},"indent":[]}}],"position":{"start":{"line":433,"column":1,"offset":15825},"end":{"line":433,"column":89,"offset":15913},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":435,"column":1,"offset":15915},"end":{"line":439,"column":4,"offset":16040},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":441,"column":1,"offset":16042},"end":{"line":441,"column":78,"offset":16119},"indent":[]}}],"position":{"start":{"line":441,"column":1,"offset":16042},"end":{"line":441,"column":78,"offset":16119},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":443,"column":1,"offset":16121},"end":{"line":447,"column":4,"offset":16225},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":449,"column":1,"offset":16227},"end":{"line":449,"column":75,"offset":16301},"indent":[]}}],"position":{"start":{"line":449,"column":1,"offset":16227},"end":{"line":449,"column":75,"offset":16301},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":451,"column":1,"offset":16303},"end":{"line":455,"column":4,"offset":16376},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":457,"column":1,"offset":16378},"end":{"line":457,"column":145,"offset":16522},"indent":[]}}],"position":{"start":{"line":457,"column":1,"offset":16378},"end":{"line":457,"column":145,"offset":16522},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":459,"column":5,"offset":16528},"end":{"line":459,"column":17,"offset":16540},"indent":[]}}],"position":{"start":{"line":459,"column":1,"offset":16524},"end":{"line":459,"column":17,"offset":16540},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":461,"column":1,"offset":16542},"end":{"line":461,"column":300,"offset":16841},"indent":[]}}],"position":{"start":{"line":461,"column":1,"offset":16542},"end":{"line":461,"column":300,"offset":16841},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":463,"column":1,"offset":16843},"end":{"line":463,"column":178,"offset":17020},"indent":[]}}],"position":{"start":{"line":463,"column":1,"offset":16843},"end":{"line":463,"column":178,"offset":17020},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":465,"column":1,"offset":17022},"end":{"line":465,"column":48,"offset":17069},"indent":[]}}],"position":{"start":{"line":465,"column":1,"offset":17022},"end":{"line":465,"column":48,"offset":17069},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":467,"column":1,"offset":17071},"end":{"line":469,"column":4,"offset":17115},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":471,"column":1,"offset":17117},"end":{"line":471,"column":104,"offset":17220},"indent":[]}}],"position":{"start":{"line":471,"column":1,"offset":17117},"end":{"line":471,"column":104,"offset":17220},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":473,"column":1,"offset":17222},"end":{"line":481,"column":4,"offset":17492},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":483,"column":1,"offset":17494},"end":{"line":483,"column":28,"offset":17521},"indent":[]}}],"position":{"start":{"line":483,"column":1,"offset":17494},"end":{"line":483,"column":28,"offset":17521},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":485,"column":1,"offset":17523},"end":{"line":487,"column":4,"offset":17571},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":489,"column":1,"offset":17573},"end":{"line":489,"column":48,"offset":17620},"indent":[]}}],"position":{"start":{"line":489,"column":1,"offset":17573},"end":{"line":489,"column":48,"offset":17620},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":491,"column":1,"offset":17622},"end":{"line":493,"column":4,"offset":17644},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":495,"column":1,"offset":17646},"end":{"line":495,"column":72,"offset":17717},"indent":[]}}],"position":{"start":{"line":495,"column":1,"offset":17646},"end":{"line":495,"column":72,"offset":17717},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":497,"column":1,"offset":17719},"end":{"line":499,"column":4,"offset":17780},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":502,"column":1,"offset":17783},"end":{"line":502,"column":31,"offset":17813},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":502,"column":31,"offset":17813}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug-and-Play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS for Raspberry Pi`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.`}

\n

{`Especially in the worl\neven on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.`}

\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-9a7c34ea4af7641209130611e67a9961.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-9a7c34ea4af7641209130611e67a9961.json new file mode 100644 index 0000000..35ff6f4 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-9a7c34ea4af7641209130611e67a9961.json @@ -0,0 +1 @@ +{"expireTime":9007200842320153000,"key":"gatsby-plugin-mdx-entire-payload-59d862b71643ddd8f26d91335616c6ef-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4645},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4647},"end":{"line":107,"column":80,"offset":4726},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4726},"end":{"line":107,"column":101,"offset":4747},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4747},"end":{"line":107,"column":162,"offset":4808},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4647},"end":{"line":107,"column":162,"offset":4808},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4810},"end":{"line":112,"column":4,"offset":4899},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4904},"end":{"line":114,"column":10,"offset":4910},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4901},"end":{"line":114,"column":10,"offset":4910},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on ","position":{"start":{"line":116,"column":1,"offset":4912},"end":{"line":116,"column":54,"offset":4965},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":55,"offset":4966},"end":{"line":116,"column":69,"offset":4980},"indent":[]}}],"position":{"start":{"line":116,"column":54,"offset":4965},"end":{"line":116,"column":105,"offset":5016},"indent":[]}},{"type":"text","value":", which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use DDocker, to get the Kerberos agent up and running. All Docker images can be found on ","position":{"start":{"line":116,"column":105,"offset":5016},"end":{"line":116,"column":377,"offset":5288},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":378,"offset":5289},"end":{"line":116,"column":392,"offset":5303},"indent":[]}}],"position":{"start":{"line":116,"column":377,"offset":5288},"end":{"line":116,"column":428,"offset":5339},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":428,"offset":5339},"end":{"line":116,"column":429,"offset":5340},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4912},"end":{"line":116,"column":429,"offset":5340},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5346},"end":{"line":118,"column":18,"offset":5359},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5342},"end":{"line":118,"column":18,"offset":5359},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5363},"end":{"line":120,"column":50,"offset":5410},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5363},"end":{"line":120,"column":50,"offset":5410},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5361},"end":{"line":120,"column":50,"offset":5410},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5416},"end":{"line":122,"column":11,"offset":5422},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5412},"end":{"line":122,"column":11,"offset":5422},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5424},"end":{"line":124,"column":64,"offset":5487},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5488},"end":{"line":124,"column":86,"offset":5509},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5487},"end":{"line":124,"column":126,"offset":5549},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5549},"end":{"line":124,"column":127,"offset":5550},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5424},"end":{"line":124,"column":127,"offset":5550},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5556},"end":{"line":126,"column":26,"offset":5577},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5552},"end":{"line":126,"column":26,"offset":5577},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5579},"end":{"line":128,"column":126,"offset":5704},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5579},"end":{"line":128,"column":126,"offset":5704},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5706},"end":{"line":132,"column":4,"offset":5745},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5747},"end":{"line":134,"column":187,"offset":5933},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5747},"end":{"line":134,"column":187,"offset":5933},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5935},"end":{"line":138,"column":4,"offset":6013},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6015},"end":{"line":140,"column":153,"offset":6167},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6015},"end":{"line":140,"column":153,"offset":6167},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6169},"end":{"line":145,"column":4,"offset":6316},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6318},"end":{"line":147,"column":100,"offset":6417},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6318},"end":{"line":147,"column":100,"offset":6417},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6418},"end":{"line":152,"column":4,"offset":6487},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6493},"end":{"line":154,"column":12,"offset":6500},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6489},"end":{"line":154,"column":12,"offset":6500},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Instead of just running the Kerberos container, you can also persist your configuration by assigning volumes. An example of mounting volumes looks like this; an overview of ","position":{"start":{"line":156,"column":1,"offset":6502},"end":{"line":156,"column":174,"offset":6675},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker/blob/master/Dockerfile#L171-L177","children":[{"type":"text","value":"the different volumes can be found here","position":{"start":{"line":156,"column":175,"offset":6676},"end":{"line":156,"column":214,"offset":6715},"indent":[]}}],"position":{"start":{"line":156,"column":174,"offset":6675},"end":{"line":156,"column":287,"offset":6788},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":156,"column":287,"offset":6788},"end":{"line":156,"column":288,"offset":6789},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6502},"end":{"line":156,"column":288,"offset":6789},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":158,"column":3,"offset":6793},"end":{"line":158,"column":25,"offset":6815},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6793},"end":{"line":158,"column":25,"offset":6815},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6791},"end":{"line":158,"column":25,"offset":6815},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":159,"column":3,"offset":6818},"end":{"line":159,"column":59,"offset":6874},"indent":[]}}],"position":{"start":{"line":159,"column":3,"offset":6818},"end":{"line":159,"column":59,"offset":6874},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":6816},"end":{"line":159,"column":59,"offset":6874},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6791},"end":{"line":159,"column":59,"offset":6874},"indent":[1]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name kerberos-camera1 \\\n-p 80:80 -p 8889:8889 \\\n-v ~/config:/etc/opt/kerberosio/config \\\n-v ~/capture:/etc/opt/kerberosio/capture \\\n-v ~/logs:/etc/opt/kerberosio/logs \\\n-v ~/webconfig:/var/www/web/config \\\n-d kerberos/kerberos","position":{"start":{"line":161,"column":1,"offset":6876},"end":{"line":169,"column":4,"offset":7125},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.","position":{"start":{"line":171,"column":1,"offset":7127},"end":{"line":171,"column":87,"offset":7213},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":7127},"end":{"line":171,"column":87,"offset":7213},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://medium.com/@cedricverst/kerberos-io-the-road-to-docker-8e048a480241","children":[{"type":"text","value":"Kerberos.io — the road to Docker","position":{"start":{"line":172,"column":4,"offset":7217},"end":{"line":172,"column":36,"offset":7249},"indent":[]}}],"position":{"start":{"line":172,"column":3,"offset":7216},"end":{"line":172,"column":114,"offset":7327},"indent":[]}}],"position":{"start":{"line":172,"column":3,"offset":7216},"end":{"line":172,"column":114,"offset":7327},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7214},"end":{"line":172,"column":114,"offset":7327},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7214},"end":{"line":172,"column":114,"offset":7327},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":175,"column":4,"offset":7333},"end":{"line":175,"column":10,"offset":7339},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7330},"end":{"line":175,"column":10,"offset":7339},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.","position":{"start":{"line":177,"column":1,"offset":7341},"end":{"line":177,"column":310,"offset":7650},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7341},"end":{"line":177,"column":310,"offset":7650},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To fill the gap, regarding the latter, we can rely on another solution called ","position":{"start":{"line":179,"column":1,"offset":7652},"end":{"line":179,"column":79,"offset":7730},"indent":[]}},{"type":"link","title":null,"url":"https://balena.io","children":[{"type":"text","value":"Balena.io","position":{"start":{"line":179,"column":80,"offset":7731},"end":{"line":179,"column":89,"offset":7740},"indent":[]}}],"position":{"start":{"line":179,"column":79,"offset":7730},"end":{"line":179,"column":109,"offset":7760},"indent":[]}},{"type":"text","value":". Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).","position":{"start":{"line":179,"column":109,"offset":7760},"end":{"line":179,"column":386,"offset":8037},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7652},"end":{"line":179,"column":386,"offset":8037},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On top of supporting a lot of boars,","position":{"start":{"line":181,"column":1,"offset":8039},"end":{"line":181,"column":37,"offset":8075},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":8039},"end":{"line":181,"column":37,"offset":8075},"indent":[]}},{"type":"thematicBreak","position":{"start":{"line":183,"column":1,"offset":8077},"end":{"line":183,"column":4,"offset":8080},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":185,"column":3,"offset":8084},"end":{"line":185,"column":11,"offset":8092},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":8082},"end":{"line":185,"column":11,"offset":8092},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":187,"column":1,"offset":8094},"end":{"line":187,"column":133,"offset":8226},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":8094},"end":{"line":187,"column":133,"offset":8226},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":189,"column":4,"offset":8231},"end":{"line":189,"column":12,"offset":8239},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":8228},"end":{"line":189,"column":12,"offset":8239},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":191,"column":1,"offset":8241},"end":{"line":191,"column":193,"offset":8433},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":8241},"end":{"line":191,"column":193,"offset":8433},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":193,"column":4,"offset":8438},"end":{"line":193,"column":62,"offset":8496},"indent":[]}}],"position":{"start":{"line":193,"column":4,"offset":8438},"end":{"line":193,"column":62,"offset":8496},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8435},"end":{"line":193,"column":62,"offset":8496},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":194,"column":4,"offset":8500},"end":{"line":194,"column":69,"offset":8565},"indent":[]}}],"position":{"start":{"line":194,"column":4,"offset":8500},"end":{"line":194,"column":69,"offset":8565},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":8497},"end":{"line":194,"column":69,"offset":8565},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8435},"end":{"line":194,"column":69,"offset":8565},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":196,"column":1,"offset":8567},"end":{"line":196,"column":99,"offset":8665},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8567},"end":{"line":196,"column":99,"offset":8665},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":198,"column":5,"offset":8671},"end":{"line":198,"column":14,"offset":8680},"indent":[]}}],"position":{"start":{"line":198,"column":1,"offset":8667},"end":{"line":198,"column":14,"offset":8680},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":200,"column":1,"offset":8682},"end":{"line":200,"column":71,"offset":8752},"indent":[]}}],"position":{"start":{"line":200,"column":1,"offset":8682},"end":{"line":200,"column":71,"offset":8752},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":202,"column":3,"offset":8756},"end":{"line":202,"column":47,"offset":8800},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":202,"column":47,"offset":8800},"end":{"line":202,"column":79,"offset":8832},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":202,"column":79,"offset":8832},"end":{"line":202,"column":198,"offset":8951},"indent":[]}}],"position":{"start":{"line":202,"column":3,"offset":8756},"end":{"line":202,"column":198,"offset":8951},"indent":[]}}],"position":{"start":{"line":202,"column":1,"offset":8754},"end":{"line":202,"column":198,"offset":8951},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":204,"column":1,"offset":8953},"end":{"line":206,"column":4,"offset":9016},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":208,"column":5,"offset":9022},"end":{"line":208,"column":14,"offset":9031},"indent":[]}}],"position":{"start":{"line":208,"column":1,"offset":9018},"end":{"line":208,"column":14,"offset":9031},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":210,"column":1,"offset":9033},"end":{"line":210,"column":56,"offset":9088},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":9033},"end":{"line":210,"column":56,"offset":9088},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":211,"column":3,"offset":9091},"end":{"line":211,"column":52,"offset":9140},"indent":[]}}],"position":{"start":{"line":211,"column":3,"offset":9091},"end":{"line":211,"column":52,"offset":9140},"indent":[]}}],"position":{"start":{"line":211,"column":3,"offset":9091},"end":{"line":211,"column":52,"offset":9140},"indent":[]}}],"position":{"start":{"line":211,"column":1,"offset":9089},"end":{"line":211,"column":52,"offset":9140},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":213,"column":1,"offset":9142},"end":{"line":213,"column":3,"offset":9144},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":213,"column":3,"offset":9144},"end":{"line":213,"column":9,"offset":9150},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":213,"column":9,"offset":9150},"end":{"line":213,"column":223,"offset":9364},"indent":[]}}],"position":{"start":{"line":213,"column":1,"offset":9142},"end":{"line":213,"column":223,"offset":9364},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":215,"column":3,"offset":9368},"end":{"line":215,"column":159,"offset":9524},"indent":[]}}],"position":{"start":{"line":215,"column":3,"offset":9368},"end":{"line":215,"column":159,"offset":9524},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":9366},"end":{"line":215,"column":159,"offset":9524},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":217,"column":1,"offset":9526},"end":{"line":220,"column":4,"offset":9703},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":222,"column":1,"offset":9705},"end":{"line":222,"column":160,"offset":9864},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":9705},"end":{"line":222,"column":160,"offset":9864},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":224,"column":3,"offset":9868},"end":{"line":224,"column":31,"offset":9896},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":224,"column":31,"offset":9896},"end":{"line":224,"column":101,"offset":9966},"indent":[]}}],"position":{"start":{"line":224,"column":3,"offset":9868},"end":{"line":224,"column":101,"offset":9966},"indent":[]}}],"position":{"start":{"line":224,"column":1,"offset":9866},"end":{"line":224,"column":101,"offset":9966},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":226,"column":1,"offset":9968},"end":{"line":229,"column":4,"offset":10140},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":231,"column":1,"offset":10142},"end":{"line":231,"column":73,"offset":10214},"indent":[]}}],"position":{"start":{"line":231,"column":1,"offset":10142},"end":{"line":231,"column":73,"offset":10214},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":234,"column":3,"offset":10219},"end":{"line":234,"column":31,"offset":10247},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":234,"column":31,"offset":10247},"end":{"line":234,"column":101,"offset":10317},"indent":[]}}],"position":{"start":{"line":234,"column":3,"offset":10219},"end":{"line":234,"column":101,"offset":10317},"indent":[]}}],"position":{"start":{"line":234,"column":1,"offset":10217},"end":{"line":234,"column":101,"offset":10317},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":236,"column":1,"offset":10319},"end":{"line":239,"column":4,"offset":10491},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":241,"column":1,"offset":10493},"end":{"line":241,"column":62,"offset":10554},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":241,"column":63,"offset":10555},"end":{"line":241,"column":75,"offset":10567},"indent":[]}}],"position":{"start":{"line":241,"column":62,"offset":10554},"end":{"line":241,"column":143,"offset":10635},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":241,"column":143,"offset":10635},"end":{"line":241,"column":150,"offset":10642},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":241,"column":150,"offset":10642},"end":{"line":241,"column":169,"offset":10661},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":241,"column":169,"offset":10661},"end":{"line":241,"column":170,"offset":10662},"indent":[]}}],"position":{"start":{"line":241,"column":1,"offset":10493},"end":{"line":241,"column":170,"offset":10662},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":243,"column":1,"offset":10664},"end":{"line":245,"column":4,"offset":10691},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":247,"column":1,"offset":10693},"end":{"line":247,"column":58,"offset":10750},"indent":[]}}],"position":{"start":{"line":247,"column":1,"offset":10693},"end":{"line":247,"column":58,"offset":10750},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":249,"column":1,"offset":10752},"end":{"line":252,"column":4,"offset":10822},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":254,"column":5,"offset":10828},"end":{"line":254,"column":8,"offset":10831},"indent":[]}}],"position":{"start":{"line":254,"column":1,"offset":10824},"end":{"line":254,"column":8,"offset":10831},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":256,"column":1,"offset":10833},"end":{"line":256,"column":280,"offset":11112},"indent":[]}}],"position":{"start":{"line":256,"column":1,"offset":10833},"end":{"line":256,"column":280,"offset":11112},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":258,"column":1,"offset":11114},"end":{"line":258,"column":37,"offset":11150},"indent":[]}}],"position":{"start":{"line":258,"column":1,"offset":11114},"end":{"line":258,"column":37,"offset":11150},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":260,"column":1,"offset":11152},"end":{"line":262,"column":4,"offset":11325},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":264,"column":1,"offset":11327},"end":{"line":264,"column":25,"offset":11351},"indent":[]}}],"position":{"start":{"line":264,"column":1,"offset":11327},"end":{"line":264,"column":25,"offset":11351},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":266,"column":1,"offset":11353},"end":{"line":269,"column":4,"offset":11457},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":271,"column":1,"offset":11459},"end":{"line":271,"column":118,"offset":11576},"indent":[]}}],"position":{"start":{"line":271,"column":1,"offset":11459},"end":{"line":271,"column":118,"offset":11576},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":273,"column":1,"offset":11578},"end":{"line":293,"column":4,"offset":12085},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":295,"column":1,"offset":12087},"end":{"line":295,"column":14,"offset":12100},"indent":[]}}],"position":{"start":{"line":295,"column":1,"offset":12087},"end":{"line":295,"column":14,"offset":12100},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":297,"column":1,"offset":12102},"end":{"line":299,"column":4,"offset":12138},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":301,"column":1,"offset":12140},"end":{"line":301,"column":91,"offset":12230},"indent":[]}}],"position":{"start":{"line":301,"column":1,"offset":12140},"end":{"line":301,"column":91,"offset":12230},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":303,"column":1,"offset":12232},"end":{"line":311,"column":4,"offset":12605},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":313,"column":1,"offset":12607},"end":{"line":313,"column":145,"offset":12751},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":12607},"end":{"line":313,"column":145,"offset":12751},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":315,"column":5,"offset":12757},"end":{"line":315,"column":17,"offset":12769},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12753},"end":{"line":315,"column":17,"offset":12769},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":317,"column":1,"offset":12771},"end":{"line":317,"column":300,"offset":13070},"indent":[]}}],"position":{"start":{"line":317,"column":1,"offset":12771},"end":{"line":317,"column":300,"offset":13070},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":319,"column":1,"offset":13072},"end":{"line":319,"column":178,"offset":13249},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":13072},"end":{"line":319,"column":178,"offset":13249},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":321,"column":1,"offset":13251},"end":{"line":321,"column":48,"offset":13298},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":13251},"end":{"line":321,"column":48,"offset":13298},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":323,"column":1,"offset":13300},"end":{"line":325,"column":4,"offset":13340},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":327,"column":1,"offset":13342},"end":{"line":327,"column":104,"offset":13445},"indent":[]}}],"position":{"start":{"line":327,"column":1,"offset":13342},"end":{"line":327,"column":104,"offset":13445},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":329,"column":1,"offset":13447},"end":{"line":337,"column":4,"offset":13717},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":339,"column":1,"offset":13719},"end":{"line":339,"column":28,"offset":13746},"indent":[]}}],"position":{"start":{"line":339,"column":1,"offset":13719},"end":{"line":339,"column":28,"offset":13746},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":341,"column":1,"offset":13748},"end":{"line":343,"column":4,"offset":13792},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":345,"column":1,"offset":13794},"end":{"line":345,"column":48,"offset":13841},"indent":[]}}],"position":{"start":{"line":345,"column":1,"offset":13794},"end":{"line":345,"column":48,"offset":13841},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":347,"column":1,"offset":13843},"end":{"line":349,"column":4,"offset":13865},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":351,"column":1,"offset":13867},"end":{"line":351,"column":72,"offset":13938},"indent":[]}}],"position":{"start":{"line":351,"column":1,"offset":13867},"end":{"line":351,"column":72,"offset":13938},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":353,"column":1,"offset":13940},"end":{"line":355,"column":4,"offset":13997},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":357,"column":4,"offset":14002},"end":{"line":357,"column":11,"offset":14009},"indent":[]}}],"position":{"start":{"line":357,"column":1,"offset":13999},"end":{"line":357,"column":11,"offset":14009},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":359,"column":1,"offset":14011},"end":{"line":359,"column":283,"offset":14293},"indent":[]}}],"position":{"start":{"line":359,"column":1,"offset":14011},"end":{"line":359,"column":283,"offset":14293},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":361,"column":3,"offset":14297},"end":{"line":361,"column":54,"offset":14348},"indent":[]}}],"position":{"start":{"line":361,"column":3,"offset":14297},"end":{"line":361,"column":54,"offset":14348},"indent":[]}}],"position":{"start":{"line":361,"column":1,"offset":14295},"end":{"line":361,"column":54,"offset":14348},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":363,"column":5,"offset":14354},"end":{"line":363,"column":14,"offset":14363},"indent":[]}}],"position":{"start":{"line":363,"column":1,"offset":14350},"end":{"line":363,"column":14,"offset":14363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":365,"column":1,"offset":14365},"end":{"line":365,"column":68,"offset":14432},"indent":[]}}],"position":{"start":{"line":365,"column":1,"offset":14365},"end":{"line":365,"column":68,"offset":14432},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":367,"column":1,"offset":14434},"end":{"line":370,"column":4,"offset":14585},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":372,"column":1,"offset":14587},"end":{"line":372,"column":46,"offset":14632},"indent":[]}}],"position":{"start":{"line":372,"column":1,"offset":14587},"end":{"line":372,"column":46,"offset":14632},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":374,"column":3,"offset":14636},"end":{"line":374,"column":103,"offset":14736},"indent":[]}}],"position":{"start":{"line":374,"column":3,"offset":14636},"end":{"line":374,"column":103,"offset":14736},"indent":[]}}],"position":{"start":{"line":374,"column":1,"offset":14634},"end":{"line":374,"column":103,"offset":14736},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":376,"column":1,"offset":14738},"end":{"line":381,"column":4,"offset":14948},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":383,"column":1,"offset":14950},"end":{"line":383,"column":151,"offset":15100},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14950},"end":{"line":383,"column":151,"offset":15100},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":385,"column":3,"offset":15104},"end":{"line":385,"column":22,"offset":15123},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":385,"column":22,"offset":15123},"end":{"line":385,"column":26,"offset":15127},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":385,"column":26,"offset":15127},"end":{"line":385,"column":40,"offset":15141},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":385,"column":40,"offset":15141},"end":{"line":385,"column":50,"offset":15151},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":385,"column":50,"offset":15151},"end":{"line":385,"column":98,"offset":15199},"indent":[]}}],"position":{"start":{"line":385,"column":3,"offset":15104},"end":{"line":385,"column":98,"offset":15199},"indent":[]}}],"position":{"start":{"line":385,"column":1,"offset":15102},"end":{"line":385,"column":98,"offset":15199},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":387,"column":1,"offset":15201},"end":{"line":391,"column":4,"offset":15363},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":393,"column":1,"offset":15365},"end":{"line":393,"column":72,"offset":15436},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":393,"column":72,"offset":15436},"end":{"line":393,"column":84,"offset":15448},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":393,"column":84,"offset":15448},"end":{"line":393,"column":102,"offset":15466},"indent":[]}}],"position":{"start":{"line":393,"column":1,"offset":15365},"end":{"line":393,"column":102,"offset":15466},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":395,"column":1,"offset":15468},"end":{"line":398,"column":4,"offset":15542},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":400,"column":5,"offset":15548},"end":{"line":400,"column":8,"offset":15551},"indent":[]}}],"position":{"start":{"line":400,"column":1,"offset":15544},"end":{"line":400,"column":8,"offset":15551},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":402,"column":1,"offset":15553},"end":{"line":402,"column":176,"offset":15728},"indent":[]}}],"position":{"start":{"line":402,"column":1,"offset":15553},"end":{"line":402,"column":176,"offset":15728},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":404,"column":1,"offset":15730},"end":{"line":411,"column":4,"offset":16027},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":413,"column":1,"offset":16029},"end":{"line":413,"column":60,"offset":16088},"indent":[]}}],"position":{"start":{"line":413,"column":1,"offset":16029},"end":{"line":413,"column":60,"offset":16088},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":415,"column":1,"offset":16090},"end":{"line":419,"column":4,"offset":16216},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":421,"column":1,"offset":16218},"end":{"line":421,"column":63,"offset":16280},"indent":[]}}],"position":{"start":{"line":421,"column":1,"offset":16218},"end":{"line":421,"column":63,"offset":16280},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":423,"column":1,"offset":16282},"end":{"line":443,"column":4,"offset":16789},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":445,"column":1,"offset":16791},"end":{"line":445,"column":99,"offset":16889},"indent":[]}}],"position":{"start":{"line":445,"column":1,"offset":16791},"end":{"line":445,"column":99,"offset":16889},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":447,"column":1,"offset":16891},"end":{"line":450,"column":4,"offset":16993},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":452,"column":1,"offset":16995},"end":{"line":452,"column":37,"offset":17031},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":452,"column":37,"offset":17031},"end":{"line":452,"column":47,"offset":17041},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":452,"column":47,"offset":17041},"end":{"line":452,"column":89,"offset":17083},"indent":[]}}],"position":{"start":{"line":452,"column":1,"offset":16995},"end":{"line":452,"column":89,"offset":17083},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":454,"column":1,"offset":17085},"end":{"line":458,"column":4,"offset":17210},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":460,"column":1,"offset":17212},"end":{"line":460,"column":78,"offset":17289},"indent":[]}}],"position":{"start":{"line":460,"column":1,"offset":17212},"end":{"line":460,"column":78,"offset":17289},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":462,"column":1,"offset":17291},"end":{"line":466,"column":4,"offset":17395},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":468,"column":1,"offset":17397},"end":{"line":468,"column":75,"offset":17471},"indent":[]}}],"position":{"start":{"line":468,"column":1,"offset":17397},"end":{"line":468,"column":75,"offset":17471},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":470,"column":1,"offset":17473},"end":{"line":474,"column":4,"offset":17546},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":476,"column":1,"offset":17548},"end":{"line":476,"column":145,"offset":17692},"indent":[]}}],"position":{"start":{"line":476,"column":1,"offset":17548},"end":{"line":476,"column":145,"offset":17692},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":478,"column":5,"offset":17698},"end":{"line":478,"column":17,"offset":17710},"indent":[]}}],"position":{"start":{"line":478,"column":1,"offset":17694},"end":{"line":478,"column":17,"offset":17710},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":480,"column":1,"offset":17712},"end":{"line":480,"column":300,"offset":18011},"indent":[]}}],"position":{"start":{"line":480,"column":1,"offset":17712},"end":{"line":480,"column":300,"offset":18011},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":482,"column":1,"offset":18013},"end":{"line":482,"column":178,"offset":18190},"indent":[]}}],"position":{"start":{"line":482,"column":1,"offset":18013},"end":{"line":482,"column":178,"offset":18190},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":484,"column":1,"offset":18192},"end":{"line":484,"column":48,"offset":18239},"indent":[]}}],"position":{"start":{"line":484,"column":1,"offset":18192},"end":{"line":484,"column":48,"offset":18239},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":486,"column":1,"offset":18241},"end":{"line":488,"column":4,"offset":18285},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":490,"column":1,"offset":18287},"end":{"line":490,"column":104,"offset":18390},"indent":[]}}],"position":{"start":{"line":490,"column":1,"offset":18287},"end":{"line":490,"column":104,"offset":18390},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":492,"column":1,"offset":18392},"end":{"line":500,"column":4,"offset":18662},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":502,"column":1,"offset":18664},"end":{"line":502,"column":28,"offset":18691},"indent":[]}}],"position":{"start":{"line":502,"column":1,"offset":18664},"end":{"line":502,"column":28,"offset":18691},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":504,"column":1,"offset":18693},"end":{"line":506,"column":4,"offset":18741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":508,"column":1,"offset":18743},"end":{"line":508,"column":48,"offset":18790},"indent":[]}}],"position":{"start":{"line":508,"column":1,"offset":18743},"end":{"line":508,"column":48,"offset":18790},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":510,"column":1,"offset":18792},"end":{"line":512,"column":4,"offset":18814},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":514,"column":1,"offset":18816},"end":{"line":514,"column":72,"offset":18887},"indent":[]}}],"position":{"start":{"line":514,"column":1,"offset":18816},"end":{"line":514,"column":72,"offset":18887},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":516,"column":1,"offset":18889},"end":{"line":518,"column":4,"offset":18950},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":521,"column":1,"offset":18953},"end":{"line":521,"column":31,"offset":18983},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":521,"column":31,"offset":18983}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on `}{`the Docker hub`}{`, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use DDocker, to get the Kerberos agent up and running. All Docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`Instead of just running the Kerberos container, you can also persist your configuration by assigning volumes. An example of mounting volumes looks like this; an overview of `}{`the different volumes can be found here`}{`.`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`kerberos`}{`-`}{`camera1`}{` \\\\`}{`\n`}{`-`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/config:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`config`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/capture:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`capture`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/logs:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`logs`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/webconfig:/`}{`var`}{`/`}{`www`}{`/web/config \\\\`}{`\n`}{`-`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.`}

\n \n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.`}

\n

{`To fill the gap, regarding the latter, we can rely on another solution called `}{`Balena.io`}{`. Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).`}

\n

{`On top of supporting a lot of boars,`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-9c0f902ec1f902379deebc0934cd225c.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-9c0f902ec1f902379deebc0934cd225c.json new file mode 100644 index 0000000..7542b81 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-9c0f902ec1f902379deebc0934cd225c.json @@ -0,0 +1 @@ +{"expireTime":9007200842327605000,"key":"gatsby-plugin-mdx-entire-payload-936149cdd6f05400b24209e9e66baa1c-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4645},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4647},"end":{"line":107,"column":80,"offset":4726},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4726},"end":{"line":107,"column":101,"offset":4747},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4747},"end":{"line":107,"column":162,"offset":4808},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4647},"end":{"line":107,"column":162,"offset":4808},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4810},"end":{"line":112,"column":4,"offset":4899},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4904},"end":{"line":114,"column":10,"offset":4910},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4901},"end":{"line":114,"column":10,"offset":4910},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on ","position":{"start":{"line":116,"column":1,"offset":4912},"end":{"line":116,"column":54,"offset":4965},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":55,"offset":4966},"end":{"line":116,"column":69,"offset":4980},"indent":[]}}],"position":{"start":{"line":116,"column":54,"offset":4965},"end":{"line":116,"column":105,"offset":5016},"indent":[]}},{"type":"text","value":", which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use Docker, to get the Kerberos agent up and running. All Docker images can be found on ","position":{"start":{"line":116,"column":105,"offset":5016},"end":{"line":116,"column":376,"offset":5287},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":377,"offset":5288},"end":{"line":116,"column":391,"offset":5302},"indent":[]}}],"position":{"start":{"line":116,"column":376,"offset":5287},"end":{"line":116,"column":427,"offset":5338},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":427,"offset":5338},"end":{"line":116,"column":428,"offset":5339},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4912},"end":{"line":116,"column":428,"offset":5339},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5345},"end":{"line":118,"column":18,"offset":5358},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5341},"end":{"line":118,"column":18,"offset":5358},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5362},"end":{"line":120,"column":50,"offset":5409},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5362},"end":{"line":120,"column":50,"offset":5409},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5360},"end":{"line":120,"column":50,"offset":5409},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5415},"end":{"line":122,"column":11,"offset":5421},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5411},"end":{"line":122,"column":11,"offset":5421},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5423},"end":{"line":124,"column":64,"offset":5486},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5487},"end":{"line":124,"column":86,"offset":5508},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5486},"end":{"line":124,"column":126,"offset":5548},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5548},"end":{"line":124,"column":127,"offset":5549},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5423},"end":{"line":124,"column":127,"offset":5549},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5555},"end":{"line":126,"column":26,"offset":5576},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5551},"end":{"line":126,"column":26,"offset":5576},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5578},"end":{"line":128,"column":126,"offset":5703},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5578},"end":{"line":128,"column":126,"offset":5703},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5705},"end":{"line":132,"column":4,"offset":5744},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5746},"end":{"line":134,"column":187,"offset":5932},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5746},"end":{"line":134,"column":187,"offset":5932},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5934},"end":{"line":138,"column":4,"offset":6012},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6014},"end":{"line":140,"column":153,"offset":6166},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6014},"end":{"line":140,"column":153,"offset":6166},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6168},"end":{"line":145,"column":4,"offset":6315},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6317},"end":{"line":147,"column":100,"offset":6416},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6317},"end":{"line":147,"column":100,"offset":6416},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6417},"end":{"line":152,"column":4,"offset":6486},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6492},"end":{"line":154,"column":12,"offset":6499},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6488},"end":{"line":154,"column":12,"offset":6499},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Instead of just running the Kerberos container, you can also persist your configuration by assigning volumes. An example of mounting volumes looks like this; an overview of ","position":{"start":{"line":156,"column":1,"offset":6501},"end":{"line":156,"column":174,"offset":6674},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker/blob/master/Dockerfile#L171-L177","children":[{"type":"text","value":"the different volumes can be found here","position":{"start":{"line":156,"column":175,"offset":6675},"end":{"line":156,"column":214,"offset":6714},"indent":[]}}],"position":{"start":{"line":156,"column":174,"offset":6674},"end":{"line":156,"column":287,"offset":6787},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":156,"column":287,"offset":6787},"end":{"line":156,"column":288,"offset":6788},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6501},"end":{"line":156,"column":288,"offset":6788},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":158,"column":3,"offset":6792},"end":{"line":158,"column":25,"offset":6814},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6792},"end":{"line":158,"column":25,"offset":6814},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6790},"end":{"line":158,"column":25,"offset":6814},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":159,"column":3,"offset":6817},"end":{"line":159,"column":59,"offset":6873},"indent":[]}}],"position":{"start":{"line":159,"column":3,"offset":6817},"end":{"line":159,"column":59,"offset":6873},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":6815},"end":{"line":159,"column":59,"offset":6873},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6790},"end":{"line":159,"column":59,"offset":6873},"indent":[1]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name kerberos-camera1 \\\n-p 80:80 -p 8889:8889 \\\n-v ~/config:/etc/opt/kerberosio/config \\\n-v ~/capture:/etc/opt/kerberosio/capture \\\n-v ~/logs:/etc/opt/kerberosio/logs \\\n-v ~/webconfig:/var/www/web/config \\\n-d kerberos/kerberos","position":{"start":{"line":161,"column":1,"offset":6875},"end":{"line":169,"column":4,"offset":7124},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.","position":{"start":{"line":171,"column":1,"offset":7126},"end":{"line":171,"column":87,"offset":7212},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":7126},"end":{"line":171,"column":87,"offset":7212},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://medium.com/@cedricverst/kerberos-io-the-road-to-docker-8e048a480241","children":[{"type":"text","value":"Kerberos.io — the road to Docker","position":{"start":{"line":172,"column":4,"offset":7216},"end":{"line":172,"column":36,"offset":7248},"indent":[]}}],"position":{"start":{"line":172,"column":3,"offset":7215},"end":{"line":172,"column":114,"offset":7326},"indent":[]}}],"position":{"start":{"line":172,"column":3,"offset":7215},"end":{"line":172,"column":114,"offset":7326},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7213},"end":{"line":172,"column":114,"offset":7326},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://medium.com/@cedricverst/kerberos-io-on-docker-19b25fa7efd1","children":[{"type":"text","value":"Kerberos.io on Docker","position":{"start":{"line":173,"column":4,"offset":7330},"end":{"line":173,"column":25,"offset":7351},"indent":[]}}],"position":{"start":{"line":173,"column":3,"offset":7329},"end":{"line":173,"column":94,"offset":7420},"indent":[]}}],"position":{"start":{"line":173,"column":3,"offset":7329},"end":{"line":173,"column":94,"offset":7420},"indent":[]}}],"position":{"start":{"line":173,"column":1,"offset":7327},"end":{"line":173,"column":94,"offset":7420},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7213},"end":{"line":173,"column":94,"offset":7420},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":176,"column":4,"offset":7426},"end":{"line":176,"column":10,"offset":7432},"indent":[]}}],"position":{"start":{"line":176,"column":1,"offset":7423},"end":{"line":176,"column":10,"offset":7432},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.","position":{"start":{"line":178,"column":1,"offset":7434},"end":{"line":178,"column":310,"offset":7743},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7434},"end":{"line":178,"column":310,"offset":7743},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To fill the gap, regarding the latter, we can rely on another solution called ","position":{"start":{"line":180,"column":1,"offset":7745},"end":{"line":180,"column":79,"offset":7823},"indent":[]}},{"type":"link","title":null,"url":"https://balena.io","children":[{"type":"text","value":"Balena.io","position":{"start":{"line":180,"column":80,"offset":7824},"end":{"line":180,"column":89,"offset":7833},"indent":[]}}],"position":{"start":{"line":180,"column":79,"offset":7823},"end":{"line":180,"column":109,"offset":7853},"indent":[]}},{"type":"text","value":". Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).","position":{"start":{"line":180,"column":109,"offset":7853},"end":{"line":180,"column":386,"offset":8130},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7745},"end":{"line":180,"column":386,"offset":8130},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On top of supporting a lot of boars,","position":{"start":{"line":182,"column":1,"offset":8132},"end":{"line":182,"column":37,"offset":8168},"indent":[]}}],"position":{"start":{"line":182,"column":1,"offset":8132},"end":{"line":182,"column":37,"offset":8168},"indent":[]}},{"type":"thematicBreak","position":{"start":{"line":184,"column":1,"offset":8170},"end":{"line":184,"column":4,"offset":8173},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":186,"column":3,"offset":8177},"end":{"line":186,"column":11,"offset":8185},"indent":[]}}],"position":{"start":{"line":186,"column":1,"offset":8175},"end":{"line":186,"column":11,"offset":8185},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":188,"column":1,"offset":8187},"end":{"line":188,"column":133,"offset":8319},"indent":[]}}],"position":{"start":{"line":188,"column":1,"offset":8187},"end":{"line":188,"column":133,"offset":8319},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":190,"column":4,"offset":8324},"end":{"line":190,"column":12,"offset":8332},"indent":[]}}],"position":{"start":{"line":190,"column":1,"offset":8321},"end":{"line":190,"column":12,"offset":8332},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":192,"column":1,"offset":8334},"end":{"line":192,"column":193,"offset":8526},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":8334},"end":{"line":192,"column":193,"offset":8526},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":194,"column":4,"offset":8531},"end":{"line":194,"column":62,"offset":8589},"indent":[]}}],"position":{"start":{"line":194,"column":4,"offset":8531},"end":{"line":194,"column":62,"offset":8589},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":8528},"end":{"line":194,"column":62,"offset":8589},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":195,"column":4,"offset":8593},"end":{"line":195,"column":69,"offset":8658},"indent":[]}}],"position":{"start":{"line":195,"column":4,"offset":8593},"end":{"line":195,"column":69,"offset":8658},"indent":[]}}],"position":{"start":{"line":195,"column":1,"offset":8590},"end":{"line":195,"column":69,"offset":8658},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":8528},"end":{"line":195,"column":69,"offset":8658},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":197,"column":1,"offset":8660},"end":{"line":197,"column":99,"offset":8758},"indent":[]}}],"position":{"start":{"line":197,"column":1,"offset":8660},"end":{"line":197,"column":99,"offset":8758},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":199,"column":5,"offset":8764},"end":{"line":199,"column":14,"offset":8773},"indent":[]}}],"position":{"start":{"line":199,"column":1,"offset":8760},"end":{"line":199,"column":14,"offset":8773},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":201,"column":1,"offset":8775},"end":{"line":201,"column":71,"offset":8845},"indent":[]}}],"position":{"start":{"line":201,"column":1,"offset":8775},"end":{"line":201,"column":71,"offset":8845},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":203,"column":3,"offset":8849},"end":{"line":203,"column":47,"offset":8893},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":203,"column":47,"offset":8893},"end":{"line":203,"column":79,"offset":8925},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":203,"column":79,"offset":8925},"end":{"line":203,"column":198,"offset":9044},"indent":[]}}],"position":{"start":{"line":203,"column":3,"offset":8849},"end":{"line":203,"column":198,"offset":9044},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":8847},"end":{"line":203,"column":198,"offset":9044},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":205,"column":1,"offset":9046},"end":{"line":207,"column":4,"offset":9109},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":209,"column":5,"offset":9115},"end":{"line":209,"column":14,"offset":9124},"indent":[]}}],"position":{"start":{"line":209,"column":1,"offset":9111},"end":{"line":209,"column":14,"offset":9124},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":211,"column":1,"offset":9126},"end":{"line":211,"column":56,"offset":9181},"indent":[]}}],"position":{"start":{"line":211,"column":1,"offset":9126},"end":{"line":211,"column":56,"offset":9181},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":212,"column":3,"offset":9184},"end":{"line":212,"column":52,"offset":9233},"indent":[]}}],"position":{"start":{"line":212,"column":3,"offset":9184},"end":{"line":212,"column":52,"offset":9233},"indent":[]}}],"position":{"start":{"line":212,"column":3,"offset":9184},"end":{"line":212,"column":52,"offset":9233},"indent":[]}}],"position":{"start":{"line":212,"column":1,"offset":9182},"end":{"line":212,"column":52,"offset":9233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":214,"column":1,"offset":9235},"end":{"line":214,"column":3,"offset":9237},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":214,"column":3,"offset":9237},"end":{"line":214,"column":9,"offset":9243},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":214,"column":9,"offset":9243},"end":{"line":214,"column":223,"offset":9457},"indent":[]}}],"position":{"start":{"line":214,"column":1,"offset":9235},"end":{"line":214,"column":223,"offset":9457},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":216,"column":3,"offset":9461},"end":{"line":216,"column":159,"offset":9617},"indent":[]}}],"position":{"start":{"line":216,"column":3,"offset":9461},"end":{"line":216,"column":159,"offset":9617},"indent":[]}}],"position":{"start":{"line":216,"column":1,"offset":9459},"end":{"line":216,"column":159,"offset":9617},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":218,"column":1,"offset":9619},"end":{"line":221,"column":4,"offset":9796},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":223,"column":1,"offset":9798},"end":{"line":223,"column":160,"offset":9957},"indent":[]}}],"position":{"start":{"line":223,"column":1,"offset":9798},"end":{"line":223,"column":160,"offset":9957},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":225,"column":3,"offset":9961},"end":{"line":225,"column":31,"offset":9989},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":225,"column":31,"offset":9989},"end":{"line":225,"column":101,"offset":10059},"indent":[]}}],"position":{"start":{"line":225,"column":3,"offset":9961},"end":{"line":225,"column":101,"offset":10059},"indent":[]}}],"position":{"start":{"line":225,"column":1,"offset":9959},"end":{"line":225,"column":101,"offset":10059},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":227,"column":1,"offset":10061},"end":{"line":230,"column":4,"offset":10233},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":232,"column":1,"offset":10235},"end":{"line":232,"column":73,"offset":10307},"indent":[]}}],"position":{"start":{"line":232,"column":1,"offset":10235},"end":{"line":232,"column":73,"offset":10307},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":235,"column":3,"offset":10312},"end":{"line":235,"column":31,"offset":10340},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":235,"column":31,"offset":10340},"end":{"line":235,"column":101,"offset":10410},"indent":[]}}],"position":{"start":{"line":235,"column":3,"offset":10312},"end":{"line":235,"column":101,"offset":10410},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":10310},"end":{"line":235,"column":101,"offset":10410},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":237,"column":1,"offset":10412},"end":{"line":240,"column":4,"offset":10584},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":242,"column":1,"offset":10586},"end":{"line":242,"column":62,"offset":10647},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":242,"column":63,"offset":10648},"end":{"line":242,"column":75,"offset":10660},"indent":[]}}],"position":{"start":{"line":242,"column":62,"offset":10647},"end":{"line":242,"column":143,"offset":10728},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":242,"column":143,"offset":10728},"end":{"line":242,"column":150,"offset":10735},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":242,"column":150,"offset":10735},"end":{"line":242,"column":169,"offset":10754},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":242,"column":169,"offset":10754},"end":{"line":242,"column":170,"offset":10755},"indent":[]}}],"position":{"start":{"line":242,"column":1,"offset":10586},"end":{"line":242,"column":170,"offset":10755},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":244,"column":1,"offset":10757},"end":{"line":246,"column":4,"offset":10784},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":248,"column":1,"offset":10786},"end":{"line":248,"column":58,"offset":10843},"indent":[]}}],"position":{"start":{"line":248,"column":1,"offset":10786},"end":{"line":248,"column":58,"offset":10843},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":250,"column":1,"offset":10845},"end":{"line":253,"column":4,"offset":10915},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":255,"column":5,"offset":10921},"end":{"line":255,"column":8,"offset":10924},"indent":[]}}],"position":{"start":{"line":255,"column":1,"offset":10917},"end":{"line":255,"column":8,"offset":10924},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":257,"column":1,"offset":10926},"end":{"line":257,"column":280,"offset":11205},"indent":[]}}],"position":{"start":{"line":257,"column":1,"offset":10926},"end":{"line":257,"column":280,"offset":11205},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":259,"column":1,"offset":11207},"end":{"line":259,"column":37,"offset":11243},"indent":[]}}],"position":{"start":{"line":259,"column":1,"offset":11207},"end":{"line":259,"column":37,"offset":11243},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":261,"column":1,"offset":11245},"end":{"line":263,"column":4,"offset":11418},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":265,"column":1,"offset":11420},"end":{"line":265,"column":25,"offset":11444},"indent":[]}}],"position":{"start":{"line":265,"column":1,"offset":11420},"end":{"line":265,"column":25,"offset":11444},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":267,"column":1,"offset":11446},"end":{"line":270,"column":4,"offset":11550},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":272,"column":1,"offset":11552},"end":{"line":272,"column":118,"offset":11669},"indent":[]}}],"position":{"start":{"line":272,"column":1,"offset":11552},"end":{"line":272,"column":118,"offset":11669},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":274,"column":1,"offset":11671},"end":{"line":294,"column":4,"offset":12178},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":296,"column":1,"offset":12180},"end":{"line":296,"column":14,"offset":12193},"indent":[]}}],"position":{"start":{"line":296,"column":1,"offset":12180},"end":{"line":296,"column":14,"offset":12193},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":298,"column":1,"offset":12195},"end":{"line":300,"column":4,"offset":12231},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":302,"column":1,"offset":12233},"end":{"line":302,"column":91,"offset":12323},"indent":[]}}],"position":{"start":{"line":302,"column":1,"offset":12233},"end":{"line":302,"column":91,"offset":12323},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":304,"column":1,"offset":12325},"end":{"line":312,"column":4,"offset":12698},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":314,"column":1,"offset":12700},"end":{"line":314,"column":145,"offset":12844},"indent":[]}}],"position":{"start":{"line":314,"column":1,"offset":12700},"end":{"line":314,"column":145,"offset":12844},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":316,"column":5,"offset":12850},"end":{"line":316,"column":17,"offset":12862},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12846},"end":{"line":316,"column":17,"offset":12862},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":318,"column":1,"offset":12864},"end":{"line":318,"column":300,"offset":13163},"indent":[]}}],"position":{"start":{"line":318,"column":1,"offset":12864},"end":{"line":318,"column":300,"offset":13163},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":320,"column":1,"offset":13165},"end":{"line":320,"column":178,"offset":13342},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":13165},"end":{"line":320,"column":178,"offset":13342},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":322,"column":1,"offset":13344},"end":{"line":322,"column":48,"offset":13391},"indent":[]}}],"position":{"start":{"line":322,"column":1,"offset":13344},"end":{"line":322,"column":48,"offset":13391},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":324,"column":1,"offset":13393},"end":{"line":326,"column":4,"offset":13433},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":328,"column":1,"offset":13435},"end":{"line":328,"column":104,"offset":13538},"indent":[]}}],"position":{"start":{"line":328,"column":1,"offset":13435},"end":{"line":328,"column":104,"offset":13538},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":330,"column":1,"offset":13540},"end":{"line":338,"column":4,"offset":13810},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":340,"column":1,"offset":13812},"end":{"line":340,"column":28,"offset":13839},"indent":[]}}],"position":{"start":{"line":340,"column":1,"offset":13812},"end":{"line":340,"column":28,"offset":13839},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":342,"column":1,"offset":13841},"end":{"line":344,"column":4,"offset":13885},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":346,"column":1,"offset":13887},"end":{"line":346,"column":48,"offset":13934},"indent":[]}}],"position":{"start":{"line":346,"column":1,"offset":13887},"end":{"line":346,"column":48,"offset":13934},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":348,"column":1,"offset":13936},"end":{"line":350,"column":4,"offset":13958},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":352,"column":1,"offset":13960},"end":{"line":352,"column":72,"offset":14031},"indent":[]}}],"position":{"start":{"line":352,"column":1,"offset":13960},"end":{"line":352,"column":72,"offset":14031},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":354,"column":1,"offset":14033},"end":{"line":356,"column":4,"offset":14090},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":358,"column":4,"offset":14095},"end":{"line":358,"column":11,"offset":14102},"indent":[]}}],"position":{"start":{"line":358,"column":1,"offset":14092},"end":{"line":358,"column":11,"offset":14102},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":360,"column":1,"offset":14104},"end":{"line":360,"column":283,"offset":14386},"indent":[]}}],"position":{"start":{"line":360,"column":1,"offset":14104},"end":{"line":360,"column":283,"offset":14386},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":362,"column":3,"offset":14390},"end":{"line":362,"column":54,"offset":14441},"indent":[]}}],"position":{"start":{"line":362,"column":3,"offset":14390},"end":{"line":362,"column":54,"offset":14441},"indent":[]}}],"position":{"start":{"line":362,"column":1,"offset":14388},"end":{"line":362,"column":54,"offset":14441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":364,"column":5,"offset":14447},"end":{"line":364,"column":14,"offset":14456},"indent":[]}}],"position":{"start":{"line":364,"column":1,"offset":14443},"end":{"line":364,"column":14,"offset":14456},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":366,"column":1,"offset":14458},"end":{"line":366,"column":68,"offset":14525},"indent":[]}}],"position":{"start":{"line":366,"column":1,"offset":14458},"end":{"line":366,"column":68,"offset":14525},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":368,"column":1,"offset":14527},"end":{"line":371,"column":4,"offset":14678},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":373,"column":1,"offset":14680},"end":{"line":373,"column":46,"offset":14725},"indent":[]}}],"position":{"start":{"line":373,"column":1,"offset":14680},"end":{"line":373,"column":46,"offset":14725},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":375,"column":3,"offset":14729},"end":{"line":375,"column":103,"offset":14829},"indent":[]}}],"position":{"start":{"line":375,"column":3,"offset":14729},"end":{"line":375,"column":103,"offset":14829},"indent":[]}}],"position":{"start":{"line":375,"column":1,"offset":14727},"end":{"line":375,"column":103,"offset":14829},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":377,"column":1,"offset":14831},"end":{"line":382,"column":4,"offset":15041},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":384,"column":1,"offset":15043},"end":{"line":384,"column":151,"offset":15193},"indent":[]}}],"position":{"start":{"line":384,"column":1,"offset":15043},"end":{"line":384,"column":151,"offset":15193},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":386,"column":3,"offset":15197},"end":{"line":386,"column":22,"offset":15216},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":386,"column":22,"offset":15216},"end":{"line":386,"column":26,"offset":15220},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":386,"column":26,"offset":15220},"end":{"line":386,"column":40,"offset":15234},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":386,"column":40,"offset":15234},"end":{"line":386,"column":50,"offset":15244},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":386,"column":50,"offset":15244},"end":{"line":386,"column":98,"offset":15292},"indent":[]}}],"position":{"start":{"line":386,"column":3,"offset":15197},"end":{"line":386,"column":98,"offset":15292},"indent":[]}}],"position":{"start":{"line":386,"column":1,"offset":15195},"end":{"line":386,"column":98,"offset":15292},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":388,"column":1,"offset":15294},"end":{"line":392,"column":4,"offset":15456},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":394,"column":1,"offset":15458},"end":{"line":394,"column":72,"offset":15529},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":394,"column":72,"offset":15529},"end":{"line":394,"column":84,"offset":15541},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":394,"column":84,"offset":15541},"end":{"line":394,"column":102,"offset":15559},"indent":[]}}],"position":{"start":{"line":394,"column":1,"offset":15458},"end":{"line":394,"column":102,"offset":15559},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":396,"column":1,"offset":15561},"end":{"line":399,"column":4,"offset":15635},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":401,"column":5,"offset":15641},"end":{"line":401,"column":8,"offset":15644},"indent":[]}}],"position":{"start":{"line":401,"column":1,"offset":15637},"end":{"line":401,"column":8,"offset":15644},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":403,"column":1,"offset":15646},"end":{"line":403,"column":176,"offset":15821},"indent":[]}}],"position":{"start":{"line":403,"column":1,"offset":15646},"end":{"line":403,"column":176,"offset":15821},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":405,"column":1,"offset":15823},"end":{"line":412,"column":4,"offset":16120},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":414,"column":1,"offset":16122},"end":{"line":414,"column":60,"offset":16181},"indent":[]}}],"position":{"start":{"line":414,"column":1,"offset":16122},"end":{"line":414,"column":60,"offset":16181},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":416,"column":1,"offset":16183},"end":{"line":420,"column":4,"offset":16309},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":422,"column":1,"offset":16311},"end":{"line":422,"column":63,"offset":16373},"indent":[]}}],"position":{"start":{"line":422,"column":1,"offset":16311},"end":{"line":422,"column":63,"offset":16373},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":424,"column":1,"offset":16375},"end":{"line":444,"column":4,"offset":16882},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":446,"column":1,"offset":16884},"end":{"line":446,"column":99,"offset":16982},"indent":[]}}],"position":{"start":{"line":446,"column":1,"offset":16884},"end":{"line":446,"column":99,"offset":16982},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":448,"column":1,"offset":16984},"end":{"line":451,"column":4,"offset":17086},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":453,"column":1,"offset":17088},"end":{"line":453,"column":37,"offset":17124},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":453,"column":37,"offset":17124},"end":{"line":453,"column":47,"offset":17134},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":453,"column":47,"offset":17134},"end":{"line":453,"column":89,"offset":17176},"indent":[]}}],"position":{"start":{"line":453,"column":1,"offset":17088},"end":{"line":453,"column":89,"offset":17176},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":455,"column":1,"offset":17178},"end":{"line":459,"column":4,"offset":17303},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":461,"column":1,"offset":17305},"end":{"line":461,"column":78,"offset":17382},"indent":[]}}],"position":{"start":{"line":461,"column":1,"offset":17305},"end":{"line":461,"column":78,"offset":17382},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":463,"column":1,"offset":17384},"end":{"line":467,"column":4,"offset":17488},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":469,"column":1,"offset":17490},"end":{"line":469,"column":75,"offset":17564},"indent":[]}}],"position":{"start":{"line":469,"column":1,"offset":17490},"end":{"line":469,"column":75,"offset":17564},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":471,"column":1,"offset":17566},"end":{"line":475,"column":4,"offset":17639},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":477,"column":1,"offset":17641},"end":{"line":477,"column":145,"offset":17785},"indent":[]}}],"position":{"start":{"line":477,"column":1,"offset":17641},"end":{"line":477,"column":145,"offset":17785},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":479,"column":5,"offset":17791},"end":{"line":479,"column":17,"offset":17803},"indent":[]}}],"position":{"start":{"line":479,"column":1,"offset":17787},"end":{"line":479,"column":17,"offset":17803},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":481,"column":1,"offset":17805},"end":{"line":481,"column":300,"offset":18104},"indent":[]}}],"position":{"start":{"line":481,"column":1,"offset":17805},"end":{"line":481,"column":300,"offset":18104},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":483,"column":1,"offset":18106},"end":{"line":483,"column":178,"offset":18283},"indent":[]}}],"position":{"start":{"line":483,"column":1,"offset":18106},"end":{"line":483,"column":178,"offset":18283},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":485,"column":1,"offset":18285},"end":{"line":485,"column":48,"offset":18332},"indent":[]}}],"position":{"start":{"line":485,"column":1,"offset":18285},"end":{"line":485,"column":48,"offset":18332},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":487,"column":1,"offset":18334},"end":{"line":489,"column":4,"offset":18378},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":491,"column":1,"offset":18380},"end":{"line":491,"column":104,"offset":18483},"indent":[]}}],"position":{"start":{"line":491,"column":1,"offset":18380},"end":{"line":491,"column":104,"offset":18483},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":493,"column":1,"offset":18485},"end":{"line":501,"column":4,"offset":18755},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":503,"column":1,"offset":18757},"end":{"line":503,"column":28,"offset":18784},"indent":[]}}],"position":{"start":{"line":503,"column":1,"offset":18757},"end":{"line":503,"column":28,"offset":18784},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":505,"column":1,"offset":18786},"end":{"line":507,"column":4,"offset":18834},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":509,"column":1,"offset":18836},"end":{"line":509,"column":48,"offset":18883},"indent":[]}}],"position":{"start":{"line":509,"column":1,"offset":18836},"end":{"line":509,"column":48,"offset":18883},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":511,"column":1,"offset":18885},"end":{"line":513,"column":4,"offset":18907},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":515,"column":1,"offset":18909},"end":{"line":515,"column":72,"offset":18980},"indent":[]}}],"position":{"start":{"line":515,"column":1,"offset":18909},"end":{"line":515,"column":72,"offset":18980},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":517,"column":1,"offset":18982},"end":{"line":519,"column":4,"offset":19043},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":522,"column":1,"offset":19046},"end":{"line":522,"column":31,"offset":19076},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":522,"column":31,"offset":19076}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on `}{`the Docker hub`}{`, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use Docker, to get the Kerberos agent up and running. All Docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`Instead of just running the Kerberos container, you can also persist your configuration by assigning volumes. An example of mounting volumes looks like this; an overview of `}{`the different volumes can be found here`}{`.`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`kerberos`}{`-`}{`camera1`}{` \\\\`}{`\n`}{`-`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/config:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`config`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/capture:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`capture`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/logs:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`logs`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/webconfig:/`}{`var`}{`/`}{`www`}{`/web/config \\\\`}{`\n`}{`-`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.`}

\n \n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.`}

\n

{`To fill the gap, regarding the latter, we can rely on another solution called `}{`Balena.io`}{`. Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).`}

\n

{`On top of supporting a lot of boars,`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-9f4c0c5af3244082021f4985f686a308.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-9f4c0c5af3244082021f4985f686a308.json new file mode 100644 index 0000000..aa2f9cc --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-9f4c0c5af3244082021f4985f686a308.json @@ -0,0 +1 @@ +{"expireTime":9007200842067986000,"key":"gatsby-plugin-mdx-entire-payload-51233538cdabbc694fe9d75f39523cbf-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug-and-Play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":23,"column":3,"offset":1136},"end":{"line":23,"column":16,"offset":1149},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":16,"offset":1149},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":25,"column":1,"offset":1151},"end":{"line":25,"column":156,"offset":1306},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1151},"end":{"line":25,"column":156,"offset":1306},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":27,"column":4,"offset":1311},"end":{"line":27,"column":8,"offset":1315},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1308},"end":{"line":27,"column":9,"offset":1316},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":29,"column":1,"offset":1318},"end":{"line":29,"column":229,"offset":1546},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1318},"end":{"line":29,"column":229,"offset":1546},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":31,"column":1,"offset":1548},"end":{"line":31,"column":197,"offset":1744},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1548},"end":{"line":31,"column":197,"offset":1744},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":33,"column":5,"offset":1750},"end":{"line":33,"column":11,"offset":1756},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1746},"end":{"line":33,"column":11,"offset":1756},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":35,"column":1,"offset":1758},"end":{"line":35,"column":63,"offset":1820},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":35,"column":64,"offset":1821},"end":{"line":35,"column":85,"offset":1842},"indent":[]}}],"position":{"start":{"line":35,"column":63,"offset":1820},"end":{"line":35,"column":123,"offset":1880},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":35,"column":123,"offset":1880},"end":{"line":35,"column":124,"offset":1881},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1758},"end":{"line":35,"column":124,"offset":1881},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos installer","position":{"start":{"line":37,"column":5,"offset":1887},"end":{"line":37,"column":23,"offset":1905},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1883},"end":{"line":37,"column":23,"offset":1905},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":39,"column":1,"offset":1907},"end":{"line":39,"column":228,"offset":2134},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1907},"end":{"line":39,"column":228,"offset":2134},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":41,"column":1,"offset":2136},"end":{"line":41,"column":67,"offset":2202},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":2136},"end":{"line":41,"column":67,"offset":2202},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":43,"column":1,"offset":2204},"end":{"line":43,"column":50,"offset":2253},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2204},"end":{"line":43,"column":50,"offset":2253},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":45,"column":3,"offset":2257},"end":{"line":45,"column":49,"offset":2303},"indent":[]}}],"position":{"start":{"line":45,"column":3,"offset":2257},"end":{"line":45,"column":49,"offset":2303},"indent":[]}}],"position":{"start":{"line":45,"column":3,"offset":2257},"end":{"line":45,"column":49,"offset":2303},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2255},"end":{"line":45,"column":49,"offset":2303},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":47,"column":5,"offset":2309},"end":{"line":47,"column":11,"offset":2315},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2305},"end":{"line":47,"column":11,"offset":2315},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":49,"column":1,"offset":2317},"end":{"line":49,"column":160,"offset":2476},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2317},"end":{"line":49,"column":160,"offset":2476},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":51,"column":4,"offset":2481},"end":{"line":51,"column":13,"offset":2490},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":51,"column":14,"offset":2491},"end":{"line":51,"column":28,"offset":2505},"indent":[]}}],"position":{"start":{"line":51,"column":13,"offset":2490},"end":{"line":51,"column":75,"offset":2552},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":51,"column":75,"offset":2552},"end":{"line":51,"column":76,"offset":2553},"indent":[]}}],"position":{"start":{"line":51,"column":4,"offset":2481},"end":{"line":51,"column":76,"offset":2553},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2478},"end":{"line":51,"column":76,"offset":2553},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":52,"column":4,"offset":2557},"end":{"line":52,"column":41,"offset":2594},"indent":[]}}],"position":{"start":{"line":52,"column":4,"offset":2557},"end":{"line":52,"column":41,"offset":2594},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2554},"end":{"line":52,"column":41,"offset":2594},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":53,"column":4,"offset":2598},"end":{"line":53,"column":60,"offset":2654},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2598},"end":{"line":53,"column":60,"offset":2654},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2595},"end":{"line":53,"column":60,"offset":2654},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2478},"end":{"line":53,"column":60,"offset":2654},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":55,"column":2,"offset":2657},"end":{"line":55,"column":64,"offset":2719},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2656},"end":{"line":55,"column":96,"offset":2751},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2656},"end":{"line":55,"column":96,"offset":2751},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":57,"column":1,"offset":2753},"end":{"line":57,"column":204,"offset":2956},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2753},"end":{"line":57,"column":204,"offset":2956},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":59,"column":6,"offset":2963},"end":{"line":59,"column":24,"offset":2981},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2958},"end":{"line":59,"column":24,"offset":2981},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":61,"column":1,"offset":2983},"end":{"line":61,"column":95,"offset":3077},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":61,"column":95,"offset":3077},"end":{"line":61,"column":110,"offset":3092},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":61,"column":110,"offset":3092},"end":{"line":61,"column":222,"offset":3204},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2983},"end":{"line":61,"column":222,"offset":3204},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":63,"column":1,"offset":3206},"end":{"line":71,"column":4,"offset":3315},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":73,"column":6,"offset":3322},"end":{"line":73,"column":31,"offset":3347},"indent":[]}}],"position":{"start":{"line":73,"column":1,"offset":3317},"end":{"line":73,"column":31,"offset":3347},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":75,"column":1,"offset":3349},"end":{"line":75,"column":79,"offset":3427},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":75,"column":79,"offset":3427},"end":{"line":75,"column":95,"offset":3443},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":75,"column":95,"offset":3443},"end":{"line":75,"column":137,"offset":3485},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3349},"end":{"line":75,"column":137,"offset":3485},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":77,"column":1,"offset":3487},"end":{"line":87,"column":4,"offset":3855},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":89,"column":5,"offset":3861},"end":{"line":89,"column":30,"offset":3886},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":3857},"end":{"line":89,"column":30,"offset":3886},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":91,"column":1,"offset":3888},"end":{"line":91,"column":464,"offset":4351},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3888},"end":{"line":91,"column":464,"offset":4351},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":93,"column":1,"offset":4353},"end":{"line":93,"column":61,"offset":4413},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":4353},"end":{"line":93,"column":61,"offset":4413},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":95,"column":5,"offset":4419},"end":{"line":95,"column":28,"offset":4442},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4415},"end":{"line":95,"column":28,"offset":4442},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":97,"column":1,"offset":4444},"end":{"line":97,"column":95,"offset":4538},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":97,"column":95,"offset":4538},"end":{"line":97,"column":100,"offset":4543},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":97,"column":100,"offset":4543},"end":{"line":97,"column":101,"offset":4544},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4444},"end":{"line":97,"column":101,"offset":4544},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":99,"column":1,"offset":4546},"end":{"line":103,"column":4,"offset":4663},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":105,"column":1,"offset":4665},"end":{"line":105,"column":80,"offset":4744},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":105,"column":80,"offset":4744},"end":{"line":105,"column":101,"offset":4765},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":105,"column":101,"offset":4765},"end":{"line":105,"column":162,"offset":4826},"indent":[]}}],"position":{"start":{"line":105,"column":1,"offset":4665},"end":{"line":105,"column":162,"offset":4826},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":107,"column":1,"offset":4828},"end":{"line":110,"column":4,"offset":4917},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":112,"column":4,"offset":4922},"end":{"line":112,"column":10,"offset":4928},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":4919},"end":{"line":112,"column":10,"offset":4928},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":114,"column":1,"offset":4930},"end":{"line":114,"column":337,"offset":5266},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":114,"column":338,"offset":5267},"end":{"line":114,"column":352,"offset":5281},"indent":[]}}],"position":{"start":{"line":114,"column":337,"offset":5266},"end":{"line":114,"column":388,"offset":5317},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":114,"column":388,"offset":5317},"end":{"line":114,"column":389,"offset":5318},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4930},"end":{"line":114,"column":389,"offset":5318},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":116,"column":5,"offset":5324},"end":{"line":116,"column":18,"offset":5337},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":5320},"end":{"line":116,"column":18,"offset":5337},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":118,"column":3,"offset":5341},"end":{"line":118,"column":50,"offset":5388},"indent":[]}}],"position":{"start":{"line":118,"column":3,"offset":5341},"end":{"line":118,"column":50,"offset":5388},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5339},"end":{"line":118,"column":50,"offset":5388},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":120,"column":5,"offset":5394},"end":{"line":120,"column":11,"offset":5400},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5390},"end":{"line":120,"column":11,"offset":5400},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":122,"column":1,"offset":5402},"end":{"line":122,"column":64,"offset":5465},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":122,"column":65,"offset":5466},"end":{"line":122,"column":86,"offset":5487},"indent":[]}}],"position":{"start":{"line":122,"column":64,"offset":5465},"end":{"line":122,"column":126,"offset":5527},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":122,"column":126,"offset":5527},"end":{"line":122,"column":127,"offset":5528},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5402},"end":{"line":122,"column":127,"offset":5528},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":124,"column":5,"offset":5534},"end":{"line":124,"column":26,"offset":5555},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5530},"end":{"line":124,"column":26,"offset":5555},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":126,"column":1,"offset":5557},"end":{"line":126,"column":126,"offset":5682},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5557},"end":{"line":126,"column":126,"offset":5682},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":128,"column":1,"offset":5684},"end":{"line":130,"column":4,"offset":5723},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":132,"column":1,"offset":5725},"end":{"line":132,"column":187,"offset":5911},"indent":[]}}],"position":{"start":{"line":132,"column":1,"offset":5725},"end":{"line":132,"column":187,"offset":5911},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":134,"column":1,"offset":5913},"end":{"line":136,"column":4,"offset":5991},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":138,"column":1,"offset":5993},"end":{"line":138,"column":153,"offset":6145},"indent":[]}}],"position":{"start":{"line":138,"column":1,"offset":5993},"end":{"line":138,"column":153,"offset":6145},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":140,"column":1,"offset":6147},"end":{"line":143,"column":4,"offset":6294},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":145,"column":1,"offset":6296},"end":{"line":145,"column":100,"offset":6395},"indent":[]}}],"position":{"start":{"line":145,"column":1,"offset":6296},"end":{"line":145,"column":100,"offset":6395},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":146,"column":1,"offset":6396},"end":{"line":150,"column":4,"offset":6465},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":152,"column":5,"offset":6471},"end":{"line":152,"column":12,"offset":6478},"indent":[]}}],"position":{"start":{"line":152,"column":1,"offset":6467},"end":{"line":152,"column":12,"offset":6478},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":154,"column":1,"offset":6480},"end":{"line":154,"column":64,"offset":6543},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6480},"end":{"line":154,"column":64,"offset":6543},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":155,"column":3,"offset":6546},"end":{"line":155,"column":25,"offset":6568},"indent":[]}}],"position":{"start":{"line":155,"column":3,"offset":6546},"end":{"line":155,"column":25,"offset":6568},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":6544},"end":{"line":155,"column":25,"offset":6568},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":156,"column":3,"offset":6571},"end":{"line":156,"column":59,"offset":6627},"indent":[]}}],"position":{"start":{"line":156,"column":3,"offset":6571},"end":{"line":156,"column":59,"offset":6627},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6569},"end":{"line":156,"column":59,"offset":6627},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":6544},"end":{"line":156,"column":59,"offset":6627},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":158,"column":4,"offset":6632},"end":{"line":158,"column":10,"offset":6638},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6629},"end":{"line":158,"column":10,"offset":6638},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.","position":{"start":{"line":160,"column":1,"offset":6640},"end":{"line":160,"column":102,"offset":6741},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":6640},"end":{"line":160,"column":102,"offset":6741},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Especially in the worl\n even on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.","position":{"start":{"line":162,"column":1,"offset":6743},"end":{"line":163,"column":128,"offset":6893},"indent":[1]}}],"position":{"start":{"line":162,"column":1,"offset":6743},"end":{"line":163,"column":128,"offset":6893},"indent":[1]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":166,"column":3,"offset":6898},"end":{"line":166,"column":11,"offset":6906},"indent":[]}}],"position":{"start":{"line":166,"column":1,"offset":6896},"end":{"line":166,"column":11,"offset":6906},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":168,"column":1,"offset":6908},"end":{"line":168,"column":133,"offset":7040},"indent":[]}}],"position":{"start":{"line":168,"column":1,"offset":6908},"end":{"line":168,"column":133,"offset":7040},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":170,"column":4,"offset":7045},"end":{"line":170,"column":12,"offset":7053},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7042},"end":{"line":170,"column":12,"offset":7053},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":172,"column":1,"offset":7055},"end":{"line":172,"column":193,"offset":7247},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7055},"end":{"line":172,"column":193,"offset":7247},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":174,"column":4,"offset":7252},"end":{"line":174,"column":62,"offset":7310},"indent":[]}}],"position":{"start":{"line":174,"column":4,"offset":7252},"end":{"line":174,"column":62,"offset":7310},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7249},"end":{"line":174,"column":62,"offset":7310},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":175,"column":4,"offset":7314},"end":{"line":175,"column":69,"offset":7379},"indent":[]}}],"position":{"start":{"line":175,"column":4,"offset":7314},"end":{"line":175,"column":69,"offset":7379},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7311},"end":{"line":175,"column":69,"offset":7379},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7249},"end":{"line":175,"column":69,"offset":7379},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":177,"column":1,"offset":7381},"end":{"line":177,"column":99,"offset":7479},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7381},"end":{"line":177,"column":99,"offset":7479},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":179,"column":5,"offset":7485},"end":{"line":179,"column":14,"offset":7494},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7481},"end":{"line":179,"column":14,"offset":7494},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":181,"column":1,"offset":7496},"end":{"line":181,"column":71,"offset":7566},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":7496},"end":{"line":181,"column":71,"offset":7566},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":183,"column":3,"offset":7570},"end":{"line":183,"column":47,"offset":7614},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":183,"column":47,"offset":7614},"end":{"line":183,"column":79,"offset":7646},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":183,"column":79,"offset":7646},"end":{"line":183,"column":198,"offset":7765},"indent":[]}}],"position":{"start":{"line":183,"column":3,"offset":7570},"end":{"line":183,"column":198,"offset":7765},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":7568},"end":{"line":183,"column":198,"offset":7765},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":185,"column":1,"offset":7767},"end":{"line":187,"column":4,"offset":7830},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":189,"column":5,"offset":7836},"end":{"line":189,"column":14,"offset":7845},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":7832},"end":{"line":189,"column":14,"offset":7845},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":191,"column":1,"offset":7847},"end":{"line":191,"column":56,"offset":7902},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":7847},"end":{"line":191,"column":56,"offset":7902},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":192,"column":3,"offset":7905},"end":{"line":192,"column":52,"offset":7954},"indent":[]}}],"position":{"start":{"line":192,"column":3,"offset":7905},"end":{"line":192,"column":52,"offset":7954},"indent":[]}}],"position":{"start":{"line":192,"column":3,"offset":7905},"end":{"line":192,"column":52,"offset":7954},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":7903},"end":{"line":192,"column":52,"offset":7954},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":194,"column":1,"offset":7956},"end":{"line":194,"column":3,"offset":7958},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":194,"column":3,"offset":7958},"end":{"line":194,"column":9,"offset":7964},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":194,"column":9,"offset":7964},"end":{"line":194,"column":223,"offset":8178},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":7956},"end":{"line":194,"column":223,"offset":8178},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":196,"column":3,"offset":8182},"end":{"line":196,"column":159,"offset":8338},"indent":[]}}],"position":{"start":{"line":196,"column":3,"offset":8182},"end":{"line":196,"column":159,"offset":8338},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8180},"end":{"line":196,"column":159,"offset":8338},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":198,"column":1,"offset":8340},"end":{"line":201,"column":4,"offset":8517},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":203,"column":1,"offset":8519},"end":{"line":203,"column":160,"offset":8678},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":8519},"end":{"line":203,"column":160,"offset":8678},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":205,"column":3,"offset":8682},"end":{"line":205,"column":31,"offset":8710},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":205,"column":31,"offset":8710},"end":{"line":205,"column":101,"offset":8780},"indent":[]}}],"position":{"start":{"line":205,"column":3,"offset":8682},"end":{"line":205,"column":101,"offset":8780},"indent":[]}}],"position":{"start":{"line":205,"column":1,"offset":8680},"end":{"line":205,"column":101,"offset":8780},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":207,"column":1,"offset":8782},"end":{"line":210,"column":4,"offset":8954},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":212,"column":1,"offset":8956},"end":{"line":212,"column":73,"offset":9028},"indent":[]}}],"position":{"start":{"line":212,"column":1,"offset":8956},"end":{"line":212,"column":73,"offset":9028},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":215,"column":3,"offset":9033},"end":{"line":215,"column":31,"offset":9061},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":215,"column":31,"offset":9061},"end":{"line":215,"column":101,"offset":9131},"indent":[]}}],"position":{"start":{"line":215,"column":3,"offset":9033},"end":{"line":215,"column":101,"offset":9131},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":9031},"end":{"line":215,"column":101,"offset":9131},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":217,"column":1,"offset":9133},"end":{"line":220,"column":4,"offset":9305},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":222,"column":1,"offset":9307},"end":{"line":222,"column":62,"offset":9368},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":222,"column":63,"offset":9369},"end":{"line":222,"column":75,"offset":9381},"indent":[]}}],"position":{"start":{"line":222,"column":62,"offset":9368},"end":{"line":222,"column":143,"offset":9449},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":222,"column":143,"offset":9449},"end":{"line":222,"column":150,"offset":9456},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":222,"column":150,"offset":9456},"end":{"line":222,"column":169,"offset":9475},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":222,"column":169,"offset":9475},"end":{"line":222,"column":170,"offset":9476},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":9307},"end":{"line":222,"column":170,"offset":9476},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":224,"column":1,"offset":9478},"end":{"line":226,"column":4,"offset":9505},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":228,"column":1,"offset":9507},"end":{"line":228,"column":58,"offset":9564},"indent":[]}}],"position":{"start":{"line":228,"column":1,"offset":9507},"end":{"line":228,"column":58,"offset":9564},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":230,"column":1,"offset":9566},"end":{"line":233,"column":4,"offset":9636},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":235,"column":5,"offset":9642},"end":{"line":235,"column":8,"offset":9645},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":9638},"end":{"line":235,"column":8,"offset":9645},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":237,"column":1,"offset":9647},"end":{"line":237,"column":280,"offset":9926},"indent":[]}}],"position":{"start":{"line":237,"column":1,"offset":9647},"end":{"line":237,"column":280,"offset":9926},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":239,"column":1,"offset":9928},"end":{"line":239,"column":37,"offset":9964},"indent":[]}}],"position":{"start":{"line":239,"column":1,"offset":9928},"end":{"line":239,"column":37,"offset":9964},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":241,"column":1,"offset":9966},"end":{"line":243,"column":4,"offset":10139},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":245,"column":1,"offset":10141},"end":{"line":245,"column":25,"offset":10165},"indent":[]}}],"position":{"start":{"line":245,"column":1,"offset":10141},"end":{"line":245,"column":25,"offset":10165},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":247,"column":1,"offset":10167},"end":{"line":250,"column":4,"offset":10271},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":252,"column":1,"offset":10273},"end":{"line":252,"column":118,"offset":10390},"indent":[]}}],"position":{"start":{"line":252,"column":1,"offset":10273},"end":{"line":252,"column":118,"offset":10390},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":254,"column":1,"offset":10392},"end":{"line":274,"column":4,"offset":10899},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":276,"column":1,"offset":10901},"end":{"line":276,"column":14,"offset":10914},"indent":[]}}],"position":{"start":{"line":276,"column":1,"offset":10901},"end":{"line":276,"column":14,"offset":10914},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":278,"column":1,"offset":10916},"end":{"line":280,"column":4,"offset":10952},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":282,"column":1,"offset":10954},"end":{"line":282,"column":91,"offset":11044},"indent":[]}}],"position":{"start":{"line":282,"column":1,"offset":10954},"end":{"line":282,"column":91,"offset":11044},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":284,"column":1,"offset":11046},"end":{"line":292,"column":4,"offset":11419},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":294,"column":1,"offset":11421},"end":{"line":294,"column":145,"offset":11565},"indent":[]}}],"position":{"start":{"line":294,"column":1,"offset":11421},"end":{"line":294,"column":145,"offset":11565},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":296,"column":5,"offset":11571},"end":{"line":296,"column":17,"offset":11583},"indent":[]}}],"position":{"start":{"line":296,"column":1,"offset":11567},"end":{"line":296,"column":17,"offset":11583},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":298,"column":1,"offset":11585},"end":{"line":298,"column":300,"offset":11884},"indent":[]}}],"position":{"start":{"line":298,"column":1,"offset":11585},"end":{"line":298,"column":300,"offset":11884},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":300,"column":1,"offset":11886},"end":{"line":300,"column":178,"offset":12063},"indent":[]}}],"position":{"start":{"line":300,"column":1,"offset":11886},"end":{"line":300,"column":178,"offset":12063},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":302,"column":1,"offset":12065},"end":{"line":302,"column":48,"offset":12112},"indent":[]}}],"position":{"start":{"line":302,"column":1,"offset":12065},"end":{"line":302,"column":48,"offset":12112},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":304,"column":1,"offset":12114},"end":{"line":306,"column":4,"offset":12154},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":308,"column":1,"offset":12156},"end":{"line":308,"column":104,"offset":12259},"indent":[]}}],"position":{"start":{"line":308,"column":1,"offset":12156},"end":{"line":308,"column":104,"offset":12259},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":310,"column":1,"offset":12261},"end":{"line":318,"column":4,"offset":12531},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":320,"column":1,"offset":12533},"end":{"line":320,"column":28,"offset":12560},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":12533},"end":{"line":320,"column":28,"offset":12560},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":322,"column":1,"offset":12562},"end":{"line":324,"column":4,"offset":12606},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":326,"column":1,"offset":12608},"end":{"line":326,"column":48,"offset":12655},"indent":[]}}],"position":{"start":{"line":326,"column":1,"offset":12608},"end":{"line":326,"column":48,"offset":12655},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":328,"column":1,"offset":12657},"end":{"line":330,"column":4,"offset":12679},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":332,"column":1,"offset":12681},"end":{"line":332,"column":72,"offset":12752},"indent":[]}}],"position":{"start":{"line":332,"column":1,"offset":12681},"end":{"line":332,"column":72,"offset":12752},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":334,"column":1,"offset":12754},"end":{"line":336,"column":4,"offset":12811},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":338,"column":4,"offset":12816},"end":{"line":338,"column":11,"offset":12823},"indent":[]}}],"position":{"start":{"line":338,"column":1,"offset":12813},"end":{"line":338,"column":11,"offset":12823},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":340,"column":1,"offset":12825},"end":{"line":340,"column":283,"offset":13107},"indent":[]}}],"position":{"start":{"line":340,"column":1,"offset":12825},"end":{"line":340,"column":283,"offset":13107},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":342,"column":3,"offset":13111},"end":{"line":342,"column":54,"offset":13162},"indent":[]}}],"position":{"start":{"line":342,"column":3,"offset":13111},"end":{"line":342,"column":54,"offset":13162},"indent":[]}}],"position":{"start":{"line":342,"column":1,"offset":13109},"end":{"line":342,"column":54,"offset":13162},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":344,"column":5,"offset":13168},"end":{"line":344,"column":14,"offset":13177},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13164},"end":{"line":344,"column":14,"offset":13177},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":346,"column":1,"offset":13179},"end":{"line":346,"column":68,"offset":13246},"indent":[]}}],"position":{"start":{"line":346,"column":1,"offset":13179},"end":{"line":346,"column":68,"offset":13246},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":348,"column":1,"offset":13248},"end":{"line":351,"column":4,"offset":13399},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":353,"column":1,"offset":13401},"end":{"line":353,"column":46,"offset":13446},"indent":[]}}],"position":{"start":{"line":353,"column":1,"offset":13401},"end":{"line":353,"column":46,"offset":13446},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":355,"column":3,"offset":13450},"end":{"line":355,"column":103,"offset":13550},"indent":[]}}],"position":{"start":{"line":355,"column":3,"offset":13450},"end":{"line":355,"column":103,"offset":13550},"indent":[]}}],"position":{"start":{"line":355,"column":1,"offset":13448},"end":{"line":355,"column":103,"offset":13550},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":357,"column":1,"offset":13552},"end":{"line":362,"column":4,"offset":13762},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":364,"column":1,"offset":13764},"end":{"line":364,"column":151,"offset":13914},"indent":[]}}],"position":{"start":{"line":364,"column":1,"offset":13764},"end":{"line":364,"column":151,"offset":13914},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":366,"column":3,"offset":13918},"end":{"line":366,"column":22,"offset":13937},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":366,"column":22,"offset":13937},"end":{"line":366,"column":26,"offset":13941},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":366,"column":26,"offset":13941},"end":{"line":366,"column":40,"offset":13955},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":366,"column":40,"offset":13955},"end":{"line":366,"column":50,"offset":13965},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":366,"column":50,"offset":13965},"end":{"line":366,"column":98,"offset":14013},"indent":[]}}],"position":{"start":{"line":366,"column":3,"offset":13918},"end":{"line":366,"column":98,"offset":14013},"indent":[]}}],"position":{"start":{"line":366,"column":1,"offset":13916},"end":{"line":366,"column":98,"offset":14013},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":368,"column":1,"offset":14015},"end":{"line":372,"column":4,"offset":14177},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":374,"column":1,"offset":14179},"end":{"line":374,"column":72,"offset":14250},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":374,"column":72,"offset":14250},"end":{"line":374,"column":84,"offset":14262},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":374,"column":84,"offset":14262},"end":{"line":374,"column":102,"offset":14280},"indent":[]}}],"position":{"start":{"line":374,"column":1,"offset":14179},"end":{"line":374,"column":102,"offset":14280},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":376,"column":1,"offset":14282},"end":{"line":379,"column":4,"offset":14356},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":381,"column":5,"offset":14362},"end":{"line":381,"column":8,"offset":14365},"indent":[]}}],"position":{"start":{"line":381,"column":1,"offset":14358},"end":{"line":381,"column":8,"offset":14365},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":383,"column":1,"offset":14367},"end":{"line":383,"column":176,"offset":14542},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14367},"end":{"line":383,"column":176,"offset":14542},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":385,"column":1,"offset":14544},"end":{"line":392,"column":4,"offset":14841},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":394,"column":1,"offset":14843},"end":{"line":394,"column":60,"offset":14902},"indent":[]}}],"position":{"start":{"line":394,"column":1,"offset":14843},"end":{"line":394,"column":60,"offset":14902},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":396,"column":1,"offset":14904},"end":{"line":400,"column":4,"offset":15030},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":402,"column":1,"offset":15032},"end":{"line":402,"column":63,"offset":15094},"indent":[]}}],"position":{"start":{"line":402,"column":1,"offset":15032},"end":{"line":402,"column":63,"offset":15094},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":404,"column":1,"offset":15096},"end":{"line":424,"column":4,"offset":15603},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":426,"column":1,"offset":15605},"end":{"line":426,"column":99,"offset":15703},"indent":[]}}],"position":{"start":{"line":426,"column":1,"offset":15605},"end":{"line":426,"column":99,"offset":15703},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":428,"column":1,"offset":15705},"end":{"line":431,"column":4,"offset":15807},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":433,"column":1,"offset":15809},"end":{"line":433,"column":37,"offset":15845},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":433,"column":37,"offset":15845},"end":{"line":433,"column":47,"offset":15855},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":433,"column":47,"offset":15855},"end":{"line":433,"column":89,"offset":15897},"indent":[]}}],"position":{"start":{"line":433,"column":1,"offset":15809},"end":{"line":433,"column":89,"offset":15897},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":435,"column":1,"offset":15899},"end":{"line":439,"column":4,"offset":16024},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":441,"column":1,"offset":16026},"end":{"line":441,"column":78,"offset":16103},"indent":[]}}],"position":{"start":{"line":441,"column":1,"offset":16026},"end":{"line":441,"column":78,"offset":16103},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":443,"column":1,"offset":16105},"end":{"line":447,"column":4,"offset":16209},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":449,"column":1,"offset":16211},"end":{"line":449,"column":75,"offset":16285},"indent":[]}}],"position":{"start":{"line":449,"column":1,"offset":16211},"end":{"line":449,"column":75,"offset":16285},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":451,"column":1,"offset":16287},"end":{"line":455,"column":4,"offset":16360},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":457,"column":1,"offset":16362},"end":{"line":457,"column":145,"offset":16506},"indent":[]}}],"position":{"start":{"line":457,"column":1,"offset":16362},"end":{"line":457,"column":145,"offset":16506},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":459,"column":5,"offset":16512},"end":{"line":459,"column":17,"offset":16524},"indent":[]}}],"position":{"start":{"line":459,"column":1,"offset":16508},"end":{"line":459,"column":17,"offset":16524},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":461,"column":1,"offset":16526},"end":{"line":461,"column":300,"offset":16825},"indent":[]}}],"position":{"start":{"line":461,"column":1,"offset":16526},"end":{"line":461,"column":300,"offset":16825},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":463,"column":1,"offset":16827},"end":{"line":463,"column":178,"offset":17004},"indent":[]}}],"position":{"start":{"line":463,"column":1,"offset":16827},"end":{"line":463,"column":178,"offset":17004},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":465,"column":1,"offset":17006},"end":{"line":465,"column":48,"offset":17053},"indent":[]}}],"position":{"start":{"line":465,"column":1,"offset":17006},"end":{"line":465,"column":48,"offset":17053},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":467,"column":1,"offset":17055},"end":{"line":469,"column":4,"offset":17099},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":471,"column":1,"offset":17101},"end":{"line":471,"column":104,"offset":17204},"indent":[]}}],"position":{"start":{"line":471,"column":1,"offset":17101},"end":{"line":471,"column":104,"offset":17204},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":473,"column":1,"offset":17206},"end":{"line":481,"column":4,"offset":17476},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":483,"column":1,"offset":17478},"end":{"line":483,"column":28,"offset":17505},"indent":[]}}],"position":{"start":{"line":483,"column":1,"offset":17478},"end":{"line":483,"column":28,"offset":17505},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":485,"column":1,"offset":17507},"end":{"line":487,"column":4,"offset":17555},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":489,"column":1,"offset":17557},"end":{"line":489,"column":48,"offset":17604},"indent":[]}}],"position":{"start":{"line":489,"column":1,"offset":17557},"end":{"line":489,"column":48,"offset":17604},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":491,"column":1,"offset":17606},"end":{"line":493,"column":4,"offset":17628},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":495,"column":1,"offset":17630},"end":{"line":495,"column":72,"offset":17701},"indent":[]}}],"position":{"start":{"line":495,"column":1,"offset":17630},"end":{"line":495,"column":72,"offset":17701},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":497,"column":1,"offset":17703},"end":{"line":499,"column":4,"offset":17764},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":502,"column":1,"offset":17767},"end":{"line":502,"column":31,"offset":17797},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":502,"column":31,"offset":17797}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug-and-Play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.`}

\n

{`Especially in the worl\neven on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.`}

\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-a07cf4b43fe03cb970799ca6225b026d.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-a07cf4b43fe03cb970799ca6225b026d.json new file mode 100644 index 0000000..e1856b3 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-a07cf4b43fe03cb970799ca6225b026d.json @@ -0,0 +1 @@ +{"expireTime":9007200842319793000,"key":"gatsby-plugin-mdx-entire-payload-701e7ccd3fd5168831ea9bdb10cbba14-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4679},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":80,"offset":4760},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4760},"end":{"line":107,"column":101,"offset":4781},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4781},"end":{"line":107,"column":162,"offset":4842},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":162,"offset":4842},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4844},"end":{"line":112,"column":4,"offset":4933},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4938},"end":{"line":114,"column":10,"offset":4944},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4935},"end":{"line":114,"column":10,"offset":4944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":339,"offset":5284},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":340,"offset":5285},"end":{"line":116,"column":354,"offset":5299},"indent":[]}}],"position":{"start":{"line":116,"column":339,"offset":5284},"end":{"line":116,"column":390,"offset":5335},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":390,"offset":5335},"end":{"line":116,"column":391,"offset":5336},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":391,"offset":5336},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5342},"end":{"line":118,"column":18,"offset":5355},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5338},"end":{"line":118,"column":18,"offset":5355},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5357},"end":{"line":120,"column":50,"offset":5406},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5412},"end":{"line":122,"column":11,"offset":5418},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5408},"end":{"line":122,"column":11,"offset":5418},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":64,"offset":5483},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5484},"end":{"line":124,"column":86,"offset":5505},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5483},"end":{"line":124,"column":126,"offset":5545},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5545},"end":{"line":124,"column":127,"offset":5546},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":127,"offset":5546},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5552},"end":{"line":126,"column":26,"offset":5573},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5548},"end":{"line":126,"column":26,"offset":5573},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5702},"end":{"line":132,"column":4,"offset":5741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5931},"end":{"line":138,"column":4,"offset":6009},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6165},"end":{"line":145,"column":4,"offset":6312},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6414},"end":{"line":152,"column":4,"offset":6483},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6489},"end":{"line":154,"column":12,"offset":6496},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6485},"end":{"line":154,"column":12,"offset":6496},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example:","position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":65,"offset":6562},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":65,"offset":6562},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":157,"column":3,"offset":6565},"end":{"line":157,"column":25,"offset":6587},"indent":[]}}],"position":{"start":{"line":157,"column":3,"offset":6565},"end":{"line":157,"column":25,"offset":6587},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6563},"end":{"line":157,"column":25,"offset":6587},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":158,"column":3,"offset":6590},"end":{"line":158,"column":59,"offset":6646},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6590},"end":{"line":158,"column":59,"offset":6646},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6588},"end":{"line":158,"column":59,"offset":6646},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6563},"end":{"line":158,"column":59,"offset":6646},"indent":[1]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name kerberos-camera1 \\\n-p 80:80 -p 8889:8889 \\\n-v ~/config:/etc/opt/kerberosio/config \\\n-v ~/capture:/etc/opt/kerberosio/capture \\\n-v ~/logs:/etc/opt/kerberosio/logs \\\n-v ~/webconfig:/var/www/web/config \\\n-d kerberos/kerberos","position":{"start":{"line":160,"column":1,"offset":6648},"end":{"line":168,"column":4,"offset":6897},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.","position":{"start":{"line":170,"column":1,"offset":6899},"end":{"line":170,"column":87,"offset":6985},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":6899},"end":{"line":170,"column":87,"offset":6985},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://medium.com/@cedricverst/kerberos-io-the-road-to-docker-8e048a480241","children":[{"type":"text","value":"Kerberos.io — the road to Docker","position":{"start":{"line":171,"column":4,"offset":6989},"end":{"line":171,"column":36,"offset":7021},"indent":[]}}],"position":{"start":{"line":171,"column":3,"offset":6988},"end":{"line":171,"column":114,"offset":7099},"indent":[]}}],"position":{"start":{"line":171,"column":3,"offset":6988},"end":{"line":171,"column":114,"offset":7099},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":6986},"end":{"line":171,"column":114,"offset":7099},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":6986},"end":{"line":171,"column":114,"offset":7099},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":174,"column":4,"offset":7105},"end":{"line":174,"column":10,"offset":7111},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7102},"end":{"line":174,"column":10,"offset":7111},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.","position":{"start":{"line":176,"column":1,"offset":7113},"end":{"line":176,"column":310,"offset":7422},"indent":[]}}],"position":{"start":{"line":176,"column":1,"offset":7113},"end":{"line":176,"column":310,"offset":7422},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To fill the gap, regarding the latter, we can rely on another solution called ","position":{"start":{"line":178,"column":1,"offset":7424},"end":{"line":178,"column":79,"offset":7502},"indent":[]}},{"type":"link","title":null,"url":"https://balena.io","children":[{"type":"text","value":"Balena.io","position":{"start":{"line":178,"column":80,"offset":7503},"end":{"line":178,"column":89,"offset":7512},"indent":[]}}],"position":{"start":{"line":178,"column":79,"offset":7502},"end":{"line":178,"column":109,"offset":7532},"indent":[]}},{"type":"text","value":". Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).","position":{"start":{"line":178,"column":109,"offset":7532},"end":{"line":178,"column":386,"offset":7809},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7424},"end":{"line":178,"column":386,"offset":7809},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On top of supporting a lot of boars,","position":{"start":{"line":180,"column":1,"offset":7811},"end":{"line":180,"column":37,"offset":7847},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7811},"end":{"line":180,"column":37,"offset":7847},"indent":[]}},{"type":"thematicBreak","position":{"start":{"line":182,"column":1,"offset":7849},"end":{"line":182,"column":4,"offset":7852},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":184,"column":3,"offset":7856},"end":{"line":184,"column":11,"offset":7864},"indent":[]}}],"position":{"start":{"line":184,"column":1,"offset":7854},"end":{"line":184,"column":11,"offset":7864},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":186,"column":1,"offset":7866},"end":{"line":186,"column":133,"offset":7998},"indent":[]}}],"position":{"start":{"line":186,"column":1,"offset":7866},"end":{"line":186,"column":133,"offset":7998},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":188,"column":4,"offset":8003},"end":{"line":188,"column":12,"offset":8011},"indent":[]}}],"position":{"start":{"line":188,"column":1,"offset":8000},"end":{"line":188,"column":12,"offset":8011},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":190,"column":1,"offset":8013},"end":{"line":190,"column":193,"offset":8205},"indent":[]}}],"position":{"start":{"line":190,"column":1,"offset":8013},"end":{"line":190,"column":193,"offset":8205},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":192,"column":4,"offset":8210},"end":{"line":192,"column":62,"offset":8268},"indent":[]}}],"position":{"start":{"line":192,"column":4,"offset":8210},"end":{"line":192,"column":62,"offset":8268},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":8207},"end":{"line":192,"column":62,"offset":8268},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":193,"column":4,"offset":8272},"end":{"line":193,"column":69,"offset":8337},"indent":[]}}],"position":{"start":{"line":193,"column":4,"offset":8272},"end":{"line":193,"column":69,"offset":8337},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8269},"end":{"line":193,"column":69,"offset":8337},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":8207},"end":{"line":193,"column":69,"offset":8337},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":195,"column":1,"offset":8339},"end":{"line":195,"column":99,"offset":8437},"indent":[]}}],"position":{"start":{"line":195,"column":1,"offset":8339},"end":{"line":195,"column":99,"offset":8437},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":197,"column":5,"offset":8443},"end":{"line":197,"column":14,"offset":8452},"indent":[]}}],"position":{"start":{"line":197,"column":1,"offset":8439},"end":{"line":197,"column":14,"offset":8452},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":199,"column":1,"offset":8454},"end":{"line":199,"column":71,"offset":8524},"indent":[]}}],"position":{"start":{"line":199,"column":1,"offset":8454},"end":{"line":199,"column":71,"offset":8524},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":201,"column":3,"offset":8528},"end":{"line":201,"column":47,"offset":8572},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":201,"column":47,"offset":8572},"end":{"line":201,"column":79,"offset":8604},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":201,"column":79,"offset":8604},"end":{"line":201,"column":198,"offset":8723},"indent":[]}}],"position":{"start":{"line":201,"column":3,"offset":8528},"end":{"line":201,"column":198,"offset":8723},"indent":[]}}],"position":{"start":{"line":201,"column":1,"offset":8526},"end":{"line":201,"column":198,"offset":8723},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":203,"column":1,"offset":8725},"end":{"line":205,"column":4,"offset":8788},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":207,"column":5,"offset":8794},"end":{"line":207,"column":14,"offset":8803},"indent":[]}}],"position":{"start":{"line":207,"column":1,"offset":8790},"end":{"line":207,"column":14,"offset":8803},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":209,"column":1,"offset":8805},"end":{"line":209,"column":56,"offset":8860},"indent":[]}}],"position":{"start":{"line":209,"column":1,"offset":8805},"end":{"line":209,"column":56,"offset":8860},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":210,"column":3,"offset":8863},"end":{"line":210,"column":52,"offset":8912},"indent":[]}}],"position":{"start":{"line":210,"column":3,"offset":8863},"end":{"line":210,"column":52,"offset":8912},"indent":[]}}],"position":{"start":{"line":210,"column":3,"offset":8863},"end":{"line":210,"column":52,"offset":8912},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":8861},"end":{"line":210,"column":52,"offset":8912},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":212,"column":1,"offset":8914},"end":{"line":212,"column":3,"offset":8916},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":212,"column":3,"offset":8916},"end":{"line":212,"column":9,"offset":8922},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":212,"column":9,"offset":8922},"end":{"line":212,"column":223,"offset":9136},"indent":[]}}],"position":{"start":{"line":212,"column":1,"offset":8914},"end":{"line":212,"column":223,"offset":9136},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":214,"column":3,"offset":9140},"end":{"line":214,"column":159,"offset":9296},"indent":[]}}],"position":{"start":{"line":214,"column":3,"offset":9140},"end":{"line":214,"column":159,"offset":9296},"indent":[]}}],"position":{"start":{"line":214,"column":1,"offset":9138},"end":{"line":214,"column":159,"offset":9296},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":216,"column":1,"offset":9298},"end":{"line":219,"column":4,"offset":9475},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":221,"column":1,"offset":9477},"end":{"line":221,"column":160,"offset":9636},"indent":[]}}],"position":{"start":{"line":221,"column":1,"offset":9477},"end":{"line":221,"column":160,"offset":9636},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":223,"column":3,"offset":9640},"end":{"line":223,"column":31,"offset":9668},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":223,"column":31,"offset":9668},"end":{"line":223,"column":101,"offset":9738},"indent":[]}}],"position":{"start":{"line":223,"column":3,"offset":9640},"end":{"line":223,"column":101,"offset":9738},"indent":[]}}],"position":{"start":{"line":223,"column":1,"offset":9638},"end":{"line":223,"column":101,"offset":9738},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":225,"column":1,"offset":9740},"end":{"line":228,"column":4,"offset":9912},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":230,"column":1,"offset":9914},"end":{"line":230,"column":73,"offset":9986},"indent":[]}}],"position":{"start":{"line":230,"column":1,"offset":9914},"end":{"line":230,"column":73,"offset":9986},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":233,"column":3,"offset":9991},"end":{"line":233,"column":31,"offset":10019},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":233,"column":31,"offset":10019},"end":{"line":233,"column":101,"offset":10089},"indent":[]}}],"position":{"start":{"line":233,"column":3,"offset":9991},"end":{"line":233,"column":101,"offset":10089},"indent":[]}}],"position":{"start":{"line":233,"column":1,"offset":9989},"end":{"line":233,"column":101,"offset":10089},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":235,"column":1,"offset":10091},"end":{"line":238,"column":4,"offset":10263},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":240,"column":1,"offset":10265},"end":{"line":240,"column":62,"offset":10326},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":240,"column":63,"offset":10327},"end":{"line":240,"column":75,"offset":10339},"indent":[]}}],"position":{"start":{"line":240,"column":62,"offset":10326},"end":{"line":240,"column":143,"offset":10407},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":240,"column":143,"offset":10407},"end":{"line":240,"column":150,"offset":10414},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":240,"column":150,"offset":10414},"end":{"line":240,"column":169,"offset":10433},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":240,"column":169,"offset":10433},"end":{"line":240,"column":170,"offset":10434},"indent":[]}}],"position":{"start":{"line":240,"column":1,"offset":10265},"end":{"line":240,"column":170,"offset":10434},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":242,"column":1,"offset":10436},"end":{"line":244,"column":4,"offset":10463},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":246,"column":1,"offset":10465},"end":{"line":246,"column":58,"offset":10522},"indent":[]}}],"position":{"start":{"line":246,"column":1,"offset":10465},"end":{"line":246,"column":58,"offset":10522},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":248,"column":1,"offset":10524},"end":{"line":251,"column":4,"offset":10594},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":253,"column":5,"offset":10600},"end":{"line":253,"column":8,"offset":10603},"indent":[]}}],"position":{"start":{"line":253,"column":1,"offset":10596},"end":{"line":253,"column":8,"offset":10603},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":255,"column":1,"offset":10605},"end":{"line":255,"column":280,"offset":10884},"indent":[]}}],"position":{"start":{"line":255,"column":1,"offset":10605},"end":{"line":255,"column":280,"offset":10884},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":257,"column":1,"offset":10886},"end":{"line":257,"column":37,"offset":10922},"indent":[]}}],"position":{"start":{"line":257,"column":1,"offset":10886},"end":{"line":257,"column":37,"offset":10922},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":259,"column":1,"offset":10924},"end":{"line":261,"column":4,"offset":11097},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":263,"column":1,"offset":11099},"end":{"line":263,"column":25,"offset":11123},"indent":[]}}],"position":{"start":{"line":263,"column":1,"offset":11099},"end":{"line":263,"column":25,"offset":11123},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":265,"column":1,"offset":11125},"end":{"line":268,"column":4,"offset":11229},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":270,"column":1,"offset":11231},"end":{"line":270,"column":118,"offset":11348},"indent":[]}}],"position":{"start":{"line":270,"column":1,"offset":11231},"end":{"line":270,"column":118,"offset":11348},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":272,"column":1,"offset":11350},"end":{"line":292,"column":4,"offset":11857},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":294,"column":1,"offset":11859},"end":{"line":294,"column":14,"offset":11872},"indent":[]}}],"position":{"start":{"line":294,"column":1,"offset":11859},"end":{"line":294,"column":14,"offset":11872},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":296,"column":1,"offset":11874},"end":{"line":298,"column":4,"offset":11910},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":300,"column":1,"offset":11912},"end":{"line":300,"column":91,"offset":12002},"indent":[]}}],"position":{"start":{"line":300,"column":1,"offset":11912},"end":{"line":300,"column":91,"offset":12002},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":302,"column":1,"offset":12004},"end":{"line":310,"column":4,"offset":12377},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":312,"column":1,"offset":12379},"end":{"line":312,"column":145,"offset":12523},"indent":[]}}],"position":{"start":{"line":312,"column":1,"offset":12379},"end":{"line":312,"column":145,"offset":12523},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":314,"column":5,"offset":12529},"end":{"line":314,"column":17,"offset":12541},"indent":[]}}],"position":{"start":{"line":314,"column":1,"offset":12525},"end":{"line":314,"column":17,"offset":12541},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":316,"column":1,"offset":12543},"end":{"line":316,"column":300,"offset":12842},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12543},"end":{"line":316,"column":300,"offset":12842},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":318,"column":1,"offset":12844},"end":{"line":318,"column":178,"offset":13021},"indent":[]}}],"position":{"start":{"line":318,"column":1,"offset":12844},"end":{"line":318,"column":178,"offset":13021},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":320,"column":1,"offset":13023},"end":{"line":320,"column":48,"offset":13070},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":13023},"end":{"line":320,"column":48,"offset":13070},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":322,"column":1,"offset":13072},"end":{"line":324,"column":4,"offset":13112},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":326,"column":1,"offset":13114},"end":{"line":326,"column":104,"offset":13217},"indent":[]}}],"position":{"start":{"line":326,"column":1,"offset":13114},"end":{"line":326,"column":104,"offset":13217},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":328,"column":1,"offset":13219},"end":{"line":336,"column":4,"offset":13489},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":338,"column":1,"offset":13491},"end":{"line":338,"column":28,"offset":13518},"indent":[]}}],"position":{"start":{"line":338,"column":1,"offset":13491},"end":{"line":338,"column":28,"offset":13518},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":340,"column":1,"offset":13520},"end":{"line":342,"column":4,"offset":13564},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":344,"column":1,"offset":13566},"end":{"line":344,"column":48,"offset":13613},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13566},"end":{"line":344,"column":48,"offset":13613},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":346,"column":1,"offset":13615},"end":{"line":348,"column":4,"offset":13637},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":350,"column":1,"offset":13639},"end":{"line":350,"column":72,"offset":13710},"indent":[]}}],"position":{"start":{"line":350,"column":1,"offset":13639},"end":{"line":350,"column":72,"offset":13710},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":352,"column":1,"offset":13712},"end":{"line":354,"column":4,"offset":13769},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":356,"column":4,"offset":13774},"end":{"line":356,"column":11,"offset":13781},"indent":[]}}],"position":{"start":{"line":356,"column":1,"offset":13771},"end":{"line":356,"column":11,"offset":13781},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":358,"column":1,"offset":13783},"end":{"line":358,"column":283,"offset":14065},"indent":[]}}],"position":{"start":{"line":358,"column":1,"offset":13783},"end":{"line":358,"column":283,"offset":14065},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":360,"column":3,"offset":14069},"end":{"line":360,"column":54,"offset":14120},"indent":[]}}],"position":{"start":{"line":360,"column":3,"offset":14069},"end":{"line":360,"column":54,"offset":14120},"indent":[]}}],"position":{"start":{"line":360,"column":1,"offset":14067},"end":{"line":360,"column":54,"offset":14120},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":362,"column":5,"offset":14126},"end":{"line":362,"column":14,"offset":14135},"indent":[]}}],"position":{"start":{"line":362,"column":1,"offset":14122},"end":{"line":362,"column":14,"offset":14135},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":364,"column":1,"offset":14137},"end":{"line":364,"column":68,"offset":14204},"indent":[]}}],"position":{"start":{"line":364,"column":1,"offset":14137},"end":{"line":364,"column":68,"offset":14204},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":366,"column":1,"offset":14206},"end":{"line":369,"column":4,"offset":14357},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":371,"column":1,"offset":14359},"end":{"line":371,"column":46,"offset":14404},"indent":[]}}],"position":{"start":{"line":371,"column":1,"offset":14359},"end":{"line":371,"column":46,"offset":14404},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":373,"column":3,"offset":14408},"end":{"line":373,"column":103,"offset":14508},"indent":[]}}],"position":{"start":{"line":373,"column":3,"offset":14408},"end":{"line":373,"column":103,"offset":14508},"indent":[]}}],"position":{"start":{"line":373,"column":1,"offset":14406},"end":{"line":373,"column":103,"offset":14508},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":375,"column":1,"offset":14510},"end":{"line":380,"column":4,"offset":14720},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":382,"column":1,"offset":14722},"end":{"line":382,"column":151,"offset":14872},"indent":[]}}],"position":{"start":{"line":382,"column":1,"offset":14722},"end":{"line":382,"column":151,"offset":14872},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":384,"column":3,"offset":14876},"end":{"line":384,"column":22,"offset":14895},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":384,"column":22,"offset":14895},"end":{"line":384,"column":26,"offset":14899},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":384,"column":26,"offset":14899},"end":{"line":384,"column":40,"offset":14913},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":384,"column":40,"offset":14913},"end":{"line":384,"column":50,"offset":14923},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":384,"column":50,"offset":14923},"end":{"line":384,"column":98,"offset":14971},"indent":[]}}],"position":{"start":{"line":384,"column":3,"offset":14876},"end":{"line":384,"column":98,"offset":14971},"indent":[]}}],"position":{"start":{"line":384,"column":1,"offset":14874},"end":{"line":384,"column":98,"offset":14971},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":386,"column":1,"offset":14973},"end":{"line":390,"column":4,"offset":15135},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":392,"column":1,"offset":15137},"end":{"line":392,"column":72,"offset":15208},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":392,"column":72,"offset":15208},"end":{"line":392,"column":84,"offset":15220},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":392,"column":84,"offset":15220},"end":{"line":392,"column":102,"offset":15238},"indent":[]}}],"position":{"start":{"line":392,"column":1,"offset":15137},"end":{"line":392,"column":102,"offset":15238},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":394,"column":1,"offset":15240},"end":{"line":397,"column":4,"offset":15314},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":399,"column":5,"offset":15320},"end":{"line":399,"column":8,"offset":15323},"indent":[]}}],"position":{"start":{"line":399,"column":1,"offset":15316},"end":{"line":399,"column":8,"offset":15323},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":401,"column":1,"offset":15325},"end":{"line":401,"column":176,"offset":15500},"indent":[]}}],"position":{"start":{"line":401,"column":1,"offset":15325},"end":{"line":401,"column":176,"offset":15500},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":403,"column":1,"offset":15502},"end":{"line":410,"column":4,"offset":15799},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":412,"column":1,"offset":15801},"end":{"line":412,"column":60,"offset":15860},"indent":[]}}],"position":{"start":{"line":412,"column":1,"offset":15801},"end":{"line":412,"column":60,"offset":15860},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":414,"column":1,"offset":15862},"end":{"line":418,"column":4,"offset":15988},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":420,"column":1,"offset":15990},"end":{"line":420,"column":63,"offset":16052},"indent":[]}}],"position":{"start":{"line":420,"column":1,"offset":15990},"end":{"line":420,"column":63,"offset":16052},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":422,"column":1,"offset":16054},"end":{"line":442,"column":4,"offset":16561},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":444,"column":1,"offset":16563},"end":{"line":444,"column":99,"offset":16661},"indent":[]}}],"position":{"start":{"line":444,"column":1,"offset":16563},"end":{"line":444,"column":99,"offset":16661},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":446,"column":1,"offset":16663},"end":{"line":449,"column":4,"offset":16765},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":451,"column":1,"offset":16767},"end":{"line":451,"column":37,"offset":16803},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":451,"column":37,"offset":16803},"end":{"line":451,"column":47,"offset":16813},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":451,"column":47,"offset":16813},"end":{"line":451,"column":89,"offset":16855},"indent":[]}}],"position":{"start":{"line":451,"column":1,"offset":16767},"end":{"line":451,"column":89,"offset":16855},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":453,"column":1,"offset":16857},"end":{"line":457,"column":4,"offset":16982},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":459,"column":1,"offset":16984},"end":{"line":459,"column":78,"offset":17061},"indent":[]}}],"position":{"start":{"line":459,"column":1,"offset":16984},"end":{"line":459,"column":78,"offset":17061},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":461,"column":1,"offset":17063},"end":{"line":465,"column":4,"offset":17167},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":467,"column":1,"offset":17169},"end":{"line":467,"column":75,"offset":17243},"indent":[]}}],"position":{"start":{"line":467,"column":1,"offset":17169},"end":{"line":467,"column":75,"offset":17243},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":469,"column":1,"offset":17245},"end":{"line":473,"column":4,"offset":17318},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":475,"column":1,"offset":17320},"end":{"line":475,"column":145,"offset":17464},"indent":[]}}],"position":{"start":{"line":475,"column":1,"offset":17320},"end":{"line":475,"column":145,"offset":17464},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":477,"column":5,"offset":17470},"end":{"line":477,"column":17,"offset":17482},"indent":[]}}],"position":{"start":{"line":477,"column":1,"offset":17466},"end":{"line":477,"column":17,"offset":17482},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":479,"column":1,"offset":17484},"end":{"line":479,"column":300,"offset":17783},"indent":[]}}],"position":{"start":{"line":479,"column":1,"offset":17484},"end":{"line":479,"column":300,"offset":17783},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":481,"column":1,"offset":17785},"end":{"line":481,"column":178,"offset":17962},"indent":[]}}],"position":{"start":{"line":481,"column":1,"offset":17785},"end":{"line":481,"column":178,"offset":17962},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":483,"column":1,"offset":17964},"end":{"line":483,"column":48,"offset":18011},"indent":[]}}],"position":{"start":{"line":483,"column":1,"offset":17964},"end":{"line":483,"column":48,"offset":18011},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":485,"column":1,"offset":18013},"end":{"line":487,"column":4,"offset":18057},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":489,"column":1,"offset":18059},"end":{"line":489,"column":104,"offset":18162},"indent":[]}}],"position":{"start":{"line":489,"column":1,"offset":18059},"end":{"line":489,"column":104,"offset":18162},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":491,"column":1,"offset":18164},"end":{"line":499,"column":4,"offset":18434},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":501,"column":1,"offset":18436},"end":{"line":501,"column":28,"offset":18463},"indent":[]}}],"position":{"start":{"line":501,"column":1,"offset":18436},"end":{"line":501,"column":28,"offset":18463},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":503,"column":1,"offset":18465},"end":{"line":505,"column":4,"offset":18513},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":507,"column":1,"offset":18515},"end":{"line":507,"column":48,"offset":18562},"indent":[]}}],"position":{"start":{"line":507,"column":1,"offset":18515},"end":{"line":507,"column":48,"offset":18562},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":509,"column":1,"offset":18564},"end":{"line":511,"column":4,"offset":18586},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":513,"column":1,"offset":18588},"end":{"line":513,"column":72,"offset":18659},"indent":[]}}],"position":{"start":{"line":513,"column":1,"offset":18588},"end":{"line":513,"column":72,"offset":18659},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":515,"column":1,"offset":18661},"end":{"line":517,"column":4,"offset":18722},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":520,"column":1,"offset":18725},"end":{"line":520,"column":31,"offset":18755},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":520,"column":31,"offset":18755}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example:`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`kerberos`}{`-`}{`camera1`}{` \\\\`}{`\n`}{`-`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/config:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`config`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/capture:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`capture`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/logs:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`logs`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/webconfig:/`}{`var`}{`/`}{`www`}{`/web/config \\\\`}{`\n`}{`-`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`If you want to learn more about Kerberos.io on Docker, have a look at these tutorials.`}

\n \n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.`}

\n

{`To fill the gap, regarding the latter, we can rely on another solution called `}{`Balena.io`}{`. Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).`}

\n

{`On top of supporting a lot of boars,`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-a89b84451932065903e6bf25d9b03550.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-a89b84451932065903e6bf25d9b03550.json index 29bd805..77ec465 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-a89b84451932065903e6bf25d9b03550.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-a89b84451932065903e6bf25d9b03550.json @@ -1 +1 @@ -{"expireTime":9007200841014158000,"key":"gatsby-plugin-mdx-entire-payload-7b81f609843c42116aa94d7c916b4828-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"CC BY-NC-SA 4.0","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":18,"offset":176},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":18,"offset":176},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Summary","position":{"start":{"line":10,"column":4,"offset":181},"end":{"line":10,"column":11,"offset":188},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":178},"end":{"line":10,"column":11,"offset":188},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You are free to:","position":{"start":{"line":12,"column":1,"offset":190},"end":{"line":12,"column":17,"offset":206},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":190},"end":{"line":12,"column":17,"offset":206},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Share — copy and redistribute the material in any medium or format","position":{"start":{"line":14,"column":3,"offset":210},"end":{"line":14,"column":69,"offset":276},"indent":[]}}],"position":{"start":{"line":14,"column":3,"offset":210},"end":{"line":14,"column":69,"offset":276},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":208},"end":{"line":14,"column":69,"offset":276},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Adapt — remix, transform, and build upon the material","position":{"start":{"line":15,"column":3,"offset":279},"end":{"line":15,"column":56,"offset":332},"indent":[]}}],"position":{"start":{"line":15,"column":3,"offset":279},"end":{"line":15,"column":56,"offset":332},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":277},"end":{"line":15,"column":56,"offset":332},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":208},"end":{"line":15,"column":56,"offset":332},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"The license","position":{"start":{"line":17,"column":4,"offset":337},"end":{"line":17,"column":15,"offset":348},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":334},"end":{"line":17,"column":15,"offset":348},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International Public License\nBy exercising the Licensed Rights (defined below), You accept and agree to be bound by the terms and conditions of this Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International Public License (\"Public License\"). To the extent this Public License may be interpreted as a contract, You are granted the Licensed Rights in consideration of Your acceptance of these terms and conditions, and the Licensor grants You such rights in consideration of benefits the Licensor receives from making the Licensed Material available under these terms and conditions.","position":{"start":{"line":19,"column":1,"offset":350},"end":{"line":20,"column":567,"offset":1003},"indent":[1]}}],"position":{"start":{"line":19,"column":1,"offset":350},"end":{"line":20,"column":567,"offset":1003},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 1 – Definitions.","position":{"start":{"line":22,"column":5,"offset":1009},"end":{"line":22,"column":29,"offset":1033},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1005},"end":{"line":22,"column":29,"offset":1033},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Adapted Material means material subject to Copyright and Similar Rights that is derived from or based upon the Licensed Material and in which the Licensed Material is translated, altered, arranged, transformed, or otherwise modified in a manner requiring permission under the Copyright and Similar Rights held by the Licensor. For purposes of this Public License, where the Licensed Material is a musical work, performance, or sound recording, Adapted Material is always produced where the Licensed Material is synched in timed relation with a moving image.\nAdapter's License means the license You apply to Your Copyright and Similar Rights in Your contributions to Adapted Material in accordance with the terms and conditions of this Public License.\nBY-NC-SA Compatible License means a license listed at creativecommons.org/compatiblelicenses, approved by Creative Commons as essentially the equivalent of this Public License.\nCopyright and Similar Rights means copyright and/or similar rights closely related to copyright including, without limitation, performance, broadcast, sound recording, and Sui Generis Database Rights, without regard to how the rights are labeled or categorized. For purposes of this Public License, the rights specified in Section 2(b)(1)-(2) are not Copyright and Similar Rights.\nEffective Technological Measures means those measures that, in the absence of proper authority, may not be circumvented under laws fulfilling obligations under Article 11 of the WIPO Copyright Treaty adopted on December 20, 1996, and/or similar international agreements.\nExceptions and Limitations means fair use, fair dealing, and/or any other exception or limitation to Copyright and Similar Rights that applies to Your use of the Licensed Material.\nLicense Elements means the license attributes listed in the name of a Creative Commons Public License. The License Elements of this Public License are Attribution, NonCommercial, and ShareAlike.\nLicensed Material means the artistic or literary work, database, or other material to which the Licensor applied this Public License.\nLicensed Rights means the rights granted to You subject to the terms and conditions of this Public License, which are limited to all Copyright and Similar Rights that apply to Your use of the Licensed Material and that the Licensor has authority to license.\nLicensor means the individual(s) or entity(ies) granting rights under this Public License.\nNonCommercial means not primarily intended for or directed towards commercial advantage or monetary compensation. For purposes of this Public License, the exchange of the Licensed Material for other material subject to Copyright and Similar Rights by digital file-sharing or similar means is NonCommercial provided there is no payment of monetary compensation in connection with the exchange.\nShare means to provide material to the public by any means or process that requires permission under the Licensed Rights, such as reproduction, public display, public performance, distribution, dissemination, communication, or importation, and to make material available to the public including in ways that members of the public may access the material from a place and at a time individually chosen by them.\nSui Generis Database Rights means rights other than copyright resulting from Directive 96/9/EC of the European Parliament and of the Council of 11 March 1996 on the legal protection of databases, as amended and/or succeeded, as well as other essentially equivalent rights anywhere in the world.\nYou means the individual or entity exercising the Licensed Rights under this Public License. Your has a corresponding meaning.","position":{"start":{"line":24,"column":1,"offset":1035},"end":{"line":37,"column":127,"offset":4698},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1]}}],"position":{"start":{"line":24,"column":1,"offset":1035},"end":{"line":37,"column":127,"offset":4698},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 2 – Scope.","position":{"start":{"line":39,"column":5,"offset":4704},"end":{"line":39,"column":23,"offset":4722},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":4700},"end":{"line":39,"column":23,"offset":4722},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"License grant.\nSubject to the terms and conditions of this Public License, the Licensor hereby grants You a worldwide, royalty-free, non-sublicensable, non-exclusive, irrevocable license to exercise the Licensed Rights in the Licensed Material to:\nreproduce and Share the Licensed Material, in whole or in part, for NonCommercial purposes only; and\nproduce, reproduce, and Share Adapted Material for NonCommercial purposes only.\nExceptions and Limitations. For the avoidance of doubt, where Exceptions and Limitations apply to Your use, this Public License does not apply, and You do not need to comply with its terms and conditions.\nTerm. The term of this Public License is specified in Section 6(a).\nMedia and formats; technical modifications allowed. The Licensor authorizes You to exercise the Licensed Rights in all media and formats whether now known or hereafter created, and to make technical modifications necessary to do so. The Licensor waives and/or agrees not to assert any right or authority to forbid You from making technical modifications necessary to exercise the Licensed Rights, including technical modifications necessary to circumvent Effective Technological Measures. For purposes of this Public License, simply making modifications authorized by this Section 2(a)(4) never produces Adapted Material.\nDownstream recipients.\nOffer from the Licensor – Licensed Material. Every recipient of the Licensed Material automatically receives an offer from the Licensor to exercise the Licensed Rights under the terms and conditions of this Public License.\nAdditional offer from the Licensor – Adapted Material. Every recipient of Adapted Material from You automatically receives an offer from the Licensor to exercise the Licensed Rights in the Adapted Material under the conditions of the Adapter’s License You apply.\nNo downstream restrictions. You may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, the Licensed Material if doing so restricts exercise of the Licensed Rights by any recipient of the Licensed Material.\nNo endorsement. Nothing in this Public License constitutes or may be construed as permission to assert or imply that You are, or that Your use of the Licensed Material is, connected with, or sponsored, endorsed, or granted official status by, the Licensor or others designated to receive attribution as provided in Section 3(a)(1)(A)(i).\nOther rights.","position":{"start":{"line":41,"column":1,"offset":4724},"end":{"line":53,"column":14,"offset":7185},"indent":[1,1,1,1,1,1,1,1,1,1,1,1]}}],"position":{"start":{"line":41,"column":1,"offset":4724},"end":{"line":53,"column":14,"offset":7185},"indent":[1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Moral rights, such as the right of integrity, are not licensed under this Public License, nor are publicity, privacy, and/or other similar personality rights; however, to the extent possible, the Licensor waives and/or agrees not to assert any such rights held by the Licensor to the limited extent necessary to allow You to exercise the Licensed Rights, but not otherwise.\nPatent and trademark rights are not licensed under this Public License.\nTo the extent possible, the Licensor waives any right to collect royalties from You for the exercise of the Licensed Rights, whether directly or through a collecting society under any voluntary or waivable statutory or compulsory licensing scheme. In all other cases the Licensor expressly reserves any right to collect such royalties, including when the Licensed Material is used other than for NonCommercial purposes.","position":{"start":{"line":55,"column":1,"offset":7187},"end":{"line":57,"column":420,"offset":8052},"indent":[1,1]}}],"position":{"start":{"line":55,"column":1,"offset":7187},"end":{"line":57,"column":420,"offset":8052},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 3 – License Conditions.","position":{"start":{"line":59,"column":5,"offset":8058},"end":{"line":59,"column":36,"offset":8089},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":8054},"end":{"line":59,"column":36,"offset":8089},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Your exercise of the Licensed Rights is expressly made subject to the following conditions.","position":{"start":{"line":61,"column":1,"offset":8091},"end":{"line":61,"column":92,"offset":8182},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":8091},"end":{"line":61,"column":92,"offset":8182},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Attribution.","position":{"start":{"line":63,"column":1,"offset":8184},"end":{"line":63,"column":13,"offset":8196},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":8184},"end":{"line":63,"column":13,"offset":8196},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If You Share the Licensed Material (including in modified form), You must:","position":{"start":{"line":65,"column":1,"offset":8198},"end":{"line":65,"column":75,"offset":8272},"indent":[]}}],"position":{"start":{"line":65,"column":1,"offset":8198},"end":{"line":65,"column":75,"offset":8272},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"retain the following if it is supplied by the Licensor with the Licensed Material:\nidentification of the creator(s) of the Licensed Material and any others designated to receive attribution, in any reasonable manner requested by the Licensor (including by pseudonym if designated);\na copyright notice;\na notice that refers to this Public License;\na notice that refers to the disclaimer of warranties;\na URI or hyperlink to the Licensed Material to the extent reasonably practicable;\nindicate if You modified the Licensed Material and retain an indication of any previous modifications; and\nindicate the Licensed Material is licensed under this Public License, and include the text of, or the URI or hyperlink to, this Public License.\nYou may satisfy the conditions in Section 3(a)(1) in any reasonable manner based on the medium, means, and context in which You Share the Licensed Material. For example, it may be reasonable to satisfy the conditions by providing a URI or hyperlink to a resource that includes the required information.\nIf requested by the Licensor, You must remove any of the information required by Section 3(a)(1)(A) to the extent reasonably practicable.\nShareAlike.\nIn addition to the conditions in Section 3(a), if You Share Adapted Material You produce, the following conditions also apply.","position":{"start":{"line":67,"column":1,"offset":8274},"end":{"line":78,"column":127,"offset":9587},"indent":[1,1,1,1,1,1,1,1,1,1,1]}}],"position":{"start":{"line":67,"column":1,"offset":8274},"end":{"line":78,"column":127,"offset":9587},"indent":[1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"The Adapter’s License You apply must be a Creative Commons license with the same License Elements, this version or later, or a BY-NC-SA Compatible License.\nYou must include the text of, or the URI or hyperlink to, the Adapter's License You apply. You may satisfy this condition in any reasonable manner based on the medium, means, and context in which You Share Adapted Material.\nYou may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, Adapted Material that restrict exercise of the rights granted under the Adapter's License You apply.","position":{"start":{"line":80,"column":1,"offset":9589},"end":{"line":82,"column":231,"offset":10199},"indent":[1,1]}}],"position":{"start":{"line":80,"column":1,"offset":9589},"end":{"line":82,"column":231,"offset":10199},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 4 – Sui Generis Database Rights.","position":{"start":{"line":84,"column":5,"offset":10205},"end":{"line":84,"column":45,"offset":10245},"indent":[]}}],"position":{"start":{"line":84,"column":1,"offset":10201},"end":{"line":84,"column":45,"offset":10245},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Where the Licensed Rights include Sui Generis Database Rights that apply to Your use of the Licensed Material:","position":{"start":{"line":86,"column":1,"offset":10247},"end":{"line":86,"column":111,"offset":10357},"indent":[]}}],"position":{"start":{"line":86,"column":1,"offset":10247},"end":{"line":86,"column":111,"offset":10357},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"for the avoidance of doubt, Section 2(a)(1) grants You the right to extract, reuse, reproduce, and Share all or a substantial portion of the contents of the database for NonCommercial purposes only;\nif You include all or a substantial portion of the database contents in a database in which You have Sui Generis Database Rights, then the database in which You have Sui Generis Database Rights (but not its individual contents) is Adapted Material, including for purposes of Section 3(b); and\nYou must comply with the conditions in Section 3(a) if You Share all or a substantial portion of the contents of the database.\nFor the avoidance of doubt, this Section 4 supplements and does not replace Your obligations under this Public License where the Licensed Rights include other Copyright and Similar Rights.","position":{"start":{"line":88,"column":1,"offset":10359},"end":{"line":91,"column":189,"offset":11166},"indent":[1,1,1]}}],"position":{"start":{"line":88,"column":1,"offset":10359},"end":{"line":91,"column":189,"offset":11166},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 5 – Disclaimer of Warranties and Limitation of Liability.","position":{"start":{"line":93,"column":5,"offset":11172},"end":{"line":93,"column":70,"offset":11237},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":11168},"end":{"line":93,"column":70,"offset":11237},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Unless otherwise separately undertaken by the Licensor, to the extent possible, the Licensor offers the Licensed Material as-is and as-available, and makes no representations or warranties of any kind concerning the Licensed Material, whether express, implied, statutory, or other. This includes, without limitation, warranties of title, merchantability, fitness for a particular purpose, non-infringement, absence of latent or other defects, accuracy, or the presence or absence of errors, whether or not known or discoverable. Where disclaimers of warranties are not allowed in full or in part, this disclaimer may not apply to You.\nTo the extent possible, in no event will the Licensor be liable to You on any legal theory (including, without limitation, negligence) or otherwise for any direct, special, indirect, incidental, consequential, punitive, exemplary, or other losses, costs, expenses, or damages arising out of this Public License or use of the Licensed Material, even if the Licensor has been advised of the possibility of such losses, costs, expenses, or damages. Where a limitation of liability is not allowed in full or in part, this limitation may not apply to You.\nThe disclaimer of warranties and limitation of liability provided above shall be interpreted in a manner that, to the extent possible, most closely approximates an absolute disclaimer and waiver of all liability.","position":{"start":{"line":95,"column":1,"offset":11239},"end":{"line":97,"column":213,"offset":12637},"indent":[1,1]}}],"position":{"start":{"line":95,"column":1,"offset":11239},"end":{"line":97,"column":213,"offset":12637},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 6 – Term and Termination.","position":{"start":{"line":99,"column":5,"offset":12643},"end":{"line":99,"column":38,"offset":12676},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":12639},"end":{"line":99,"column":38,"offset":12676},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This Public License applies for the term of the Copyright and Similar Rights licensed here. However, if You fail to comply with this Public License, then Your rights under this Public License terminate automatically.\nWhere Your right to use the Licensed Material has terminated under Section 6(a), it reinstates:","position":{"start":{"line":101,"column":1,"offset":12678},"end":{"line":102,"column":96,"offset":12990},"indent":[1]}}],"position":{"start":{"line":101,"column":1,"offset":12678},"end":{"line":102,"column":96,"offset":12990},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"automatically as of the date the violation is cured, provided it is cured within 30 days of Your discovery of the violation; or\nupon express reinstatement by the Licensor.\nFor the avoidance of doubt, this Section 6(b) does not affect any right the Licensor may have to seek remedies for Your violations of this Public License.\nFor the avoidance of doubt, the Licensor may also offer the Licensed Material under separate terms or conditions or stop distributing the Licensed Material at any time; however, doing so will not terminate this Public License.\nSections 1, 5, 6, 7, and 8 survive termination of this Public License.","position":{"start":{"line":104,"column":1,"offset":12992},"end":{"line":108,"column":71,"offset":13616},"indent":[1,1,1,1]}}],"position":{"start":{"line":104,"column":1,"offset":12992},"end":{"line":108,"column":71,"offset":13616},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 7 – Other Terms and Conditions.","position":{"start":{"line":110,"column":5,"offset":13622},"end":{"line":110,"column":44,"offset":13661},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":13618},"end":{"line":110,"column":44,"offset":13661},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Licensor shall not be bound by any additional or different terms or conditions communicated by You unless expressly agreed.\nAny arrangements, understandings, or agreements regarding the Licensed Material not stated herein are separate from and independent of the terms and conditions of this Public License.","position":{"start":{"line":112,"column":1,"offset":13663},"end":{"line":113,"column":184,"offset":13974},"indent":[1]}}],"position":{"start":{"line":112,"column":1,"offset":13663},"end":{"line":113,"column":184,"offset":13974},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 8 – Interpretation.","position":{"start":{"line":115,"column":5,"offset":13980},"end":{"line":115,"column":32,"offset":14007},"indent":[]}}],"position":{"start":{"line":115,"column":1,"offset":13976},"end":{"line":115,"column":32,"offset":14007},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"For the avoidance of doubt, this Public License does not, and shall not be interpreted to, reduce, limit, restrict, or impose conditions on any use of the Licensed Material that could lawfully be made without permission under this Public License.\nTo the extent possible, if any provision of this Public License is deemed unenforceable, it shall be automatically reformed to the minimum extent necessary to make it enforceable. If the provision cannot be reformed, it shall be severed from this Public License without affecting the enforceability of the remaining terms and conditions.\nNo term or condition of this Public License will be waived and no failure to comply consented to unless expressly agreed to by the Licensor.\nNothing in this Public License constitutes or may be interpreted as a limitation upon, or waiver of, any privileges and immunities that apply to the Licensor or You, including from the legal processes of any jurisdiction or authority.","position":{"start":{"line":117,"column":1,"offset":14009},"end":{"line":120,"column":235,"offset":14969},"indent":[1,1,1]}}],"position":{"start":{"line":117,"column":1,"offset":14009},"end":{"line":120,"column":235,"offset":14969},"indent":[1,1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":123,"column":1,"offset":14972},"end":{"line":123,"column":31,"offset":15002},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":123,"column":31,"offset":15002}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`CC BY-NC-SA 4.0`}

\n

{`Summary`}

\n

{`You are free to:`}

\n
    \n
  • {`Share — copy and redistribute the material in any medium or format`}
  • \n
  • {`Adapt — remix, transform, and build upon the material`}
  • \n
\n

{`The license`}

\n

{`Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International Public License\nBy exercising the Licensed Rights (defined below), You accept and agree to be bound by the terms and conditions of this Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International Public License (\"Public License\"). To the extent this Public License may be interpreted as a contract, You are granted the Licensed Rights in consideration of Your acceptance of these terms and conditions, and the Licensor grants You such rights in consideration of benefits the Licensor receives from making the Licensed Material available under these terms and conditions.`}

\n

{`Section 1 – Definitions.`}

\n

{`Adapted Material means material subject to Copyright and Similar Rights that is derived from or based upon the Licensed Material and in which the Licensed Material is translated, altered, arranged, transformed, or otherwise modified in a manner requiring permission under the Copyright and Similar Rights held by the Licensor. For purposes of this Public License, where the Licensed Material is a musical work, performance, or sound recording, Adapted Material is always produced where the Licensed Material is synched in timed relation with a moving image.\nAdapter's License means the license You apply to Your Copyright and Similar Rights in Your contributions to Adapted Material in accordance with the terms and conditions of this Public License.\nBY-NC-SA Compatible License means a license listed at creativecommons.org/compatiblelicenses, approved by Creative Commons as essentially the equivalent of this Public License.\nCopyright and Similar Rights means copyright and/or similar rights closely related to copyright including, without limitation, performance, broadcast, sound recording, and Sui Generis Database Rights, without regard to how the rights are labeled or categorized. For purposes of this Public License, the rights specified in Section 2(b)(1)-(2) are not Copyright and Similar Rights.\nEffective Technological Measures means those measures that, in the absence of proper authority, may not be circumvented under laws fulfilling obligations under Article 11 of the WIPO Copyright Treaty adopted on December 20, 1996, and/or similar international agreements.\nExceptions and Limitations means fair use, fair dealing, and/or any other exception or limitation to Copyright and Similar Rights that applies to Your use of the Licensed Material.\nLicense Elements means the license attributes listed in the name of a Creative Commons Public License. The License Elements of this Public License are Attribution, NonCommercial, and ShareAlike.\nLicensed Material means the artistic or literary work, database, or other material to which the Licensor applied this Public License.\nLicensed Rights means the rights granted to You subject to the terms and conditions of this Public License, which are limited to all Copyright and Similar Rights that apply to Your use of the Licensed Material and that the Licensor has authority to license.\nLicensor means the individual(s) or entity(ies) granting rights under this Public License.\nNonCommercial means not primarily intended for or directed towards commercial advantage or monetary compensation. For purposes of this Public License, the exchange of the Licensed Material for other material subject to Copyright and Similar Rights by digital file-sharing or similar means is NonCommercial provided there is no payment of monetary compensation in connection with the exchange.\nShare means to provide material to the public by any means or process that requires permission under the Licensed Rights, such as reproduction, public display, public performance, distribution, dissemination, communication, or importation, and to make material available to the public including in ways that members of the public may access the material from a place and at a time individually chosen by them.\nSui Generis Database Rights means rights other than copyright resulting from Directive 96/9/EC of the European Parliament and of the Council of 11 March 1996 on the legal protection of databases, as amended and/or succeeded, as well as other essentially equivalent rights anywhere in the world.\nYou means the individual or entity exercising the Licensed Rights under this Public License. Your has a corresponding meaning.`}

\n

{`Section 2 – Scope.`}

\n

{`License grant.\nSubject to the terms and conditions of this Public License, the Licensor hereby grants You a worldwide, royalty-free, non-sublicensable, non-exclusive, irrevocable license to exercise the Licensed Rights in the Licensed Material to:\nreproduce and Share the Licensed Material, in whole or in part, for NonCommercial purposes only; and\nproduce, reproduce, and Share Adapted Material for NonCommercial purposes only.\nExceptions and Limitations. For the avoidance of doubt, where Exceptions and Limitations apply to Your use, this Public License does not apply, and You do not need to comply with its terms and conditions.\nTerm. The term of this Public License is specified in Section 6(a).\nMedia and formats; technical modifications allowed. The Licensor authorizes You to exercise the Licensed Rights in all media and formats whether now known or hereafter created, and to make technical modifications necessary to do so. The Licensor waives and/or agrees not to assert any right or authority to forbid You from making technical modifications necessary to exercise the Licensed Rights, including technical modifications necessary to circumvent Effective Technological Measures. For purposes of this Public License, simply making modifications authorized by this Section 2(a)(4) never produces Adapted Material.\nDownstream recipients.\nOffer from the Licensor – Licensed Material. Every recipient of the Licensed Material automatically receives an offer from the Licensor to exercise the Licensed Rights under the terms and conditions of this Public License.\nAdditional offer from the Licensor – Adapted Material. Every recipient of Adapted Material from You automatically receives an offer from the Licensor to exercise the Licensed Rights in the Adapted Material under the conditions of the Adapter’s License You apply.\nNo downstream restrictions. You may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, the Licensed Material if doing so restricts exercise of the Licensed Rights by any recipient of the Licensed Material.\nNo endorsement. Nothing in this Public License constitutes or may be construed as permission to assert or imply that You are, or that Your use of the Licensed Material is, connected with, or sponsored, endorsed, or granted official status by, the Licensor or others designated to receive attribution as provided in Section 3(a)(1)(A)(i).\nOther rights.`}

\n

{`Moral rights, such as the right of integrity, are not licensed under this Public License, nor are publicity, privacy, and/or other similar personality rights; however, to the extent possible, the Licensor waives and/or agrees not to assert any such rights held by the Licensor to the limited extent necessary to allow You to exercise the Licensed Rights, but not otherwise.\nPatent and trademark rights are not licensed under this Public License.\nTo the extent possible, the Licensor waives any right to collect royalties from You for the exercise of the Licensed Rights, whether directly or through a collecting society under any voluntary or waivable statutory or compulsory licensing scheme. In all other cases the Licensor expressly reserves any right to collect such royalties, including when the Licensed Material is used other than for NonCommercial purposes.`}

\n

{`Section 3 – License Conditions.`}

\n

{`Your exercise of the Licensed Rights is expressly made subject to the following conditions.`}

\n

{`Attribution.`}

\n

{`If You Share the Licensed Material (including in modified form), You must:`}

\n

{`retain the following if it is supplied by the Licensor with the Licensed Material:\nidentification of the creator(s) of the Licensed Material and any others designated to receive attribution, in any reasonable manner requested by the Licensor (including by pseudonym if designated);\na copyright notice;\na notice that refers to this Public License;\na notice that refers to the disclaimer of warranties;\na URI or hyperlink to the Licensed Material to the extent reasonably practicable;\nindicate if You modified the Licensed Material and retain an indication of any previous modifications; and\nindicate the Licensed Material is licensed under this Public License, and include the text of, or the URI or hyperlink to, this Public License.\nYou may satisfy the conditions in Section 3(a)(1) in any reasonable manner based on the medium, means, and context in which You Share the Licensed Material. For example, it may be reasonable to satisfy the conditions by providing a URI or hyperlink to a resource that includes the required information.\nIf requested by the Licensor, You must remove any of the information required by Section 3(a)(1)(A) to the extent reasonably practicable.\nShareAlike.\nIn addition to the conditions in Section 3(a), if You Share Adapted Material You produce, the following conditions also apply.`}

\n

{`The Adapter’s License You apply must be a Creative Commons license with the same License Elements, this version or later, or a BY-NC-SA Compatible License.\nYou must include the text of, or the URI or hyperlink to, the Adapter's License You apply. You may satisfy this condition in any reasonable manner based on the medium, means, and context in which You Share Adapted Material.\nYou may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, Adapted Material that restrict exercise of the rights granted under the Adapter's License You apply.`}

\n

{`Section 4 – Sui Generis Database Rights.`}

\n

{`Where the Licensed Rights include Sui Generis Database Rights that apply to Your use of the Licensed Material:`}

\n

{`for the avoidance of doubt, Section 2(a)(1) grants You the right to extract, reuse, reproduce, and Share all or a substantial portion of the contents of the database for NonCommercial purposes only;\nif You include all or a substantial portion of the database contents in a database in which You have Sui Generis Database Rights, then the database in which You have Sui Generis Database Rights (but not its individual contents) is Adapted Material, including for purposes of Section 3(b); and\nYou must comply with the conditions in Section 3(a) if You Share all or a substantial portion of the contents of the database.\nFor the avoidance of doubt, this Section 4 supplements and does not replace Your obligations under this Public License where the Licensed Rights include other Copyright and Similar Rights.`}

\n

{`Section 5 – Disclaimer of Warranties and Limitation of Liability.`}

\n

{`Unless otherwise separately undertaken by the Licensor, to the extent possible, the Licensor offers the Licensed Material as-is and as-available, and makes no representations or warranties of any kind concerning the Licensed Material, whether express, implied, statutory, or other. This includes, without limitation, warranties of title, merchantability, fitness for a particular purpose, non-infringement, absence of latent or other defects, accuracy, or the presence or absence of errors, whether or not known or discoverable. Where disclaimers of warranties are not allowed in full or in part, this disclaimer may not apply to You.\nTo the extent possible, in no event will the Licensor be liable to You on any legal theory (including, without limitation, negligence) or otherwise for any direct, special, indirect, incidental, consequential, punitive, exemplary, or other losses, costs, expenses, or damages arising out of this Public License or use of the Licensed Material, even if the Licensor has been advised of the possibility of such losses, costs, expenses, or damages. Where a limitation of liability is not allowed in full or in part, this limitation may not apply to You.\nThe disclaimer of warranties and limitation of liability provided above shall be interpreted in a manner that, to the extent possible, most closely approximates an absolute disclaimer and waiver of all liability.`}

\n

{`Section 6 – Term and Termination.`}

\n

{`This Public License applies for the term of the Copyright and Similar Rights licensed here. However, if You fail to comply with this Public License, then Your rights under this Public License terminate automatically.\nWhere Your right to use the Licensed Material has terminated under Section 6(a), it reinstates:`}

\n

{`automatically as of the date the violation is cured, provided it is cured within 30 days of Your discovery of the violation; or\nupon express reinstatement by the Licensor.\nFor the avoidance of doubt, this Section 6(b) does not affect any right the Licensor may have to seek remedies for Your violations of this Public License.\nFor the avoidance of doubt, the Licensor may also offer the Licensed Material under separate terms or conditions or stop distributing the Licensed Material at any time; however, doing so will not terminate this Public License.\nSections 1, 5, 6, 7, and 8 survive termination of this Public License.`}

\n

{`Section 7 – Other Terms and Conditions.`}

\n

{`The Licensor shall not be bound by any additional or different terms or conditions communicated by You unless expressly agreed.\nAny arrangements, understandings, or agreements regarding the Licensed Material not stated herein are separate from and independent of the terms and conditions of this Public License.`}

\n

{`Section 8 – Interpretation.`}

\n

{`For the avoidance of doubt, this Public License does not, and shall not be interpreted to, reduce, limit, restrict, or impose conditions on any use of the Licensed Material that could lawfully be made without permission under this Public License.\nTo the extent possible, if any provision of this Public License is deemed unenforceable, it shall be automatically reformed to the minimum extent necessary to make it enforceable. If the provision cannot be reformed, it shall be severed from this Public License without affecting the enforceability of the remaining terms and conditions.\nNo term or condition of this Public License will be waived and no failure to comply consented to unless expressly agreed to by the Licensor.\nNothing in this Public License constitutes or may be interpreted as a limitation upon, or waiver of, any privileges and immunities that apply to the Licensor or You, including from the legal processes of any jurisdiction or authority.`}

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974263000,"key":"gatsby-plugin-mdx-entire-payload-7b81f609843c42116aa94d7c916b4828-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"CC BY-NC-SA 4.0","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":18,"offset":176},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":18,"offset":176},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Summary","position":{"start":{"line":10,"column":4,"offset":181},"end":{"line":10,"column":11,"offset":188},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":178},"end":{"line":10,"column":11,"offset":188},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You are free to:","position":{"start":{"line":12,"column":1,"offset":190},"end":{"line":12,"column":17,"offset":206},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":190},"end":{"line":12,"column":17,"offset":206},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Share — copy and redistribute the material in any medium or format","position":{"start":{"line":14,"column":3,"offset":210},"end":{"line":14,"column":69,"offset":276},"indent":[]}}],"position":{"start":{"line":14,"column":3,"offset":210},"end":{"line":14,"column":69,"offset":276},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":208},"end":{"line":14,"column":69,"offset":276},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Adapt — remix, transform, and build upon the material","position":{"start":{"line":15,"column":3,"offset":279},"end":{"line":15,"column":56,"offset":332},"indent":[]}}],"position":{"start":{"line":15,"column":3,"offset":279},"end":{"line":15,"column":56,"offset":332},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":277},"end":{"line":15,"column":56,"offset":332},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":208},"end":{"line":15,"column":56,"offset":332},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"The license","position":{"start":{"line":17,"column":4,"offset":337},"end":{"line":17,"column":15,"offset":348},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":334},"end":{"line":17,"column":15,"offset":348},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International Public License\nBy exercising the Licensed Rights (defined below), You accept and agree to be bound by the terms and conditions of this Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International Public License (\"Public License\"). To the extent this Public License may be interpreted as a contract, You are granted the Licensed Rights in consideration of Your acceptance of these terms and conditions, and the Licensor grants You such rights in consideration of benefits the Licensor receives from making the Licensed Material available under these terms and conditions.","position":{"start":{"line":19,"column":1,"offset":350},"end":{"line":20,"column":567,"offset":1003},"indent":[1]}}],"position":{"start":{"line":19,"column":1,"offset":350},"end":{"line":20,"column":567,"offset":1003},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 1 – Definitions.","position":{"start":{"line":22,"column":5,"offset":1009},"end":{"line":22,"column":29,"offset":1033},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1005},"end":{"line":22,"column":29,"offset":1033},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Adapted Material means material subject to Copyright and Similar Rights that is derived from or based upon the Licensed Material and in which the Licensed Material is translated, altered, arranged, transformed, or otherwise modified in a manner requiring permission under the Copyright and Similar Rights held by the Licensor. For purposes of this Public License, where the Licensed Material is a musical work, performance, or sound recording, Adapted Material is always produced where the Licensed Material is synched in timed relation with a moving image.\nAdapter's License means the license You apply to Your Copyright and Similar Rights in Your contributions to Adapted Material in accordance with the terms and conditions of this Public License.\nBY-NC-SA Compatible License means a license listed at creativecommons.org/compatiblelicenses, approved by Creative Commons as essentially the equivalent of this Public License.\nCopyright and Similar Rights means copyright and/or similar rights closely related to copyright including, without limitation, performance, broadcast, sound recording, and Sui Generis Database Rights, without regard to how the rights are labeled or categorized. For purposes of this Public License, the rights specified in Section 2(b)(1)-(2) are not Copyright and Similar Rights.\nEffective Technological Measures means those measures that, in the absence of proper authority, may not be circumvented under laws fulfilling obligations under Article 11 of the WIPO Copyright Treaty adopted on December 20, 1996, and/or similar international agreements.\nExceptions and Limitations means fair use, fair dealing, and/or any other exception or limitation to Copyright and Similar Rights that applies to Your use of the Licensed Material.\nLicense Elements means the license attributes listed in the name of a Creative Commons Public License. The License Elements of this Public License are Attribution, NonCommercial, and ShareAlike.\nLicensed Material means the artistic or literary work, database, or other material to which the Licensor applied this Public License.\nLicensed Rights means the rights granted to You subject to the terms and conditions of this Public License, which are limited to all Copyright and Similar Rights that apply to Your use of the Licensed Material and that the Licensor has authority to license.\nLicensor means the individual(s) or entity(ies) granting rights under this Public License.\nNonCommercial means not primarily intended for or directed towards commercial advantage or monetary compensation. For purposes of this Public License, the exchange of the Licensed Material for other material subject to Copyright and Similar Rights by digital file-sharing or similar means is NonCommercial provided there is no payment of monetary compensation in connection with the exchange.\nShare means to provide material to the public by any means or process that requires permission under the Licensed Rights, such as reproduction, public display, public performance, distribution, dissemination, communication, or importation, and to make material available to the public including in ways that members of the public may access the material from a place and at a time individually chosen by them.\nSui Generis Database Rights means rights other than copyright resulting from Directive 96/9/EC of the European Parliament and of the Council of 11 March 1996 on the legal protection of databases, as amended and/or succeeded, as well as other essentially equivalent rights anywhere in the world.\nYou means the individual or entity exercising the Licensed Rights under this Public License. Your has a corresponding meaning.","position":{"start":{"line":24,"column":1,"offset":1035},"end":{"line":37,"column":127,"offset":4698},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1]}}],"position":{"start":{"line":24,"column":1,"offset":1035},"end":{"line":37,"column":127,"offset":4698},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 2 – Scope.","position":{"start":{"line":39,"column":5,"offset":4704},"end":{"line":39,"column":23,"offset":4722},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":4700},"end":{"line":39,"column":23,"offset":4722},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"License grant.\nSubject to the terms and conditions of this Public License, the Licensor hereby grants You a worldwide, royalty-free, non-sublicensable, non-exclusive, irrevocable license to exercise the Licensed Rights in the Licensed Material to:\nreproduce and Share the Licensed Material, in whole or in part, for NonCommercial purposes only; and\nproduce, reproduce, and Share Adapted Material for NonCommercial purposes only.\nExceptions and Limitations. For the avoidance of doubt, where Exceptions and Limitations apply to Your use, this Public License does not apply, and You do not need to comply with its terms and conditions.\nTerm. The term of this Public License is specified in Section 6(a).\nMedia and formats; technical modifications allowed. The Licensor authorizes You to exercise the Licensed Rights in all media and formats whether now known or hereafter created, and to make technical modifications necessary to do so. The Licensor waives and/or agrees not to assert any right or authority to forbid You from making technical modifications necessary to exercise the Licensed Rights, including technical modifications necessary to circumvent Effective Technological Measures. For purposes of this Public License, simply making modifications authorized by this Section 2(a)(4) never produces Adapted Material.\nDownstream recipients.\nOffer from the Licensor – Licensed Material. Every recipient of the Licensed Material automatically receives an offer from the Licensor to exercise the Licensed Rights under the terms and conditions of this Public License.\nAdditional offer from the Licensor – Adapted Material. Every recipient of Adapted Material from You automatically receives an offer from the Licensor to exercise the Licensed Rights in the Adapted Material under the conditions of the Adapter’s License You apply.\nNo downstream restrictions. You may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, the Licensed Material if doing so restricts exercise of the Licensed Rights by any recipient of the Licensed Material.\nNo endorsement. Nothing in this Public License constitutes or may be construed as permission to assert or imply that You are, or that Your use of the Licensed Material is, connected with, or sponsored, endorsed, or granted official status by, the Licensor or others designated to receive attribution as provided in Section 3(a)(1)(A)(i).\nOther rights.","position":{"start":{"line":41,"column":1,"offset":4724},"end":{"line":53,"column":14,"offset":7185},"indent":[1,1,1,1,1,1,1,1,1,1,1,1]}}],"position":{"start":{"line":41,"column":1,"offset":4724},"end":{"line":53,"column":14,"offset":7185},"indent":[1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Moral rights, such as the right of integrity, are not licensed under this Public License, nor are publicity, privacy, and/or other similar personality rights; however, to the extent possible, the Licensor waives and/or agrees not to assert any such rights held by the Licensor to the limited extent necessary to allow You to exercise the Licensed Rights, but not otherwise.\nPatent and trademark rights are not licensed under this Public License.\nTo the extent possible, the Licensor waives any right to collect royalties from You for the exercise of the Licensed Rights, whether directly or through a collecting society under any voluntary or waivable statutory or compulsory licensing scheme. In all other cases the Licensor expressly reserves any right to collect such royalties, including when the Licensed Material is used other than for NonCommercial purposes.","position":{"start":{"line":55,"column":1,"offset":7187},"end":{"line":57,"column":420,"offset":8052},"indent":[1,1]}}],"position":{"start":{"line":55,"column":1,"offset":7187},"end":{"line":57,"column":420,"offset":8052},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 3 – License Conditions.","position":{"start":{"line":59,"column":5,"offset":8058},"end":{"line":59,"column":36,"offset":8089},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":8054},"end":{"line":59,"column":36,"offset":8089},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Your exercise of the Licensed Rights is expressly made subject to the following conditions.","position":{"start":{"line":61,"column":1,"offset":8091},"end":{"line":61,"column":92,"offset":8182},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":8091},"end":{"line":61,"column":92,"offset":8182},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Attribution.","position":{"start":{"line":63,"column":1,"offset":8184},"end":{"line":63,"column":13,"offset":8196},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":8184},"end":{"line":63,"column":13,"offset":8196},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If You Share the Licensed Material (including in modified form), You must:","position":{"start":{"line":65,"column":1,"offset":8198},"end":{"line":65,"column":75,"offset":8272},"indent":[]}}],"position":{"start":{"line":65,"column":1,"offset":8198},"end":{"line":65,"column":75,"offset":8272},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"retain the following if it is supplied by the Licensor with the Licensed Material:\nidentification of the creator(s) of the Licensed Material and any others designated to receive attribution, in any reasonable manner requested by the Licensor (including by pseudonym if designated);\na copyright notice;\na notice that refers to this Public License;\na notice that refers to the disclaimer of warranties;\na URI or hyperlink to the Licensed Material to the extent reasonably practicable;\nindicate if You modified the Licensed Material and retain an indication of any previous modifications; and\nindicate the Licensed Material is licensed under this Public License, and include the text of, or the URI or hyperlink to, this Public License.\nYou may satisfy the conditions in Section 3(a)(1) in any reasonable manner based on the medium, means, and context in which You Share the Licensed Material. For example, it may be reasonable to satisfy the conditions by providing a URI or hyperlink to a resource that includes the required information.\nIf requested by the Licensor, You must remove any of the information required by Section 3(a)(1)(A) to the extent reasonably practicable.\nShareAlike.\nIn addition to the conditions in Section 3(a), if You Share Adapted Material You produce, the following conditions also apply.","position":{"start":{"line":67,"column":1,"offset":8274},"end":{"line":78,"column":127,"offset":9587},"indent":[1,1,1,1,1,1,1,1,1,1,1]}}],"position":{"start":{"line":67,"column":1,"offset":8274},"end":{"line":78,"column":127,"offset":9587},"indent":[1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"The Adapter’s License You apply must be a Creative Commons license with the same License Elements, this version or later, or a BY-NC-SA Compatible License.\nYou must include the text of, or the URI or hyperlink to, the Adapter's License You apply. You may satisfy this condition in any reasonable manner based on the medium, means, and context in which You Share Adapted Material.\nYou may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, Adapted Material that restrict exercise of the rights granted under the Adapter's License You apply.","position":{"start":{"line":80,"column":1,"offset":9589},"end":{"line":82,"column":231,"offset":10199},"indent":[1,1]}}],"position":{"start":{"line":80,"column":1,"offset":9589},"end":{"line":82,"column":231,"offset":10199},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 4 – Sui Generis Database Rights.","position":{"start":{"line":84,"column":5,"offset":10205},"end":{"line":84,"column":45,"offset":10245},"indent":[]}}],"position":{"start":{"line":84,"column":1,"offset":10201},"end":{"line":84,"column":45,"offset":10245},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Where the Licensed Rights include Sui Generis Database Rights that apply to Your use of the Licensed Material:","position":{"start":{"line":86,"column":1,"offset":10247},"end":{"line":86,"column":111,"offset":10357},"indent":[]}}],"position":{"start":{"line":86,"column":1,"offset":10247},"end":{"line":86,"column":111,"offset":10357},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"for the avoidance of doubt, Section 2(a)(1) grants You the right to extract, reuse, reproduce, and Share all or a substantial portion of the contents of the database for NonCommercial purposes only;\nif You include all or a substantial portion of the database contents in a database in which You have Sui Generis Database Rights, then the database in which You have Sui Generis Database Rights (but not its individual contents) is Adapted Material, including for purposes of Section 3(b); and\nYou must comply with the conditions in Section 3(a) if You Share all or a substantial portion of the contents of the database.\nFor the avoidance of doubt, this Section 4 supplements and does not replace Your obligations under this Public License where the Licensed Rights include other Copyright and Similar Rights.","position":{"start":{"line":88,"column":1,"offset":10359},"end":{"line":91,"column":189,"offset":11166},"indent":[1,1,1]}}],"position":{"start":{"line":88,"column":1,"offset":10359},"end":{"line":91,"column":189,"offset":11166},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 5 – Disclaimer of Warranties and Limitation of Liability.","position":{"start":{"line":93,"column":5,"offset":11172},"end":{"line":93,"column":70,"offset":11237},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":11168},"end":{"line":93,"column":70,"offset":11237},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Unless otherwise separately undertaken by the Licensor, to the extent possible, the Licensor offers the Licensed Material as-is and as-available, and makes no representations or warranties of any kind concerning the Licensed Material, whether express, implied, statutory, or other. This includes, without limitation, warranties of title, merchantability, fitness for a particular purpose, non-infringement, absence of latent or other defects, accuracy, or the presence or absence of errors, whether or not known or discoverable. Where disclaimers of warranties are not allowed in full or in part, this disclaimer may not apply to You.\nTo the extent possible, in no event will the Licensor be liable to You on any legal theory (including, without limitation, negligence) or otherwise for any direct, special, indirect, incidental, consequential, punitive, exemplary, or other losses, costs, expenses, or damages arising out of this Public License or use of the Licensed Material, even if the Licensor has been advised of the possibility of such losses, costs, expenses, or damages. Where a limitation of liability is not allowed in full or in part, this limitation may not apply to You.\nThe disclaimer of warranties and limitation of liability provided above shall be interpreted in a manner that, to the extent possible, most closely approximates an absolute disclaimer and waiver of all liability.","position":{"start":{"line":95,"column":1,"offset":11239},"end":{"line":97,"column":213,"offset":12637},"indent":[1,1]}}],"position":{"start":{"line":95,"column":1,"offset":11239},"end":{"line":97,"column":213,"offset":12637},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 6 – Term and Termination.","position":{"start":{"line":99,"column":5,"offset":12643},"end":{"line":99,"column":38,"offset":12676},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":12639},"end":{"line":99,"column":38,"offset":12676},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This Public License applies for the term of the Copyright and Similar Rights licensed here. However, if You fail to comply with this Public License, then Your rights under this Public License terminate automatically.\nWhere Your right to use the Licensed Material has terminated under Section 6(a), it reinstates:","position":{"start":{"line":101,"column":1,"offset":12678},"end":{"line":102,"column":96,"offset":12990},"indent":[1]}}],"position":{"start":{"line":101,"column":1,"offset":12678},"end":{"line":102,"column":96,"offset":12990},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"automatically as of the date the violation is cured, provided it is cured within 30 days of Your discovery of the violation; or\nupon express reinstatement by the Licensor.\nFor the avoidance of doubt, this Section 6(b) does not affect any right the Licensor may have to seek remedies for Your violations of this Public License.\nFor the avoidance of doubt, the Licensor may also offer the Licensed Material under separate terms or conditions or stop distributing the Licensed Material at any time; however, doing so will not terminate this Public License.\nSections 1, 5, 6, 7, and 8 survive termination of this Public License.","position":{"start":{"line":104,"column":1,"offset":12992},"end":{"line":108,"column":71,"offset":13616},"indent":[1,1,1,1]}}],"position":{"start":{"line":104,"column":1,"offset":12992},"end":{"line":108,"column":71,"offset":13616},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 7 – Other Terms and Conditions.","position":{"start":{"line":110,"column":5,"offset":13622},"end":{"line":110,"column":44,"offset":13661},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":13618},"end":{"line":110,"column":44,"offset":13661},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Licensor shall not be bound by any additional or different terms or conditions communicated by You unless expressly agreed.\nAny arrangements, understandings, or agreements regarding the Licensed Material not stated herein are separate from and independent of the terms and conditions of this Public License.","position":{"start":{"line":112,"column":1,"offset":13663},"end":{"line":113,"column":184,"offset":13974},"indent":[1]}}],"position":{"start":{"line":112,"column":1,"offset":13663},"end":{"line":113,"column":184,"offset":13974},"indent":[1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Section 8 – Interpretation.","position":{"start":{"line":115,"column":5,"offset":13980},"end":{"line":115,"column":32,"offset":14007},"indent":[]}}],"position":{"start":{"line":115,"column":1,"offset":13976},"end":{"line":115,"column":32,"offset":14007},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"For the avoidance of doubt, this Public License does not, and shall not be interpreted to, reduce, limit, restrict, or impose conditions on any use of the Licensed Material that could lawfully be made without permission under this Public License.\nTo the extent possible, if any provision of this Public License is deemed unenforceable, it shall be automatically reformed to the minimum extent necessary to make it enforceable. If the provision cannot be reformed, it shall be severed from this Public License without affecting the enforceability of the remaining terms and conditions.\nNo term or condition of this Public License will be waived and no failure to comply consented to unless expressly agreed to by the Licensor.\nNothing in this Public License constitutes or may be interpreted as a limitation upon, or waiver of, any privileges and immunities that apply to the Licensor or You, including from the legal processes of any jurisdiction or authority.","position":{"start":{"line":117,"column":1,"offset":14009},"end":{"line":120,"column":235,"offset":14969},"indent":[1,1,1]}}],"position":{"start":{"line":117,"column":1,"offset":14009},"end":{"line":120,"column":235,"offset":14969},"indent":[1,1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":123,"column":1,"offset":14972},"end":{"line":123,"column":31,"offset":15002},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":123,"column":31,"offset":15002}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`CC BY-NC-SA 4.0`}

\n

{`Summary`}

\n

{`You are free to:`}

\n
    \n
  • {`Share — copy and redistribute the material in any medium or format`}
  • \n
  • {`Adapt — remix, transform, and build upon the material`}
  • \n
\n

{`The license`}

\n

{`Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International Public License\nBy exercising the Licensed Rights (defined below), You accept and agree to be bound by the terms and conditions of this Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International Public License (\"Public License\"). To the extent this Public License may be interpreted as a contract, You are granted the Licensed Rights in consideration of Your acceptance of these terms and conditions, and the Licensor grants You such rights in consideration of benefits the Licensor receives from making the Licensed Material available under these terms and conditions.`}

\n

{`Section 1 – Definitions.`}

\n

{`Adapted Material means material subject to Copyright and Similar Rights that is derived from or based upon the Licensed Material and in which the Licensed Material is translated, altered, arranged, transformed, or otherwise modified in a manner requiring permission under the Copyright and Similar Rights held by the Licensor. For purposes of this Public License, where the Licensed Material is a musical work, performance, or sound recording, Adapted Material is always produced where the Licensed Material is synched in timed relation with a moving image.\nAdapter's License means the license You apply to Your Copyright and Similar Rights in Your contributions to Adapted Material in accordance with the terms and conditions of this Public License.\nBY-NC-SA Compatible License means a license listed at creativecommons.org/compatiblelicenses, approved by Creative Commons as essentially the equivalent of this Public License.\nCopyright and Similar Rights means copyright and/or similar rights closely related to copyright including, without limitation, performance, broadcast, sound recording, and Sui Generis Database Rights, without regard to how the rights are labeled or categorized. For purposes of this Public License, the rights specified in Section 2(b)(1)-(2) are not Copyright and Similar Rights.\nEffective Technological Measures means those measures that, in the absence of proper authority, may not be circumvented under laws fulfilling obligations under Article 11 of the WIPO Copyright Treaty adopted on December 20, 1996, and/or similar international agreements.\nExceptions and Limitations means fair use, fair dealing, and/or any other exception or limitation to Copyright and Similar Rights that applies to Your use of the Licensed Material.\nLicense Elements means the license attributes listed in the name of a Creative Commons Public License. The License Elements of this Public License are Attribution, NonCommercial, and ShareAlike.\nLicensed Material means the artistic or literary work, database, or other material to which the Licensor applied this Public License.\nLicensed Rights means the rights granted to You subject to the terms and conditions of this Public License, which are limited to all Copyright and Similar Rights that apply to Your use of the Licensed Material and that the Licensor has authority to license.\nLicensor means the individual(s) or entity(ies) granting rights under this Public License.\nNonCommercial means not primarily intended for or directed towards commercial advantage or monetary compensation. For purposes of this Public License, the exchange of the Licensed Material for other material subject to Copyright and Similar Rights by digital file-sharing or similar means is NonCommercial provided there is no payment of monetary compensation in connection with the exchange.\nShare means to provide material to the public by any means or process that requires permission under the Licensed Rights, such as reproduction, public display, public performance, distribution, dissemination, communication, or importation, and to make material available to the public including in ways that members of the public may access the material from a place and at a time individually chosen by them.\nSui Generis Database Rights means rights other than copyright resulting from Directive 96/9/EC of the European Parliament and of the Council of 11 March 1996 on the legal protection of databases, as amended and/or succeeded, as well as other essentially equivalent rights anywhere in the world.\nYou means the individual or entity exercising the Licensed Rights under this Public License. Your has a corresponding meaning.`}

\n

{`Section 2 – Scope.`}

\n

{`License grant.\nSubject to the terms and conditions of this Public License, the Licensor hereby grants You a worldwide, royalty-free, non-sublicensable, non-exclusive, irrevocable license to exercise the Licensed Rights in the Licensed Material to:\nreproduce and Share the Licensed Material, in whole or in part, for NonCommercial purposes only; and\nproduce, reproduce, and Share Adapted Material for NonCommercial purposes only.\nExceptions and Limitations. For the avoidance of doubt, where Exceptions and Limitations apply to Your use, this Public License does not apply, and You do not need to comply with its terms and conditions.\nTerm. The term of this Public License is specified in Section 6(a).\nMedia and formats; technical modifications allowed. The Licensor authorizes You to exercise the Licensed Rights in all media and formats whether now known or hereafter created, and to make technical modifications necessary to do so. The Licensor waives and/or agrees not to assert any right or authority to forbid You from making technical modifications necessary to exercise the Licensed Rights, including technical modifications necessary to circumvent Effective Technological Measures. For purposes of this Public License, simply making modifications authorized by this Section 2(a)(4) never produces Adapted Material.\nDownstream recipients.\nOffer from the Licensor – Licensed Material. Every recipient of the Licensed Material automatically receives an offer from the Licensor to exercise the Licensed Rights under the terms and conditions of this Public License.\nAdditional offer from the Licensor – Adapted Material. Every recipient of Adapted Material from You automatically receives an offer from the Licensor to exercise the Licensed Rights in the Adapted Material under the conditions of the Adapter’s License You apply.\nNo downstream restrictions. You may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, the Licensed Material if doing so restricts exercise of the Licensed Rights by any recipient of the Licensed Material.\nNo endorsement. Nothing in this Public License constitutes or may be construed as permission to assert or imply that You are, or that Your use of the Licensed Material is, connected with, or sponsored, endorsed, or granted official status by, the Licensor or others designated to receive attribution as provided in Section 3(a)(1)(A)(i).\nOther rights.`}

\n

{`Moral rights, such as the right of integrity, are not licensed under this Public License, nor are publicity, privacy, and/or other similar personality rights; however, to the extent possible, the Licensor waives and/or agrees not to assert any such rights held by the Licensor to the limited extent necessary to allow You to exercise the Licensed Rights, but not otherwise.\nPatent and trademark rights are not licensed under this Public License.\nTo the extent possible, the Licensor waives any right to collect royalties from You for the exercise of the Licensed Rights, whether directly or through a collecting society under any voluntary or waivable statutory or compulsory licensing scheme. In all other cases the Licensor expressly reserves any right to collect such royalties, including when the Licensed Material is used other than for NonCommercial purposes.`}

\n

{`Section 3 – License Conditions.`}

\n

{`Your exercise of the Licensed Rights is expressly made subject to the following conditions.`}

\n

{`Attribution.`}

\n

{`If You Share the Licensed Material (including in modified form), You must:`}

\n

{`retain the following if it is supplied by the Licensor with the Licensed Material:\nidentification of the creator(s) of the Licensed Material and any others designated to receive attribution, in any reasonable manner requested by the Licensor (including by pseudonym if designated);\na copyright notice;\na notice that refers to this Public License;\na notice that refers to the disclaimer of warranties;\na URI or hyperlink to the Licensed Material to the extent reasonably practicable;\nindicate if You modified the Licensed Material and retain an indication of any previous modifications; and\nindicate the Licensed Material is licensed under this Public License, and include the text of, or the URI or hyperlink to, this Public License.\nYou may satisfy the conditions in Section 3(a)(1) in any reasonable manner based on the medium, means, and context in which You Share the Licensed Material. For example, it may be reasonable to satisfy the conditions by providing a URI or hyperlink to a resource that includes the required information.\nIf requested by the Licensor, You must remove any of the information required by Section 3(a)(1)(A) to the extent reasonably practicable.\nShareAlike.\nIn addition to the conditions in Section 3(a), if You Share Adapted Material You produce, the following conditions also apply.`}

\n

{`The Adapter’s License You apply must be a Creative Commons license with the same License Elements, this version or later, or a BY-NC-SA Compatible License.\nYou must include the text of, or the URI or hyperlink to, the Adapter's License You apply. You may satisfy this condition in any reasonable manner based on the medium, means, and context in which You Share Adapted Material.\nYou may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, Adapted Material that restrict exercise of the rights granted under the Adapter's License You apply.`}

\n

{`Section 4 – Sui Generis Database Rights.`}

\n

{`Where the Licensed Rights include Sui Generis Database Rights that apply to Your use of the Licensed Material:`}

\n

{`for the avoidance of doubt, Section 2(a)(1) grants You the right to extract, reuse, reproduce, and Share all or a substantial portion of the contents of the database for NonCommercial purposes only;\nif You include all or a substantial portion of the database contents in a database in which You have Sui Generis Database Rights, then the database in which You have Sui Generis Database Rights (but not its individual contents) is Adapted Material, including for purposes of Section 3(b); and\nYou must comply with the conditions in Section 3(a) if You Share all or a substantial portion of the contents of the database.\nFor the avoidance of doubt, this Section 4 supplements and does not replace Your obligations under this Public License where the Licensed Rights include other Copyright and Similar Rights.`}

\n

{`Section 5 – Disclaimer of Warranties and Limitation of Liability.`}

\n

{`Unless otherwise separately undertaken by the Licensor, to the extent possible, the Licensor offers the Licensed Material as-is and as-available, and makes no representations or warranties of any kind concerning the Licensed Material, whether express, implied, statutory, or other. This includes, without limitation, warranties of title, merchantability, fitness for a particular purpose, non-infringement, absence of latent or other defects, accuracy, or the presence or absence of errors, whether or not known or discoverable. Where disclaimers of warranties are not allowed in full or in part, this disclaimer may not apply to You.\nTo the extent possible, in no event will the Licensor be liable to You on any legal theory (including, without limitation, negligence) or otherwise for any direct, special, indirect, incidental, consequential, punitive, exemplary, or other losses, costs, expenses, or damages arising out of this Public License or use of the Licensed Material, even if the Licensor has been advised of the possibility of such losses, costs, expenses, or damages. Where a limitation of liability is not allowed in full or in part, this limitation may not apply to You.\nThe disclaimer of warranties and limitation of liability provided above shall be interpreted in a manner that, to the extent possible, most closely approximates an absolute disclaimer and waiver of all liability.`}

\n

{`Section 6 – Term and Termination.`}

\n

{`This Public License applies for the term of the Copyright and Similar Rights licensed here. However, if You fail to comply with this Public License, then Your rights under this Public License terminate automatically.\nWhere Your right to use the Licensed Material has terminated under Section 6(a), it reinstates:`}

\n

{`automatically as of the date the violation is cured, provided it is cured within 30 days of Your discovery of the violation; or\nupon express reinstatement by the Licensor.\nFor the avoidance of doubt, this Section 6(b) does not affect any right the Licensor may have to seek remedies for Your violations of this Public License.\nFor the avoidance of doubt, the Licensor may also offer the Licensed Material under separate terms or conditions or stop distributing the Licensed Material at any time; however, doing so will not terminate this Public License.\nSections 1, 5, 6, 7, and 8 survive termination of this Public License.`}

\n

{`Section 7 – Other Terms and Conditions.`}

\n

{`The Licensor shall not be bound by any additional or different terms or conditions communicated by You unless expressly agreed.\nAny arrangements, understandings, or agreements regarding the Licensed Material not stated herein are separate from and independent of the terms and conditions of this Public License.`}

\n

{`Section 8 – Interpretation.`}

\n

{`For the avoidance of doubt, this Public License does not, and shall not be interpreted to, reduce, limit, restrict, or impose conditions on any use of the Licensed Material that could lawfully be made without permission under this Public License.\nTo the extent possible, if any provision of this Public License is deemed unenforceable, it shall be automatically reformed to the minimum extent necessary to make it enforceable. If the provision cannot be reformed, it shall be severed from this Public License without affecting the enforceability of the remaining terms and conditions.\nNo term or condition of this Public License will be waived and no failure to comply consented to unless expressly agreed to by the Licensor.\nNothing in this Public License constitutes or may be interpreted as a limitation upon, or waiver of, any privileges and immunities that apply to the Licensor or You, including from the legal processes of any jurisdiction or authority.`}

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-bb82aa854932c622ccbfd9f435edcc09.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-bb82aa854932c622ccbfd9f435edcc09.json index fe18031..deb7be5 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-bb82aa854932c622ccbfd9f435edcc09.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-bb82aa854932c622ccbfd9f435edcc09.json @@ -1 +1 @@ -{"expireTime":9007200841014157000,"key":"gatsby-plugin-mdx-entire-payload-a8908e0eaea1e9144f6be04175ca6c5d-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Architectures","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":16,"offset":174},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":16,"offset":174},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"In this section we will explain some usecases and best practices, which might help you to define the architecture that fits your needs.","position":{"start":{"line":10,"column":1,"offset":176},"end":{"line":10,"column":136,"offset":311},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":176},"end":{"line":10,"column":136,"offset":311},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please read the ","position":{"start":{"line":12,"column":3,"offset":315},"end":{"line":12,"column":19,"offset":331},"indent":[]}},{"type":"link","title":null,"url":"/","children":[{"type":"text","value":"introduction page","position":{"start":{"line":12,"column":20,"offset":332},"end":{"line":12,"column":37,"offset":349},"indent":[]}}],"position":{"start":{"line":12,"column":19,"offset":331},"end":{"line":12,"column":41,"offset":353},"indent":[]}},{"type":"text","value":" first, before moving forward.","position":{"start":{"line":12,"column":41,"offset":353},"end":{"line":12,"column":71,"offset":383},"indent":[]}}],"position":{"start":{"line":12,"column":3,"offset":315},"end":{"line":12,"column":71,"offset":383},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":313},"end":{"line":12,"column":71,"offset":383},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When starting with Kerberos you might ask yourself, how should I deploy these so called, Kerberos agents? Well, there are different options. You can install a Kerberos agent on a Raspberry Pi, VM, Server or even in a Kubernetes cluster. So what should you do, and when? Let's have a closer look at the different options.","position":{"start":{"line":14,"column":1,"offset":385},"end":{"line":14,"column":321,"offset":705},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":385},"end":{"line":14,"column":321,"offset":705},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The first thing you need to consider is the environment, in which you want to deploy your Kerberos agents. Is it inside your house, your company or at a public place? Another important factor is the number of surveillance cameras you would like to monitor, and if you have any high availability requirements.","position":{"start":{"line":16,"column":1,"offset":707},"end":{"line":16,"column":309,"offset":1015},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":707},"end":{"line":16,"column":309,"offset":1015},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Agents on-premise","position":{"start":{"line":18,"column":4,"offset":1020},"end":{"line":18,"column":21,"offset":1037},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":1017},"end":{"line":18,"column":21,"offset":1037},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The most common scenario is to install your Kerberos agents on-premise. This has a couple of benefits such as latency, bandwidth and a less complex security model. When installing a Kerberos agent on-premise, you have a couple of different options.","position":{"start":{"line":20,"column":1,"offset":1039},"end":{"line":20,"column":249,"offset":1287},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":1039},"end":{"line":20,"column":249,"offset":1287},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source (< 5 Kerberos agents)","position":{"start":{"line":22,"column":5,"offset":1293},"end":{"line":22,"column":47,"offset":1335},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1289},"end":{"line":22,"column":47,"offset":1335},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have a limited number of surveillance cameras you would like to monitor, and don't have any high availability requirements, the Kerberos Open Source agent is a good choice. For example, you can install the Kerberos Open Source agent on a Raspberry Pi, by using ","position":{"start":{"line":24,"column":1,"offset":1337},"end":{"line":24,"column":269,"offset":1605},"indent":[]}},{"type":"link","title":null,"url":"opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":24,"column":270,"offset":1606},"end":{"line":24,"column":274,"offset":1610},"indent":[]}}],"position":{"start":{"line":24,"column":269,"offset":1605},"end":{"line":24,"column":305,"offset":1641},"indent":[]}},{"type":"text","value":", ","position":{"start":{"line":24,"column":305,"offset":1641},"end":{"line":24,"column":307,"offset":1643},"indent":[]}},{"type":"link","title":null,"url":"opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian OS","position":{"start":{"line":24,"column":308,"offset":1644},"end":{"line":24,"column":319,"offset":1655},"indent":[]}}],"position":{"start":{"line":24,"column":307,"offset":1643},"end":{"line":24,"column":354,"offset":1690},"indent":[]}},{"type":"text","value":" or compile it from source.","position":{"start":{"line":24,"column":354,"offset":1690},"end":{"line":24,"column":381,"offset":1717},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1337},"end":{"line":24,"column":381,"offset":1717},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On below architecture, a couple of Kerberos agents are installed on-premise (inside the local network). A Kerberos agent is installed for each surveillance camera, and each Kerberos agent runs on a seperate host (Raspberry Pi, VM, etc). The web interface of the Kerberos agents can be reached from the internal network, but cannot be accessed from the cloud.","position":{"start":{"line":26,"column":1,"offset":1719},"end":{"line":26,"column":359,"offset":2077},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1719},"end":{"line":26,"column":359,"offset":2077},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../public/images/kerberos-agent-architecture-kios.png","alt":"architecture kios","position":{"start":{"line":28,"column":1,"offset":2079},"end":{"line":28,"column":76,"offset":2154},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":2079},"end":{"line":28,"column":76,"offset":2154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Another option to install the Kerberos Open Source agent is to use Docker. Instead of having seperate hosts for each Kerberos agent, you will have a single host (Docker host) with multiple Docker containers. A Docker container is deployed for each surveillance camera, which contains the software to run the Kerberos agent.","position":{"start":{"line":30,"column":1,"offset":2156},"end":{"line":30,"column":324,"offset":2479},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":2156},"end":{"line":30,"column":324,"offset":2479},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running your Kerberos agents inside Docker containers, allows you to process multiple surveilllance cameras using only one host.","position":{"start":{"line":32,"column":1,"offset":2481},"end":{"line":32,"column":129,"offset":2609},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":2481},"end":{"line":32,"column":129,"offset":2609},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../public/images/kerberos-agent-architecture-docker.png","alt":"architecture kios","position":{"start":{"line":34,"column":1,"offset":2611},"end":{"line":34,"column":78,"offset":2688},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":2611},"end":{"line":34,"column":78,"offset":2688},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Enterprise (> 5 Kerberos agents)","position":{"start":{"line":36,"column":5,"offset":2694},"end":{"line":36,"column":46,"offset":2735},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":2690},"end":{"line":36,"column":46,"offset":2735},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When working within an enterprise context, where you require high availability and have a large amount of surveillance cameras being monitored, ","position":{"start":{"line":38,"column":1,"offset":2737},"end":{"line":38,"column":145,"offset":2881},"indent":[]}},{"type":"link","title":null,"url":"/enterprise/introduction","children":[{"type":"text","value":"Kerberos Enterprise","position":{"start":{"line":38,"column":146,"offset":2882},"end":{"line":38,"column":165,"offset":2901},"indent":[]}}],"position":{"start":{"line":38,"column":145,"offset":2881},"end":{"line":38,"column":192,"offset":2928},"indent":[]}},{"type":"text","value":" is a good choice. Im comparison to the Open Source version, Kerberos Enterprise will use Kubernetes to help you scale (and secure) your security landscape. Kerberos agents, or Kubernetes deployments, are deployed inside your cluster and load balanced over the different nodes. When a Kerberos agent dies, or the node on which the deployment is running, Kubernetes will reschedule it to another healthy node.","position":{"start":{"line":38,"column":192,"offset":2928},"end":{"line":38,"column":600,"offset":3336},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":2737},"end":{"line":38,"column":600,"offset":3336},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../public/images/kerberos-agent-architecture-kubernetes.png","alt":"architecture kubernetes","position":{"start":{"line":40,"column":1,"offset":3338},"end":{"line":40,"column":88,"offset":3425},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":3338},"end":{"line":40,"column":88,"offset":3425},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Agents in the cloud","position":{"start":{"line":42,"column":4,"offset":3430},"end":{"line":42,"column":23,"offset":3449},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":3427},"end":{"line":42,"column":23,"offset":3449},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Instead of processing your surveillance cameras on-premise you could also process them in the cloud. There are a couple advantages, for example, you don't have to manage your owner hardware, you can simply spin up a VM on one of the hyperscalers.","position":{"start":{"line":44,"column":1,"offset":3451},"end":{"line":44,"column":247,"offset":3697},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":3451},"end":{"line":44,"column":247,"offset":3697},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When dealing with Kerberos agents in the cloud, the complexity starts with the security model. As your surveillance cameras are running somewhere on-premise, you will need to make them available to your Kerberos agents, which are running in the cloud. There are several ways to do that, such as port forwarding (not recommended) or setting up a site-to-site VPN (recommended).","position":{"start":{"line":46,"column":1,"offset":3699},"end":{"line":46,"column":377,"offset":4075},"indent":[]}}],"position":{"start":{"line":46,"column":1,"offset":3699},"end":{"line":46,"column":377,"offset":4075},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When setting up a VPN connection you will expose your surveillance cameras to your Kerberos agents. Once you've configured the Kerberos agents, data will flow through this secure tunnel, from on-premise to your cloud enviroment.","position":{"start":{"line":48,"column":1,"offset":4077},"end":{"line":48,"column":229,"offset":4305},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":4077},"end":{"line":48,"column":229,"offset":4305},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source (< 5 Kerberos agents)","position":{"start":{"line":50,"column":5,"offset":4311},"end":{"line":50,"column":47,"offset":4353},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":4307},"end":{"line":50,"column":47,"offset":4353},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have a limited number of surveillance cameras you would like to monitor, and don't have any high availability requirements, the Kerberos Open Source agent is a good choice. You can install the Kerberos Open Source agent on Docker. Instead of having seperate VM's for each Kerberos agent, you will have a single VM (Docker host) with multiple Docker containers. A Docker container is deployed for each surveillance camera, which contains the software to run the Kerberos agent.","position":{"start":{"line":52,"column":1,"offset":4355},"end":{"line":52,"column":484,"offset":4838},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":4355},"end":{"line":52,"column":484,"offset":4838},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../public/images/kerberos-agent-architecture-docker-cloud.png","alt":"architecture kios","position":{"start":{"line":54,"column":1,"offset":4840},"end":{"line":54,"column":84,"offset":4923},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":4840},"end":{"line":54,"column":84,"offset":4923},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Enterprise (> 5 Kerberos agents)","position":{"start":{"line":56,"column":5,"offset":4929},"end":{"line":56,"column":46,"offset":4970},"indent":[]}}],"position":{"start":{"line":56,"column":1,"offset":4925},"end":{"line":56,"column":46,"offset":4970},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Similar to ","position":{"start":{"line":58,"column":1,"offset":4972},"end":{"line":58,"column":12,"offset":4983},"indent":[]}},{"type":"link","title":null,"url":"/enterprise/introduction","children":[{"type":"text","value":"Kerberos Enterprise","position":{"start":{"line":58,"column":13,"offset":4984},"end":{"line":58,"column":32,"offset":5003},"indent":[]}}],"position":{"start":{"line":58,"column":12,"offset":4983},"end":{"line":58,"column":59,"offset":5030},"indent":[]}},{"type":"text","value":" on-premise, you can run the a Kubernetes in the cloud. The exact same solution is available, only the way how you connect to your video surveillance cameras will be different, as they will probably live in a different network. To make this work you will need to setup a VPN tunnel (or whatever your security teams have defined as a back practice). When ","position":{"start":{"line":58,"column":59,"offset":5030},"end":{"line":58,"column":413,"offset":5384},"indent":[]}},{"type":"link","title":null,"url":"/enterprise/introduction","children":[{"type":"text","value":"Kerberos Enterprise","position":{"start":{"line":58,"column":414,"offset":5385},"end":{"line":58,"column":433,"offset":5404},"indent":[]}}],"position":{"start":{"line":58,"column":413,"offset":5384},"end":{"line":58,"column":460,"offset":5431},"indent":[]}},{"type":"text","value":" is deployed to the cloud, it can be used any where. Public cloud (AWS, Google, Azure, etc) or private cloud. You can run it where you want.","position":{"start":{"line":58,"column":460,"offset":5431},"end":{"line":58,"column":600,"offset":5571},"indent":[]}}],"position":{"start":{"line":58,"column":1,"offset":4972},"end":{"line":58,"column":600,"offset":5571},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../public/images/kerberos-agent-architecture-kubernetes-cloud.png","alt":"architecture kubernetes","position":{"start":{"line":60,"column":1,"offset":5573},"end":{"line":60,"column":94,"offset":5666},"indent":[]}}],"position":{"start":{"line":60,"column":1,"offset":5573},"end":{"line":60,"column":94,"offset":5666},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Kerberos Cloud","position":{"start":{"line":62,"column":4,"offset":5671},"end":{"line":62,"column":18,"offset":5685},"indent":[]}}],"position":{"start":{"line":62,"column":1,"offset":5668},"end":{"line":62,"column":18,"offset":5685},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've configured one of the previously mentioned architectures, you will have one or more Kerberos agents running, in the cloud or on-premise.","position":{"start":{"line":64,"column":1,"offset":5687},"end":{"line":64,"column":149,"offset":5835},"indent":[]}}],"position":{"start":{"line":64,"column":1,"offset":5687},"end":{"line":64,"column":149,"offset":5835},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Kerberos Open Source agent comes with a web interface, which makes it possible to review the activity for that specific agent; they don't have a consolidated overview. This means that you will need to open multiple web interfaces, one for Kerberos agent. In contrary Kerberos Enterprise agents, don't come with a web interface, therefore the Kerberos Cloud (public or private edition) is recommended.","position":{"start":{"line":66,"column":1,"offset":5837},"end":{"line":66,"column":405,"offset":6241},"indent":[]}}],"position":{"start":{"line":66,"column":1,"offset":5837},"end":{"line":66,"column":405,"offset":6241},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To simplify this process and resolve some other challenges, Kerberos Cloud was developed.","position":{"start":{"line":68,"column":1,"offset":6243},"end":{"line":68,"column":90,"offset":6332},"indent":[]}}],"position":{"start":{"line":68,"column":1,"offset":6243},"end":{"line":68,"column":90,"offset":6332},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://cloud.kerberos.io","children":[{"type":"text","value":"Kerberos Cloud","position":{"start":{"line":70,"column":4,"offset":6337},"end":{"line":70,"column":18,"offset":6351},"indent":[]}}],"position":{"start":{"line":70,"column":3,"offset":6336},"end":{"line":70,"column":46,"offset":6379},"indent":[]}},{"type":"text","value":" is a cloud solution which allows you to have a single overview of all the media recordings generated by your surveillance cameras. It's not a solution for processing your surveillance cameras in the cloud. For processing of your surveillance cameras, a Kerberos agent is used.","position":{"start":{"line":70,"column":46,"offset":6379},"end":{"line":70,"column":323,"offset":6656},"indent":[]}}],"position":{"start":{"line":70,"column":3,"offset":6336},"end":{"line":70,"column":323,"offset":6656},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":6334},"end":{"line":70,"column":323,"offset":6656},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A brief list of the key features of Kerberos Cloud are:","position":{"start":{"line":72,"column":1,"offset":6658},"end":{"line":72,"column":56,"offset":6713},"indent":[]}}],"position":{"start":{"line":72,"column":1,"offset":6658},"end":{"line":72,"column":56,"offset":6713},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Secured storage","position":{"start":{"line":74,"column":3,"offset":6717},"end":{"line":74,"column":18,"offset":6732},"indent":[]}}],"position":{"start":{"line":74,"column":3,"offset":6717},"end":{"line":74,"column":18,"offset":6732},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":6715},"end":{"line":74,"column":18,"offset":6732},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Consolidated overview","position":{"start":{"line":75,"column":3,"offset":6735},"end":{"line":75,"column":24,"offset":6756},"indent":[]}}],"position":{"start":{"line":75,"column":3,"offset":6735},"end":{"line":75,"column":24,"offset":6756},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":6733},"end":{"line":75,"column":24,"offset":6756},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Advanced searching","position":{"start":{"line":76,"column":3,"offset":6759},"end":{"line":76,"column":21,"offset":6777},"indent":[]}}],"position":{"start":{"line":76,"column":3,"offset":6759},"end":{"line":76,"column":21,"offset":6777},"indent":[]}}],"position":{"start":{"line":76,"column":1,"offset":6757},"end":{"line":76,"column":21,"offset":6777},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Machine learning","position":{"start":{"line":77,"column":3,"offset":6780},"end":{"line":77,"column":19,"offset":6796},"indent":[]}}],"position":{"start":{"line":77,"column":3,"offset":6780},"end":{"line":77,"column":19,"offset":6796},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":6778},"end":{"line":77,"column":19,"offset":6796},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Alerts","position":{"start":{"line":78,"column":3,"offset":6799},"end":{"line":78,"column":9,"offset":6805},"indent":[]}}],"position":{"start":{"line":78,"column":3,"offset":6799},"end":{"line":78,"column":9,"offset":6805},"indent":[]}}],"position":{"start":{"line":78,"column":1,"offset":6797},"end":{"line":78,"column":9,"offset":6805},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Live streaming","position":{"start":{"line":79,"column":3,"offset":6808},"end":{"line":79,"column":17,"offset":6822},"indent":[]}}],"position":{"start":{"line":79,"column":3,"offset":6808},"end":{"line":79,"column":17,"offset":6822},"indent":[]}}],"position":{"start":{"line":79,"column":1,"offset":6806},"end":{"line":79,"column":17,"offset":6822},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Accounts","position":{"start":{"line":80,"column":3,"offset":6825},"end":{"line":80,"column":11,"offset":6833},"indent":[]}}],"position":{"start":{"line":80,"column":3,"offset":6825},"end":{"line":80,"column":11,"offset":6833},"indent":[]}}],"position":{"start":{"line":80,"column":1,"offset":6823},"end":{"line":80,"column":11,"offset":6833},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Logging","position":{"start":{"line":81,"column":3,"offset":6836},"end":{"line":81,"column":10,"offset":6843},"indent":[]}}],"position":{"start":{"line":81,"column":3,"offset":6836},"end":{"line":81,"column":10,"offset":6843},"indent":[]}}],"position":{"start":{"line":81,"column":1,"offset":6834},"end":{"line":81,"column":10,"offset":6843},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":6715},"end":{"line":81,"column":10,"offset":6843},"indent":[1,1,1,1,1,1,1]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Checkout ","position":{"start":{"line":83,"column":3,"offset":6847},"end":{"line":83,"column":12,"offset":6856},"indent":[]}},{"type":"link","title":null,"url":"https://app-demo.kerberos.io","children":[{"type":"text","value":"the demo environment","position":{"start":{"line":83,"column":13,"offset":6857},"end":{"line":83,"column":33,"offset":6877},"indent":[]}}],"position":{"start":{"line":83,"column":12,"offset":6856},"end":{"line":83,"column":64,"offset":6908},"indent":[]}},{"type":"text","value":" to see and feel the Kerberos Cloud solution yourself.","position":{"start":{"line":83,"column":64,"offset":6908},"end":{"line":83,"column":118,"offset":6962},"indent":[]}}],"position":{"start":{"line":83,"column":3,"offset":6847},"end":{"line":83,"column":118,"offset":6962},"indent":[]}}],"position":{"start":{"line":83,"column":1,"offset":6845},"end":{"line":83,"column":118,"offset":6962},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Architecture","position":{"start":{"line":85,"column":5,"offset":6968},"end":{"line":85,"column":17,"offset":6980},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":6964},"end":{"line":85,"column":17,"offset":6980},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A simplified architecture is found below. In this architecture the Kerberos agents are installed on-premise (but this could also be in the cloud), next to the surveillance cameras. Once one of the agents recorded something it will send the recording to our AWS S3 bucket, using the credentials you've defined inside the agent.","position":{"start":{"line":87,"column":1,"offset":6982},"end":{"line":87,"column":327,"offset":7308},"indent":[]}}],"position":{"start":{"line":87,"column":1,"offset":6982},"end":{"line":87,"column":327,"offset":7308},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"As soon as the recording is succesfully received several engines will be executed, that will further process the recording and extract metadata from it (classification, origin of the surveillance camera, etc). A lot of processing is happening behind the scenes.","position":{"start":{"line":89,"column":1,"offset":7310},"end":{"line":89,"column":262,"offset":7571},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":7310},"end":{"line":89,"column":262,"offset":7571},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By using a browser you can navigate to Kerberos Cloud, and review all the recordings made by the Kerberos agents on-premise. On top of that you will receive more context about the recordings, get notifications, view a livestream and much more. Read more about ","position":{"start":{"line":91,"column":1,"offset":7573},"end":{"line":91,"column":261,"offset":7833},"indent":[]}},{"type":"link","title":null,"url":"/cloud","children":[{"type":"text","value":"Kerberos Cloud here","position":{"start":{"line":91,"column":262,"offset":7834},"end":{"line":91,"column":281,"offset":7853},"indent":[]}}],"position":{"start":{"line":91,"column":261,"offset":7833},"end":{"line":91,"column":290,"offset":7862},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":91,"column":290,"offset":7862},"end":{"line":91,"column":291,"offset":7863},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":7573},"end":{"line":91,"column":291,"offset":7863},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../public/images/kerberos-architecture.png","alt":"cloud","position":{"start":{"line":93,"column":1,"offset":7865},"end":{"line":93,"column":53,"offset":7917},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":7865},"end":{"line":93,"column":53,"offset":7917},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":96,"column":1,"offset":7920},"end":{"line":96,"column":31,"offset":7950},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":96,"column":31,"offset":7950}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Architectures`}

\n

{`In this section we will explain some usecases and best practices, which might help you to define the architecture that fits your needs.`}

\n
\n

{`Please read the `}{`introduction page`}{` first, before moving forward.`}

\n
\n

{`When starting with Kerberos you might ask yourself, how should I deploy these so called, Kerberos agents? Well, there are different options. You can install a Kerberos agent on a Raspberry Pi, VM, Server or even in a Kubernetes cluster. So what should you do, and when? Let's have a closer look at the different options.`}

\n

{`The first thing you need to consider is the environment, in which you want to deploy your Kerberos agents. Is it inside your house, your company or at a public place? Another important factor is the number of surveillance cameras you would like to monitor, and if you have any high availability requirements.`}

\n

{`Agents on-premise`}

\n

{`The most common scenario is to install your Kerberos agents on-premise. This has a couple of benefits such as latency, bandwidth and a less complex security model. When installing a Kerberos agent on-premise, you have a couple of different options.`}

\n

{`Kerberos Open Source (< 5 Kerberos agents)`}

\n

{`If you have a limited number of surveillance cameras you would like to monitor, and don't have any high availability requirements, the Kerberos Open Source agent is a good choice. For example, you can install the Kerberos Open Source agent on a Raspberry Pi, by using `}{`KiOS`}{`, `}{`Raspbian OS`}{` or compile it from source.`}

\n

{`On below architecture, a couple of Kerberos agents are installed on-premise (inside the local network). A Kerberos agent is installed for each surveillance camera, and each Kerberos agent runs on a seperate host (Raspberry Pi, VM, etc). The web interface of the Kerberos agents can be reached from the internal network, but cannot be accessed from the cloud.`}

\n

\"architecture

\n

{`Another option to install the Kerberos Open Source agent is to use Docker. Instead of having seperate hosts for each Kerberos agent, you will have a single host (Docker host) with multiple Docker containers. A Docker container is deployed for each surveillance camera, which contains the software to run the Kerberos agent.`}

\n

{`Running your Kerberos agents inside Docker containers, allows you to process multiple surveilllance cameras using only one host.`}

\n

\"architecture

\n

{`Kerberos Enterprise (> 5 Kerberos agents)`}

\n

{`When working within an enterprise context, where you require high availability and have a large amount of surveillance cameras being monitored, `}{`Kerberos Enterprise`}{` is a good choice. Im comparison to the Open Source version, Kerberos Enterprise will use Kubernetes to help you scale (and secure) your security landscape. Kerberos agents, or Kubernetes deployments, are deployed inside your cluster and load balanced over the different nodes. When a Kerberos agent dies, or the node on which the deployment is running, Kubernetes will reschedule it to another healthy node.`}

\n

\"architecture

\n

{`Agents in the cloud`}

\n

{`Instead of processing your surveillance cameras on-premise you could also process them in the cloud. There are a couple advantages, for example, you don't have to manage your owner hardware, you can simply spin up a VM on one of the hyperscalers.`}

\n

{`When dealing with Kerberos agents in the cloud, the complexity starts with the security model. As your surveillance cameras are running somewhere on-premise, you will need to make them available to your Kerberos agents, which are running in the cloud. There are several ways to do that, such as port forwarding (not recommended) or setting up a site-to-site VPN (recommended).`}

\n

{`When setting up a VPN connection you will expose your surveillance cameras to your Kerberos agents. Once you've configured the Kerberos agents, data will flow through this secure tunnel, from on-premise to your cloud enviroment.`}

\n

{`Kerberos Open Source (< 5 Kerberos agents)`}

\n

{`If you have a limited number of surveillance cameras you would like to monitor, and don't have any high availability requirements, the Kerberos Open Source agent is a good choice. You can install the Kerberos Open Source agent on Docker. Instead of having seperate VM's for each Kerberos agent, you will have a single VM (Docker host) with multiple Docker containers. A Docker container is deployed for each surveillance camera, which contains the software to run the Kerberos agent.`}

\n

\"architecture

\n

{`Kerberos Enterprise (> 5 Kerberos agents)`}

\n

{`Similar to `}{`Kerberos Enterprise`}{` on-premise, you can run the a Kubernetes in the cloud. The exact same solution is available, only the way how you connect to your video surveillance cameras will be different, as they will probably live in a different network. To make this work you will need to setup a VPN tunnel (or whatever your security teams have defined as a back practice). When `}{`Kerberos Enterprise`}{` is deployed to the cloud, it can be used any where. Public cloud (AWS, Google, Azure, etc) or private cloud. You can run it where you want.`}

\n

\"architecture

\n

{`Kerberos Cloud`}

\n

{`Once you've configured one of the previously mentioned architectures, you will have one or more Kerberos agents running, in the cloud or on-premise.`}

\n

{`The Kerberos Open Source agent comes with a web interface, which makes it possible to review the activity for that specific agent; they don't have a consolidated overview. This means that you will need to open multiple web interfaces, one for Kerberos agent. In contrary Kerberos Enterprise agents, don't come with a web interface, therefore the Kerberos Cloud (public or private edition) is recommended.`}

\n

{`To simplify this process and resolve some other challenges, Kerberos Cloud was developed.`}

\n
\n

{`Kerberos Cloud`}{` is a cloud solution which allows you to have a single overview of all the media recordings generated by your surveillance cameras. It's not a solution for processing your surveillance cameras in the cloud. For processing of your surveillance cameras, a Kerberos agent is used.`}

\n
\n

{`A brief list of the key features of Kerberos Cloud are:`}

\n
    \n
  • {`Secured storage`}
  • \n
  • {`Consolidated overview`}
  • \n
  • {`Advanced searching`}
  • \n
  • {`Machine learning`}
  • \n
  • {`Alerts`}
  • \n
  • {`Live streaming`}
  • \n
  • {`Accounts`}
  • \n
  • {`Logging`}
  • \n
\n
\n

{`Checkout `}{`the demo environment`}{` to see and feel the Kerberos Cloud solution yourself.`}

\n
\n

{`Architecture`}

\n

{`A simplified architecture is found below. In this architecture the Kerberos agents are installed on-premise (but this could also be in the cloud), next to the surveillance cameras. Once one of the agents recorded something it will send the recording to our AWS S3 bucket, using the credentials you've defined inside the agent.`}

\n

{`As soon as the recording is succesfully received several engines will be executed, that will further process the recording and extract metadata from it (classification, origin of the surveillance camera, etc). A lot of processing is happening behind the scenes.`}

\n

{`By using a browser you can navigate to Kerberos Cloud, and review all the recordings made by the Kerberos agents on-premise. On top of that you will receive more context about the recordings, get notifications, view a livestream and much more. Read more about `}{`Kerberos Cloud here`}{`.`}

\n

\"cloud\"

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974263000,"key":"gatsby-plugin-mdx-entire-payload-a8908e0eaea1e9144f6be04175ca6c5d-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Architectures","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":16,"offset":174},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":16,"offset":174},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"In this section we will explain some usecases and best practices, which might help you to define the architecture that fits your needs.","position":{"start":{"line":10,"column":1,"offset":176},"end":{"line":10,"column":136,"offset":311},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":176},"end":{"line":10,"column":136,"offset":311},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please read the ","position":{"start":{"line":12,"column":3,"offset":315},"end":{"line":12,"column":19,"offset":331},"indent":[]}},{"type":"link","title":null,"url":"/","children":[{"type":"text","value":"introduction page","position":{"start":{"line":12,"column":20,"offset":332},"end":{"line":12,"column":37,"offset":349},"indent":[]}}],"position":{"start":{"line":12,"column":19,"offset":331},"end":{"line":12,"column":41,"offset":353},"indent":[]}},{"type":"text","value":" first, before moving forward.","position":{"start":{"line":12,"column":41,"offset":353},"end":{"line":12,"column":71,"offset":383},"indent":[]}}],"position":{"start":{"line":12,"column":3,"offset":315},"end":{"line":12,"column":71,"offset":383},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":313},"end":{"line":12,"column":71,"offset":383},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When starting with Kerberos you might ask yourself, how should I deploy these so called, Kerberos agents? Well, there are different options. You can install a Kerberos agent on a Raspberry Pi, VM, Server or even in a Kubernetes cluster. So what should you do, and when? Let's have a closer look at the different options.","position":{"start":{"line":14,"column":1,"offset":385},"end":{"line":14,"column":321,"offset":705},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":385},"end":{"line":14,"column":321,"offset":705},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The first thing you need to consider is the environment, in which you want to deploy your Kerberos agents. Is it inside your house, your company or at a public place? Another important factor is the number of surveillance cameras you would like to monitor, and if you have any high availability requirements.","position":{"start":{"line":16,"column":1,"offset":707},"end":{"line":16,"column":309,"offset":1015},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":707},"end":{"line":16,"column":309,"offset":1015},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Agents on-premise","position":{"start":{"line":18,"column":4,"offset":1020},"end":{"line":18,"column":21,"offset":1037},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":1017},"end":{"line":18,"column":21,"offset":1037},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The most common scenario is to install your Kerberos agents on-premise. This has a couple of benefits such as latency, bandwidth and a less complex security model. When installing a Kerberos agent on-premise, you have a couple of different options.","position":{"start":{"line":20,"column":1,"offset":1039},"end":{"line":20,"column":249,"offset":1287},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":1039},"end":{"line":20,"column":249,"offset":1287},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source (< 5 Kerberos agents)","position":{"start":{"line":22,"column":5,"offset":1293},"end":{"line":22,"column":47,"offset":1335},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1289},"end":{"line":22,"column":47,"offset":1335},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have a limited number of surveillance cameras you would like to monitor, and don't have any high availability requirements, the Kerberos Open Source agent is a good choice. For example, you can install the Kerberos Open Source agent on a Raspberry Pi, by using ","position":{"start":{"line":24,"column":1,"offset":1337},"end":{"line":24,"column":269,"offset":1605},"indent":[]}},{"type":"link","title":null,"url":"opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":24,"column":270,"offset":1606},"end":{"line":24,"column":274,"offset":1610},"indent":[]}}],"position":{"start":{"line":24,"column":269,"offset":1605},"end":{"line":24,"column":305,"offset":1641},"indent":[]}},{"type":"text","value":", ","position":{"start":{"line":24,"column":305,"offset":1641},"end":{"line":24,"column":307,"offset":1643},"indent":[]}},{"type":"link","title":null,"url":"opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian OS","position":{"start":{"line":24,"column":308,"offset":1644},"end":{"line":24,"column":319,"offset":1655},"indent":[]}}],"position":{"start":{"line":24,"column":307,"offset":1643},"end":{"line":24,"column":354,"offset":1690},"indent":[]}},{"type":"text","value":" or compile it from source.","position":{"start":{"line":24,"column":354,"offset":1690},"end":{"line":24,"column":381,"offset":1717},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1337},"end":{"line":24,"column":381,"offset":1717},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On below architecture, a couple of Kerberos agents are installed on-premise (inside the local network). A Kerberos agent is installed for each surveillance camera, and each Kerberos agent runs on a seperate host (Raspberry Pi, VM, etc). The web interface of the Kerberos agents can be reached from the internal network, but cannot be accessed from the cloud.","position":{"start":{"line":26,"column":1,"offset":1719},"end":{"line":26,"column":359,"offset":2077},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1719},"end":{"line":26,"column":359,"offset":2077},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../public/images/kerberos-agent-architecture-kios.png","alt":"architecture kios","position":{"start":{"line":28,"column":1,"offset":2079},"end":{"line":28,"column":76,"offset":2154},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":2079},"end":{"line":28,"column":76,"offset":2154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Another option to install the Kerberos Open Source agent is to use Docker. Instead of having seperate hosts for each Kerberos agent, you will have a single host (Docker host) with multiple Docker containers. A Docker container is deployed for each surveillance camera, which contains the software to run the Kerberos agent.","position":{"start":{"line":30,"column":1,"offset":2156},"end":{"line":30,"column":324,"offset":2479},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":2156},"end":{"line":30,"column":324,"offset":2479},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running your Kerberos agents inside Docker containers, allows you to process multiple surveilllance cameras using only one host.","position":{"start":{"line":32,"column":1,"offset":2481},"end":{"line":32,"column":129,"offset":2609},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":2481},"end":{"line":32,"column":129,"offset":2609},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../public/images/kerberos-agent-architecture-docker.png","alt":"architecture kios","position":{"start":{"line":34,"column":1,"offset":2611},"end":{"line":34,"column":78,"offset":2688},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":2611},"end":{"line":34,"column":78,"offset":2688},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Enterprise (> 5 Kerberos agents)","position":{"start":{"line":36,"column":5,"offset":2694},"end":{"line":36,"column":46,"offset":2735},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":2690},"end":{"line":36,"column":46,"offset":2735},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When working within an enterprise context, where you require high availability and have a large amount of surveillance cameras being monitored, ","position":{"start":{"line":38,"column":1,"offset":2737},"end":{"line":38,"column":145,"offset":2881},"indent":[]}},{"type":"link","title":null,"url":"/enterprise/introduction","children":[{"type":"text","value":"Kerberos Enterprise","position":{"start":{"line":38,"column":146,"offset":2882},"end":{"line":38,"column":165,"offset":2901},"indent":[]}}],"position":{"start":{"line":38,"column":145,"offset":2881},"end":{"line":38,"column":192,"offset":2928},"indent":[]}},{"type":"text","value":" is a good choice. Im comparison to the Open Source version, Kerberos Enterprise will use Kubernetes to help you scale (and secure) your security landscape. Kerberos agents, or Kubernetes deployments, are deployed inside your cluster and load balanced over the different nodes. When a Kerberos agent dies, or the node on which the deployment is running, Kubernetes will reschedule it to another healthy node.","position":{"start":{"line":38,"column":192,"offset":2928},"end":{"line":38,"column":600,"offset":3336},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":2737},"end":{"line":38,"column":600,"offset":3336},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../public/images/kerberos-agent-architecture-kubernetes.png","alt":"architecture kubernetes","position":{"start":{"line":40,"column":1,"offset":3338},"end":{"line":40,"column":88,"offset":3425},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":3338},"end":{"line":40,"column":88,"offset":3425},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Agents in the cloud","position":{"start":{"line":42,"column":4,"offset":3430},"end":{"line":42,"column":23,"offset":3449},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":3427},"end":{"line":42,"column":23,"offset":3449},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Instead of processing your surveillance cameras on-premise you could also process them in the cloud. There are a couple advantages, for example, you don't have to manage your owner hardware, you can simply spin up a VM on one of the hyperscalers.","position":{"start":{"line":44,"column":1,"offset":3451},"end":{"line":44,"column":247,"offset":3697},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":3451},"end":{"line":44,"column":247,"offset":3697},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When dealing with Kerberos agents in the cloud, the complexity starts with the security model. As your surveillance cameras are running somewhere on-premise, you will need to make them available to your Kerberos agents, which are running in the cloud. There are several ways to do that, such as port forwarding (not recommended) or setting up a site-to-site VPN (recommended).","position":{"start":{"line":46,"column":1,"offset":3699},"end":{"line":46,"column":377,"offset":4075},"indent":[]}}],"position":{"start":{"line":46,"column":1,"offset":3699},"end":{"line":46,"column":377,"offset":4075},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When setting up a VPN connection you will expose your surveillance cameras to your Kerberos agents. Once you've configured the Kerberos agents, data will flow through this secure tunnel, from on-premise to your cloud enviroment.","position":{"start":{"line":48,"column":1,"offset":4077},"end":{"line":48,"column":229,"offset":4305},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":4077},"end":{"line":48,"column":229,"offset":4305},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source (< 5 Kerberos agents)","position":{"start":{"line":50,"column":5,"offset":4311},"end":{"line":50,"column":47,"offset":4353},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":4307},"end":{"line":50,"column":47,"offset":4353},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have a limited number of surveillance cameras you would like to monitor, and don't have any high availability requirements, the Kerberos Open Source agent is a good choice. You can install the Kerberos Open Source agent on Docker. Instead of having seperate VM's for each Kerberos agent, you will have a single VM (Docker host) with multiple Docker containers. A Docker container is deployed for each surveillance camera, which contains the software to run the Kerberos agent.","position":{"start":{"line":52,"column":1,"offset":4355},"end":{"line":52,"column":484,"offset":4838},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":4355},"end":{"line":52,"column":484,"offset":4838},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../public/images/kerberos-agent-architecture-docker-cloud.png","alt":"architecture kios","position":{"start":{"line":54,"column":1,"offset":4840},"end":{"line":54,"column":84,"offset":4923},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":4840},"end":{"line":54,"column":84,"offset":4923},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Enterprise (> 5 Kerberos agents)","position":{"start":{"line":56,"column":5,"offset":4929},"end":{"line":56,"column":46,"offset":4970},"indent":[]}}],"position":{"start":{"line":56,"column":1,"offset":4925},"end":{"line":56,"column":46,"offset":4970},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Similar to ","position":{"start":{"line":58,"column":1,"offset":4972},"end":{"line":58,"column":12,"offset":4983},"indent":[]}},{"type":"link","title":null,"url":"/enterprise/introduction","children":[{"type":"text","value":"Kerberos Enterprise","position":{"start":{"line":58,"column":13,"offset":4984},"end":{"line":58,"column":32,"offset":5003},"indent":[]}}],"position":{"start":{"line":58,"column":12,"offset":4983},"end":{"line":58,"column":59,"offset":5030},"indent":[]}},{"type":"text","value":" on-premise, you can run the a Kubernetes in the cloud. The exact same solution is available, only the way how you connect to your video surveillance cameras will be different, as they will probably live in a different network. To make this work you will need to setup a VPN tunnel (or whatever your security teams have defined as a back practice). When ","position":{"start":{"line":58,"column":59,"offset":5030},"end":{"line":58,"column":413,"offset":5384},"indent":[]}},{"type":"link","title":null,"url":"/enterprise/introduction","children":[{"type":"text","value":"Kerberos Enterprise","position":{"start":{"line":58,"column":414,"offset":5385},"end":{"line":58,"column":433,"offset":5404},"indent":[]}}],"position":{"start":{"line":58,"column":413,"offset":5384},"end":{"line":58,"column":460,"offset":5431},"indent":[]}},{"type":"text","value":" is deployed to the cloud, it can be used any where. Public cloud (AWS, Google, Azure, etc) or private cloud. You can run it where you want.","position":{"start":{"line":58,"column":460,"offset":5431},"end":{"line":58,"column":600,"offset":5571},"indent":[]}}],"position":{"start":{"line":58,"column":1,"offset":4972},"end":{"line":58,"column":600,"offset":5571},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../public/images/kerberos-agent-architecture-kubernetes-cloud.png","alt":"architecture kubernetes","position":{"start":{"line":60,"column":1,"offset":5573},"end":{"line":60,"column":94,"offset":5666},"indent":[]}}],"position":{"start":{"line":60,"column":1,"offset":5573},"end":{"line":60,"column":94,"offset":5666},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Kerberos Cloud","position":{"start":{"line":62,"column":4,"offset":5671},"end":{"line":62,"column":18,"offset":5685},"indent":[]}}],"position":{"start":{"line":62,"column":1,"offset":5668},"end":{"line":62,"column":18,"offset":5685},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've configured one of the previously mentioned architectures, you will have one or more Kerberos agents running, in the cloud or on-premise.","position":{"start":{"line":64,"column":1,"offset":5687},"end":{"line":64,"column":149,"offset":5835},"indent":[]}}],"position":{"start":{"line":64,"column":1,"offset":5687},"end":{"line":64,"column":149,"offset":5835},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Kerberos Open Source agent comes with a web interface, which makes it possible to review the activity for that specific agent; they don't have a consolidated overview. This means that you will need to open multiple web interfaces, one for Kerberos agent. In contrary Kerberos Enterprise agents, don't come with a web interface, therefore the Kerberos Cloud (public or private edition) is recommended.","position":{"start":{"line":66,"column":1,"offset":5837},"end":{"line":66,"column":405,"offset":6241},"indent":[]}}],"position":{"start":{"line":66,"column":1,"offset":5837},"end":{"line":66,"column":405,"offset":6241},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To simplify this process and resolve some other challenges, Kerberos Cloud was developed.","position":{"start":{"line":68,"column":1,"offset":6243},"end":{"line":68,"column":90,"offset":6332},"indent":[]}}],"position":{"start":{"line":68,"column":1,"offset":6243},"end":{"line":68,"column":90,"offset":6332},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://cloud.kerberos.io","children":[{"type":"text","value":"Kerberos Cloud","position":{"start":{"line":70,"column":4,"offset":6337},"end":{"line":70,"column":18,"offset":6351},"indent":[]}}],"position":{"start":{"line":70,"column":3,"offset":6336},"end":{"line":70,"column":46,"offset":6379},"indent":[]}},{"type":"text","value":" is a cloud solution which allows you to have a single overview of all the media recordings generated by your surveillance cameras. It's not a solution for processing your surveillance cameras in the cloud. For processing of your surveillance cameras, a Kerberos agent is used.","position":{"start":{"line":70,"column":46,"offset":6379},"end":{"line":70,"column":323,"offset":6656},"indent":[]}}],"position":{"start":{"line":70,"column":3,"offset":6336},"end":{"line":70,"column":323,"offset":6656},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":6334},"end":{"line":70,"column":323,"offset":6656},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A brief list of the key features of Kerberos Cloud are:","position":{"start":{"line":72,"column":1,"offset":6658},"end":{"line":72,"column":56,"offset":6713},"indent":[]}}],"position":{"start":{"line":72,"column":1,"offset":6658},"end":{"line":72,"column":56,"offset":6713},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Secured storage","position":{"start":{"line":74,"column":3,"offset":6717},"end":{"line":74,"column":18,"offset":6732},"indent":[]}}],"position":{"start":{"line":74,"column":3,"offset":6717},"end":{"line":74,"column":18,"offset":6732},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":6715},"end":{"line":74,"column":18,"offset":6732},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Consolidated overview","position":{"start":{"line":75,"column":3,"offset":6735},"end":{"line":75,"column":24,"offset":6756},"indent":[]}}],"position":{"start":{"line":75,"column":3,"offset":6735},"end":{"line":75,"column":24,"offset":6756},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":6733},"end":{"line":75,"column":24,"offset":6756},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Advanced searching","position":{"start":{"line":76,"column":3,"offset":6759},"end":{"line":76,"column":21,"offset":6777},"indent":[]}}],"position":{"start":{"line":76,"column":3,"offset":6759},"end":{"line":76,"column":21,"offset":6777},"indent":[]}}],"position":{"start":{"line":76,"column":1,"offset":6757},"end":{"line":76,"column":21,"offset":6777},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Machine learning","position":{"start":{"line":77,"column":3,"offset":6780},"end":{"line":77,"column":19,"offset":6796},"indent":[]}}],"position":{"start":{"line":77,"column":3,"offset":6780},"end":{"line":77,"column":19,"offset":6796},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":6778},"end":{"line":77,"column":19,"offset":6796},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Alerts","position":{"start":{"line":78,"column":3,"offset":6799},"end":{"line":78,"column":9,"offset":6805},"indent":[]}}],"position":{"start":{"line":78,"column":3,"offset":6799},"end":{"line":78,"column":9,"offset":6805},"indent":[]}}],"position":{"start":{"line":78,"column":1,"offset":6797},"end":{"line":78,"column":9,"offset":6805},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Live streaming","position":{"start":{"line":79,"column":3,"offset":6808},"end":{"line":79,"column":17,"offset":6822},"indent":[]}}],"position":{"start":{"line":79,"column":3,"offset":6808},"end":{"line":79,"column":17,"offset":6822},"indent":[]}}],"position":{"start":{"line":79,"column":1,"offset":6806},"end":{"line":79,"column":17,"offset":6822},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Accounts","position":{"start":{"line":80,"column":3,"offset":6825},"end":{"line":80,"column":11,"offset":6833},"indent":[]}}],"position":{"start":{"line":80,"column":3,"offset":6825},"end":{"line":80,"column":11,"offset":6833},"indent":[]}}],"position":{"start":{"line":80,"column":1,"offset":6823},"end":{"line":80,"column":11,"offset":6833},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Logging","position":{"start":{"line":81,"column":3,"offset":6836},"end":{"line":81,"column":10,"offset":6843},"indent":[]}}],"position":{"start":{"line":81,"column":3,"offset":6836},"end":{"line":81,"column":10,"offset":6843},"indent":[]}}],"position":{"start":{"line":81,"column":1,"offset":6834},"end":{"line":81,"column":10,"offset":6843},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":6715},"end":{"line":81,"column":10,"offset":6843},"indent":[1,1,1,1,1,1,1]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Checkout ","position":{"start":{"line":83,"column":3,"offset":6847},"end":{"line":83,"column":12,"offset":6856},"indent":[]}},{"type":"link","title":null,"url":"https://app-demo.kerberos.io","children":[{"type":"text","value":"the demo environment","position":{"start":{"line":83,"column":13,"offset":6857},"end":{"line":83,"column":33,"offset":6877},"indent":[]}}],"position":{"start":{"line":83,"column":12,"offset":6856},"end":{"line":83,"column":64,"offset":6908},"indent":[]}},{"type":"text","value":" to see and feel the Kerberos Cloud solution yourself.","position":{"start":{"line":83,"column":64,"offset":6908},"end":{"line":83,"column":118,"offset":6962},"indent":[]}}],"position":{"start":{"line":83,"column":3,"offset":6847},"end":{"line":83,"column":118,"offset":6962},"indent":[]}}],"position":{"start":{"line":83,"column":1,"offset":6845},"end":{"line":83,"column":118,"offset":6962},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Architecture","position":{"start":{"line":85,"column":5,"offset":6968},"end":{"line":85,"column":17,"offset":6980},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":6964},"end":{"line":85,"column":17,"offset":6980},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A simplified architecture is found below. In this architecture the Kerberos agents are installed on-premise (but this could also be in the cloud), next to the surveillance cameras. Once one of the agents recorded something it will send the recording to our AWS S3 bucket, using the credentials you've defined inside the agent.","position":{"start":{"line":87,"column":1,"offset":6982},"end":{"line":87,"column":327,"offset":7308},"indent":[]}}],"position":{"start":{"line":87,"column":1,"offset":6982},"end":{"line":87,"column":327,"offset":7308},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"As soon as the recording is succesfully received several engines will be executed, that will further process the recording and extract metadata from it (classification, origin of the surveillance camera, etc). A lot of processing is happening behind the scenes.","position":{"start":{"line":89,"column":1,"offset":7310},"end":{"line":89,"column":262,"offset":7571},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":7310},"end":{"line":89,"column":262,"offset":7571},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By using a browser you can navigate to Kerberos Cloud, and review all the recordings made by the Kerberos agents on-premise. On top of that you will receive more context about the recordings, get notifications, view a livestream and much more. Read more about ","position":{"start":{"line":91,"column":1,"offset":7573},"end":{"line":91,"column":261,"offset":7833},"indent":[]}},{"type":"link","title":null,"url":"/cloud","children":[{"type":"text","value":"Kerberos Cloud here","position":{"start":{"line":91,"column":262,"offset":7834},"end":{"line":91,"column":281,"offset":7853},"indent":[]}}],"position":{"start":{"line":91,"column":261,"offset":7833},"end":{"line":91,"column":290,"offset":7862},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":91,"column":290,"offset":7862},"end":{"line":91,"column":291,"offset":7863},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":7573},"end":{"line":91,"column":291,"offset":7863},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../public/images/kerberos-architecture.png","alt":"cloud","position":{"start":{"line":93,"column":1,"offset":7865},"end":{"line":93,"column":53,"offset":7917},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":7865},"end":{"line":93,"column":53,"offset":7917},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":96,"column":1,"offset":7920},"end":{"line":96,"column":31,"offset":7950},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":96,"column":31,"offset":7950}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Architectures`}

\n

{`In this section we will explain some usecases and best practices, which might help you to define the architecture that fits your needs.`}

\n
\n

{`Please read the `}{`introduction page`}{` first, before moving forward.`}

\n
\n

{`When starting with Kerberos you might ask yourself, how should I deploy these so called, Kerberos agents? Well, there are different options. You can install a Kerberos agent on a Raspberry Pi, VM, Server or even in a Kubernetes cluster. So what should you do, and when? Let's have a closer look at the different options.`}

\n

{`The first thing you need to consider is the environment, in which you want to deploy your Kerberos agents. Is it inside your house, your company or at a public place? Another important factor is the number of surveillance cameras you would like to monitor, and if you have any high availability requirements.`}

\n

{`Agents on-premise`}

\n

{`The most common scenario is to install your Kerberos agents on-premise. This has a couple of benefits such as latency, bandwidth and a less complex security model. When installing a Kerberos agent on-premise, you have a couple of different options.`}

\n

{`Kerberos Open Source (< 5 Kerberos agents)`}

\n

{`If you have a limited number of surveillance cameras you would like to monitor, and don't have any high availability requirements, the Kerberos Open Source agent is a good choice. For example, you can install the Kerberos Open Source agent on a Raspberry Pi, by using `}{`KiOS`}{`, `}{`Raspbian OS`}{` or compile it from source.`}

\n

{`On below architecture, a couple of Kerberos agents are installed on-premise (inside the local network). A Kerberos agent is installed for each surveillance camera, and each Kerberos agent runs on a seperate host (Raspberry Pi, VM, etc). The web interface of the Kerberos agents can be reached from the internal network, but cannot be accessed from the cloud.`}

\n

\"architecture

\n

{`Another option to install the Kerberos Open Source agent is to use Docker. Instead of having seperate hosts for each Kerberos agent, you will have a single host (Docker host) with multiple Docker containers. A Docker container is deployed for each surveillance camera, which contains the software to run the Kerberos agent.`}

\n

{`Running your Kerberos agents inside Docker containers, allows you to process multiple surveilllance cameras using only one host.`}

\n

\"architecture

\n

{`Kerberos Enterprise (> 5 Kerberos agents)`}

\n

{`When working within an enterprise context, where you require high availability and have a large amount of surveillance cameras being monitored, `}{`Kerberos Enterprise`}{` is a good choice. Im comparison to the Open Source version, Kerberos Enterprise will use Kubernetes to help you scale (and secure) your security landscape. Kerberos agents, or Kubernetes deployments, are deployed inside your cluster and load balanced over the different nodes. When a Kerberos agent dies, or the node on which the deployment is running, Kubernetes will reschedule it to another healthy node.`}

\n

\"architecture

\n

{`Agents in the cloud`}

\n

{`Instead of processing your surveillance cameras on-premise you could also process them in the cloud. There are a couple advantages, for example, you don't have to manage your owner hardware, you can simply spin up a VM on one of the hyperscalers.`}

\n

{`When dealing with Kerberos agents in the cloud, the complexity starts with the security model. As your surveillance cameras are running somewhere on-premise, you will need to make them available to your Kerberos agents, which are running in the cloud. There are several ways to do that, such as port forwarding (not recommended) or setting up a site-to-site VPN (recommended).`}

\n

{`When setting up a VPN connection you will expose your surveillance cameras to your Kerberos agents. Once you've configured the Kerberos agents, data will flow through this secure tunnel, from on-premise to your cloud enviroment.`}

\n

{`Kerberos Open Source (< 5 Kerberos agents)`}

\n

{`If you have a limited number of surveillance cameras you would like to monitor, and don't have any high availability requirements, the Kerberos Open Source agent is a good choice. You can install the Kerberos Open Source agent on Docker. Instead of having seperate VM's for each Kerberos agent, you will have a single VM (Docker host) with multiple Docker containers. A Docker container is deployed for each surveillance camera, which contains the software to run the Kerberos agent.`}

\n

\"architecture

\n

{`Kerberos Enterprise (> 5 Kerberos agents)`}

\n

{`Similar to `}{`Kerberos Enterprise`}{` on-premise, you can run the a Kubernetes in the cloud. The exact same solution is available, only the way how you connect to your video surveillance cameras will be different, as they will probably live in a different network. To make this work you will need to setup a VPN tunnel (or whatever your security teams have defined as a back practice). When `}{`Kerberos Enterprise`}{` is deployed to the cloud, it can be used any where. Public cloud (AWS, Google, Azure, etc) or private cloud. You can run it where you want.`}

\n

\"architecture

\n

{`Kerberos Cloud`}

\n

{`Once you've configured one of the previously mentioned architectures, you will have one or more Kerberos agents running, in the cloud or on-premise.`}

\n

{`The Kerberos Open Source agent comes with a web interface, which makes it possible to review the activity for that specific agent; they don't have a consolidated overview. This means that you will need to open multiple web interfaces, one for Kerberos agent. In contrary Kerberos Enterprise agents, don't come with a web interface, therefore the Kerberos Cloud (public or private edition) is recommended.`}

\n

{`To simplify this process and resolve some other challenges, Kerberos Cloud was developed.`}

\n
\n

{`Kerberos Cloud`}{` is a cloud solution which allows you to have a single overview of all the media recordings generated by your surveillance cameras. It's not a solution for processing your surveillance cameras in the cloud. For processing of your surveillance cameras, a Kerberos agent is used.`}

\n
\n

{`A brief list of the key features of Kerberos Cloud are:`}

\n
    \n
  • {`Secured storage`}
  • \n
  • {`Consolidated overview`}
  • \n
  • {`Advanced searching`}
  • \n
  • {`Machine learning`}
  • \n
  • {`Alerts`}
  • \n
  • {`Live streaming`}
  • \n
  • {`Accounts`}
  • \n
  • {`Logging`}
  • \n
\n
\n

{`Checkout `}{`the demo environment`}{` to see and feel the Kerberos Cloud solution yourself.`}

\n
\n

{`Architecture`}

\n

{`A simplified architecture is found below. In this architecture the Kerberos agents are installed on-premise (but this could also be in the cloud), next to the surveillance cameras. Once one of the agents recorded something it will send the recording to our AWS S3 bucket, using the credentials you've defined inside the agent.`}

\n

{`As soon as the recording is succesfully received several engines will be executed, that will further process the recording and extract metadata from it (classification, origin of the surveillance camera, etc). A lot of processing is happening behind the scenes.`}

\n

{`By using a browser you can navigate to Kerberos Cloud, and review all the recordings made by the Kerberos agents on-premise. On top of that you will receive more context about the recordings, get notifications, view a livestream and much more. Read more about `}{`Kerberos Cloud here`}{`.`}

\n

\"cloud\"

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-bf88f10bc76df564c81248fad75cc3c5.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-bf88f10bc76df564c81248fad75cc3c5.json new file mode 100644 index 0000000..773b680 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-bf88f10bc76df564c81248fad75cc3c5.json @@ -0,0 +1 @@ +{"expireTime":9007200841983003000,"key":"gatsby-plugin-mdx-entire-payload-9b83d6a8fb23013a44968bb1f9969a16-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug-and-Play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":23,"column":4,"offset":1137},"end":{"line":23,"column":8,"offset":1141},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":8,"offset":1141},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":25,"column":1,"offset":1143},"end":{"line":25,"column":229,"offset":1371},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1143},"end":{"line":25,"column":229,"offset":1371},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":27,"column":1,"offset":1373},"end":{"line":27,"column":197,"offset":1569},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1373},"end":{"line":27,"column":197,"offset":1569},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":29,"column":5,"offset":1575},"end":{"line":29,"column":11,"offset":1581},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1571},"end":{"line":29,"column":11,"offset":1581},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":31,"column":1,"offset":1583},"end":{"line":31,"column":63,"offset":1645},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":31,"column":64,"offset":1646},"end":{"line":31,"column":85,"offset":1667},"indent":[]}}],"position":{"start":{"line":31,"column":63,"offset":1645},"end":{"line":31,"column":123,"offset":1705},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":31,"column":123,"offset":1705},"end":{"line":31,"column":124,"offset":1706},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1583},"end":{"line":31,"column":124,"offset":1706},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos installer","position":{"start":{"line":33,"column":5,"offset":1712},"end":{"line":33,"column":23,"offset":1730},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1708},"end":{"line":33,"column":23,"offset":1730},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":35,"column":1,"offset":1732},"end":{"line":35,"column":228,"offset":1959},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1732},"end":{"line":35,"column":228,"offset":1959},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":37,"column":1,"offset":1961},"end":{"line":37,"column":67,"offset":2027},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1961},"end":{"line":37,"column":67,"offset":2027},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":39,"column":1,"offset":2029},"end":{"line":39,"column":50,"offset":2078},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":2029},"end":{"line":39,"column":50,"offset":2078},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":41,"column":3,"offset":2082},"end":{"line":41,"column":49,"offset":2128},"indent":[]}}],"position":{"start":{"line":41,"column":3,"offset":2082},"end":{"line":41,"column":49,"offset":2128},"indent":[]}}],"position":{"start":{"line":41,"column":3,"offset":2082},"end":{"line":41,"column":49,"offset":2128},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":2080},"end":{"line":41,"column":49,"offset":2128},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":43,"column":5,"offset":2134},"end":{"line":43,"column":11,"offset":2140},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2130},"end":{"line":43,"column":11,"offset":2140},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":45,"column":1,"offset":2142},"end":{"line":45,"column":160,"offset":2301},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2142},"end":{"line":45,"column":160,"offset":2301},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":47,"column":4,"offset":2306},"end":{"line":47,"column":13,"offset":2315},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":47,"column":14,"offset":2316},"end":{"line":47,"column":28,"offset":2330},"indent":[]}}],"position":{"start":{"line":47,"column":13,"offset":2315},"end":{"line":47,"column":75,"offset":2377},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":47,"column":75,"offset":2377},"end":{"line":47,"column":76,"offset":2378},"indent":[]}}],"position":{"start":{"line":47,"column":4,"offset":2306},"end":{"line":47,"column":76,"offset":2378},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2303},"end":{"line":47,"column":76,"offset":2378},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":48,"column":4,"offset":2382},"end":{"line":48,"column":41,"offset":2419},"indent":[]}}],"position":{"start":{"line":48,"column":4,"offset":2382},"end":{"line":48,"column":41,"offset":2419},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2379},"end":{"line":48,"column":41,"offset":2419},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":49,"column":4,"offset":2423},"end":{"line":49,"column":60,"offset":2479},"indent":[]}}],"position":{"start":{"line":49,"column":4,"offset":2423},"end":{"line":49,"column":60,"offset":2479},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2420},"end":{"line":49,"column":60,"offset":2479},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2303},"end":{"line":49,"column":60,"offset":2479},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":51,"column":2,"offset":2482},"end":{"line":51,"column":64,"offset":2544},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2481},"end":{"line":51,"column":96,"offset":2576},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2481},"end":{"line":51,"column":96,"offset":2576},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":53,"column":1,"offset":2578},"end":{"line":53,"column":204,"offset":2781},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2578},"end":{"line":53,"column":204,"offset":2781},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":55,"column":6,"offset":2788},"end":{"line":55,"column":24,"offset":2806},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2783},"end":{"line":55,"column":24,"offset":2806},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":57,"column":1,"offset":2808},"end":{"line":57,"column":95,"offset":2902},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":57,"column":95,"offset":2902},"end":{"line":57,"column":110,"offset":2917},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":57,"column":110,"offset":2917},"end":{"line":57,"column":222,"offset":3029},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2808},"end":{"line":57,"column":222,"offset":3029},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":59,"column":1,"offset":3031},"end":{"line":67,"column":4,"offset":3140},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":69,"column":6,"offset":3147},"end":{"line":69,"column":31,"offset":3172},"indent":[]}}],"position":{"start":{"line":69,"column":1,"offset":3142},"end":{"line":69,"column":31,"offset":3172},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":71,"column":1,"offset":3174},"end":{"line":71,"column":79,"offset":3252},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":71,"column":79,"offset":3252},"end":{"line":71,"column":95,"offset":3268},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":71,"column":95,"offset":3268},"end":{"line":71,"column":137,"offset":3310},"indent":[]}}],"position":{"start":{"line":71,"column":1,"offset":3174},"end":{"line":71,"column":137,"offset":3310},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":73,"column":1,"offset":3312},"end":{"line":83,"column":4,"offset":3680},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":85,"column":5,"offset":3686},"end":{"line":85,"column":30,"offset":3711},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":3682},"end":{"line":85,"column":30,"offset":3711},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":87,"column":1,"offset":3713},"end":{"line":87,"column":464,"offset":4176},"indent":[]}}],"position":{"start":{"line":87,"column":1,"offset":3713},"end":{"line":87,"column":464,"offset":4176},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":89,"column":1,"offset":4178},"end":{"line":89,"column":61,"offset":4238},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":4178},"end":{"line":89,"column":61,"offset":4238},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":4244},"end":{"line":91,"column":28,"offset":4267},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":4240},"end":{"line":91,"column":28,"offset":4267},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":93,"column":1,"offset":4269},"end":{"line":93,"column":95,"offset":4363},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":93,"column":95,"offset":4363},"end":{"line":93,"column":100,"offset":4368},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":93,"column":100,"offset":4368},"end":{"line":93,"column":101,"offset":4369},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":4269},"end":{"line":93,"column":101,"offset":4369},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":95,"column":1,"offset":4371},"end":{"line":99,"column":4,"offset":4488},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":101,"column":1,"offset":4490},"end":{"line":101,"column":80,"offset":4569},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":101,"column":80,"offset":4569},"end":{"line":101,"column":101,"offset":4590},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":101,"column":101,"offset":4590},"end":{"line":101,"column":162,"offset":4651},"indent":[]}}],"position":{"start":{"line":101,"column":1,"offset":4490},"end":{"line":101,"column":162,"offset":4651},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":103,"column":1,"offset":4653},"end":{"line":106,"column":4,"offset":4742},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":108,"column":4,"offset":4747},"end":{"line":108,"column":10,"offset":4753},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":4744},"end":{"line":108,"column":10,"offset":4753},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":110,"column":1,"offset":4755},"end":{"line":110,"column":337,"offset":5091},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":110,"column":338,"offset":5092},"end":{"line":110,"column":352,"offset":5106},"indent":[]}}],"position":{"start":{"line":110,"column":337,"offset":5091},"end":{"line":110,"column":388,"offset":5142},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":110,"column":388,"offset":5142},"end":{"line":110,"column":389,"offset":5143},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4755},"end":{"line":110,"column":389,"offset":5143},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":112,"column":5,"offset":5149},"end":{"line":112,"column":18,"offset":5162},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":5145},"end":{"line":112,"column":18,"offset":5162},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":114,"column":3,"offset":5166},"end":{"line":114,"column":50,"offset":5213},"indent":[]}}],"position":{"start":{"line":114,"column":3,"offset":5166},"end":{"line":114,"column":50,"offset":5213},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":5164},"end":{"line":114,"column":50,"offset":5213},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":116,"column":5,"offset":5219},"end":{"line":116,"column":11,"offset":5225},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":5215},"end":{"line":116,"column":11,"offset":5225},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":118,"column":1,"offset":5227},"end":{"line":118,"column":64,"offset":5290},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":118,"column":65,"offset":5291},"end":{"line":118,"column":86,"offset":5312},"indent":[]}}],"position":{"start":{"line":118,"column":64,"offset":5290},"end":{"line":118,"column":126,"offset":5352},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":118,"column":126,"offset":5352},"end":{"line":118,"column":127,"offset":5353},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5227},"end":{"line":118,"column":127,"offset":5353},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":120,"column":5,"offset":5359},"end":{"line":120,"column":26,"offset":5380},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5355},"end":{"line":120,"column":26,"offset":5380},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":122,"column":1,"offset":5382},"end":{"line":122,"column":126,"offset":5507},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5382},"end":{"line":122,"column":126,"offset":5507},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":124,"column":1,"offset":5509},"end":{"line":126,"column":4,"offset":5548},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":128,"column":1,"offset":5550},"end":{"line":128,"column":187,"offset":5736},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5550},"end":{"line":128,"column":187,"offset":5736},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5738},"end":{"line":132,"column":4,"offset":5816},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":134,"column":1,"offset":5818},"end":{"line":134,"column":153,"offset":5970},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5818},"end":{"line":134,"column":153,"offset":5970},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5972},"end":{"line":139,"column":4,"offset":6119},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":141,"column":1,"offset":6121},"end":{"line":141,"column":100,"offset":6220},"indent":[]}}],"position":{"start":{"line":141,"column":1,"offset":6121},"end":{"line":141,"column":100,"offset":6220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":142,"column":1,"offset":6221},"end":{"line":146,"column":4,"offset":6290},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":148,"column":5,"offset":6296},"end":{"line":148,"column":12,"offset":6303},"indent":[]}}],"position":{"start":{"line":148,"column":1,"offset":6292},"end":{"line":148,"column":12,"offset":6303},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":150,"column":1,"offset":6305},"end":{"line":150,"column":64,"offset":6368},"indent":[]}}],"position":{"start":{"line":150,"column":1,"offset":6305},"end":{"line":150,"column":64,"offset":6368},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":151,"column":3,"offset":6371},"end":{"line":151,"column":25,"offset":6393},"indent":[]}}],"position":{"start":{"line":151,"column":3,"offset":6371},"end":{"line":151,"column":25,"offset":6393},"indent":[]}}],"position":{"start":{"line":151,"column":1,"offset":6369},"end":{"line":151,"column":25,"offset":6393},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":152,"column":3,"offset":6396},"end":{"line":152,"column":59,"offset":6452},"indent":[]}}],"position":{"start":{"line":152,"column":3,"offset":6396},"end":{"line":152,"column":59,"offset":6452},"indent":[]}}],"position":{"start":{"line":152,"column":1,"offset":6394},"end":{"line":152,"column":59,"offset":6452},"indent":[]}}],"position":{"start":{"line":151,"column":1,"offset":6369},"end":{"line":152,"column":59,"offset":6452},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":154,"column":4,"offset":6457},"end":{"line":154,"column":10,"offset":6463},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6454},"end":{"line":154,"column":10,"offset":6463},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos as a Docker container is great, and makes it possible to run Kerberos everywhere, even on a Raspberry Pi or any other tiny PC. However some you might need more control and flexibility. This is where Balena comes into the picture.","position":{"start":{"line":156,"column":1,"offset":6465},"end":{"line":156,"column":247,"offset":6711},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6465},"end":{"line":156,"column":247,"offset":6711},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":159,"column":4,"offset":6717},"end":{"line":159,"column":12,"offset":6725},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":6714},"end":{"line":159,"column":12,"offset":6725},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":161,"column":1,"offset":6727},"end":{"line":161,"column":193,"offset":6919},"indent":[]}}],"position":{"start":{"line":161,"column":1,"offset":6727},"end":{"line":161,"column":193,"offset":6919},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":163,"column":4,"offset":6924},"end":{"line":163,"column":62,"offset":6982},"indent":[]}}],"position":{"start":{"line":163,"column":4,"offset":6924},"end":{"line":163,"column":62,"offset":6982},"indent":[]}}],"position":{"start":{"line":163,"column":1,"offset":6921},"end":{"line":163,"column":62,"offset":6982},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":164,"column":4,"offset":6986},"end":{"line":164,"column":69,"offset":7051},"indent":[]}}],"position":{"start":{"line":164,"column":4,"offset":6986},"end":{"line":164,"column":69,"offset":7051},"indent":[]}}],"position":{"start":{"line":164,"column":1,"offset":6983},"end":{"line":164,"column":69,"offset":7051},"indent":[]}}],"position":{"start":{"line":163,"column":1,"offset":6921},"end":{"line":164,"column":69,"offset":7051},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":166,"column":1,"offset":7053},"end":{"line":166,"column":99,"offset":7151},"indent":[]}}],"position":{"start":{"line":166,"column":1,"offset":7053},"end":{"line":166,"column":99,"offset":7151},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":168,"column":5,"offset":7157},"end":{"line":168,"column":14,"offset":7166},"indent":[]}}],"position":{"start":{"line":168,"column":1,"offset":7153},"end":{"line":168,"column":14,"offset":7166},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":170,"column":1,"offset":7168},"end":{"line":170,"column":71,"offset":7238},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7168},"end":{"line":170,"column":71,"offset":7238},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":172,"column":3,"offset":7242},"end":{"line":172,"column":47,"offset":7286},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":172,"column":47,"offset":7286},"end":{"line":172,"column":79,"offset":7318},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":172,"column":79,"offset":7318},"end":{"line":172,"column":198,"offset":7437},"indent":[]}}],"position":{"start":{"line":172,"column":3,"offset":7242},"end":{"line":172,"column":198,"offset":7437},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7240},"end":{"line":172,"column":198,"offset":7437},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":174,"column":1,"offset":7439},"end":{"line":176,"column":4,"offset":7502},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":178,"column":5,"offset":7508},"end":{"line":178,"column":14,"offset":7517},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7504},"end":{"line":178,"column":14,"offset":7517},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":180,"column":1,"offset":7519},"end":{"line":180,"column":56,"offset":7574},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7519},"end":{"line":180,"column":56,"offset":7574},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":181,"column":3,"offset":7577},"end":{"line":181,"column":52,"offset":7626},"indent":[]}}],"position":{"start":{"line":181,"column":3,"offset":7577},"end":{"line":181,"column":52,"offset":7626},"indent":[]}}],"position":{"start":{"line":181,"column":3,"offset":7577},"end":{"line":181,"column":52,"offset":7626},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":7575},"end":{"line":181,"column":52,"offset":7626},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":183,"column":1,"offset":7628},"end":{"line":183,"column":3,"offset":7630},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":183,"column":3,"offset":7630},"end":{"line":183,"column":9,"offset":7636},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":183,"column":9,"offset":7636},"end":{"line":183,"column":223,"offset":7850},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":7628},"end":{"line":183,"column":223,"offset":7850},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":185,"column":3,"offset":7854},"end":{"line":185,"column":159,"offset":8010},"indent":[]}}],"position":{"start":{"line":185,"column":3,"offset":7854},"end":{"line":185,"column":159,"offset":8010},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":7852},"end":{"line":185,"column":159,"offset":8010},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":187,"column":1,"offset":8012},"end":{"line":190,"column":4,"offset":8189},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":192,"column":1,"offset":8191},"end":{"line":192,"column":160,"offset":8350},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":8191},"end":{"line":192,"column":160,"offset":8350},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":194,"column":3,"offset":8354},"end":{"line":194,"column":31,"offset":8382},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":194,"column":31,"offset":8382},"end":{"line":194,"column":101,"offset":8452},"indent":[]}}],"position":{"start":{"line":194,"column":3,"offset":8354},"end":{"line":194,"column":101,"offset":8452},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":8352},"end":{"line":194,"column":101,"offset":8452},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":196,"column":1,"offset":8454},"end":{"line":199,"column":4,"offset":8626},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":201,"column":1,"offset":8628},"end":{"line":201,"column":73,"offset":8700},"indent":[]}}],"position":{"start":{"line":201,"column":1,"offset":8628},"end":{"line":201,"column":73,"offset":8700},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":204,"column":3,"offset":8705},"end":{"line":204,"column":31,"offset":8733},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":204,"column":31,"offset":8733},"end":{"line":204,"column":101,"offset":8803},"indent":[]}}],"position":{"start":{"line":204,"column":3,"offset":8705},"end":{"line":204,"column":101,"offset":8803},"indent":[]}}],"position":{"start":{"line":204,"column":1,"offset":8703},"end":{"line":204,"column":101,"offset":8803},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":206,"column":1,"offset":8805},"end":{"line":209,"column":4,"offset":8977},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":211,"column":1,"offset":8979},"end":{"line":211,"column":62,"offset":9040},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":211,"column":63,"offset":9041},"end":{"line":211,"column":75,"offset":9053},"indent":[]}}],"position":{"start":{"line":211,"column":62,"offset":9040},"end":{"line":211,"column":143,"offset":9121},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":211,"column":143,"offset":9121},"end":{"line":211,"column":150,"offset":9128},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":211,"column":150,"offset":9128},"end":{"line":211,"column":169,"offset":9147},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":211,"column":169,"offset":9147},"end":{"line":211,"column":170,"offset":9148},"indent":[]}}],"position":{"start":{"line":211,"column":1,"offset":8979},"end":{"line":211,"column":170,"offset":9148},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":213,"column":1,"offset":9150},"end":{"line":215,"column":4,"offset":9177},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":217,"column":1,"offset":9179},"end":{"line":217,"column":58,"offset":9236},"indent":[]}}],"position":{"start":{"line":217,"column":1,"offset":9179},"end":{"line":217,"column":58,"offset":9236},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":219,"column":1,"offset":9238},"end":{"line":222,"column":4,"offset":9308},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":224,"column":5,"offset":9314},"end":{"line":224,"column":8,"offset":9317},"indent":[]}}],"position":{"start":{"line":224,"column":1,"offset":9310},"end":{"line":224,"column":8,"offset":9317},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":226,"column":1,"offset":9319},"end":{"line":226,"column":280,"offset":9598},"indent":[]}}],"position":{"start":{"line":226,"column":1,"offset":9319},"end":{"line":226,"column":280,"offset":9598},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":228,"column":1,"offset":9600},"end":{"line":228,"column":37,"offset":9636},"indent":[]}}],"position":{"start":{"line":228,"column":1,"offset":9600},"end":{"line":228,"column":37,"offset":9636},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":230,"column":1,"offset":9638},"end":{"line":232,"column":4,"offset":9811},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":234,"column":1,"offset":9813},"end":{"line":234,"column":25,"offset":9837},"indent":[]}}],"position":{"start":{"line":234,"column":1,"offset":9813},"end":{"line":234,"column":25,"offset":9837},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":236,"column":1,"offset":9839},"end":{"line":239,"column":4,"offset":9943},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":241,"column":1,"offset":9945},"end":{"line":241,"column":118,"offset":10062},"indent":[]}}],"position":{"start":{"line":241,"column":1,"offset":9945},"end":{"line":241,"column":118,"offset":10062},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":243,"column":1,"offset":10064},"end":{"line":263,"column":4,"offset":10571},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":265,"column":1,"offset":10573},"end":{"line":265,"column":14,"offset":10586},"indent":[]}}],"position":{"start":{"line":265,"column":1,"offset":10573},"end":{"line":265,"column":14,"offset":10586},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":267,"column":1,"offset":10588},"end":{"line":269,"column":4,"offset":10624},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":271,"column":1,"offset":10626},"end":{"line":271,"column":91,"offset":10716},"indent":[]}}],"position":{"start":{"line":271,"column":1,"offset":10626},"end":{"line":271,"column":91,"offset":10716},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":273,"column":1,"offset":10718},"end":{"line":281,"column":4,"offset":11091},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":283,"column":1,"offset":11093},"end":{"line":283,"column":145,"offset":11237},"indent":[]}}],"position":{"start":{"line":283,"column":1,"offset":11093},"end":{"line":283,"column":145,"offset":11237},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":285,"column":5,"offset":11243},"end":{"line":285,"column":17,"offset":11255},"indent":[]}}],"position":{"start":{"line":285,"column":1,"offset":11239},"end":{"line":285,"column":17,"offset":11255},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":287,"column":1,"offset":11257},"end":{"line":287,"column":300,"offset":11556},"indent":[]}}],"position":{"start":{"line":287,"column":1,"offset":11257},"end":{"line":287,"column":300,"offset":11556},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":289,"column":1,"offset":11558},"end":{"line":289,"column":178,"offset":11735},"indent":[]}}],"position":{"start":{"line":289,"column":1,"offset":11558},"end":{"line":289,"column":178,"offset":11735},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":291,"column":1,"offset":11737},"end":{"line":291,"column":48,"offset":11784},"indent":[]}}],"position":{"start":{"line":291,"column":1,"offset":11737},"end":{"line":291,"column":48,"offset":11784},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":293,"column":1,"offset":11786},"end":{"line":295,"column":4,"offset":11826},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":297,"column":1,"offset":11828},"end":{"line":297,"column":104,"offset":11931},"indent":[]}}],"position":{"start":{"line":297,"column":1,"offset":11828},"end":{"line":297,"column":104,"offset":11931},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":299,"column":1,"offset":11933},"end":{"line":307,"column":4,"offset":12203},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":309,"column":1,"offset":12205},"end":{"line":309,"column":28,"offset":12232},"indent":[]}}],"position":{"start":{"line":309,"column":1,"offset":12205},"end":{"line":309,"column":28,"offset":12232},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":311,"column":1,"offset":12234},"end":{"line":313,"column":4,"offset":12278},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":315,"column":1,"offset":12280},"end":{"line":315,"column":48,"offset":12327},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12280},"end":{"line":315,"column":48,"offset":12327},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":317,"column":1,"offset":12329},"end":{"line":319,"column":4,"offset":12351},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":321,"column":1,"offset":12353},"end":{"line":321,"column":72,"offset":12424},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":12353},"end":{"line":321,"column":72,"offset":12424},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":323,"column":1,"offset":12426},"end":{"line":325,"column":4,"offset":12483},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":327,"column":4,"offset":12488},"end":{"line":327,"column":11,"offset":12495},"indent":[]}}],"position":{"start":{"line":327,"column":1,"offset":12485},"end":{"line":327,"column":11,"offset":12495},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":329,"column":1,"offset":12497},"end":{"line":329,"column":283,"offset":12779},"indent":[]}}],"position":{"start":{"line":329,"column":1,"offset":12497},"end":{"line":329,"column":283,"offset":12779},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":331,"column":3,"offset":12783},"end":{"line":331,"column":54,"offset":12834},"indent":[]}}],"position":{"start":{"line":331,"column":3,"offset":12783},"end":{"line":331,"column":54,"offset":12834},"indent":[]}}],"position":{"start":{"line":331,"column":1,"offset":12781},"end":{"line":331,"column":54,"offset":12834},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":333,"column":5,"offset":12840},"end":{"line":333,"column":14,"offset":12849},"indent":[]}}],"position":{"start":{"line":333,"column":1,"offset":12836},"end":{"line":333,"column":14,"offset":12849},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":335,"column":1,"offset":12851},"end":{"line":335,"column":68,"offset":12918},"indent":[]}}],"position":{"start":{"line":335,"column":1,"offset":12851},"end":{"line":335,"column":68,"offset":12918},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":337,"column":1,"offset":12920},"end":{"line":340,"column":4,"offset":13071},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":342,"column":1,"offset":13073},"end":{"line":342,"column":46,"offset":13118},"indent":[]}}],"position":{"start":{"line":342,"column":1,"offset":13073},"end":{"line":342,"column":46,"offset":13118},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":344,"column":3,"offset":13122},"end":{"line":344,"column":103,"offset":13222},"indent":[]}}],"position":{"start":{"line":344,"column":3,"offset":13122},"end":{"line":344,"column":103,"offset":13222},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13120},"end":{"line":344,"column":103,"offset":13222},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":346,"column":1,"offset":13224},"end":{"line":351,"column":4,"offset":13434},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":353,"column":1,"offset":13436},"end":{"line":353,"column":151,"offset":13586},"indent":[]}}],"position":{"start":{"line":353,"column":1,"offset":13436},"end":{"line":353,"column":151,"offset":13586},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":355,"column":3,"offset":13590},"end":{"line":355,"column":22,"offset":13609},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":355,"column":22,"offset":13609},"end":{"line":355,"column":26,"offset":13613},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":355,"column":26,"offset":13613},"end":{"line":355,"column":40,"offset":13627},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":355,"column":40,"offset":13627},"end":{"line":355,"column":50,"offset":13637},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":355,"column":50,"offset":13637},"end":{"line":355,"column":98,"offset":13685},"indent":[]}}],"position":{"start":{"line":355,"column":3,"offset":13590},"end":{"line":355,"column":98,"offset":13685},"indent":[]}}],"position":{"start":{"line":355,"column":1,"offset":13588},"end":{"line":355,"column":98,"offset":13685},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":357,"column":1,"offset":13687},"end":{"line":361,"column":4,"offset":13849},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":363,"column":1,"offset":13851},"end":{"line":363,"column":72,"offset":13922},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":363,"column":72,"offset":13922},"end":{"line":363,"column":84,"offset":13934},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":363,"column":84,"offset":13934},"end":{"line":363,"column":102,"offset":13952},"indent":[]}}],"position":{"start":{"line":363,"column":1,"offset":13851},"end":{"line":363,"column":102,"offset":13952},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":365,"column":1,"offset":13954},"end":{"line":368,"column":4,"offset":14028},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":370,"column":5,"offset":14034},"end":{"line":370,"column":8,"offset":14037},"indent":[]}}],"position":{"start":{"line":370,"column":1,"offset":14030},"end":{"line":370,"column":8,"offset":14037},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":372,"column":1,"offset":14039},"end":{"line":372,"column":176,"offset":14214},"indent":[]}}],"position":{"start":{"line":372,"column":1,"offset":14039},"end":{"line":372,"column":176,"offset":14214},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":374,"column":1,"offset":14216},"end":{"line":381,"column":4,"offset":14513},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":383,"column":1,"offset":14515},"end":{"line":383,"column":60,"offset":14574},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14515},"end":{"line":383,"column":60,"offset":14574},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":385,"column":1,"offset":14576},"end":{"line":389,"column":4,"offset":14702},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":391,"column":1,"offset":14704},"end":{"line":391,"column":63,"offset":14766},"indent":[]}}],"position":{"start":{"line":391,"column":1,"offset":14704},"end":{"line":391,"column":63,"offset":14766},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":393,"column":1,"offset":14768},"end":{"line":413,"column":4,"offset":15275},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":415,"column":1,"offset":15277},"end":{"line":415,"column":99,"offset":15375},"indent":[]}}],"position":{"start":{"line":415,"column":1,"offset":15277},"end":{"line":415,"column":99,"offset":15375},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":417,"column":1,"offset":15377},"end":{"line":420,"column":4,"offset":15479},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":422,"column":1,"offset":15481},"end":{"line":422,"column":37,"offset":15517},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":422,"column":37,"offset":15517},"end":{"line":422,"column":47,"offset":15527},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":422,"column":47,"offset":15527},"end":{"line":422,"column":89,"offset":15569},"indent":[]}}],"position":{"start":{"line":422,"column":1,"offset":15481},"end":{"line":422,"column":89,"offset":15569},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":424,"column":1,"offset":15571},"end":{"line":428,"column":4,"offset":15696},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":430,"column":1,"offset":15698},"end":{"line":430,"column":78,"offset":15775},"indent":[]}}],"position":{"start":{"line":430,"column":1,"offset":15698},"end":{"line":430,"column":78,"offset":15775},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":432,"column":1,"offset":15777},"end":{"line":436,"column":4,"offset":15881},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":438,"column":1,"offset":15883},"end":{"line":438,"column":75,"offset":15957},"indent":[]}}],"position":{"start":{"line":438,"column":1,"offset":15883},"end":{"line":438,"column":75,"offset":15957},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":440,"column":1,"offset":15959},"end":{"line":444,"column":4,"offset":16032},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":446,"column":1,"offset":16034},"end":{"line":446,"column":145,"offset":16178},"indent":[]}}],"position":{"start":{"line":446,"column":1,"offset":16034},"end":{"line":446,"column":145,"offset":16178},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":448,"column":5,"offset":16184},"end":{"line":448,"column":17,"offset":16196},"indent":[]}}],"position":{"start":{"line":448,"column":1,"offset":16180},"end":{"line":448,"column":17,"offset":16196},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":450,"column":1,"offset":16198},"end":{"line":450,"column":300,"offset":16497},"indent":[]}}],"position":{"start":{"line":450,"column":1,"offset":16198},"end":{"line":450,"column":300,"offset":16497},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":452,"column":1,"offset":16499},"end":{"line":452,"column":178,"offset":16676},"indent":[]}}],"position":{"start":{"line":452,"column":1,"offset":16499},"end":{"line":452,"column":178,"offset":16676},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":454,"column":1,"offset":16678},"end":{"line":454,"column":48,"offset":16725},"indent":[]}}],"position":{"start":{"line":454,"column":1,"offset":16678},"end":{"line":454,"column":48,"offset":16725},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":456,"column":1,"offset":16727},"end":{"line":458,"column":4,"offset":16771},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":460,"column":1,"offset":16773},"end":{"line":460,"column":104,"offset":16876},"indent":[]}}],"position":{"start":{"line":460,"column":1,"offset":16773},"end":{"line":460,"column":104,"offset":16876},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":462,"column":1,"offset":16878},"end":{"line":470,"column":4,"offset":17148},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":472,"column":1,"offset":17150},"end":{"line":472,"column":28,"offset":17177},"indent":[]}}],"position":{"start":{"line":472,"column":1,"offset":17150},"end":{"line":472,"column":28,"offset":17177},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":474,"column":1,"offset":17179},"end":{"line":476,"column":4,"offset":17227},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":478,"column":1,"offset":17229},"end":{"line":478,"column":48,"offset":17276},"indent":[]}}],"position":{"start":{"line":478,"column":1,"offset":17229},"end":{"line":478,"column":48,"offset":17276},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":480,"column":1,"offset":17278},"end":{"line":482,"column":4,"offset":17300},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":484,"column":1,"offset":17302},"end":{"line":484,"column":72,"offset":17373},"indent":[]}}],"position":{"start":{"line":484,"column":1,"offset":17302},"end":{"line":484,"column":72,"offset":17373},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":486,"column":1,"offset":17375},"end":{"line":488,"column":4,"offset":17436},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":491,"column":1,"offset":17439},"end":{"line":491,"column":31,"offset":17469},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":491,"column":31,"offset":17469}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug-and-Play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos as a Docker container is great, and makes it possible to run Kerberos everywhere, even on a Raspberry Pi or any other tiny PC. However some you might need more control and flexibility. This is where Balena comes into the picture.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-c7806681374e300d3ec3b0d9c62563c5.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-c7806681374e300d3ec3b0d9c62563c5.json new file mode 100644 index 0000000..91e6f5a --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-c7806681374e300d3ec3b0d9c62563c5.json @@ -0,0 +1 @@ +{"expireTime":9007200842068149000,"key":"gatsby-plugin-mdx-entire-payload-4004eca646bd893f758494731a42d6da-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug-and-Play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Plug and play","position":{"start":{"line":23,"column":3,"offset":1136},"end":{"line":23,"column":16,"offset":1149},"indent":[]}}],"position":{"start":{"line":23,"column":3,"offset":1136},"end":{"line":23,"column":16,"offset":1149},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":16,"offset":1149},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":25,"column":1,"offset":1151},"end":{"line":25,"column":156,"offset":1306},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1151},"end":{"line":25,"column":156,"offset":1306},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS for Raspberry Pi","position":{"start":{"line":27,"column":4,"offset":1311},"end":{"line":27,"column":25,"offset":1332},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1308},"end":{"line":27,"column":25,"offset":1332},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":29,"column":1,"offset":1334},"end":{"line":29,"column":229,"offset":1562},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1334},"end":{"line":29,"column":229,"offset":1562},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":31,"column":1,"offset":1564},"end":{"line":31,"column":197,"offset":1760},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1564},"end":{"line":31,"column":197,"offset":1760},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":33,"column":5,"offset":1766},"end":{"line":33,"column":11,"offset":1772},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1762},"end":{"line":33,"column":11,"offset":1772},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":35,"column":1,"offset":1774},"end":{"line":35,"column":63,"offset":1836},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":35,"column":64,"offset":1837},"end":{"line":35,"column":85,"offset":1858},"indent":[]}}],"position":{"start":{"line":35,"column":63,"offset":1836},"end":{"line":35,"column":123,"offset":1896},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":35,"column":123,"offset":1896},"end":{"line":35,"column":124,"offset":1897},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1774},"end":{"line":35,"column":124,"offset":1897},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":37,"column":5,"offset":1903},"end":{"line":37,"column":35,"offset":1933},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1899},"end":{"line":37,"column":35,"offset":1933},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":39,"column":1,"offset":1935},"end":{"line":39,"column":228,"offset":2162},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1935},"end":{"line":39,"column":228,"offset":2162},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":41,"column":1,"offset":2164},"end":{"line":41,"column":67,"offset":2230},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":2164},"end":{"line":41,"column":67,"offset":2230},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":43,"column":1,"offset":2232},"end":{"line":43,"column":50,"offset":2281},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2232},"end":{"line":43,"column":50,"offset":2281},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":45,"column":3,"offset":2285},"end":{"line":45,"column":49,"offset":2331},"indent":[]}}],"position":{"start":{"line":45,"column":3,"offset":2285},"end":{"line":45,"column":49,"offset":2331},"indent":[]}}],"position":{"start":{"line":45,"column":3,"offset":2285},"end":{"line":45,"column":49,"offset":2331},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2283},"end":{"line":45,"column":49,"offset":2331},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":47,"column":5,"offset":2337},"end":{"line":47,"column":11,"offset":2343},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2333},"end":{"line":47,"column":11,"offset":2343},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":49,"column":1,"offset":2345},"end":{"line":49,"column":160,"offset":2504},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2345},"end":{"line":49,"column":160,"offset":2504},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":51,"column":4,"offset":2509},"end":{"line":51,"column":13,"offset":2518},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":51,"column":14,"offset":2519},"end":{"line":51,"column":28,"offset":2533},"indent":[]}}],"position":{"start":{"line":51,"column":13,"offset":2518},"end":{"line":51,"column":75,"offset":2580},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":51,"column":75,"offset":2580},"end":{"line":51,"column":76,"offset":2581},"indent":[]}}],"position":{"start":{"line":51,"column":4,"offset":2509},"end":{"line":51,"column":76,"offset":2581},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2506},"end":{"line":51,"column":76,"offset":2581},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":52,"column":4,"offset":2585},"end":{"line":52,"column":41,"offset":2622},"indent":[]}}],"position":{"start":{"line":52,"column":4,"offset":2585},"end":{"line":52,"column":41,"offset":2622},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2582},"end":{"line":52,"column":41,"offset":2622},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":53,"column":4,"offset":2626},"end":{"line":53,"column":60,"offset":2682},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2626},"end":{"line":53,"column":60,"offset":2682},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2623},"end":{"line":53,"column":60,"offset":2682},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2506},"end":{"line":53,"column":60,"offset":2682},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":55,"column":2,"offset":2685},"end":{"line":55,"column":64,"offset":2747},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2684},"end":{"line":55,"column":96,"offset":2779},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2684},"end":{"line":55,"column":96,"offset":2779},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":57,"column":1,"offset":2781},"end":{"line":57,"column":204,"offset":2984},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2781},"end":{"line":57,"column":204,"offset":2984},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":59,"column":6,"offset":2991},"end":{"line":59,"column":24,"offset":3009},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2986},"end":{"line":59,"column":24,"offset":3009},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":61,"column":1,"offset":3011},"end":{"line":61,"column":95,"offset":3105},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":61,"column":95,"offset":3105},"end":{"line":61,"column":110,"offset":3120},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":61,"column":110,"offset":3120},"end":{"line":61,"column":222,"offset":3232},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":3011},"end":{"line":61,"column":222,"offset":3232},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":63,"column":1,"offset":3234},"end":{"line":71,"column":4,"offset":3343},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":73,"column":6,"offset":3350},"end":{"line":73,"column":31,"offset":3375},"indent":[]}}],"position":{"start":{"line":73,"column":1,"offset":3345},"end":{"line":73,"column":31,"offset":3375},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":75,"column":1,"offset":3377},"end":{"line":75,"column":79,"offset":3455},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":75,"column":79,"offset":3455},"end":{"line":75,"column":95,"offset":3471},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":75,"column":95,"offset":3471},"end":{"line":75,"column":137,"offset":3513},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3377},"end":{"line":75,"column":137,"offset":3513},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":77,"column":1,"offset":3515},"end":{"line":87,"column":4,"offset":3883},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":89,"column":5,"offset":3889},"end":{"line":89,"column":30,"offset":3914},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":3885},"end":{"line":89,"column":30,"offset":3914},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":91,"column":1,"offset":3916},"end":{"line":91,"column":464,"offset":4379},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3916},"end":{"line":91,"column":464,"offset":4379},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":93,"column":1,"offset":4381},"end":{"line":93,"column":61,"offset":4441},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":4381},"end":{"line":93,"column":61,"offset":4441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":95,"column":5,"offset":4447},"end":{"line":95,"column":28,"offset":4470},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4443},"end":{"line":95,"column":28,"offset":4470},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":97,"column":1,"offset":4472},"end":{"line":97,"column":95,"offset":4566},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":97,"column":95,"offset":4566},"end":{"line":97,"column":100,"offset":4571},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":97,"column":100,"offset":4571},"end":{"line":97,"column":101,"offset":4572},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4472},"end":{"line":97,"column":101,"offset":4572},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":99,"column":1,"offset":4574},"end":{"line":103,"column":4,"offset":4691},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":105,"column":1,"offset":4693},"end":{"line":105,"column":80,"offset":4772},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":105,"column":80,"offset":4772},"end":{"line":105,"column":101,"offset":4793},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":105,"column":101,"offset":4793},"end":{"line":105,"column":162,"offset":4854},"indent":[]}}],"position":{"start":{"line":105,"column":1,"offset":4693},"end":{"line":105,"column":162,"offset":4854},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":107,"column":1,"offset":4856},"end":{"line":110,"column":4,"offset":4945},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker for amd64, armv7, arm64","position":{"start":{"line":112,"column":4,"offset":4950},"end":{"line":112,"column":34,"offset":4980},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":4947},"end":{"line":112,"column":34,"offset":4980},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":114,"column":1,"offset":4982},"end":{"line":114,"column":339,"offset":5320},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":114,"column":340,"offset":5321},"end":{"line":114,"column":354,"offset":5335},"indent":[]}}],"position":{"start":{"line":114,"column":339,"offset":5320},"end":{"line":114,"column":390,"offset":5371},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":114,"column":390,"offset":5371},"end":{"line":114,"column":391,"offset":5372},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4982},"end":{"line":114,"column":391,"offset":5372},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":116,"column":5,"offset":5378},"end":{"line":116,"column":18,"offset":5391},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":5374},"end":{"line":116,"column":18,"offset":5391},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":118,"column":3,"offset":5395},"end":{"line":118,"column":50,"offset":5442},"indent":[]}}],"position":{"start":{"line":118,"column":3,"offset":5395},"end":{"line":118,"column":50,"offset":5442},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5393},"end":{"line":118,"column":50,"offset":5442},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":120,"column":5,"offset":5448},"end":{"line":120,"column":11,"offset":5454},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5444},"end":{"line":120,"column":11,"offset":5454},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":122,"column":1,"offset":5456},"end":{"line":122,"column":64,"offset":5519},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":122,"column":65,"offset":5520},"end":{"line":122,"column":86,"offset":5541},"indent":[]}}],"position":{"start":{"line":122,"column":64,"offset":5519},"end":{"line":122,"column":126,"offset":5581},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":122,"column":126,"offset":5581},"end":{"line":122,"column":127,"offset":5582},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5456},"end":{"line":122,"column":127,"offset":5582},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":124,"column":5,"offset":5588},"end":{"line":124,"column":26,"offset":5609},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5584},"end":{"line":124,"column":26,"offset":5609},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":126,"column":1,"offset":5611},"end":{"line":126,"column":126,"offset":5736},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5611},"end":{"line":126,"column":126,"offset":5736},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":128,"column":1,"offset":5738},"end":{"line":130,"column":4,"offset":5777},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":132,"column":1,"offset":5779},"end":{"line":132,"column":187,"offset":5965},"indent":[]}}],"position":{"start":{"line":132,"column":1,"offset":5779},"end":{"line":132,"column":187,"offset":5965},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":134,"column":1,"offset":5967},"end":{"line":136,"column":4,"offset":6045},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":138,"column":1,"offset":6047},"end":{"line":138,"column":153,"offset":6199},"indent":[]}}],"position":{"start":{"line":138,"column":1,"offset":6047},"end":{"line":138,"column":153,"offset":6199},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":140,"column":1,"offset":6201},"end":{"line":143,"column":4,"offset":6348},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":145,"column":1,"offset":6350},"end":{"line":145,"column":100,"offset":6449},"indent":[]}}],"position":{"start":{"line":145,"column":1,"offset":6350},"end":{"line":145,"column":100,"offset":6449},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":146,"column":1,"offset":6450},"end":{"line":150,"column":4,"offset":6519},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":152,"column":5,"offset":6525},"end":{"line":152,"column":12,"offset":6532},"indent":[]}}],"position":{"start":{"line":152,"column":1,"offset":6521},"end":{"line":152,"column":12,"offset":6532},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":154,"column":1,"offset":6534},"end":{"line":154,"column":64,"offset":6597},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6534},"end":{"line":154,"column":64,"offset":6597},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":155,"column":3,"offset":6600},"end":{"line":155,"column":25,"offset":6622},"indent":[]}}],"position":{"start":{"line":155,"column":3,"offset":6600},"end":{"line":155,"column":25,"offset":6622},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":6598},"end":{"line":155,"column":25,"offset":6622},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":156,"column":3,"offset":6625},"end":{"line":156,"column":59,"offset":6681},"indent":[]}}],"position":{"start":{"line":156,"column":3,"offset":6625},"end":{"line":156,"column":59,"offset":6681},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6623},"end":{"line":156,"column":59,"offset":6681},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":6598},"end":{"line":156,"column":59,"offset":6681},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":158,"column":4,"offset":6686},"end":{"line":158,"column":10,"offset":6692},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6683},"end":{"line":158,"column":10,"offset":6692},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.","position":{"start":{"line":160,"column":1,"offset":6694},"end":{"line":160,"column":102,"offset":6795},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":6694},"end":{"line":160,"column":102,"offset":6795},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Especially in the worl\n even on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.","position":{"start":{"line":162,"column":1,"offset":6797},"end":{"line":163,"column":128,"offset":6947},"indent":[1]}}],"position":{"start":{"line":162,"column":1,"offset":6797},"end":{"line":163,"column":128,"offset":6947},"indent":[1]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":166,"column":3,"offset":6952},"end":{"line":166,"column":11,"offset":6960},"indent":[]}}],"position":{"start":{"line":166,"column":1,"offset":6950},"end":{"line":166,"column":11,"offset":6960},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":168,"column":1,"offset":6962},"end":{"line":168,"column":133,"offset":7094},"indent":[]}}],"position":{"start":{"line":168,"column":1,"offset":6962},"end":{"line":168,"column":133,"offset":7094},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":170,"column":4,"offset":7099},"end":{"line":170,"column":12,"offset":7107},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7096},"end":{"line":170,"column":12,"offset":7107},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":172,"column":1,"offset":7109},"end":{"line":172,"column":193,"offset":7301},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7109},"end":{"line":172,"column":193,"offset":7301},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":174,"column":4,"offset":7306},"end":{"line":174,"column":62,"offset":7364},"indent":[]}}],"position":{"start":{"line":174,"column":4,"offset":7306},"end":{"line":174,"column":62,"offset":7364},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7303},"end":{"line":174,"column":62,"offset":7364},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":175,"column":4,"offset":7368},"end":{"line":175,"column":69,"offset":7433},"indent":[]}}],"position":{"start":{"line":175,"column":4,"offset":7368},"end":{"line":175,"column":69,"offset":7433},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7365},"end":{"line":175,"column":69,"offset":7433},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7303},"end":{"line":175,"column":69,"offset":7433},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":177,"column":1,"offset":7435},"end":{"line":177,"column":99,"offset":7533},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7435},"end":{"line":177,"column":99,"offset":7533},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":179,"column":5,"offset":7539},"end":{"line":179,"column":14,"offset":7548},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7535},"end":{"line":179,"column":14,"offset":7548},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":181,"column":1,"offset":7550},"end":{"line":181,"column":71,"offset":7620},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":7550},"end":{"line":181,"column":71,"offset":7620},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":183,"column":3,"offset":7624},"end":{"line":183,"column":47,"offset":7668},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":183,"column":47,"offset":7668},"end":{"line":183,"column":79,"offset":7700},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":183,"column":79,"offset":7700},"end":{"line":183,"column":198,"offset":7819},"indent":[]}}],"position":{"start":{"line":183,"column":3,"offset":7624},"end":{"line":183,"column":198,"offset":7819},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":7622},"end":{"line":183,"column":198,"offset":7819},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":185,"column":1,"offset":7821},"end":{"line":187,"column":4,"offset":7884},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":189,"column":5,"offset":7890},"end":{"line":189,"column":14,"offset":7899},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":7886},"end":{"line":189,"column":14,"offset":7899},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":191,"column":1,"offset":7901},"end":{"line":191,"column":56,"offset":7956},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":7901},"end":{"line":191,"column":56,"offset":7956},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":192,"column":3,"offset":7959},"end":{"line":192,"column":52,"offset":8008},"indent":[]}}],"position":{"start":{"line":192,"column":3,"offset":7959},"end":{"line":192,"column":52,"offset":8008},"indent":[]}}],"position":{"start":{"line":192,"column":3,"offset":7959},"end":{"line":192,"column":52,"offset":8008},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":7957},"end":{"line":192,"column":52,"offset":8008},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":194,"column":1,"offset":8010},"end":{"line":194,"column":3,"offset":8012},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":194,"column":3,"offset":8012},"end":{"line":194,"column":9,"offset":8018},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":194,"column":9,"offset":8018},"end":{"line":194,"column":223,"offset":8232},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":8010},"end":{"line":194,"column":223,"offset":8232},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":196,"column":3,"offset":8236},"end":{"line":196,"column":159,"offset":8392},"indent":[]}}],"position":{"start":{"line":196,"column":3,"offset":8236},"end":{"line":196,"column":159,"offset":8392},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8234},"end":{"line":196,"column":159,"offset":8392},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":198,"column":1,"offset":8394},"end":{"line":201,"column":4,"offset":8571},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":203,"column":1,"offset":8573},"end":{"line":203,"column":160,"offset":8732},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":8573},"end":{"line":203,"column":160,"offset":8732},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":205,"column":3,"offset":8736},"end":{"line":205,"column":31,"offset":8764},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":205,"column":31,"offset":8764},"end":{"line":205,"column":101,"offset":8834},"indent":[]}}],"position":{"start":{"line":205,"column":3,"offset":8736},"end":{"line":205,"column":101,"offset":8834},"indent":[]}}],"position":{"start":{"line":205,"column":1,"offset":8734},"end":{"line":205,"column":101,"offset":8834},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":207,"column":1,"offset":8836},"end":{"line":210,"column":4,"offset":9008},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":212,"column":1,"offset":9010},"end":{"line":212,"column":73,"offset":9082},"indent":[]}}],"position":{"start":{"line":212,"column":1,"offset":9010},"end":{"line":212,"column":73,"offset":9082},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":215,"column":3,"offset":9087},"end":{"line":215,"column":31,"offset":9115},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":215,"column":31,"offset":9115},"end":{"line":215,"column":101,"offset":9185},"indent":[]}}],"position":{"start":{"line":215,"column":3,"offset":9087},"end":{"line":215,"column":101,"offset":9185},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":9085},"end":{"line":215,"column":101,"offset":9185},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":217,"column":1,"offset":9187},"end":{"line":220,"column":4,"offset":9359},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":222,"column":1,"offset":9361},"end":{"line":222,"column":62,"offset":9422},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":222,"column":63,"offset":9423},"end":{"line":222,"column":75,"offset":9435},"indent":[]}}],"position":{"start":{"line":222,"column":62,"offset":9422},"end":{"line":222,"column":143,"offset":9503},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":222,"column":143,"offset":9503},"end":{"line":222,"column":150,"offset":9510},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":222,"column":150,"offset":9510},"end":{"line":222,"column":169,"offset":9529},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":222,"column":169,"offset":9529},"end":{"line":222,"column":170,"offset":9530},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":9361},"end":{"line":222,"column":170,"offset":9530},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":224,"column":1,"offset":9532},"end":{"line":226,"column":4,"offset":9559},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":228,"column":1,"offset":9561},"end":{"line":228,"column":58,"offset":9618},"indent":[]}}],"position":{"start":{"line":228,"column":1,"offset":9561},"end":{"line":228,"column":58,"offset":9618},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":230,"column":1,"offset":9620},"end":{"line":233,"column":4,"offset":9690},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":235,"column":5,"offset":9696},"end":{"line":235,"column":8,"offset":9699},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":9692},"end":{"line":235,"column":8,"offset":9699},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":237,"column":1,"offset":9701},"end":{"line":237,"column":280,"offset":9980},"indent":[]}}],"position":{"start":{"line":237,"column":1,"offset":9701},"end":{"line":237,"column":280,"offset":9980},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":239,"column":1,"offset":9982},"end":{"line":239,"column":37,"offset":10018},"indent":[]}}],"position":{"start":{"line":239,"column":1,"offset":9982},"end":{"line":239,"column":37,"offset":10018},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":241,"column":1,"offset":10020},"end":{"line":243,"column":4,"offset":10193},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":245,"column":1,"offset":10195},"end":{"line":245,"column":25,"offset":10219},"indent":[]}}],"position":{"start":{"line":245,"column":1,"offset":10195},"end":{"line":245,"column":25,"offset":10219},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":247,"column":1,"offset":10221},"end":{"line":250,"column":4,"offset":10325},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":252,"column":1,"offset":10327},"end":{"line":252,"column":118,"offset":10444},"indent":[]}}],"position":{"start":{"line":252,"column":1,"offset":10327},"end":{"line":252,"column":118,"offset":10444},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":254,"column":1,"offset":10446},"end":{"line":274,"column":4,"offset":10953},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":276,"column":1,"offset":10955},"end":{"line":276,"column":14,"offset":10968},"indent":[]}}],"position":{"start":{"line":276,"column":1,"offset":10955},"end":{"line":276,"column":14,"offset":10968},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":278,"column":1,"offset":10970},"end":{"line":280,"column":4,"offset":11006},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":282,"column":1,"offset":11008},"end":{"line":282,"column":91,"offset":11098},"indent":[]}}],"position":{"start":{"line":282,"column":1,"offset":11008},"end":{"line":282,"column":91,"offset":11098},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":284,"column":1,"offset":11100},"end":{"line":292,"column":4,"offset":11473},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":294,"column":1,"offset":11475},"end":{"line":294,"column":145,"offset":11619},"indent":[]}}],"position":{"start":{"line":294,"column":1,"offset":11475},"end":{"line":294,"column":145,"offset":11619},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":296,"column":5,"offset":11625},"end":{"line":296,"column":17,"offset":11637},"indent":[]}}],"position":{"start":{"line":296,"column":1,"offset":11621},"end":{"line":296,"column":17,"offset":11637},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":298,"column":1,"offset":11639},"end":{"line":298,"column":300,"offset":11938},"indent":[]}}],"position":{"start":{"line":298,"column":1,"offset":11639},"end":{"line":298,"column":300,"offset":11938},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":300,"column":1,"offset":11940},"end":{"line":300,"column":178,"offset":12117},"indent":[]}}],"position":{"start":{"line":300,"column":1,"offset":11940},"end":{"line":300,"column":178,"offset":12117},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":302,"column":1,"offset":12119},"end":{"line":302,"column":48,"offset":12166},"indent":[]}}],"position":{"start":{"line":302,"column":1,"offset":12119},"end":{"line":302,"column":48,"offset":12166},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":304,"column":1,"offset":12168},"end":{"line":306,"column":4,"offset":12208},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":308,"column":1,"offset":12210},"end":{"line":308,"column":104,"offset":12313},"indent":[]}}],"position":{"start":{"line":308,"column":1,"offset":12210},"end":{"line":308,"column":104,"offset":12313},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":310,"column":1,"offset":12315},"end":{"line":318,"column":4,"offset":12585},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":320,"column":1,"offset":12587},"end":{"line":320,"column":28,"offset":12614},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":12587},"end":{"line":320,"column":28,"offset":12614},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":322,"column":1,"offset":12616},"end":{"line":324,"column":4,"offset":12660},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":326,"column":1,"offset":12662},"end":{"line":326,"column":48,"offset":12709},"indent":[]}}],"position":{"start":{"line":326,"column":1,"offset":12662},"end":{"line":326,"column":48,"offset":12709},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":328,"column":1,"offset":12711},"end":{"line":330,"column":4,"offset":12733},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":332,"column":1,"offset":12735},"end":{"line":332,"column":72,"offset":12806},"indent":[]}}],"position":{"start":{"line":332,"column":1,"offset":12735},"end":{"line":332,"column":72,"offset":12806},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":334,"column":1,"offset":12808},"end":{"line":336,"column":4,"offset":12865},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":338,"column":4,"offset":12870},"end":{"line":338,"column":11,"offset":12877},"indent":[]}}],"position":{"start":{"line":338,"column":1,"offset":12867},"end":{"line":338,"column":11,"offset":12877},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":340,"column":1,"offset":12879},"end":{"line":340,"column":283,"offset":13161},"indent":[]}}],"position":{"start":{"line":340,"column":1,"offset":12879},"end":{"line":340,"column":283,"offset":13161},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":342,"column":3,"offset":13165},"end":{"line":342,"column":54,"offset":13216},"indent":[]}}],"position":{"start":{"line":342,"column":3,"offset":13165},"end":{"line":342,"column":54,"offset":13216},"indent":[]}}],"position":{"start":{"line":342,"column":1,"offset":13163},"end":{"line":342,"column":54,"offset":13216},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":344,"column":5,"offset":13222},"end":{"line":344,"column":14,"offset":13231},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13218},"end":{"line":344,"column":14,"offset":13231},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":346,"column":1,"offset":13233},"end":{"line":346,"column":68,"offset":13300},"indent":[]}}],"position":{"start":{"line":346,"column":1,"offset":13233},"end":{"line":346,"column":68,"offset":13300},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":348,"column":1,"offset":13302},"end":{"line":351,"column":4,"offset":13453},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":353,"column":1,"offset":13455},"end":{"line":353,"column":46,"offset":13500},"indent":[]}}],"position":{"start":{"line":353,"column":1,"offset":13455},"end":{"line":353,"column":46,"offset":13500},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":355,"column":3,"offset":13504},"end":{"line":355,"column":103,"offset":13604},"indent":[]}}],"position":{"start":{"line":355,"column":3,"offset":13504},"end":{"line":355,"column":103,"offset":13604},"indent":[]}}],"position":{"start":{"line":355,"column":1,"offset":13502},"end":{"line":355,"column":103,"offset":13604},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":357,"column":1,"offset":13606},"end":{"line":362,"column":4,"offset":13816},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":364,"column":1,"offset":13818},"end":{"line":364,"column":151,"offset":13968},"indent":[]}}],"position":{"start":{"line":364,"column":1,"offset":13818},"end":{"line":364,"column":151,"offset":13968},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":366,"column":3,"offset":13972},"end":{"line":366,"column":22,"offset":13991},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":366,"column":22,"offset":13991},"end":{"line":366,"column":26,"offset":13995},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":366,"column":26,"offset":13995},"end":{"line":366,"column":40,"offset":14009},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":366,"column":40,"offset":14009},"end":{"line":366,"column":50,"offset":14019},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":366,"column":50,"offset":14019},"end":{"line":366,"column":98,"offset":14067},"indent":[]}}],"position":{"start":{"line":366,"column":3,"offset":13972},"end":{"line":366,"column":98,"offset":14067},"indent":[]}}],"position":{"start":{"line":366,"column":1,"offset":13970},"end":{"line":366,"column":98,"offset":14067},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":368,"column":1,"offset":14069},"end":{"line":372,"column":4,"offset":14231},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":374,"column":1,"offset":14233},"end":{"line":374,"column":72,"offset":14304},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":374,"column":72,"offset":14304},"end":{"line":374,"column":84,"offset":14316},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":374,"column":84,"offset":14316},"end":{"line":374,"column":102,"offset":14334},"indent":[]}}],"position":{"start":{"line":374,"column":1,"offset":14233},"end":{"line":374,"column":102,"offset":14334},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":376,"column":1,"offset":14336},"end":{"line":379,"column":4,"offset":14410},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":381,"column":5,"offset":14416},"end":{"line":381,"column":8,"offset":14419},"indent":[]}}],"position":{"start":{"line":381,"column":1,"offset":14412},"end":{"line":381,"column":8,"offset":14419},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":383,"column":1,"offset":14421},"end":{"line":383,"column":176,"offset":14596},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14421},"end":{"line":383,"column":176,"offset":14596},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":385,"column":1,"offset":14598},"end":{"line":392,"column":4,"offset":14895},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":394,"column":1,"offset":14897},"end":{"line":394,"column":60,"offset":14956},"indent":[]}}],"position":{"start":{"line":394,"column":1,"offset":14897},"end":{"line":394,"column":60,"offset":14956},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":396,"column":1,"offset":14958},"end":{"line":400,"column":4,"offset":15084},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":402,"column":1,"offset":15086},"end":{"line":402,"column":63,"offset":15148},"indent":[]}}],"position":{"start":{"line":402,"column":1,"offset":15086},"end":{"line":402,"column":63,"offset":15148},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":404,"column":1,"offset":15150},"end":{"line":424,"column":4,"offset":15657},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":426,"column":1,"offset":15659},"end":{"line":426,"column":99,"offset":15757},"indent":[]}}],"position":{"start":{"line":426,"column":1,"offset":15659},"end":{"line":426,"column":99,"offset":15757},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":428,"column":1,"offset":15759},"end":{"line":431,"column":4,"offset":15861},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":433,"column":1,"offset":15863},"end":{"line":433,"column":37,"offset":15899},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":433,"column":37,"offset":15899},"end":{"line":433,"column":47,"offset":15909},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":433,"column":47,"offset":15909},"end":{"line":433,"column":89,"offset":15951},"indent":[]}}],"position":{"start":{"line":433,"column":1,"offset":15863},"end":{"line":433,"column":89,"offset":15951},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":435,"column":1,"offset":15953},"end":{"line":439,"column":4,"offset":16078},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":441,"column":1,"offset":16080},"end":{"line":441,"column":78,"offset":16157},"indent":[]}}],"position":{"start":{"line":441,"column":1,"offset":16080},"end":{"line":441,"column":78,"offset":16157},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":443,"column":1,"offset":16159},"end":{"line":447,"column":4,"offset":16263},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":449,"column":1,"offset":16265},"end":{"line":449,"column":75,"offset":16339},"indent":[]}}],"position":{"start":{"line":449,"column":1,"offset":16265},"end":{"line":449,"column":75,"offset":16339},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":451,"column":1,"offset":16341},"end":{"line":455,"column":4,"offset":16414},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":457,"column":1,"offset":16416},"end":{"line":457,"column":145,"offset":16560},"indent":[]}}],"position":{"start":{"line":457,"column":1,"offset":16416},"end":{"line":457,"column":145,"offset":16560},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":459,"column":5,"offset":16566},"end":{"line":459,"column":17,"offset":16578},"indent":[]}}],"position":{"start":{"line":459,"column":1,"offset":16562},"end":{"line":459,"column":17,"offset":16578},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":461,"column":1,"offset":16580},"end":{"line":461,"column":300,"offset":16879},"indent":[]}}],"position":{"start":{"line":461,"column":1,"offset":16580},"end":{"line":461,"column":300,"offset":16879},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":463,"column":1,"offset":16881},"end":{"line":463,"column":178,"offset":17058},"indent":[]}}],"position":{"start":{"line":463,"column":1,"offset":16881},"end":{"line":463,"column":178,"offset":17058},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":465,"column":1,"offset":17060},"end":{"line":465,"column":48,"offset":17107},"indent":[]}}],"position":{"start":{"line":465,"column":1,"offset":17060},"end":{"line":465,"column":48,"offset":17107},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":467,"column":1,"offset":17109},"end":{"line":469,"column":4,"offset":17153},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":471,"column":1,"offset":17155},"end":{"line":471,"column":104,"offset":17258},"indent":[]}}],"position":{"start":{"line":471,"column":1,"offset":17155},"end":{"line":471,"column":104,"offset":17258},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":473,"column":1,"offset":17260},"end":{"line":481,"column":4,"offset":17530},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":483,"column":1,"offset":17532},"end":{"line":483,"column":28,"offset":17559},"indent":[]}}],"position":{"start":{"line":483,"column":1,"offset":17532},"end":{"line":483,"column":28,"offset":17559},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":485,"column":1,"offset":17561},"end":{"line":487,"column":4,"offset":17609},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":489,"column":1,"offset":17611},"end":{"line":489,"column":48,"offset":17658},"indent":[]}}],"position":{"start":{"line":489,"column":1,"offset":17611},"end":{"line":489,"column":48,"offset":17658},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":491,"column":1,"offset":17660},"end":{"line":493,"column":4,"offset":17682},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":495,"column":1,"offset":17684},"end":{"line":495,"column":72,"offset":17755},"indent":[]}}],"position":{"start":{"line":495,"column":1,"offset":17684},"end":{"line":495,"column":72,"offset":17755},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":497,"column":1,"offset":17757},"end":{"line":499,"column":4,"offset":17818},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":502,"column":1,"offset":17821},"end":{"line":502,"column":31,"offset":17851},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":502,"column":31,"offset":17851}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug-and-Play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n
\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS for Raspberry Pi`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker for amd64, armv7, arm64`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.`}

\n

{`Especially in the worl\neven on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.`}

\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-c8089618502ab2cbaca6c5ef0928b237.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-c8089618502ab2cbaca6c5ef0928b237.json new file mode 100644 index 0000000..b354d01 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-c8089618502ab2cbaca6c5ef0928b237.json @@ -0,0 +1 @@ +{"expireTime":9007200842068184000,"key":"gatsby-plugin-mdx-entire-payload-1af1b810df1bb74a9cba809e61706442-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug-and-Play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":24,"column":4,"offset":1138},"end":{"line":24,"column":17,"offset":1151},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1135},"end":{"line":24,"column":17,"offset":1151},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":26,"column":1,"offset":1153},"end":{"line":26,"column":156,"offset":1308},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1153},"end":{"line":26,"column":156,"offset":1308},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":28,"column":4,"offset":1313},"end":{"line":28,"column":8,"offset":1317},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":1310},"end":{"line":28,"column":8,"offset":1317},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":30,"column":1,"offset":1319},"end":{"line":30,"column":229,"offset":1547},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":1319},"end":{"line":30,"column":229,"offset":1547},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":32,"column":1,"offset":1549},"end":{"line":32,"column":197,"offset":1745},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":1549},"end":{"line":32,"column":197,"offset":1745},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":34,"column":5,"offset":1751},"end":{"line":34,"column":11,"offset":1757},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":1747},"end":{"line":34,"column":11,"offset":1757},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":36,"column":1,"offset":1759},"end":{"line":36,"column":63,"offset":1821},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":36,"column":64,"offset":1822},"end":{"line":36,"column":85,"offset":1843},"indent":[]}}],"position":{"start":{"line":36,"column":63,"offset":1821},"end":{"line":36,"column":123,"offset":1881},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":36,"column":123,"offset":1881},"end":{"line":36,"column":124,"offset":1882},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":1759},"end":{"line":36,"column":124,"offset":1882},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":38,"column":5,"offset":1888},"end":{"line":38,"column":35,"offset":1918},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":1884},"end":{"line":38,"column":35,"offset":1918},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":40,"column":1,"offset":1920},"end":{"line":40,"column":228,"offset":2147},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":1920},"end":{"line":40,"column":228,"offset":2147},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":42,"column":1,"offset":2149},"end":{"line":42,"column":67,"offset":2215},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":2149},"end":{"line":42,"column":67,"offset":2215},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":44,"column":1,"offset":2217},"end":{"line":44,"column":50,"offset":2266},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":2217},"end":{"line":44,"column":50,"offset":2266},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":46,"column":3,"offset":2270},"end":{"line":46,"column":49,"offset":2316},"indent":[]}}],"position":{"start":{"line":46,"column":3,"offset":2270},"end":{"line":46,"column":49,"offset":2316},"indent":[]}}],"position":{"start":{"line":46,"column":3,"offset":2270},"end":{"line":46,"column":49,"offset":2316},"indent":[]}}],"position":{"start":{"line":46,"column":1,"offset":2268},"end":{"line":46,"column":49,"offset":2316},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":48,"column":5,"offset":2322},"end":{"line":48,"column":11,"offset":2328},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2318},"end":{"line":48,"column":11,"offset":2328},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":50,"column":1,"offset":2330},"end":{"line":50,"column":160,"offset":2489},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":2330},"end":{"line":50,"column":160,"offset":2489},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":52,"column":4,"offset":2494},"end":{"line":52,"column":13,"offset":2503},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":52,"column":14,"offset":2504},"end":{"line":52,"column":28,"offset":2518},"indent":[]}}],"position":{"start":{"line":52,"column":13,"offset":2503},"end":{"line":52,"column":75,"offset":2565},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":52,"column":75,"offset":2565},"end":{"line":52,"column":76,"offset":2566},"indent":[]}}],"position":{"start":{"line":52,"column":4,"offset":2494},"end":{"line":52,"column":76,"offset":2566},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2491},"end":{"line":52,"column":76,"offset":2566},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":53,"column":4,"offset":2570},"end":{"line":53,"column":41,"offset":2607},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2570},"end":{"line":53,"column":41,"offset":2607},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2567},"end":{"line":53,"column":41,"offset":2607},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":54,"column":4,"offset":2611},"end":{"line":54,"column":60,"offset":2667},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2611},"end":{"line":54,"column":60,"offset":2667},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2608},"end":{"line":54,"column":60,"offset":2667},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2491},"end":{"line":54,"column":60,"offset":2667},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":56,"column":2,"offset":2670},"end":{"line":56,"column":64,"offset":2732},"indent":[]}}],"position":{"start":{"line":56,"column":1,"offset":2669},"end":{"line":56,"column":96,"offset":2764},"indent":[]}}],"position":{"start":{"line":56,"column":1,"offset":2669},"end":{"line":56,"column":96,"offset":2764},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":58,"column":1,"offset":2766},"end":{"line":58,"column":204,"offset":2969},"indent":[]}}],"position":{"start":{"line":58,"column":1,"offset":2766},"end":{"line":58,"column":204,"offset":2969},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":60,"column":6,"offset":2976},"end":{"line":60,"column":24,"offset":2994},"indent":[]}}],"position":{"start":{"line":60,"column":1,"offset":2971},"end":{"line":60,"column":24,"offset":2994},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":62,"column":1,"offset":2996},"end":{"line":62,"column":95,"offset":3090},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":62,"column":95,"offset":3090},"end":{"line":62,"column":110,"offset":3105},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":62,"column":110,"offset":3105},"end":{"line":62,"column":222,"offset":3217},"indent":[]}}],"position":{"start":{"line":62,"column":1,"offset":2996},"end":{"line":62,"column":222,"offset":3217},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":64,"column":1,"offset":3219},"end":{"line":72,"column":4,"offset":3328},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":74,"column":6,"offset":3335},"end":{"line":74,"column":31,"offset":3360},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":3330},"end":{"line":74,"column":31,"offset":3360},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":76,"column":1,"offset":3362},"end":{"line":76,"column":79,"offset":3440},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":76,"column":79,"offset":3440},"end":{"line":76,"column":95,"offset":3456},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":76,"column":95,"offset":3456},"end":{"line":76,"column":137,"offset":3498},"indent":[]}}],"position":{"start":{"line":76,"column":1,"offset":3362},"end":{"line":76,"column":137,"offset":3498},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":78,"column":1,"offset":3500},"end":{"line":88,"column":4,"offset":3868},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":90,"column":5,"offset":3874},"end":{"line":90,"column":30,"offset":3899},"indent":[]}}],"position":{"start":{"line":90,"column":1,"offset":3870},"end":{"line":90,"column":30,"offset":3899},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":92,"column":1,"offset":3901},"end":{"line":92,"column":464,"offset":4364},"indent":[]}}],"position":{"start":{"line":92,"column":1,"offset":3901},"end":{"line":92,"column":464,"offset":4364},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":94,"column":1,"offset":4366},"end":{"line":94,"column":61,"offset":4426},"indent":[]}}],"position":{"start":{"line":94,"column":1,"offset":4366},"end":{"line":94,"column":61,"offset":4426},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":96,"column":5,"offset":4432},"end":{"line":96,"column":28,"offset":4455},"indent":[]}}],"position":{"start":{"line":96,"column":1,"offset":4428},"end":{"line":96,"column":28,"offset":4455},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":98,"column":1,"offset":4457},"end":{"line":98,"column":95,"offset":4551},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":98,"column":95,"offset":4551},"end":{"line":98,"column":100,"offset":4556},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":98,"column":100,"offset":4556},"end":{"line":98,"column":101,"offset":4557},"indent":[]}}],"position":{"start":{"line":98,"column":1,"offset":4457},"end":{"line":98,"column":101,"offset":4557},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":100,"column":1,"offset":4559},"end":{"line":104,"column":4,"offset":4676},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":106,"column":1,"offset":4678},"end":{"line":106,"column":80,"offset":4757},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":106,"column":80,"offset":4757},"end":{"line":106,"column":101,"offset":4778},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":106,"column":101,"offset":4778},"end":{"line":106,"column":162,"offset":4839},"indent":[]}}],"position":{"start":{"line":106,"column":1,"offset":4678},"end":{"line":106,"column":162,"offset":4839},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":108,"column":1,"offset":4841},"end":{"line":111,"column":4,"offset":4930},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":113,"column":4,"offset":4935},"end":{"line":113,"column":10,"offset":4941},"indent":[]}}],"position":{"start":{"line":113,"column":1,"offset":4932},"end":{"line":113,"column":10,"offset":4941},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":115,"column":1,"offset":4943},"end":{"line":115,"column":339,"offset":5281},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":115,"column":340,"offset":5282},"end":{"line":115,"column":354,"offset":5296},"indent":[]}}],"position":{"start":{"line":115,"column":339,"offset":5281},"end":{"line":115,"column":390,"offset":5332},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":115,"column":390,"offset":5332},"end":{"line":115,"column":391,"offset":5333},"indent":[]}}],"position":{"start":{"line":115,"column":1,"offset":4943},"end":{"line":115,"column":391,"offset":5333},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":117,"column":5,"offset":5339},"end":{"line":117,"column":18,"offset":5352},"indent":[]}}],"position":{"start":{"line":117,"column":1,"offset":5335},"end":{"line":117,"column":18,"offset":5352},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":119,"column":3,"offset":5356},"end":{"line":119,"column":50,"offset":5403},"indent":[]}}],"position":{"start":{"line":119,"column":3,"offset":5356},"end":{"line":119,"column":50,"offset":5403},"indent":[]}}],"position":{"start":{"line":119,"column":1,"offset":5354},"end":{"line":119,"column":50,"offset":5403},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":121,"column":5,"offset":5409},"end":{"line":121,"column":11,"offset":5415},"indent":[]}}],"position":{"start":{"line":121,"column":1,"offset":5405},"end":{"line":121,"column":11,"offset":5415},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":123,"column":1,"offset":5417},"end":{"line":123,"column":64,"offset":5480},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":123,"column":65,"offset":5481},"end":{"line":123,"column":86,"offset":5502},"indent":[]}}],"position":{"start":{"line":123,"column":64,"offset":5480},"end":{"line":123,"column":126,"offset":5542},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":123,"column":126,"offset":5542},"end":{"line":123,"column":127,"offset":5543},"indent":[]}}],"position":{"start":{"line":123,"column":1,"offset":5417},"end":{"line":123,"column":127,"offset":5543},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":125,"column":5,"offset":5549},"end":{"line":125,"column":26,"offset":5570},"indent":[]}}],"position":{"start":{"line":125,"column":1,"offset":5545},"end":{"line":125,"column":26,"offset":5570},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":127,"column":1,"offset":5572},"end":{"line":127,"column":126,"offset":5697},"indent":[]}}],"position":{"start":{"line":127,"column":1,"offset":5572},"end":{"line":127,"column":126,"offset":5697},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":129,"column":1,"offset":5699},"end":{"line":131,"column":4,"offset":5738},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":133,"column":1,"offset":5740},"end":{"line":133,"column":187,"offset":5926},"indent":[]}}],"position":{"start":{"line":133,"column":1,"offset":5740},"end":{"line":133,"column":187,"offset":5926},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":135,"column":1,"offset":5928},"end":{"line":137,"column":4,"offset":6006},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":139,"column":1,"offset":6008},"end":{"line":139,"column":153,"offset":6160},"indent":[]}}],"position":{"start":{"line":139,"column":1,"offset":6008},"end":{"line":139,"column":153,"offset":6160},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":141,"column":1,"offset":6162},"end":{"line":144,"column":4,"offset":6309},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":146,"column":1,"offset":6311},"end":{"line":146,"column":100,"offset":6410},"indent":[]}}],"position":{"start":{"line":146,"column":1,"offset":6311},"end":{"line":146,"column":100,"offset":6410},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":147,"column":1,"offset":6411},"end":{"line":151,"column":4,"offset":6480},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":153,"column":5,"offset":6486},"end":{"line":153,"column":12,"offset":6493},"indent":[]}}],"position":{"start":{"line":153,"column":1,"offset":6482},"end":{"line":153,"column":12,"offset":6493},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":155,"column":1,"offset":6495},"end":{"line":155,"column":64,"offset":6558},"indent":[]}}],"position":{"start":{"line":155,"column":1,"offset":6495},"end":{"line":155,"column":64,"offset":6558},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":156,"column":3,"offset":6561},"end":{"line":156,"column":25,"offset":6583},"indent":[]}}],"position":{"start":{"line":156,"column":3,"offset":6561},"end":{"line":156,"column":25,"offset":6583},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6559},"end":{"line":156,"column":25,"offset":6583},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":157,"column":3,"offset":6586},"end":{"line":157,"column":59,"offset":6642},"indent":[]}}],"position":{"start":{"line":157,"column":3,"offset":6586},"end":{"line":157,"column":59,"offset":6642},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6584},"end":{"line":157,"column":59,"offset":6642},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6559},"end":{"line":157,"column":59,"offset":6642},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":159,"column":4,"offset":6647},"end":{"line":159,"column":10,"offset":6653},"indent":[]}}],"position":{"start":{"line":159,"column":1,"offset":6644},"end":{"line":159,"column":10,"offset":6653},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.","position":{"start":{"line":161,"column":1,"offset":6655},"end":{"line":161,"column":102,"offset":6756},"indent":[]}}],"position":{"start":{"line":161,"column":1,"offset":6655},"end":{"line":161,"column":102,"offset":6756},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Especially in the worl\n even on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.","position":{"start":{"line":163,"column":1,"offset":6758},"end":{"line":164,"column":128,"offset":6908},"indent":[1]}}],"position":{"start":{"line":163,"column":1,"offset":6758},"end":{"line":164,"column":128,"offset":6908},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":166,"column":4,"offset":6913},"end":{"line":166,"column":12,"offset":6921},"indent":[]}}],"position":{"start":{"line":166,"column":1,"offset":6910},"end":{"line":166,"column":12,"offset":6921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":168,"column":1,"offset":6923},"end":{"line":168,"column":133,"offset":7055},"indent":[]}}],"position":{"start":{"line":168,"column":1,"offset":6923},"end":{"line":168,"column":133,"offset":7055},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":170,"column":4,"offset":7060},"end":{"line":170,"column":12,"offset":7068},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7057},"end":{"line":170,"column":12,"offset":7068},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":172,"column":1,"offset":7070},"end":{"line":172,"column":193,"offset":7262},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7070},"end":{"line":172,"column":193,"offset":7262},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":174,"column":4,"offset":7267},"end":{"line":174,"column":62,"offset":7325},"indent":[]}}],"position":{"start":{"line":174,"column":4,"offset":7267},"end":{"line":174,"column":62,"offset":7325},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7264},"end":{"line":174,"column":62,"offset":7325},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":175,"column":4,"offset":7329},"end":{"line":175,"column":69,"offset":7394},"indent":[]}}],"position":{"start":{"line":175,"column":4,"offset":7329},"end":{"line":175,"column":69,"offset":7394},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7326},"end":{"line":175,"column":69,"offset":7394},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7264},"end":{"line":175,"column":69,"offset":7394},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":177,"column":1,"offset":7396},"end":{"line":177,"column":99,"offset":7494},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7396},"end":{"line":177,"column":99,"offset":7494},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":179,"column":5,"offset":7500},"end":{"line":179,"column":14,"offset":7509},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7496},"end":{"line":179,"column":14,"offset":7509},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":181,"column":1,"offset":7511},"end":{"line":181,"column":71,"offset":7581},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":7511},"end":{"line":181,"column":71,"offset":7581},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":183,"column":3,"offset":7585},"end":{"line":183,"column":47,"offset":7629},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":183,"column":47,"offset":7629},"end":{"line":183,"column":79,"offset":7661},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":183,"column":79,"offset":7661},"end":{"line":183,"column":198,"offset":7780},"indent":[]}}],"position":{"start":{"line":183,"column":3,"offset":7585},"end":{"line":183,"column":198,"offset":7780},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":7583},"end":{"line":183,"column":198,"offset":7780},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":185,"column":1,"offset":7782},"end":{"line":187,"column":4,"offset":7845},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":189,"column":5,"offset":7851},"end":{"line":189,"column":14,"offset":7860},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":7847},"end":{"line":189,"column":14,"offset":7860},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":191,"column":1,"offset":7862},"end":{"line":191,"column":56,"offset":7917},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":7862},"end":{"line":191,"column":56,"offset":7917},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":192,"column":3,"offset":7920},"end":{"line":192,"column":52,"offset":7969},"indent":[]}}],"position":{"start":{"line":192,"column":3,"offset":7920},"end":{"line":192,"column":52,"offset":7969},"indent":[]}}],"position":{"start":{"line":192,"column":3,"offset":7920},"end":{"line":192,"column":52,"offset":7969},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":7918},"end":{"line":192,"column":52,"offset":7969},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":194,"column":1,"offset":7971},"end":{"line":194,"column":3,"offset":7973},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":194,"column":3,"offset":7973},"end":{"line":194,"column":9,"offset":7979},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":194,"column":9,"offset":7979},"end":{"line":194,"column":223,"offset":8193},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":7971},"end":{"line":194,"column":223,"offset":8193},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":196,"column":3,"offset":8197},"end":{"line":196,"column":159,"offset":8353},"indent":[]}}],"position":{"start":{"line":196,"column":3,"offset":8197},"end":{"line":196,"column":159,"offset":8353},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8195},"end":{"line":196,"column":159,"offset":8353},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":198,"column":1,"offset":8355},"end":{"line":201,"column":4,"offset":8532},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":203,"column":1,"offset":8534},"end":{"line":203,"column":160,"offset":8693},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":8534},"end":{"line":203,"column":160,"offset":8693},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":205,"column":3,"offset":8697},"end":{"line":205,"column":31,"offset":8725},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":205,"column":31,"offset":8725},"end":{"line":205,"column":101,"offset":8795},"indent":[]}}],"position":{"start":{"line":205,"column":3,"offset":8697},"end":{"line":205,"column":101,"offset":8795},"indent":[]}}],"position":{"start":{"line":205,"column":1,"offset":8695},"end":{"line":205,"column":101,"offset":8795},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":207,"column":1,"offset":8797},"end":{"line":210,"column":4,"offset":8969},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":212,"column":1,"offset":8971},"end":{"line":212,"column":73,"offset":9043},"indent":[]}}],"position":{"start":{"line":212,"column":1,"offset":8971},"end":{"line":212,"column":73,"offset":9043},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":215,"column":3,"offset":9048},"end":{"line":215,"column":31,"offset":9076},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":215,"column":31,"offset":9076},"end":{"line":215,"column":101,"offset":9146},"indent":[]}}],"position":{"start":{"line":215,"column":3,"offset":9048},"end":{"line":215,"column":101,"offset":9146},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":9046},"end":{"line":215,"column":101,"offset":9146},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":217,"column":1,"offset":9148},"end":{"line":220,"column":4,"offset":9320},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":222,"column":1,"offset":9322},"end":{"line":222,"column":62,"offset":9383},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":222,"column":63,"offset":9384},"end":{"line":222,"column":75,"offset":9396},"indent":[]}}],"position":{"start":{"line":222,"column":62,"offset":9383},"end":{"line":222,"column":143,"offset":9464},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":222,"column":143,"offset":9464},"end":{"line":222,"column":150,"offset":9471},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":222,"column":150,"offset":9471},"end":{"line":222,"column":169,"offset":9490},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":222,"column":169,"offset":9490},"end":{"line":222,"column":170,"offset":9491},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":9322},"end":{"line":222,"column":170,"offset":9491},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":224,"column":1,"offset":9493},"end":{"line":226,"column":4,"offset":9520},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":228,"column":1,"offset":9522},"end":{"line":228,"column":58,"offset":9579},"indent":[]}}],"position":{"start":{"line":228,"column":1,"offset":9522},"end":{"line":228,"column":58,"offset":9579},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":230,"column":1,"offset":9581},"end":{"line":233,"column":4,"offset":9651},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":235,"column":5,"offset":9657},"end":{"line":235,"column":8,"offset":9660},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":9653},"end":{"line":235,"column":8,"offset":9660},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":237,"column":1,"offset":9662},"end":{"line":237,"column":280,"offset":9941},"indent":[]}}],"position":{"start":{"line":237,"column":1,"offset":9662},"end":{"line":237,"column":280,"offset":9941},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":239,"column":1,"offset":9943},"end":{"line":239,"column":37,"offset":9979},"indent":[]}}],"position":{"start":{"line":239,"column":1,"offset":9943},"end":{"line":239,"column":37,"offset":9979},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":241,"column":1,"offset":9981},"end":{"line":243,"column":4,"offset":10154},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":245,"column":1,"offset":10156},"end":{"line":245,"column":25,"offset":10180},"indent":[]}}],"position":{"start":{"line":245,"column":1,"offset":10156},"end":{"line":245,"column":25,"offset":10180},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":247,"column":1,"offset":10182},"end":{"line":250,"column":4,"offset":10286},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":252,"column":1,"offset":10288},"end":{"line":252,"column":118,"offset":10405},"indent":[]}}],"position":{"start":{"line":252,"column":1,"offset":10288},"end":{"line":252,"column":118,"offset":10405},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":254,"column":1,"offset":10407},"end":{"line":274,"column":4,"offset":10914},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":276,"column":1,"offset":10916},"end":{"line":276,"column":14,"offset":10929},"indent":[]}}],"position":{"start":{"line":276,"column":1,"offset":10916},"end":{"line":276,"column":14,"offset":10929},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":278,"column":1,"offset":10931},"end":{"line":280,"column":4,"offset":10967},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":282,"column":1,"offset":10969},"end":{"line":282,"column":91,"offset":11059},"indent":[]}}],"position":{"start":{"line":282,"column":1,"offset":10969},"end":{"line":282,"column":91,"offset":11059},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":284,"column":1,"offset":11061},"end":{"line":292,"column":4,"offset":11434},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":294,"column":1,"offset":11436},"end":{"line":294,"column":145,"offset":11580},"indent":[]}}],"position":{"start":{"line":294,"column":1,"offset":11436},"end":{"line":294,"column":145,"offset":11580},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":296,"column":5,"offset":11586},"end":{"line":296,"column":17,"offset":11598},"indent":[]}}],"position":{"start":{"line":296,"column":1,"offset":11582},"end":{"line":296,"column":17,"offset":11598},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":298,"column":1,"offset":11600},"end":{"line":298,"column":300,"offset":11899},"indent":[]}}],"position":{"start":{"line":298,"column":1,"offset":11600},"end":{"line":298,"column":300,"offset":11899},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":300,"column":1,"offset":11901},"end":{"line":300,"column":178,"offset":12078},"indent":[]}}],"position":{"start":{"line":300,"column":1,"offset":11901},"end":{"line":300,"column":178,"offset":12078},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":302,"column":1,"offset":12080},"end":{"line":302,"column":48,"offset":12127},"indent":[]}}],"position":{"start":{"line":302,"column":1,"offset":12080},"end":{"line":302,"column":48,"offset":12127},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":304,"column":1,"offset":12129},"end":{"line":306,"column":4,"offset":12169},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":308,"column":1,"offset":12171},"end":{"line":308,"column":104,"offset":12274},"indent":[]}}],"position":{"start":{"line":308,"column":1,"offset":12171},"end":{"line":308,"column":104,"offset":12274},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":310,"column":1,"offset":12276},"end":{"line":318,"column":4,"offset":12546},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":320,"column":1,"offset":12548},"end":{"line":320,"column":28,"offset":12575},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":12548},"end":{"line":320,"column":28,"offset":12575},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":322,"column":1,"offset":12577},"end":{"line":324,"column":4,"offset":12621},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":326,"column":1,"offset":12623},"end":{"line":326,"column":48,"offset":12670},"indent":[]}}],"position":{"start":{"line":326,"column":1,"offset":12623},"end":{"line":326,"column":48,"offset":12670},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":328,"column":1,"offset":12672},"end":{"line":330,"column":4,"offset":12694},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":332,"column":1,"offset":12696},"end":{"line":332,"column":72,"offset":12767},"indent":[]}}],"position":{"start":{"line":332,"column":1,"offset":12696},"end":{"line":332,"column":72,"offset":12767},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":334,"column":1,"offset":12769},"end":{"line":336,"column":4,"offset":12826},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":338,"column":4,"offset":12831},"end":{"line":338,"column":11,"offset":12838},"indent":[]}}],"position":{"start":{"line":338,"column":1,"offset":12828},"end":{"line":338,"column":11,"offset":12838},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":340,"column":1,"offset":12840},"end":{"line":340,"column":283,"offset":13122},"indent":[]}}],"position":{"start":{"line":340,"column":1,"offset":12840},"end":{"line":340,"column":283,"offset":13122},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":342,"column":3,"offset":13126},"end":{"line":342,"column":54,"offset":13177},"indent":[]}}],"position":{"start":{"line":342,"column":3,"offset":13126},"end":{"line":342,"column":54,"offset":13177},"indent":[]}}],"position":{"start":{"line":342,"column":1,"offset":13124},"end":{"line":342,"column":54,"offset":13177},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":344,"column":5,"offset":13183},"end":{"line":344,"column":14,"offset":13192},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13179},"end":{"line":344,"column":14,"offset":13192},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":346,"column":1,"offset":13194},"end":{"line":346,"column":68,"offset":13261},"indent":[]}}],"position":{"start":{"line":346,"column":1,"offset":13194},"end":{"line":346,"column":68,"offset":13261},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":348,"column":1,"offset":13263},"end":{"line":351,"column":4,"offset":13414},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":353,"column":1,"offset":13416},"end":{"line":353,"column":46,"offset":13461},"indent":[]}}],"position":{"start":{"line":353,"column":1,"offset":13416},"end":{"line":353,"column":46,"offset":13461},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":355,"column":3,"offset":13465},"end":{"line":355,"column":103,"offset":13565},"indent":[]}}],"position":{"start":{"line":355,"column":3,"offset":13465},"end":{"line":355,"column":103,"offset":13565},"indent":[]}}],"position":{"start":{"line":355,"column":1,"offset":13463},"end":{"line":355,"column":103,"offset":13565},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":357,"column":1,"offset":13567},"end":{"line":362,"column":4,"offset":13777},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":364,"column":1,"offset":13779},"end":{"line":364,"column":151,"offset":13929},"indent":[]}}],"position":{"start":{"line":364,"column":1,"offset":13779},"end":{"line":364,"column":151,"offset":13929},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":366,"column":3,"offset":13933},"end":{"line":366,"column":22,"offset":13952},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":366,"column":22,"offset":13952},"end":{"line":366,"column":26,"offset":13956},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":366,"column":26,"offset":13956},"end":{"line":366,"column":40,"offset":13970},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":366,"column":40,"offset":13970},"end":{"line":366,"column":50,"offset":13980},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":366,"column":50,"offset":13980},"end":{"line":366,"column":98,"offset":14028},"indent":[]}}],"position":{"start":{"line":366,"column":3,"offset":13933},"end":{"line":366,"column":98,"offset":14028},"indent":[]}}],"position":{"start":{"line":366,"column":1,"offset":13931},"end":{"line":366,"column":98,"offset":14028},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":368,"column":1,"offset":14030},"end":{"line":372,"column":4,"offset":14192},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":374,"column":1,"offset":14194},"end":{"line":374,"column":72,"offset":14265},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":374,"column":72,"offset":14265},"end":{"line":374,"column":84,"offset":14277},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":374,"column":84,"offset":14277},"end":{"line":374,"column":102,"offset":14295},"indent":[]}}],"position":{"start":{"line":374,"column":1,"offset":14194},"end":{"line":374,"column":102,"offset":14295},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":376,"column":1,"offset":14297},"end":{"line":379,"column":4,"offset":14371},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":381,"column":5,"offset":14377},"end":{"line":381,"column":8,"offset":14380},"indent":[]}}],"position":{"start":{"line":381,"column":1,"offset":14373},"end":{"line":381,"column":8,"offset":14380},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":383,"column":1,"offset":14382},"end":{"line":383,"column":176,"offset":14557},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14382},"end":{"line":383,"column":176,"offset":14557},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":385,"column":1,"offset":14559},"end":{"line":392,"column":4,"offset":14856},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":394,"column":1,"offset":14858},"end":{"line":394,"column":60,"offset":14917},"indent":[]}}],"position":{"start":{"line":394,"column":1,"offset":14858},"end":{"line":394,"column":60,"offset":14917},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":396,"column":1,"offset":14919},"end":{"line":400,"column":4,"offset":15045},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":402,"column":1,"offset":15047},"end":{"line":402,"column":63,"offset":15109},"indent":[]}}],"position":{"start":{"line":402,"column":1,"offset":15047},"end":{"line":402,"column":63,"offset":15109},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":404,"column":1,"offset":15111},"end":{"line":424,"column":4,"offset":15618},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":426,"column":1,"offset":15620},"end":{"line":426,"column":99,"offset":15718},"indent":[]}}],"position":{"start":{"line":426,"column":1,"offset":15620},"end":{"line":426,"column":99,"offset":15718},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":428,"column":1,"offset":15720},"end":{"line":431,"column":4,"offset":15822},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":433,"column":1,"offset":15824},"end":{"line":433,"column":37,"offset":15860},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":433,"column":37,"offset":15860},"end":{"line":433,"column":47,"offset":15870},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":433,"column":47,"offset":15870},"end":{"line":433,"column":89,"offset":15912},"indent":[]}}],"position":{"start":{"line":433,"column":1,"offset":15824},"end":{"line":433,"column":89,"offset":15912},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":435,"column":1,"offset":15914},"end":{"line":439,"column":4,"offset":16039},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":441,"column":1,"offset":16041},"end":{"line":441,"column":78,"offset":16118},"indent":[]}}],"position":{"start":{"line":441,"column":1,"offset":16041},"end":{"line":441,"column":78,"offset":16118},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":443,"column":1,"offset":16120},"end":{"line":447,"column":4,"offset":16224},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":449,"column":1,"offset":16226},"end":{"line":449,"column":75,"offset":16300},"indent":[]}}],"position":{"start":{"line":449,"column":1,"offset":16226},"end":{"line":449,"column":75,"offset":16300},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":451,"column":1,"offset":16302},"end":{"line":455,"column":4,"offset":16375},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":457,"column":1,"offset":16377},"end":{"line":457,"column":145,"offset":16521},"indent":[]}}],"position":{"start":{"line":457,"column":1,"offset":16377},"end":{"line":457,"column":145,"offset":16521},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":459,"column":5,"offset":16527},"end":{"line":459,"column":17,"offset":16539},"indent":[]}}],"position":{"start":{"line":459,"column":1,"offset":16523},"end":{"line":459,"column":17,"offset":16539},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":461,"column":1,"offset":16541},"end":{"line":461,"column":300,"offset":16840},"indent":[]}}],"position":{"start":{"line":461,"column":1,"offset":16541},"end":{"line":461,"column":300,"offset":16840},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":463,"column":1,"offset":16842},"end":{"line":463,"column":178,"offset":17019},"indent":[]}}],"position":{"start":{"line":463,"column":1,"offset":16842},"end":{"line":463,"column":178,"offset":17019},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":465,"column":1,"offset":17021},"end":{"line":465,"column":48,"offset":17068},"indent":[]}}],"position":{"start":{"line":465,"column":1,"offset":17021},"end":{"line":465,"column":48,"offset":17068},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":467,"column":1,"offset":17070},"end":{"line":469,"column":4,"offset":17114},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":471,"column":1,"offset":17116},"end":{"line":471,"column":104,"offset":17219},"indent":[]}}],"position":{"start":{"line":471,"column":1,"offset":17116},"end":{"line":471,"column":104,"offset":17219},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":473,"column":1,"offset":17221},"end":{"line":481,"column":4,"offset":17491},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":483,"column":1,"offset":17493},"end":{"line":483,"column":28,"offset":17520},"indent":[]}}],"position":{"start":{"line":483,"column":1,"offset":17493},"end":{"line":483,"column":28,"offset":17520},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":485,"column":1,"offset":17522},"end":{"line":487,"column":4,"offset":17570},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":489,"column":1,"offset":17572},"end":{"line":489,"column":48,"offset":17619},"indent":[]}}],"position":{"start":{"line":489,"column":1,"offset":17572},"end":{"line":489,"column":48,"offset":17619},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":491,"column":1,"offset":17621},"end":{"line":493,"column":4,"offset":17643},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":495,"column":1,"offset":17645},"end":{"line":495,"column":72,"offset":17716},"indent":[]}}],"position":{"start":{"line":495,"column":1,"offset":17645},"end":{"line":495,"column":72,"offset":17716},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":497,"column":1,"offset":17718},"end":{"line":499,"column":4,"offset":17779},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":502,"column":1,"offset":17782},"end":{"line":502,"column":31,"offset":17812},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":502,"column":31,"offset":17812}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug-and-Play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere.`}

\n

{`Especially in the worl\neven on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.`}

\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-d0b9eeeaa92d675686b9c7817a3167a8.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-d0b9eeeaa92d675686b9c7817a3167a8.json index d68bc5c..58fff55 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-d0b9eeeaa92d675686b9c7817a3167a8.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-d0b9eeeaa92d675686b9c7817a3167a8.json @@ -1 +1 @@ -{"expireTime":9007200841014158000,"key":"gatsby-plugin-mdx-entire-payload-987cc10b856caabc7382fd42a9082629-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Cloud","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":8,"offset":166},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":8,"offset":166},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When installing a Kerberos agent inside your local network, it's possible to review your activity by using the agent's web interface. By nature, you will not be able to access the web interface from the cloud (outside your local network). On top of that, the Kerberos agent doesn't come with a consolidated overview. This means that you will need to open multiple web interfaces, one for each connected surveillance camera.","position":{"start":{"line":10,"column":1,"offset":168},"end":{"line":10,"column":424,"offset":591},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":168},"end":{"line":10,"column":424,"offset":591},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To simplify and resolve all of these challenges, Kerberos Cloud was developed.","position":{"start":{"line":12,"column":1,"offset":593},"end":{"line":12,"column":79,"offset":671},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":593},"end":{"line":12,"column":79,"offset":671},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://cloud.kerberos.io","children":[{"type":"text","value":"Kerberos Cloud","position":{"start":{"line":14,"column":4,"offset":676},"end":{"line":14,"column":18,"offset":690},"indent":[]}}],"position":{"start":{"line":14,"column":3,"offset":675},"end":{"line":14,"column":46,"offset":718},"indent":[]}},{"type":"text","value":" is a cloud solution which allows you to have a single overview of all the media recordings generated by your surveillance cameras. It's not a solution for processing your surveillance cameras in the cloud. For processing of your surveillance cameras, a Kerberos agent is used.","position":{"start":{"line":14,"column":46,"offset":718},"end":{"line":14,"column":323,"offset":995},"indent":[]}}],"position":{"start":{"line":14,"column":3,"offset":675},"end":{"line":14,"column":323,"offset":995},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":673},"end":{"line":14,"column":323,"offset":995},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A brief list of the key features of Kerberos Cloud are:","position":{"start":{"line":16,"column":1,"offset":997},"end":{"line":16,"column":56,"offset":1052},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":997},"end":{"line":16,"column":56,"offset":1052},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Secured storage","position":{"start":{"line":18,"column":3,"offset":1056},"end":{"line":18,"column":18,"offset":1071},"indent":[]}}],"position":{"start":{"line":18,"column":3,"offset":1056},"end":{"line":18,"column":18,"offset":1071},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":1054},"end":{"line":18,"column":18,"offset":1071},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Consolidated overview","position":{"start":{"line":19,"column":3,"offset":1074},"end":{"line":19,"column":24,"offset":1095},"indent":[]}}],"position":{"start":{"line":19,"column":3,"offset":1074},"end":{"line":19,"column":24,"offset":1095},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":1072},"end":{"line":19,"column":24,"offset":1095},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Advanced searching","position":{"start":{"line":20,"column":3,"offset":1098},"end":{"line":20,"column":21,"offset":1116},"indent":[]}}],"position":{"start":{"line":20,"column":3,"offset":1098},"end":{"line":20,"column":21,"offset":1116},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":1096},"end":{"line":20,"column":21,"offset":1116},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Machine learning","position":{"start":{"line":21,"column":3,"offset":1119},"end":{"line":21,"column":19,"offset":1135},"indent":[]}}],"position":{"start":{"line":21,"column":3,"offset":1119},"end":{"line":21,"column":19,"offset":1135},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":1117},"end":{"line":21,"column":19,"offset":1135},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Alerts","position":{"start":{"line":22,"column":3,"offset":1138},"end":{"line":22,"column":9,"offset":1144},"indent":[]}}],"position":{"start":{"line":22,"column":3,"offset":1138},"end":{"line":22,"column":9,"offset":1144},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1136},"end":{"line":22,"column":9,"offset":1144},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Live streaming","position":{"start":{"line":23,"column":3,"offset":1147},"end":{"line":23,"column":17,"offset":1161},"indent":[]}}],"position":{"start":{"line":23,"column":3,"offset":1147},"end":{"line":23,"column":17,"offset":1161},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":1145},"end":{"line":23,"column":17,"offset":1161},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Accounts","position":{"start":{"line":24,"column":3,"offset":1164},"end":{"line":24,"column":11,"offset":1172},"indent":[]}}],"position":{"start":{"line":24,"column":3,"offset":1164},"end":{"line":24,"column":11,"offset":1172},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1162},"end":{"line":24,"column":11,"offset":1172},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Logging","position":{"start":{"line":25,"column":3,"offset":1175},"end":{"line":25,"column":10,"offset":1182},"indent":[]}}],"position":{"start":{"line":25,"column":3,"offset":1175},"end":{"line":25,"column":10,"offset":1182},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1173},"end":{"line":25,"column":10,"offset":1182},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":1054},"end":{"line":25,"column":10,"offset":1182},"indent":[1,1,1,1,1,1,1]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Checkout ","position":{"start":{"line":27,"column":3,"offset":1186},"end":{"line":27,"column":12,"offset":1195},"indent":[]}},{"type":"link","title":null,"url":"https://app-demo.kerberos.io","children":[{"type":"text","value":"the demo environment","position":{"start":{"line":27,"column":13,"offset":1196},"end":{"line":27,"column":33,"offset":1216},"indent":[]}}],"position":{"start":{"line":27,"column":12,"offset":1195},"end":{"line":27,"column":64,"offset":1247},"indent":[]}},{"type":"text","value":" to see and feel the Kerberos Cloud solution yourself.","position":{"start":{"line":27,"column":64,"offset":1247},"end":{"line":27,"column":118,"offset":1301},"indent":[]}}],"position":{"start":{"line":27,"column":3,"offset":1186},"end":{"line":27,"column":118,"offset":1301},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1184},"end":{"line":27,"column":118,"offset":1301},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Architecture","position":{"start":{"line":29,"column":4,"offset":1306},"end":{"line":29,"column":16,"offset":1318},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1303},"end":{"line":29,"column":16,"offset":1318},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A simplified architecture is found below. In this architecture the Kerberos agents are installed on-premise, next to the surveillance cameras. Once one of the agents recorded something it will send the recording to our AWS S3 bucket, using the credentials you've defined inside the agent.","position":{"start":{"line":31,"column":1,"offset":1320},"end":{"line":31,"column":289,"offset":1608},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1320},"end":{"line":31,"column":289,"offset":1608},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"As soon as the recording is succesfully received several engines will be executed, that will further process the recording and extract metadata from it (classification, origin of the surveillance camera, etc). A lot of processing is happening behind the scenes (by what we call microservices).","position":{"start":{"line":33,"column":1,"offset":1610},"end":{"line":33,"column":294,"offset":1903},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1610},"end":{"line":33,"column":294,"offset":1903},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By using a browser you can navigate to Kerberos Cloud, and review all the recordings made by the Kerberos agents. On top of that you will receive more context about the recordings, get notifications, view a livestream and much more.","position":{"start":{"line":35,"column":1,"offset":1905},"end":{"line":35,"column":233,"offset":2137},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1905},"end":{"line":35,"column":233,"offset":2137},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-architecture.png","alt":"cloud","position":{"start":{"line":37,"column":1,"offset":2139},"end":{"line":37,"column":56,"offset":2194},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":2139},"end":{"line":37,"column":56,"offset":2194},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Public or Private edition","position":{"start":{"line":39,"column":5,"offset":2200},"end":{"line":39,"column":30,"offset":2225},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":2196},"end":{"line":39,"column":30,"offset":2225},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"They are two different versions of using and deploying Kerberos Cloud, we have the public and private dition. What's the difference?","position":{"start":{"line":41,"column":1,"offset":2227},"end":{"line":41,"column":133,"offset":2359},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":2227},"end":{"line":41,"column":133,"offset":2359},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Public edition of Kerberos Cloud, is running all its services in what we often call the public cloud; and to be more specific on AWS and GCP. The Public cloud is mainly built for people who want to have a low cost and small scale VMS in the cloud. It's easy to (un)subscribe to the system, and you can connect your Kerberos agents in a matter of seconds.","position":{"start":{"line":43,"column":1,"offset":2361},"end":{"line":43,"column":359,"offset":2719},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2361},"end":{"line":43,"column":359,"offset":2719},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On the other hand we also have the private edition, which is available for enterprises. In contrary to the public edition, a customer can deploy the entire Kerberos Cloud platform (with all its microservices) where it wants (on-premise or cloud). Both public and private edition are built on Kubernetes, this means that you will need to\nhave a Kubernetes cluster available at the location you which to install Kerberos Cloud.","position":{"start":{"line":45,"column":1,"offset":2721},"end":{"line":46,"column":89,"offset":3146},"indent":[1]}}],"position":{"start":{"line":45,"column":1,"offset":2721},"end":{"line":46,"column":89,"offset":3146},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"For more information about the licensing of Kerberos Cloud private edition, please get in touch with cedric@verstraeten.io. The licensing model of Kerberos Cloud public edition can be found online.","position":{"start":{"line":48,"column":1,"offset":3148},"end":{"line":48,"column":198,"offset":3345},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":3148},"end":{"line":48,"column":198,"offset":3345},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Features","position":{"start":{"line":50,"column":4,"offset":3350},"end":{"line":50,"column":12,"offset":3358},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":3347},"end":{"line":50,"column":12,"offset":3358},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"So you might wonder, what's actually inside the platform? Please find a concrete list of functionalities below, this should give you more insights about how it looks like and what the capabilities are.","position":{"start":{"line":52,"column":1,"offset":3360},"end":{"line":52,"column":202,"offset":3561},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":3360},"end":{"line":52,"column":202,"offset":3561},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Secured storage","position":{"start":{"line":54,"column":4,"offset":3566},"end":{"line":54,"column":19,"offset":3581},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":3563},"end":{"line":54,"column":19,"offset":3581},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Cloud allows you to store your data in the cloud, and make it available using a secured web interface. This is how it works.","position":{"start":{"line":56,"column":1,"offset":3583},"end":{"line":56,"column":134,"offset":3716},"indent":[]}}],"position":{"start":{"line":56,"column":1,"offset":3583},"end":{"line":56,"column":134,"offset":3716},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've installed a Kerberos agent, and created an account on ","position":{"start":{"line":58,"column":1,"offset":3718},"end":{"line":58,"column":67,"offset":3784},"indent":[]}},{"type":"link","title":null,"url":"https://cloud.kerberos.io","children":[{"type":"text","value":"Kerberos Cloud","position":{"start":{"line":58,"column":68,"offset":3785},"end":{"line":58,"column":82,"offset":3799},"indent":[]}}],"position":{"start":{"line":58,"column":67,"offset":3784},"end":{"line":58,"column":110,"offset":3827},"indent":[]}},{"type":"text","value":", you will be able to connect both systems together. By entering credentials received from Kerberos Cloud, into your Kerberos agent, your media recordings will be send to our cloud storage.","position":{"start":{"line":58,"column":110,"offset":3827},"end":{"line":58,"column":299,"offset":4016},"indent":[]}}],"position":{"start":{"line":58,"column":1,"offset":3718},"end":{"line":58,"column":299,"offset":4016},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can link one or more Kerberos agents to your Kerberos Cloud account.","position":{"start":{"line":60,"column":3,"offset":4020},"end":{"line":60,"column":75,"offset":4092},"indent":[]}}],"position":{"start":{"line":60,"column":3,"offset":4020},"end":{"line":60,"column":75,"offset":4092},"indent":[]}}],"position":{"start":{"line":60,"column":1,"offset":4018},"end":{"line":60,"column":75,"offset":4092},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-linking.png","alt":"cloud linking","position":{"start":{"line":62,"column":1,"offset":4094},"end":{"line":62,"column":65,"offset":4158},"indent":[]}}],"position":{"start":{"line":62,"column":1,"offset":4094},"end":{"line":62,"column":65,"offset":4158},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"After linking your media recorded by a Kerberos agent will be send to a secure cloud storage, AWS S3 (multiple regions are supported). By default our own S3 buckets are used, however we can negotiate to have your own S3 bucket (open a support ticket).","position":{"start":{"line":64,"column":1,"offset":4160},"end":{"line":64,"column":252,"offset":4411},"indent":[]}}],"position":{"start":{"line":64,"column":1,"offset":4160},"end":{"line":64,"column":252,"offset":4411},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-network-onprem.png","alt":"cloud","position":{"start":{"line":66,"column":1,"offset":4413},"end":{"line":66,"column":58,"offset":4470},"indent":[]}}],"position":{"start":{"line":66,"column":1,"offset":4413},"end":{"line":66,"column":58,"offset":4470},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once stored your media recordings will be processed by different functions and algorithms to send alerts, apply machine learning and much more.","position":{"start":{"line":68,"column":1,"offset":4472},"end":{"line":68,"column":144,"offset":4615},"indent":[]}}],"position":{"start":{"line":68,"column":1,"offset":4472},"end":{"line":68,"column":144,"offset":4615},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Kerberos Cloud is much more than a storage service, you get intelligent capabilities as well. Read on to discover more.","position":{"start":{"line":70,"column":3,"offset":4619},"end":{"line":70,"column":122,"offset":4738},"indent":[]}}],"position":{"start":{"line":70,"column":3,"offset":4619},"end":{"line":70,"column":122,"offset":4738},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":4617},"end":{"line":70,"column":122,"offset":4738},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Consolidated overview","position":{"start":{"line":72,"column":4,"offset":4743},"end":{"line":72,"column":25,"offset":4764},"indent":[]}}],"position":{"start":{"line":72,"column":1,"offset":4740},"end":{"line":72,"column":25,"offset":4764},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Cloud will group your media recordings (coming from one or more Kerberos agents) into time bundles. We do this to simplify the searching of a specific event. Less data is shown at once, and when needed you can drill down a level deeper to see more details.","position":{"start":{"line":74,"column":1,"offset":4766},"end":{"line":74,"column":266,"offset":5031},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":4766},"end":{"line":74,"column":266,"offset":5031},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-overview.png","alt":"cloud overview","position":{"start":{"line":76,"column":1,"offset":5033},"end":{"line":76,"column":67,"offset":5099},"indent":[]}}],"position":{"start":{"line":76,"column":1,"offset":5033},"end":{"line":76,"column":67,"offset":5099},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"In a sneak peek you will see how many media recordings were generated during a certain time period, and which Kerberos agents were involved. For example, this might give you an indication of a particular event (more about in the machine learning section).","position":{"start":{"line":78,"column":1,"offset":5101},"end":{"line":78,"column":256,"offset":5356},"indent":[]}}],"position":{"start":{"line":78,"column":1,"offset":5101},"end":{"line":78,"column":256,"offset":5356},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Security","position":{"start":{"line":80,"column":5,"offset":5362},"end":{"line":80,"column":13,"offset":5370},"indent":[]}}],"position":{"start":{"line":80,"column":1,"offset":5358},"end":{"line":80,"column":13,"offset":5370},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you're inside your Kerberos Cloud account, you will see all the available media recordings of your Kerberos agents in a single interface. So how does this work?","position":{"start":{"line":82,"column":1,"offset":5372},"end":{"line":82,"column":166,"offset":5537},"indent":[]}}],"position":{"start":{"line":82,"column":1,"offset":5372},"end":{"line":82,"column":166,"offset":5537},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When you open Kerberos Cloud we will generate temporary and private links for every media recording within your account. This link includes a random and unique hash, and is only available for a couple of minutes. So this means that your recording cannot be shared afterwards, or the risk someone else accessing that link is minimised.","position":{"start":{"line":84,"column":1,"offset":5539},"end":{"line":84,"column":335,"offset":5873},"indent":[]}}],"position":{"start":{"line":84,"column":1,"offset":5539},"end":{"line":84,"column":335,"offset":5873},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Advanced searching","position":{"start":{"line":86,"column":4,"offset":5878},"end":{"line":86,"column":22,"offset":5896},"indent":[]}}],"position":{"start":{"line":86,"column":1,"offset":5875},"end":{"line":86,"column":22,"offset":5896},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Next to showing all your recordings in one overview, we also give you the capabilities to search for a recording more easily. For example you can search for recordings within a specific time boundary, recordings generated by a specific Kerberos agent, recordings which are marked as important, classified recordings such as pedestrians or animals, and more.","position":{"start":{"line":88,"column":1,"offset":5898},"end":{"line":88,"column":358,"offset":6255},"indent":[]}}],"position":{"start":{"line":88,"column":1,"offset":5898},"end":{"line":88,"column":358,"offset":6255},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-search.png","alt":"cloud search","position":{"start":{"line":90,"column":1,"offset":6257},"end":{"line":90,"column":63,"offset":6319},"indent":[]}}],"position":{"start":{"line":90,"column":1,"offset":6257},"end":{"line":90,"column":63,"offset":6319},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Machine learning","position":{"start":{"line":92,"column":4,"offset":6324},"end":{"line":92,"column":20,"offset":6340},"indent":[]}}],"position":{"start":{"line":92,"column":1,"offset":6321},"end":{"line":92,"column":20,"offset":6340},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"With Kerberos Cloud you will get far more than just a nice interface for finding back your recordings. When a recording is uploaded to Kerberos Cloud, we will execute all kind of algorithms. One of these algorithms is classification. This algorithm is used to classify/recognise all the objects inside your recording. Any human, vehicle or animal in the recording will be labeled.","position":{"start":{"line":94,"column":1,"offset":6342},"end":{"line":94,"column":381,"offset":6722},"indent":[]}}],"position":{"start":{"line":94,"column":1,"offset":6342},"end":{"line":94,"column":381,"offset":6722},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Next to classifying, the algorithm is also tracing the classified objects. By doing this we can label the recording with the object of interest. For example at the image below you see the traject of a pedestrian walking by (710 pixels).","position":{"start":{"line":96,"column":1,"offset":6724},"end":{"line":96,"column":237,"offset":6960},"indent":[]}}],"position":{"start":{"line":96,"column":1,"offset":6724},"end":{"line":96,"column":237,"offset":6960},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-ml.png","alt":"cloud ml","position":{"start":{"line":98,"column":1,"offset":6962},"end":{"line":98,"column":55,"offset":7016},"indent":[]}}],"position":{"start":{"line":98,"column":1,"offset":6962},"end":{"line":98,"column":55,"offset":7016},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Alerts","position":{"start":{"line":100,"column":4,"offset":7021},"end":{"line":100,"column":10,"offset":7027},"indent":[]}}],"position":{"start":{"line":100,"column":1,"offset":7018},"end":{"line":100,"column":10,"offset":7027},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When a specific event occurred, a notification can be send to one or more channels. A user can compose an event by selecting one or more conditions. Once the event is triggered, a notification is sent to all the enabled channels.","position":{"start":{"line":102,"column":1,"offset":7029},"end":{"line":102,"column":230,"offset":7258},"indent":[]}}],"position":{"start":{"line":102,"column":1,"offset":7029},"end":{"line":102,"column":230,"offset":7258},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Notifications","position":{"start":{"line":104,"column":5,"offset":7264},"end":{"line":104,"column":18,"offset":7277},"indent":[]}}],"position":{"start":{"line":104,"column":1,"offset":7260},"end":{"line":104,"column":18,"offset":7277},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":" Kerberos Cloud supports different types of notifications:","position":{"start":{"line":106,"column":1,"offset":7279},"end":{"line":106,"column":59,"offset":7337},"indent":[]}}],"position":{"start":{"line":106,"column":1,"offset":7279},"end":{"line":106,"column":59,"offset":7337},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Detections","position":{"start":{"line":108,"column":6,"offset":7344},"end":{"line":108,"column":16,"offset":7354},"indent":[]}}],"position":{"start":{"line":108,"column":4,"offset":7342},"end":{"line":108,"column":18,"offset":7356},"indent":[]}},{"type":"text","value":": send a notification if a recording was received from a specific Kerberos agent, within a time range, with a specific classification, etc.","position":{"start":{"line":108,"column":18,"offset":7356},"end":{"line":108,"column":157,"offset":7495},"indent":[]}}],"position":{"start":{"line":108,"column":4,"offset":7342},"end":{"line":108,"column":157,"offset":7495},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":7339},"end":{"line":108,"column":157,"offset":7495},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Devices","position":{"start":{"line":109,"column":6,"offset":7501},"end":{"line":109,"column":13,"offset":7508},"indent":[]}}],"position":{"start":{"line":109,"column":4,"offset":7499},"end":{"line":109,"column":15,"offset":7510},"indent":[]}},{"type":"text","value":": when one of your Kerberos agents stopped working, a notification can be send.","position":{"start":{"line":109,"column":15,"offset":7510},"end":{"line":109,"column":94,"offset":7589},"indent":[]}}],"position":{"start":{"line":109,"column":4,"offset":7499},"end":{"line":109,"column":94,"offset":7589},"indent":[]}}],"position":{"start":{"line":109,"column":1,"offset":7496},"end":{"line":109,"column":94,"offset":7589},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"High upload","position":{"start":{"line":110,"column":6,"offset":7595},"end":{"line":110,"column":17,"offset":7606},"indent":[]}}],"position":{"start":{"line":110,"column":4,"offset":7593},"end":{"line":110,"column":19,"offset":7608},"indent":[]}},{"type":"text","value":": when a lot of recordings are generated within a specific period of time, a notification can be send.","position":{"start":{"line":110,"column":19,"offset":7608},"end":{"line":110,"column":121,"offset":7710},"indent":[]}}],"position":{"start":{"line":110,"column":4,"offset":7593},"end":{"line":110,"column":121,"offset":7710},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":7590},"end":{"line":110,"column":121,"offset":7710},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":7339},"end":{"line":110,"column":121,"offset":7710},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-notifications.png","alt":"cloud notifications","position":{"start":{"line":112,"column":1,"offset":7712},"end":{"line":112,"column":77,"offset":7788},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":7712},"end":{"line":112,"column":77,"offset":7788},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Channels","position":{"start":{"line":114,"column":5,"offset":7794},"end":{"line":114,"column":13,"offset":7802},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":7790},"end":{"line":114,"column":13,"offset":7802},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":" Kerberos Cloud supports different types of channels, towards notifications can be send:","position":{"start":{"line":116,"column":1,"offset":7804},"end":{"line":116,"column":89,"offset":7892},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":7804},"end":{"line":116,"column":89,"offset":7892},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Browser","position":{"start":{"line":118,"column":6,"offset":7899},"end":{"line":118,"column":13,"offset":7906},"indent":[]}}],"position":{"start":{"line":118,"column":4,"offset":7897},"end":{"line":118,"column":15,"offset":7908},"indent":[]}},{"type":"text","value":": notifications inside the browser (if the used browser supports this).","position":{"start":{"line":118,"column":15,"offset":7908},"end":{"line":118,"column":86,"offset":7979},"indent":[]}}],"position":{"start":{"line":118,"column":4,"offset":7897},"end":{"line":118,"column":86,"offset":7979},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":7894},"end":{"line":118,"column":86,"offset":7979},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"E-mail","position":{"start":{"line":119,"column":6,"offset":7985},"end":{"line":119,"column":12,"offset":7991},"indent":[]}}],"position":{"start":{"line":119,"column":4,"offset":7983},"end":{"line":119,"column":14,"offset":7993},"indent":[]}},{"type":"text","value":": a personal email can be send.","position":{"start":{"line":119,"column":14,"offset":7993},"end":{"line":119,"column":45,"offset":8024},"indent":[]}}],"position":{"start":{"line":119,"column":4,"offset":7983},"end":{"line":119,"column":45,"offset":8024},"indent":[]}}],"position":{"start":{"line":119,"column":1,"offset":7980},"end":{"line":119,"column":45,"offset":8024},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Slack","position":{"start":{"line":120,"column":6,"offset":8030},"end":{"line":120,"column":11,"offset":8035},"indent":[]}}],"position":{"start":{"line":120,"column":4,"offset":8028},"end":{"line":120,"column":13,"offset":8037},"indent":[]}},{"type":"text","value":": send a message to a slack channel.","position":{"start":{"line":120,"column":13,"offset":8037},"end":{"line":120,"column":49,"offset":8073},"indent":[]}}],"position":{"start":{"line":120,"column":4,"offset":8028},"end":{"line":120,"column":49,"offset":8073},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":8025},"end":{"line":120,"column":49,"offset":8073},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Alexa","position":{"start":{"line":121,"column":6,"offset":8079},"end":{"line":121,"column":11,"offset":8084},"indent":[]}}],"position":{"start":{"line":121,"column":4,"offset":8077},"end":{"line":121,"column":13,"offset":8086},"indent":[]}},{"type":"text","value":": send a notification to Alexa skill (","position":{"start":{"line":121,"column":13,"offset":8086},"end":{"line":121,"column":51,"offset":8124},"indent":[]}},{"type":"link","title":null,"url":"https://www.amazon.com/Thomptronics-Notify-Me/dp/B07BB2FYFS","children":[{"type":"text","value":"Notify Me","position":{"start":{"line":121,"column":52,"offset":8125},"end":{"line":121,"column":61,"offset":8134},"indent":[]}}],"position":{"start":{"line":121,"column":51,"offset":8124},"end":{"line":121,"column":123,"offset":8196},"indent":[]}},{"type":"text","value":").","position":{"start":{"line":121,"column":123,"offset":8196},"end":{"line":121,"column":125,"offset":8198},"indent":[]}}],"position":{"start":{"line":121,"column":4,"offset":8077},"end":{"line":121,"column":125,"offset":8198},"indent":[]}}],"position":{"start":{"line":121,"column":1,"offset":8074},"end":{"line":121,"column":125,"offset":8198},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Telegram","position":{"start":{"line":122,"column":6,"offset":8204},"end":{"line":122,"column":14,"offset":8212},"indent":[]}}],"position":{"start":{"line":122,"column":4,"offset":8202},"end":{"line":122,"column":16,"offset":8214},"indent":[]}},{"type":"text","value":": send a message to a Telegram channel.","position":{"start":{"line":122,"column":16,"offset":8214},"end":{"line":122,"column":55,"offset":8253},"indent":[]}}],"position":{"start":{"line":122,"column":4,"offset":8202},"end":{"line":122,"column":55,"offset":8253},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":8199},"end":{"line":122,"column":55,"offset":8253},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Pushbullet","position":{"start":{"line":123,"column":6,"offset":8259},"end":{"line":123,"column":16,"offset":8269},"indent":[]}}],"position":{"start":{"line":123,"column":4,"offset":8257},"end":{"line":123,"column":18,"offset":8271},"indent":[]}},{"type":"text","value":": send a message to a Pushbullet channel.","position":{"start":{"line":123,"column":18,"offset":8271},"end":{"line":123,"column":59,"offset":8312},"indent":[]}}],"position":{"start":{"line":123,"column":4,"offset":8257},"end":{"line":123,"column":59,"offset":8312},"indent":[]}}],"position":{"start":{"line":123,"column":1,"offset":8254},"end":{"line":123,"column":59,"offset":8312},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Pushover","position":{"start":{"line":124,"column":6,"offset":8318},"end":{"line":124,"column":14,"offset":8326},"indent":[]}}],"position":{"start":{"line":124,"column":4,"offset":8316},"end":{"line":124,"column":16,"offset":8328},"indent":[]}},{"type":"text","value":": send a message to a Pushover channel.","position":{"start":{"line":124,"column":16,"offset":8328},"end":{"line":124,"column":55,"offset":8367},"indent":[]}}],"position":{"start":{"line":124,"column":4,"offset":8316},"end":{"line":124,"column":55,"offset":8367},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":8313},"end":{"line":124,"column":55,"offset":8367},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Webhook","position":{"start":{"line":125,"column":6,"offset":8373},"end":{"line":125,"column":13,"offset":8380},"indent":[]}}],"position":{"start":{"line":125,"column":4,"offset":8371},"end":{"line":125,"column":15,"offset":8382},"indent":[]}},{"type":"text","value":": trigger a webhook (POST).","position":{"start":{"line":125,"column":15,"offset":8382},"end":{"line":125,"column":42,"offset":8409},"indent":[]}}],"position":{"start":{"line":125,"column":4,"offset":8371},"end":{"line":125,"column":42,"offset":8409},"indent":[]}}],"position":{"start":{"line":125,"column":1,"offset":8368},"end":{"line":125,"column":42,"offset":8409},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"IFTTT","position":{"start":{"line":126,"column":6,"offset":8415},"end":{"line":126,"column":11,"offset":8420},"indent":[]}}],"position":{"start":{"line":126,"column":4,"offset":8413},"end":{"line":126,"column":13,"offset":8422},"indent":[]}},{"type":"text","value":": send a message to IFTTT.","position":{"start":{"line":126,"column":13,"offset":8422},"end":{"line":126,"column":39,"offset":8448},"indent":[]}}],"position":{"start":{"line":126,"column":4,"offset":8413},"end":{"line":126,"column":39,"offset":8448},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":8410},"end":{"line":126,"column":39,"offset":8448},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"SMS","position":{"start":{"line":127,"column":6,"offset":8454},"end":{"line":127,"column":9,"offset":8457},"indent":[]}}],"position":{"start":{"line":127,"column":4,"offset":8452},"end":{"line":127,"column":11,"offset":8459},"indent":[]}},{"type":"text","value":": send a text message to a mobile number.","position":{"start":{"line":127,"column":11,"offset":8459},"end":{"line":127,"column":52,"offset":8500},"indent":[]}}],"position":{"start":{"line":127,"column":4,"offset":8452},"end":{"line":127,"column":52,"offset":8500},"indent":[]}}],"position":{"start":{"line":127,"column":1,"offset":8449},"end":{"line":127,"column":52,"offset":8500},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":7894},"end":{"line":127,"column":52,"offset":8500},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-channels.png","alt":"cloud notifications","position":{"start":{"line":129,"column":1,"offset":8502},"end":{"line":129,"column":72,"offset":8573},"indent":[]}}],"position":{"start":{"line":129,"column":1,"offset":8502},"end":{"line":129,"column":72,"offset":8573},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Live streaming","position":{"start":{"line":131,"column":4,"offset":8578},"end":{"line":131,"column":18,"offset":8592},"indent":[]}}],"position":{"start":{"line":131,"column":1,"offset":8575},"end":{"line":131,"column":18,"offset":8592},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Cloud allows you to live stream from your Kerberos agents to your account. A low resolution livestream (this will be improved in future), will allow you see what is happening in front of your surveillance camera in real-time.","position":{"start":{"line":133,"column":1,"offset":8594},"end":{"line":133,"column":235,"offset":8828},"indent":[]}}],"position":{"start":{"line":133,"column":1,"offset":8594},"end":{"line":133,"column":235,"offset":8828},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-livestream.png","alt":"cloud livestream","position":{"start":{"line":135,"column":1,"offset":8830},"end":{"line":135,"column":71,"offset":8900},"indent":[]}}],"position":{"start":{"line":135,"column":1,"offset":8830},"end":{"line":135,"column":71,"offset":8900},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Accounts","position":{"start":{"line":137,"column":4,"offset":8905},"end":{"line":137,"column":12,"offset":8913},"indent":[]}}],"position":{"start":{"line":137,"column":1,"offset":8902},"end":{"line":137,"column":12,"offset":8913},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It's possible to create multiple accounts (also called subaccounts) within your main account. Their are two different roles:","position":{"start":{"line":139,"column":1,"offset":8915},"end":{"line":139,"column":125,"offset":9039},"indent":[]}}],"position":{"start":{"line":139,"column":1,"offset":8915},"end":{"line":139,"column":125,"offset":9039},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Guest: will only see your media recordings. A guest cannot modify, delete or create something.","position":{"start":{"line":141,"column":3,"offset":9043},"end":{"line":141,"column":97,"offset":9137},"indent":[]}}],"position":{"start":{"line":141,"column":3,"offset":9043},"end":{"line":141,"column":97,"offset":9137},"indent":[]}}],"position":{"start":{"line":141,"column":1,"offset":9041},"end":{"line":141,"column":97,"offset":9137},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Editor: has full access, same permissions as the main account.","position":{"start":{"line":142,"column":3,"offset":9140},"end":{"line":142,"column":65,"offset":9202},"indent":[]}}],"position":{"start":{"line":142,"column":3,"offset":9140},"end":{"line":142,"column":65,"offset":9202},"indent":[]}}],"position":{"start":{"line":142,"column":1,"offset":9138},"end":{"line":142,"column":65,"offset":9202},"indent":[]}}],"position":{"start":{"line":141,"column":1,"offset":9041},"end":{"line":142,"column":65,"offset":9202},"indent":[1]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-accounts.png","alt":"cloud accounts","position":{"start":{"line":144,"column":1,"offset":9204},"end":{"line":144,"column":67,"offset":9270},"indent":[]}}],"position":{"start":{"line":144,"column":1,"offset":9204},"end":{"line":144,"column":67,"offset":9270},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Logging","position":{"start":{"line":146,"column":4,"offset":9275},"end":{"line":146,"column":11,"offset":9282},"indent":[]}}],"position":{"start":{"line":146,"column":1,"offset":9272},"end":{"line":146,"column":11,"offset":9282},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All algorithms or functions which are applied to your recording on the Kerberos Cloud platform, are shown on the logging page. You can use this to debug.","position":{"start":{"line":148,"column":1,"offset":9284},"end":{"line":148,"column":154,"offset":9437},"indent":[]}}],"position":{"start":{"line":148,"column":1,"offset":9284},"end":{"line":148,"column":154,"offset":9437},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-logging.png","alt":"cloud logging","position":{"start":{"line":150,"column":1,"offset":9439},"end":{"line":150,"column":65,"offset":9503},"indent":[]}}],"position":{"start":{"line":150,"column":1,"offset":9439},"end":{"line":150,"column":65,"offset":9503},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":153,"column":1,"offset":9506},"end":{"line":153,"column":31,"offset":9536},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":153,"column":31,"offset":9536}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Cloud`}

\n

{`When installing a Kerberos agent inside your local network, it's possible to review your activity by using the agent's web interface. By nature, you will not be able to access the web interface from the cloud (outside your local network). On top of that, the Kerberos agent doesn't come with a consolidated overview. This means that you will need to open multiple web interfaces, one for each connected surveillance camera.`}

\n

{`To simplify and resolve all of these challenges, Kerberos Cloud was developed.`}

\n
\n

{`Kerberos Cloud`}{` is a cloud solution which allows you to have a single overview of all the media recordings generated by your surveillance cameras. It's not a solution for processing your surveillance cameras in the cloud. For processing of your surveillance cameras, a Kerberos agent is used.`}

\n
\n

{`A brief list of the key features of Kerberos Cloud are:`}

\n
    \n
  • {`Secured storage`}
  • \n
  • {`Consolidated overview`}
  • \n
  • {`Advanced searching`}
  • \n
  • {`Machine learning`}
  • \n
  • {`Alerts`}
  • \n
  • {`Live streaming`}
  • \n
  • {`Accounts`}
  • \n
  • {`Logging`}
  • \n
\n
\n

{`Checkout `}{`the demo environment`}{` to see and feel the Kerberos Cloud solution yourself.`}

\n
\n

{`Architecture`}

\n

{`A simplified architecture is found below. In this architecture the Kerberos agents are installed on-premise, next to the surveillance cameras. Once one of the agents recorded something it will send the recording to our AWS S3 bucket, using the credentials you've defined inside the agent.`}

\n

{`As soon as the recording is succesfully received several engines will be executed, that will further process the recording and extract metadata from it (classification, origin of the surveillance camera, etc). A lot of processing is happening behind the scenes (by what we call microservices).`}

\n

{`By using a browser you can navigate to Kerberos Cloud, and review all the recordings made by the Kerberos agents. On top of that you will receive more context about the recordings, get notifications, view a livestream and much more.`}

\n

\"cloud\"

\n

{`Public or Private edition`}

\n

{`They are two different versions of using and deploying Kerberos Cloud, we have the public and private dition. What's the difference?`}

\n

{`The Public edition of Kerberos Cloud, is running all its services in what we often call the public cloud; and to be more specific on AWS and GCP. The Public cloud is mainly built for people who want to have a low cost and small scale VMS in the cloud. It's easy to (un)subscribe to the system, and you can connect your Kerberos agents in a matter of seconds.`}

\n

{`On the other hand we also have the private edition, which is available for enterprises. In contrary to the public edition, a customer can deploy the entire Kerberos Cloud platform (with all its microservices) where it wants (on-premise or cloud). Both public and private edition are built on Kubernetes, this means that you will need to\nhave a Kubernetes cluster available at the location you which to install Kerberos Cloud.`}

\n

{`For more information about the licensing of Kerberos Cloud private edition, please get in touch with cedric@verstraeten.io. The licensing model of Kerberos Cloud public edition can be found online.`}

\n

{`Features`}

\n

{`So you might wonder, what's actually inside the platform? Please find a concrete list of functionalities below, this should give you more insights about how it looks like and what the capabilities are.`}

\n

{`Secured storage`}

\n

{`Kerberos Cloud allows you to store your data in the cloud, and make it available using a secured web interface. This is how it works.`}

\n

{`Once you've installed a Kerberos agent, and created an account on `}{`Kerberos Cloud`}{`, you will be able to connect both systems together. By entering credentials received from Kerberos Cloud, into your Kerberos agent, your media recordings will be send to our cloud storage.`}

\n
\n

{`You can link one or more Kerberos agents to your Kerberos Cloud account.`}

\n
\n

\"cloud

\n

{`After linking your media recorded by a Kerberos agent will be send to a secure cloud storage, AWS S3 (multiple regions are supported). By default our own S3 buckets are used, however we can negotiate to have your own S3 bucket (open a support ticket).`}

\n

\"cloud\"

\n

{`Once stored your media recordings will be processed by different functions and algorithms to send alerts, apply machine learning and much more.`}

\n
\n

{`Kerberos Cloud is much more than a storage service, you get intelligent capabilities as well. Read on to discover more.`}

\n
\n

{`Consolidated overview`}

\n

{`Kerberos Cloud will group your media recordings (coming from one or more Kerberos agents) into time bundles. We do this to simplify the searching of a specific event. Less data is shown at once, and when needed you can drill down a level deeper to see more details.`}

\n

\"cloud

\n

{`In a sneak peek you will see how many media recordings were generated during a certain time period, and which Kerberos agents were involved. For example, this might give you an indication of a particular event (more about in the machine learning section).`}

\n

{`Security`}

\n

{`Once you're inside your Kerberos Cloud account, you will see all the available media recordings of your Kerberos agents in a single interface. So how does this work?`}

\n

{`When you open Kerberos Cloud we will generate temporary and private links for every media recording within your account. This link includes a random and unique hash, and is only available for a couple of minutes. So this means that your recording cannot be shared afterwards, or the risk someone else accessing that link is minimised.`}

\n

{`Advanced searching`}

\n

{`Next to showing all your recordings in one overview, we also give you the capabilities to search for a recording more easily. For example you can search for recordings within a specific time boundary, recordings generated by a specific Kerberos agent, recordings which are marked as important, classified recordings such as pedestrians or animals, and more.`}

\n

\"cloud

\n

{`Machine learning`}

\n

{`With Kerberos Cloud you will get far more than just a nice interface for finding back your recordings. When a recording is uploaded to Kerberos Cloud, we will execute all kind of algorithms. One of these algorithms is classification. This algorithm is used to classify/recognise all the objects inside your recording. Any human, vehicle or animal in the recording will be labeled.`}

\n

{`Next to classifying, the algorithm is also tracing the classified objects. By doing this we can label the recording with the object of interest. For example at the image below you see the traject of a pedestrian walking by (710 pixels).`}

\n

\"cloud

\n

{`Alerts`}

\n

{`When a specific event occurred, a notification can be send to one or more channels. A user can compose an event by selecting one or more conditions. Once the event is triggered, a notification is sent to all the enabled channels.`}

\n

{`Notifications`}

\n

{` Kerberos Cloud supports different types of notifications:`}

\n
    \n
  • {`Detections`}{`: send a notification if a recording was received from a specific Kerberos agent, within a time range, with a specific classification, etc.`}
  • \n
  • {`Devices`}{`: when one of your Kerberos agents stopped working, a notification can be send.`}
  • \n
  • {`High upload`}{`: when a lot of recordings are generated within a specific period of time, a notification can be send.`}
  • \n
\n

\"cloud

\n

{`Channels`}

\n

{` Kerberos Cloud supports different types of channels, towards notifications can be send:`}

\n
    \n
  • {`Browser`}{`: notifications inside the browser (if the used browser supports this).`}
  • \n
  • {`E-mail`}{`: a personal email can be send.`}
  • \n
  • {`Slack`}{`: send a message to a slack channel.`}
  • \n
  • {`Alexa`}{`: send a notification to Alexa skill (`}{`Notify Me`}{`).`}
  • \n
  • {`Telegram`}{`: send a message to a Telegram channel.`}
  • \n
  • {`Pushbullet`}{`: send a message to a Pushbullet channel.`}
  • \n
  • {`Pushover`}{`: send a message to a Pushover channel.`}
  • \n
  • {`Webhook`}{`: trigger a webhook (POST).`}
  • \n
  • {`IFTTT`}{`: send a message to IFTTT.`}
  • \n
  • {`SMS`}{`: send a text message to a mobile number.`}
  • \n
\n

\"cloud

\n

{`Live streaming`}

\n

{`Kerberos Cloud allows you to live stream from your Kerberos agents to your account. A low resolution livestream (this will be improved in future), will allow you see what is happening in front of your surveillance camera in real-time.`}

\n

\"cloud

\n

{`Accounts`}

\n

{`It's possible to create multiple accounts (also called subaccounts) within your main account. Their are two different roles:`}

\n
    \n
  • {`Guest: will only see your media recordings. A guest cannot modify, delete or create something.`}
  • \n
  • {`Editor: has full access, same permissions as the main account.`}
  • \n
\n

\"cloud

\n

{`Logging`}

\n

{`All algorithms or functions which are applied to your recording on the Kerberos Cloud platform, are shown on the logging page. You can use this to debug.`}

\n

\"cloud

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974263000,"key":"gatsby-plugin-mdx-entire-payload-987cc10b856caabc7382fd42a9082629-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Cloud","position":{"start":{"line":8,"column":3,"offset":161},"end":{"line":8,"column":8,"offset":166},"indent":[]}}],"position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":8,"offset":166},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When installing a Kerberos agent inside your local network, it's possible to review your activity by using the agent's web interface. By nature, you will not be able to access the web interface from the cloud (outside your local network). On top of that, the Kerberos agent doesn't come with a consolidated overview. This means that you will need to open multiple web interfaces, one for each connected surveillance camera.","position":{"start":{"line":10,"column":1,"offset":168},"end":{"line":10,"column":424,"offset":591},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":168},"end":{"line":10,"column":424,"offset":591},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To simplify and resolve all of these challenges, Kerberos Cloud was developed.","position":{"start":{"line":12,"column":1,"offset":593},"end":{"line":12,"column":79,"offset":671},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":593},"end":{"line":12,"column":79,"offset":671},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://cloud.kerberos.io","children":[{"type":"text","value":"Kerberos Cloud","position":{"start":{"line":14,"column":4,"offset":676},"end":{"line":14,"column":18,"offset":690},"indent":[]}}],"position":{"start":{"line":14,"column":3,"offset":675},"end":{"line":14,"column":46,"offset":718},"indent":[]}},{"type":"text","value":" is a cloud solution which allows you to have a single overview of all the media recordings generated by your surveillance cameras. It's not a solution for processing your surveillance cameras in the cloud. For processing of your surveillance cameras, a Kerberos agent is used.","position":{"start":{"line":14,"column":46,"offset":718},"end":{"line":14,"column":323,"offset":995},"indent":[]}}],"position":{"start":{"line":14,"column":3,"offset":675},"end":{"line":14,"column":323,"offset":995},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":673},"end":{"line":14,"column":323,"offset":995},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A brief list of the key features of Kerberos Cloud are:","position":{"start":{"line":16,"column":1,"offset":997},"end":{"line":16,"column":56,"offset":1052},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":997},"end":{"line":16,"column":56,"offset":1052},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Secured storage","position":{"start":{"line":18,"column":3,"offset":1056},"end":{"line":18,"column":18,"offset":1071},"indent":[]}}],"position":{"start":{"line":18,"column":3,"offset":1056},"end":{"line":18,"column":18,"offset":1071},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":1054},"end":{"line":18,"column":18,"offset":1071},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Consolidated overview","position":{"start":{"line":19,"column":3,"offset":1074},"end":{"line":19,"column":24,"offset":1095},"indent":[]}}],"position":{"start":{"line":19,"column":3,"offset":1074},"end":{"line":19,"column":24,"offset":1095},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":1072},"end":{"line":19,"column":24,"offset":1095},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Advanced searching","position":{"start":{"line":20,"column":3,"offset":1098},"end":{"line":20,"column":21,"offset":1116},"indent":[]}}],"position":{"start":{"line":20,"column":3,"offset":1098},"end":{"line":20,"column":21,"offset":1116},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":1096},"end":{"line":20,"column":21,"offset":1116},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Machine learning","position":{"start":{"line":21,"column":3,"offset":1119},"end":{"line":21,"column":19,"offset":1135},"indent":[]}}],"position":{"start":{"line":21,"column":3,"offset":1119},"end":{"line":21,"column":19,"offset":1135},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":1117},"end":{"line":21,"column":19,"offset":1135},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Alerts","position":{"start":{"line":22,"column":3,"offset":1138},"end":{"line":22,"column":9,"offset":1144},"indent":[]}}],"position":{"start":{"line":22,"column":3,"offset":1138},"end":{"line":22,"column":9,"offset":1144},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1136},"end":{"line":22,"column":9,"offset":1144},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Live streaming","position":{"start":{"line":23,"column":3,"offset":1147},"end":{"line":23,"column":17,"offset":1161},"indent":[]}}],"position":{"start":{"line":23,"column":3,"offset":1147},"end":{"line":23,"column":17,"offset":1161},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":1145},"end":{"line":23,"column":17,"offset":1161},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Accounts","position":{"start":{"line":24,"column":3,"offset":1164},"end":{"line":24,"column":11,"offset":1172},"indent":[]}}],"position":{"start":{"line":24,"column":3,"offset":1164},"end":{"line":24,"column":11,"offset":1172},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1162},"end":{"line":24,"column":11,"offset":1172},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Logging","position":{"start":{"line":25,"column":3,"offset":1175},"end":{"line":25,"column":10,"offset":1182},"indent":[]}}],"position":{"start":{"line":25,"column":3,"offset":1175},"end":{"line":25,"column":10,"offset":1182},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1173},"end":{"line":25,"column":10,"offset":1182},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":1054},"end":{"line":25,"column":10,"offset":1182},"indent":[1,1,1,1,1,1,1]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Checkout ","position":{"start":{"line":27,"column":3,"offset":1186},"end":{"line":27,"column":12,"offset":1195},"indent":[]}},{"type":"link","title":null,"url":"https://app-demo.kerberos.io","children":[{"type":"text","value":"the demo environment","position":{"start":{"line":27,"column":13,"offset":1196},"end":{"line":27,"column":33,"offset":1216},"indent":[]}}],"position":{"start":{"line":27,"column":12,"offset":1195},"end":{"line":27,"column":64,"offset":1247},"indent":[]}},{"type":"text","value":" to see and feel the Kerberos Cloud solution yourself.","position":{"start":{"line":27,"column":64,"offset":1247},"end":{"line":27,"column":118,"offset":1301},"indent":[]}}],"position":{"start":{"line":27,"column":3,"offset":1186},"end":{"line":27,"column":118,"offset":1301},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1184},"end":{"line":27,"column":118,"offset":1301},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Architecture","position":{"start":{"line":29,"column":4,"offset":1306},"end":{"line":29,"column":16,"offset":1318},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1303},"end":{"line":29,"column":16,"offset":1318},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A simplified architecture is found below. In this architecture the Kerberos agents are installed on-premise, next to the surveillance cameras. Once one of the agents recorded something it will send the recording to our AWS S3 bucket, using the credentials you've defined inside the agent.","position":{"start":{"line":31,"column":1,"offset":1320},"end":{"line":31,"column":289,"offset":1608},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1320},"end":{"line":31,"column":289,"offset":1608},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"As soon as the recording is succesfully received several engines will be executed, that will further process the recording and extract metadata from it (classification, origin of the surveillance camera, etc). A lot of processing is happening behind the scenes (by what we call microservices).","position":{"start":{"line":33,"column":1,"offset":1610},"end":{"line":33,"column":294,"offset":1903},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1610},"end":{"line":33,"column":294,"offset":1903},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By using a browser you can navigate to Kerberos Cloud, and review all the recordings made by the Kerberos agents. On top of that you will receive more context about the recordings, get notifications, view a livestream and much more.","position":{"start":{"line":35,"column":1,"offset":1905},"end":{"line":35,"column":233,"offset":2137},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1905},"end":{"line":35,"column":233,"offset":2137},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-architecture.png","alt":"cloud","position":{"start":{"line":37,"column":1,"offset":2139},"end":{"line":37,"column":56,"offset":2194},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":2139},"end":{"line":37,"column":56,"offset":2194},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Public or Private edition","position":{"start":{"line":39,"column":5,"offset":2200},"end":{"line":39,"column":30,"offset":2225},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":2196},"end":{"line":39,"column":30,"offset":2225},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"They are two different versions of using and deploying Kerberos Cloud, we have the public and private dition. What's the difference?","position":{"start":{"line":41,"column":1,"offset":2227},"end":{"line":41,"column":133,"offset":2359},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":2227},"end":{"line":41,"column":133,"offset":2359},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The Public edition of Kerberos Cloud, is running all its services in what we often call the public cloud; and to be more specific on AWS and GCP. The Public cloud is mainly built for people who want to have a low cost and small scale VMS in the cloud. It's easy to (un)subscribe to the system, and you can connect your Kerberos agents in a matter of seconds.","position":{"start":{"line":43,"column":1,"offset":2361},"end":{"line":43,"column":359,"offset":2719},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2361},"end":{"line":43,"column":359,"offset":2719},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On the other hand we also have the private edition, which is available for enterprises. In contrary to the public edition, a customer can deploy the entire Kerberos Cloud platform (with all its microservices) where it wants (on-premise or cloud). Both public and private edition are built on Kubernetes, this means that you will need to\nhave a Kubernetes cluster available at the location you which to install Kerberos Cloud.","position":{"start":{"line":45,"column":1,"offset":2721},"end":{"line":46,"column":89,"offset":3146},"indent":[1]}}],"position":{"start":{"line":45,"column":1,"offset":2721},"end":{"line":46,"column":89,"offset":3146},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"For more information about the licensing of Kerberos Cloud private edition, please get in touch with cedric@verstraeten.io. The licensing model of Kerberos Cloud public edition can be found online.","position":{"start":{"line":48,"column":1,"offset":3148},"end":{"line":48,"column":198,"offset":3345},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":3148},"end":{"line":48,"column":198,"offset":3345},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Features","position":{"start":{"line":50,"column":4,"offset":3350},"end":{"line":50,"column":12,"offset":3358},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":3347},"end":{"line":50,"column":12,"offset":3358},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"So you might wonder, what's actually inside the platform? Please find a concrete list of functionalities below, this should give you more insights about how it looks like and what the capabilities are.","position":{"start":{"line":52,"column":1,"offset":3360},"end":{"line":52,"column":202,"offset":3561},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":3360},"end":{"line":52,"column":202,"offset":3561},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Secured storage","position":{"start":{"line":54,"column":4,"offset":3566},"end":{"line":54,"column":19,"offset":3581},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":3563},"end":{"line":54,"column":19,"offset":3581},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Cloud allows you to store your data in the cloud, and make it available using a secured web interface. This is how it works.","position":{"start":{"line":56,"column":1,"offset":3583},"end":{"line":56,"column":134,"offset":3716},"indent":[]}}],"position":{"start":{"line":56,"column":1,"offset":3583},"end":{"line":56,"column":134,"offset":3716},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've installed a Kerberos agent, and created an account on ","position":{"start":{"line":58,"column":1,"offset":3718},"end":{"line":58,"column":67,"offset":3784},"indent":[]}},{"type":"link","title":null,"url":"https://cloud.kerberos.io","children":[{"type":"text","value":"Kerberos Cloud","position":{"start":{"line":58,"column":68,"offset":3785},"end":{"line":58,"column":82,"offset":3799},"indent":[]}}],"position":{"start":{"line":58,"column":67,"offset":3784},"end":{"line":58,"column":110,"offset":3827},"indent":[]}},{"type":"text","value":", you will be able to connect both systems together. By entering credentials received from Kerberos Cloud, into your Kerberos agent, your media recordings will be send to our cloud storage.","position":{"start":{"line":58,"column":110,"offset":3827},"end":{"line":58,"column":299,"offset":4016},"indent":[]}}],"position":{"start":{"line":58,"column":1,"offset":3718},"end":{"line":58,"column":299,"offset":4016},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can link one or more Kerberos agents to your Kerberos Cloud account.","position":{"start":{"line":60,"column":3,"offset":4020},"end":{"line":60,"column":75,"offset":4092},"indent":[]}}],"position":{"start":{"line":60,"column":3,"offset":4020},"end":{"line":60,"column":75,"offset":4092},"indent":[]}}],"position":{"start":{"line":60,"column":1,"offset":4018},"end":{"line":60,"column":75,"offset":4092},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-linking.png","alt":"cloud linking","position":{"start":{"line":62,"column":1,"offset":4094},"end":{"line":62,"column":65,"offset":4158},"indent":[]}}],"position":{"start":{"line":62,"column":1,"offset":4094},"end":{"line":62,"column":65,"offset":4158},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"After linking your media recorded by a Kerberos agent will be send to a secure cloud storage, AWS S3 (multiple regions are supported). By default our own S3 buckets are used, however we can negotiate to have your own S3 bucket (open a support ticket).","position":{"start":{"line":64,"column":1,"offset":4160},"end":{"line":64,"column":252,"offset":4411},"indent":[]}}],"position":{"start":{"line":64,"column":1,"offset":4160},"end":{"line":64,"column":252,"offset":4411},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-network-onprem.png","alt":"cloud","position":{"start":{"line":66,"column":1,"offset":4413},"end":{"line":66,"column":58,"offset":4470},"indent":[]}}],"position":{"start":{"line":66,"column":1,"offset":4413},"end":{"line":66,"column":58,"offset":4470},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once stored your media recordings will be processed by different functions and algorithms to send alerts, apply machine learning and much more.","position":{"start":{"line":68,"column":1,"offset":4472},"end":{"line":68,"column":144,"offset":4615},"indent":[]}}],"position":{"start":{"line":68,"column":1,"offset":4472},"end":{"line":68,"column":144,"offset":4615},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Kerberos Cloud is much more than a storage service, you get intelligent capabilities as well. Read on to discover more.","position":{"start":{"line":70,"column":3,"offset":4619},"end":{"line":70,"column":122,"offset":4738},"indent":[]}}],"position":{"start":{"line":70,"column":3,"offset":4619},"end":{"line":70,"column":122,"offset":4738},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":4617},"end":{"line":70,"column":122,"offset":4738},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Consolidated overview","position":{"start":{"line":72,"column":4,"offset":4743},"end":{"line":72,"column":25,"offset":4764},"indent":[]}}],"position":{"start":{"line":72,"column":1,"offset":4740},"end":{"line":72,"column":25,"offset":4764},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Cloud will group your media recordings (coming from one or more Kerberos agents) into time bundles. We do this to simplify the searching of a specific event. Less data is shown at once, and when needed you can drill down a level deeper to see more details.","position":{"start":{"line":74,"column":1,"offset":4766},"end":{"line":74,"column":266,"offset":5031},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":4766},"end":{"line":74,"column":266,"offset":5031},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-overview.png","alt":"cloud overview","position":{"start":{"line":76,"column":1,"offset":5033},"end":{"line":76,"column":67,"offset":5099},"indent":[]}}],"position":{"start":{"line":76,"column":1,"offset":5033},"end":{"line":76,"column":67,"offset":5099},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"In a sneak peek you will see how many media recordings were generated during a certain time period, and which Kerberos agents were involved. For example, this might give you an indication of a particular event (more about in the machine learning section).","position":{"start":{"line":78,"column":1,"offset":5101},"end":{"line":78,"column":256,"offset":5356},"indent":[]}}],"position":{"start":{"line":78,"column":1,"offset":5101},"end":{"line":78,"column":256,"offset":5356},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Security","position":{"start":{"line":80,"column":5,"offset":5362},"end":{"line":80,"column":13,"offset":5370},"indent":[]}}],"position":{"start":{"line":80,"column":1,"offset":5358},"end":{"line":80,"column":13,"offset":5370},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you're inside your Kerberos Cloud account, you will see all the available media recordings of your Kerberos agents in a single interface. So how does this work?","position":{"start":{"line":82,"column":1,"offset":5372},"end":{"line":82,"column":166,"offset":5537},"indent":[]}}],"position":{"start":{"line":82,"column":1,"offset":5372},"end":{"line":82,"column":166,"offset":5537},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When you open Kerberos Cloud we will generate temporary and private links for every media recording within your account. This link includes a random and unique hash, and is only available for a couple of minutes. So this means that your recording cannot be shared afterwards, or the risk someone else accessing that link is minimised.","position":{"start":{"line":84,"column":1,"offset":5539},"end":{"line":84,"column":335,"offset":5873},"indent":[]}}],"position":{"start":{"line":84,"column":1,"offset":5539},"end":{"line":84,"column":335,"offset":5873},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Advanced searching","position":{"start":{"line":86,"column":4,"offset":5878},"end":{"line":86,"column":22,"offset":5896},"indent":[]}}],"position":{"start":{"line":86,"column":1,"offset":5875},"end":{"line":86,"column":22,"offset":5896},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Next to showing all your recordings in one overview, we also give you the capabilities to search for a recording more easily. For example you can search for recordings within a specific time boundary, recordings generated by a specific Kerberos agent, recordings which are marked as important, classified recordings such as pedestrians or animals, and more.","position":{"start":{"line":88,"column":1,"offset":5898},"end":{"line":88,"column":358,"offset":6255},"indent":[]}}],"position":{"start":{"line":88,"column":1,"offset":5898},"end":{"line":88,"column":358,"offset":6255},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-search.png","alt":"cloud search","position":{"start":{"line":90,"column":1,"offset":6257},"end":{"line":90,"column":63,"offset":6319},"indent":[]}}],"position":{"start":{"line":90,"column":1,"offset":6257},"end":{"line":90,"column":63,"offset":6319},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Machine learning","position":{"start":{"line":92,"column":4,"offset":6324},"end":{"line":92,"column":20,"offset":6340},"indent":[]}}],"position":{"start":{"line":92,"column":1,"offset":6321},"end":{"line":92,"column":20,"offset":6340},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"With Kerberos Cloud you will get far more than just a nice interface for finding back your recordings. When a recording is uploaded to Kerberos Cloud, we will execute all kind of algorithms. One of these algorithms is classification. This algorithm is used to classify/recognise all the objects inside your recording. Any human, vehicle or animal in the recording will be labeled.","position":{"start":{"line":94,"column":1,"offset":6342},"end":{"line":94,"column":381,"offset":6722},"indent":[]}}],"position":{"start":{"line":94,"column":1,"offset":6342},"end":{"line":94,"column":381,"offset":6722},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Next to classifying, the algorithm is also tracing the classified objects. By doing this we can label the recording with the object of interest. For example at the image below you see the traject of a pedestrian walking by (710 pixels).","position":{"start":{"line":96,"column":1,"offset":6724},"end":{"line":96,"column":237,"offset":6960},"indent":[]}}],"position":{"start":{"line":96,"column":1,"offset":6724},"end":{"line":96,"column":237,"offset":6960},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-ml.png","alt":"cloud ml","position":{"start":{"line":98,"column":1,"offset":6962},"end":{"line":98,"column":55,"offset":7016},"indent":[]}}],"position":{"start":{"line":98,"column":1,"offset":6962},"end":{"line":98,"column":55,"offset":7016},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Alerts","position":{"start":{"line":100,"column":4,"offset":7021},"end":{"line":100,"column":10,"offset":7027},"indent":[]}}],"position":{"start":{"line":100,"column":1,"offset":7018},"end":{"line":100,"column":10,"offset":7027},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When a specific event occurred, a notification can be send to one or more channels. A user can compose an event by selecting one or more conditions. Once the event is triggered, a notification is sent to all the enabled channels.","position":{"start":{"line":102,"column":1,"offset":7029},"end":{"line":102,"column":230,"offset":7258},"indent":[]}}],"position":{"start":{"line":102,"column":1,"offset":7029},"end":{"line":102,"column":230,"offset":7258},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Notifications","position":{"start":{"line":104,"column":5,"offset":7264},"end":{"line":104,"column":18,"offset":7277},"indent":[]}}],"position":{"start":{"line":104,"column":1,"offset":7260},"end":{"line":104,"column":18,"offset":7277},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":" Kerberos Cloud supports different types of notifications:","position":{"start":{"line":106,"column":1,"offset":7279},"end":{"line":106,"column":59,"offset":7337},"indent":[]}}],"position":{"start":{"line":106,"column":1,"offset":7279},"end":{"line":106,"column":59,"offset":7337},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Detections","position":{"start":{"line":108,"column":6,"offset":7344},"end":{"line":108,"column":16,"offset":7354},"indent":[]}}],"position":{"start":{"line":108,"column":4,"offset":7342},"end":{"line":108,"column":18,"offset":7356},"indent":[]}},{"type":"text","value":": send a notification if a recording was received from a specific Kerberos agent, within a time range, with a specific classification, etc.","position":{"start":{"line":108,"column":18,"offset":7356},"end":{"line":108,"column":157,"offset":7495},"indent":[]}}],"position":{"start":{"line":108,"column":4,"offset":7342},"end":{"line":108,"column":157,"offset":7495},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":7339},"end":{"line":108,"column":157,"offset":7495},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Devices","position":{"start":{"line":109,"column":6,"offset":7501},"end":{"line":109,"column":13,"offset":7508},"indent":[]}}],"position":{"start":{"line":109,"column":4,"offset":7499},"end":{"line":109,"column":15,"offset":7510},"indent":[]}},{"type":"text","value":": when one of your Kerberos agents stopped working, a notification can be send.","position":{"start":{"line":109,"column":15,"offset":7510},"end":{"line":109,"column":94,"offset":7589},"indent":[]}}],"position":{"start":{"line":109,"column":4,"offset":7499},"end":{"line":109,"column":94,"offset":7589},"indent":[]}}],"position":{"start":{"line":109,"column":1,"offset":7496},"end":{"line":109,"column":94,"offset":7589},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"High upload","position":{"start":{"line":110,"column":6,"offset":7595},"end":{"line":110,"column":17,"offset":7606},"indent":[]}}],"position":{"start":{"line":110,"column":4,"offset":7593},"end":{"line":110,"column":19,"offset":7608},"indent":[]}},{"type":"text","value":": when a lot of recordings are generated within a specific period of time, a notification can be send.","position":{"start":{"line":110,"column":19,"offset":7608},"end":{"line":110,"column":121,"offset":7710},"indent":[]}}],"position":{"start":{"line":110,"column":4,"offset":7593},"end":{"line":110,"column":121,"offset":7710},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":7590},"end":{"line":110,"column":121,"offset":7710},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":7339},"end":{"line":110,"column":121,"offset":7710},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-notifications.png","alt":"cloud notifications","position":{"start":{"line":112,"column":1,"offset":7712},"end":{"line":112,"column":77,"offset":7788},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":7712},"end":{"line":112,"column":77,"offset":7788},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Channels","position":{"start":{"line":114,"column":5,"offset":7794},"end":{"line":114,"column":13,"offset":7802},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":7790},"end":{"line":114,"column":13,"offset":7802},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":" Kerberos Cloud supports different types of channels, towards notifications can be send:","position":{"start":{"line":116,"column":1,"offset":7804},"end":{"line":116,"column":89,"offset":7892},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":7804},"end":{"line":116,"column":89,"offset":7892},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Browser","position":{"start":{"line":118,"column":6,"offset":7899},"end":{"line":118,"column":13,"offset":7906},"indent":[]}}],"position":{"start":{"line":118,"column":4,"offset":7897},"end":{"line":118,"column":15,"offset":7908},"indent":[]}},{"type":"text","value":": notifications inside the browser (if the used browser supports this).","position":{"start":{"line":118,"column":15,"offset":7908},"end":{"line":118,"column":86,"offset":7979},"indent":[]}}],"position":{"start":{"line":118,"column":4,"offset":7897},"end":{"line":118,"column":86,"offset":7979},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":7894},"end":{"line":118,"column":86,"offset":7979},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"E-mail","position":{"start":{"line":119,"column":6,"offset":7985},"end":{"line":119,"column":12,"offset":7991},"indent":[]}}],"position":{"start":{"line":119,"column":4,"offset":7983},"end":{"line":119,"column":14,"offset":7993},"indent":[]}},{"type":"text","value":": a personal email can be send.","position":{"start":{"line":119,"column":14,"offset":7993},"end":{"line":119,"column":45,"offset":8024},"indent":[]}}],"position":{"start":{"line":119,"column":4,"offset":7983},"end":{"line":119,"column":45,"offset":8024},"indent":[]}}],"position":{"start":{"line":119,"column":1,"offset":7980},"end":{"line":119,"column":45,"offset":8024},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Slack","position":{"start":{"line":120,"column":6,"offset":8030},"end":{"line":120,"column":11,"offset":8035},"indent":[]}}],"position":{"start":{"line":120,"column":4,"offset":8028},"end":{"line":120,"column":13,"offset":8037},"indent":[]}},{"type":"text","value":": send a message to a slack channel.","position":{"start":{"line":120,"column":13,"offset":8037},"end":{"line":120,"column":49,"offset":8073},"indent":[]}}],"position":{"start":{"line":120,"column":4,"offset":8028},"end":{"line":120,"column":49,"offset":8073},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":8025},"end":{"line":120,"column":49,"offset":8073},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Alexa","position":{"start":{"line":121,"column":6,"offset":8079},"end":{"line":121,"column":11,"offset":8084},"indent":[]}}],"position":{"start":{"line":121,"column":4,"offset":8077},"end":{"line":121,"column":13,"offset":8086},"indent":[]}},{"type":"text","value":": send a notification to Alexa skill (","position":{"start":{"line":121,"column":13,"offset":8086},"end":{"line":121,"column":51,"offset":8124},"indent":[]}},{"type":"link","title":null,"url":"https://www.amazon.com/Thomptronics-Notify-Me/dp/B07BB2FYFS","children":[{"type":"text","value":"Notify Me","position":{"start":{"line":121,"column":52,"offset":8125},"end":{"line":121,"column":61,"offset":8134},"indent":[]}}],"position":{"start":{"line":121,"column":51,"offset":8124},"end":{"line":121,"column":123,"offset":8196},"indent":[]}},{"type":"text","value":").","position":{"start":{"line":121,"column":123,"offset":8196},"end":{"line":121,"column":125,"offset":8198},"indent":[]}}],"position":{"start":{"line":121,"column":4,"offset":8077},"end":{"line":121,"column":125,"offset":8198},"indent":[]}}],"position":{"start":{"line":121,"column":1,"offset":8074},"end":{"line":121,"column":125,"offset":8198},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Telegram","position":{"start":{"line":122,"column":6,"offset":8204},"end":{"line":122,"column":14,"offset":8212},"indent":[]}}],"position":{"start":{"line":122,"column":4,"offset":8202},"end":{"line":122,"column":16,"offset":8214},"indent":[]}},{"type":"text","value":": send a message to a Telegram channel.","position":{"start":{"line":122,"column":16,"offset":8214},"end":{"line":122,"column":55,"offset":8253},"indent":[]}}],"position":{"start":{"line":122,"column":4,"offset":8202},"end":{"line":122,"column":55,"offset":8253},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":8199},"end":{"line":122,"column":55,"offset":8253},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Pushbullet","position":{"start":{"line":123,"column":6,"offset":8259},"end":{"line":123,"column":16,"offset":8269},"indent":[]}}],"position":{"start":{"line":123,"column":4,"offset":8257},"end":{"line":123,"column":18,"offset":8271},"indent":[]}},{"type":"text","value":": send a message to a Pushbullet channel.","position":{"start":{"line":123,"column":18,"offset":8271},"end":{"line":123,"column":59,"offset":8312},"indent":[]}}],"position":{"start":{"line":123,"column":4,"offset":8257},"end":{"line":123,"column":59,"offset":8312},"indent":[]}}],"position":{"start":{"line":123,"column":1,"offset":8254},"end":{"line":123,"column":59,"offset":8312},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Pushover","position":{"start":{"line":124,"column":6,"offset":8318},"end":{"line":124,"column":14,"offset":8326},"indent":[]}}],"position":{"start":{"line":124,"column":4,"offset":8316},"end":{"line":124,"column":16,"offset":8328},"indent":[]}},{"type":"text","value":": send a message to a Pushover channel.","position":{"start":{"line":124,"column":16,"offset":8328},"end":{"line":124,"column":55,"offset":8367},"indent":[]}}],"position":{"start":{"line":124,"column":4,"offset":8316},"end":{"line":124,"column":55,"offset":8367},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":8313},"end":{"line":124,"column":55,"offset":8367},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"Webhook","position":{"start":{"line":125,"column":6,"offset":8373},"end":{"line":125,"column":13,"offset":8380},"indent":[]}}],"position":{"start":{"line":125,"column":4,"offset":8371},"end":{"line":125,"column":15,"offset":8382},"indent":[]}},{"type":"text","value":": trigger a webhook (POST).","position":{"start":{"line":125,"column":15,"offset":8382},"end":{"line":125,"column":42,"offset":8409},"indent":[]}}],"position":{"start":{"line":125,"column":4,"offset":8371},"end":{"line":125,"column":42,"offset":8409},"indent":[]}}],"position":{"start":{"line":125,"column":1,"offset":8368},"end":{"line":125,"column":42,"offset":8409},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"IFTTT","position":{"start":{"line":126,"column":6,"offset":8415},"end":{"line":126,"column":11,"offset":8420},"indent":[]}}],"position":{"start":{"line":126,"column":4,"offset":8413},"end":{"line":126,"column":13,"offset":8422},"indent":[]}},{"type":"text","value":": send a message to IFTTT.","position":{"start":{"line":126,"column":13,"offset":8422},"end":{"line":126,"column":39,"offset":8448},"indent":[]}}],"position":{"start":{"line":126,"column":4,"offset":8413},"end":{"line":126,"column":39,"offset":8448},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":8410},"end":{"line":126,"column":39,"offset":8448},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"strong","children":[{"type":"text","value":"SMS","position":{"start":{"line":127,"column":6,"offset":8454},"end":{"line":127,"column":9,"offset":8457},"indent":[]}}],"position":{"start":{"line":127,"column":4,"offset":8452},"end":{"line":127,"column":11,"offset":8459},"indent":[]}},{"type":"text","value":": send a text message to a mobile number.","position":{"start":{"line":127,"column":11,"offset":8459},"end":{"line":127,"column":52,"offset":8500},"indent":[]}}],"position":{"start":{"line":127,"column":4,"offset":8452},"end":{"line":127,"column":52,"offset":8500},"indent":[]}}],"position":{"start":{"line":127,"column":1,"offset":8449},"end":{"line":127,"column":52,"offset":8500},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":7894},"end":{"line":127,"column":52,"offset":8500},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-channels.png","alt":"cloud notifications","position":{"start":{"line":129,"column":1,"offset":8502},"end":{"line":129,"column":72,"offset":8573},"indent":[]}}],"position":{"start":{"line":129,"column":1,"offset":8502},"end":{"line":129,"column":72,"offset":8573},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Live streaming","position":{"start":{"line":131,"column":4,"offset":8578},"end":{"line":131,"column":18,"offset":8592},"indent":[]}}],"position":{"start":{"line":131,"column":1,"offset":8575},"end":{"line":131,"column":18,"offset":8592},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Cloud allows you to live stream from your Kerberos agents to your account. A low resolution livestream (this will be improved in future), will allow you see what is happening in front of your surveillance camera in real-time.","position":{"start":{"line":133,"column":1,"offset":8594},"end":{"line":133,"column":235,"offset":8828},"indent":[]}}],"position":{"start":{"line":133,"column":1,"offset":8594},"end":{"line":133,"column":235,"offset":8828},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-livestream.png","alt":"cloud livestream","position":{"start":{"line":135,"column":1,"offset":8830},"end":{"line":135,"column":71,"offset":8900},"indent":[]}}],"position":{"start":{"line":135,"column":1,"offset":8830},"end":{"line":135,"column":71,"offset":8900},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Accounts","position":{"start":{"line":137,"column":4,"offset":8905},"end":{"line":137,"column":12,"offset":8913},"indent":[]}}],"position":{"start":{"line":137,"column":1,"offset":8902},"end":{"line":137,"column":12,"offset":8913},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It's possible to create multiple accounts (also called subaccounts) within your main account. Their are two different roles:","position":{"start":{"line":139,"column":1,"offset":8915},"end":{"line":139,"column":125,"offset":9039},"indent":[]}}],"position":{"start":{"line":139,"column":1,"offset":8915},"end":{"line":139,"column":125,"offset":9039},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Guest: will only see your media recordings. A guest cannot modify, delete or create something.","position":{"start":{"line":141,"column":3,"offset":9043},"end":{"line":141,"column":97,"offset":9137},"indent":[]}}],"position":{"start":{"line":141,"column":3,"offset":9043},"end":{"line":141,"column":97,"offset":9137},"indent":[]}}],"position":{"start":{"line":141,"column":1,"offset":9041},"end":{"line":141,"column":97,"offset":9137},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Editor: has full access, same permissions as the main account.","position":{"start":{"line":142,"column":3,"offset":9140},"end":{"line":142,"column":65,"offset":9202},"indent":[]}}],"position":{"start":{"line":142,"column":3,"offset":9140},"end":{"line":142,"column":65,"offset":9202},"indent":[]}}],"position":{"start":{"line":142,"column":1,"offset":9138},"end":{"line":142,"column":65,"offset":9202},"indent":[]}}],"position":{"start":{"line":141,"column":1,"offset":9041},"end":{"line":142,"column":65,"offset":9202},"indent":[1]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-accounts.png","alt":"cloud accounts","position":{"start":{"line":144,"column":1,"offset":9204},"end":{"line":144,"column":67,"offset":9270},"indent":[]}}],"position":{"start":{"line":144,"column":1,"offset":9204},"end":{"line":144,"column":67,"offset":9270},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Logging","position":{"start":{"line":146,"column":4,"offset":9275},"end":{"line":146,"column":11,"offset":9282},"indent":[]}}],"position":{"start":{"line":146,"column":1,"offset":9272},"end":{"line":146,"column":11,"offset":9282},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All algorithms or functions which are applied to your recording on the Kerberos Cloud platform, are shown on the logging page. You can use this to debug.","position":{"start":{"line":148,"column":1,"offset":9284},"end":{"line":148,"column":154,"offset":9437},"indent":[]}}],"position":{"start":{"line":148,"column":1,"offset":9284},"end":{"line":148,"column":154,"offset":9437},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kerberos-cloud-logging.png","alt":"cloud logging","position":{"start":{"line":150,"column":1,"offset":9439},"end":{"line":150,"column":65,"offset":9503},"indent":[]}}],"position":{"start":{"line":150,"column":1,"offset":9439},"end":{"line":150,"column":65,"offset":9503},"indent":[]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":153,"column":1,"offset":9506},"end":{"line":153,"column":31,"offset":9536},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":153,"column":31,"offset":9536}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n

{`Cloud`}

\n

{`When installing a Kerberos agent inside your local network, it's possible to review your activity by using the agent's web interface. By nature, you will not be able to access the web interface from the cloud (outside your local network). On top of that, the Kerberos agent doesn't come with a consolidated overview. This means that you will need to open multiple web interfaces, one for each connected surveillance camera.`}

\n

{`To simplify and resolve all of these challenges, Kerberos Cloud was developed.`}

\n
\n

{`Kerberos Cloud`}{` is a cloud solution which allows you to have a single overview of all the media recordings generated by your surveillance cameras. It's not a solution for processing your surveillance cameras in the cloud. For processing of your surveillance cameras, a Kerberos agent is used.`}

\n
\n

{`A brief list of the key features of Kerberos Cloud are:`}

\n
    \n
  • {`Secured storage`}
  • \n
  • {`Consolidated overview`}
  • \n
  • {`Advanced searching`}
  • \n
  • {`Machine learning`}
  • \n
  • {`Alerts`}
  • \n
  • {`Live streaming`}
  • \n
  • {`Accounts`}
  • \n
  • {`Logging`}
  • \n
\n
\n

{`Checkout `}{`the demo environment`}{` to see and feel the Kerberos Cloud solution yourself.`}

\n
\n

{`Architecture`}

\n

{`A simplified architecture is found below. In this architecture the Kerberos agents are installed on-premise, next to the surveillance cameras. Once one of the agents recorded something it will send the recording to our AWS S3 bucket, using the credentials you've defined inside the agent.`}

\n

{`As soon as the recording is succesfully received several engines will be executed, that will further process the recording and extract metadata from it (classification, origin of the surveillance camera, etc). A lot of processing is happening behind the scenes (by what we call microservices).`}

\n

{`By using a browser you can navigate to Kerberos Cloud, and review all the recordings made by the Kerberos agents. On top of that you will receive more context about the recordings, get notifications, view a livestream and much more.`}

\n

\"cloud\"

\n

{`Public or Private edition`}

\n

{`They are two different versions of using and deploying Kerberos Cloud, we have the public and private dition. What's the difference?`}

\n

{`The Public edition of Kerberos Cloud, is running all its services in what we often call the public cloud; and to be more specific on AWS and GCP. The Public cloud is mainly built for people who want to have a low cost and small scale VMS in the cloud. It's easy to (un)subscribe to the system, and you can connect your Kerberos agents in a matter of seconds.`}

\n

{`On the other hand we also have the private edition, which is available for enterprises. In contrary to the public edition, a customer can deploy the entire Kerberos Cloud platform (with all its microservices) where it wants (on-premise or cloud). Both public and private edition are built on Kubernetes, this means that you will need to\nhave a Kubernetes cluster available at the location you which to install Kerberos Cloud.`}

\n

{`For more information about the licensing of Kerberos Cloud private edition, please get in touch with cedric@verstraeten.io. The licensing model of Kerberos Cloud public edition can be found online.`}

\n

{`Features`}

\n

{`So you might wonder, what's actually inside the platform? Please find a concrete list of functionalities below, this should give you more insights about how it looks like and what the capabilities are.`}

\n

{`Secured storage`}

\n

{`Kerberos Cloud allows you to store your data in the cloud, and make it available using a secured web interface. This is how it works.`}

\n

{`Once you've installed a Kerberos agent, and created an account on `}{`Kerberos Cloud`}{`, you will be able to connect both systems together. By entering credentials received from Kerberos Cloud, into your Kerberos agent, your media recordings will be send to our cloud storage.`}

\n
\n

{`You can link one or more Kerberos agents to your Kerberos Cloud account.`}

\n
\n

\"cloud

\n

{`After linking your media recorded by a Kerberos agent will be send to a secure cloud storage, AWS S3 (multiple regions are supported). By default our own S3 buckets are used, however we can negotiate to have your own S3 bucket (open a support ticket).`}

\n

\"cloud\"

\n

{`Once stored your media recordings will be processed by different functions and algorithms to send alerts, apply machine learning and much more.`}

\n
\n

{`Kerberos Cloud is much more than a storage service, you get intelligent capabilities as well. Read on to discover more.`}

\n
\n

{`Consolidated overview`}

\n

{`Kerberos Cloud will group your media recordings (coming from one or more Kerberos agents) into time bundles. We do this to simplify the searching of a specific event. Less data is shown at once, and when needed you can drill down a level deeper to see more details.`}

\n

\"cloud

\n

{`In a sneak peek you will see how many media recordings were generated during a certain time period, and which Kerberos agents were involved. For example, this might give you an indication of a particular event (more about in the machine learning section).`}

\n

{`Security`}

\n

{`Once you're inside your Kerberos Cloud account, you will see all the available media recordings of your Kerberos agents in a single interface. So how does this work?`}

\n

{`When you open Kerberos Cloud we will generate temporary and private links for every media recording within your account. This link includes a random and unique hash, and is only available for a couple of minutes. So this means that your recording cannot be shared afterwards, or the risk someone else accessing that link is minimised.`}

\n

{`Advanced searching`}

\n

{`Next to showing all your recordings in one overview, we also give you the capabilities to search for a recording more easily. For example you can search for recordings within a specific time boundary, recordings generated by a specific Kerberos agent, recordings which are marked as important, classified recordings such as pedestrians or animals, and more.`}

\n

\"cloud

\n

{`Machine learning`}

\n

{`With Kerberos Cloud you will get far more than just a nice interface for finding back your recordings. When a recording is uploaded to Kerberos Cloud, we will execute all kind of algorithms. One of these algorithms is classification. This algorithm is used to classify/recognise all the objects inside your recording. Any human, vehicle or animal in the recording will be labeled.`}

\n

{`Next to classifying, the algorithm is also tracing the classified objects. By doing this we can label the recording with the object of interest. For example at the image below you see the traject of a pedestrian walking by (710 pixels).`}

\n

\"cloud

\n

{`Alerts`}

\n

{`When a specific event occurred, a notification can be send to one or more channels. A user can compose an event by selecting one or more conditions. Once the event is triggered, a notification is sent to all the enabled channels.`}

\n

{`Notifications`}

\n

{` Kerberos Cloud supports different types of notifications:`}

\n
    \n
  • {`Detections`}{`: send a notification if a recording was received from a specific Kerberos agent, within a time range, with a specific classification, etc.`}
  • \n
  • {`Devices`}{`: when one of your Kerberos agents stopped working, a notification can be send.`}
  • \n
  • {`High upload`}{`: when a lot of recordings are generated within a specific period of time, a notification can be send.`}
  • \n
\n

\"cloud

\n

{`Channels`}

\n

{` Kerberos Cloud supports different types of channels, towards notifications can be send:`}

\n
    \n
  • {`Browser`}{`: notifications inside the browser (if the used browser supports this).`}
  • \n
  • {`E-mail`}{`: a personal email can be send.`}
  • \n
  • {`Slack`}{`: send a message to a slack channel.`}
  • \n
  • {`Alexa`}{`: send a notification to Alexa skill (`}{`Notify Me`}{`).`}
  • \n
  • {`Telegram`}{`: send a message to a Telegram channel.`}
  • \n
  • {`Pushbullet`}{`: send a message to a Pushbullet channel.`}
  • \n
  • {`Pushover`}{`: send a message to a Pushover channel.`}
  • \n
  • {`Webhook`}{`: trigger a webhook (POST).`}
  • \n
  • {`IFTTT`}{`: send a message to IFTTT.`}
  • \n
  • {`SMS`}{`: send a text message to a mobile number.`}
  • \n
\n

\"cloud

\n

{`Live streaming`}

\n

{`Kerberos Cloud allows you to live stream from your Kerberos agents to your account. A low resolution livestream (this will be improved in future), will allow you see what is happening in front of your surveillance camera in real-time.`}

\n

\"cloud

\n

{`Accounts`}

\n

{`It's possible to create multiple accounts (also called subaccounts) within your main account. Their are two different roles:`}

\n
    \n
  • {`Guest: will only see your media recordings. A guest cannot modify, delete or create something.`}
  • \n
  • {`Editor: has full access, same permissions as the main account.`}
  • \n
\n

\"cloud

\n

{`Logging`}

\n

{`All algorithms or functions which are applied to your recording on the Kerberos Cloud platform, are shown on the logging page. You can use this to debug.`}

\n

\"cloud

\n\n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-d819a3072abd47de3d1d539ee0a87a44.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-d819a3072abd47de3d1d539ee0a87a44.json index b07d7c3..ee87353 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-d819a3072abd47de3d1d539ee0a87a44.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-d819a3072abd47de3d1d539ee0a87a44.json @@ -1 +1 @@ -{"expireTime":9007200841014180000,"key":"gatsby-plugin-mdx-entire-payload-5fff2e2486c2b57ea3b1c5c110cf7a7a-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":9,"offset":451},"indent":[]}}],"position":{"start":{"line":14,"column":4,"offset":446},"end":{"line":14,"column":41,"offset":483},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":14,"column":41,"offset":483},"end":{"line":14,"column":116,"offset":558},"indent":[]}}],"position":{"start":{"line":14,"column":4,"offset":446},"end":{"line":14,"column":116,"offset":558},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":116,"offset":558},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":15,"column":5,"offset":563},"end":{"line":15,"column":13,"offset":571},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":562},"end":{"line":15,"column":49,"offset":607},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":15,"column":49,"offset":607},"end":{"line":15,"column":139,"offset":697},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":562},"end":{"line":15,"column":139,"offset":697},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":559},"end":{"line":15,"column":139,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":702},"end":{"line":16,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":701},"end":{"line":16,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":742},"end":{"line":16,"column":121,"offset":818},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":701},"end":{"line":16,"column":121,"offset":818},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":698},"end":{"line":16,"column":121,"offset":818},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":17,"column":5,"offset":823},"end":{"line":17,"column":12,"offset":830},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":822},"end":{"line":17,"column":47,"offset":865},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":17,"column":47,"offset":865},"end":{"line":17,"column":179,"offset":997},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":822},"end":{"line":17,"column":179,"offset":997},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":819},"end":{"line":17,"column":179,"offset":997},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":17,"column":179,"offset":997},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":19,"column":4,"offset":1002},"end":{"line":19,"column":8,"offset":1006},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":999},"end":{"line":19,"column":8,"offset":1006},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":21,"column":1,"offset":1008},"end":{"line":21,"column":229,"offset":1236},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":1008},"end":{"line":21,"column":229,"offset":1236},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":23,"column":1,"offset":1238},"end":{"line":23,"column":197,"offset":1434},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":1238},"end":{"line":23,"column":197,"offset":1434},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":25,"column":5,"offset":1440},"end":{"line":25,"column":11,"offset":1446},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1436},"end":{"line":25,"column":11,"offset":1446},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":27,"column":1,"offset":1448},"end":{"line":27,"column":63,"offset":1510},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":27,"column":64,"offset":1511},"end":{"line":27,"column":85,"offset":1532},"indent":[]}}],"position":{"start":{"line":27,"column":63,"offset":1510},"end":{"line":27,"column":123,"offset":1570},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":27,"column":123,"offset":1570},"end":{"line":27,"column":124,"offset":1571},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1448},"end":{"line":27,"column":124,"offset":1571},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos installer","position":{"start":{"line":29,"column":5,"offset":1577},"end":{"line":29,"column":23,"offset":1595},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1573},"end":{"line":29,"column":23,"offset":1595},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":31,"column":1,"offset":1597},"end":{"line":31,"column":228,"offset":1824},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1597},"end":{"line":31,"column":228,"offset":1824},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":33,"column":1,"offset":1826},"end":{"line":33,"column":67,"offset":1892},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1826},"end":{"line":33,"column":67,"offset":1892},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":35,"column":1,"offset":1894},"end":{"line":35,"column":50,"offset":1943},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1894},"end":{"line":35,"column":50,"offset":1943},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":37,"column":3,"offset":1947},"end":{"line":37,"column":49,"offset":1993},"indent":[]}}],"position":{"start":{"line":37,"column":3,"offset":1947},"end":{"line":37,"column":49,"offset":1993},"indent":[]}}],"position":{"start":{"line":37,"column":3,"offset":1947},"end":{"line":37,"column":49,"offset":1993},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1945},"end":{"line":37,"column":49,"offset":1993},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":39,"column":5,"offset":1999},"end":{"line":39,"column":11,"offset":2005},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1995},"end":{"line":39,"column":11,"offset":2005},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":41,"column":1,"offset":2007},"end":{"line":41,"column":160,"offset":2166},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":2007},"end":{"line":41,"column":160,"offset":2166},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":43,"column":4,"offset":2171},"end":{"line":43,"column":13,"offset":2180},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":43,"column":14,"offset":2181},"end":{"line":43,"column":28,"offset":2195},"indent":[]}}],"position":{"start":{"line":43,"column":13,"offset":2180},"end":{"line":43,"column":75,"offset":2242},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":43,"column":75,"offset":2242},"end":{"line":43,"column":76,"offset":2243},"indent":[]}}],"position":{"start":{"line":43,"column":4,"offset":2171},"end":{"line":43,"column":76,"offset":2243},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2168},"end":{"line":43,"column":76,"offset":2243},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":44,"column":4,"offset":2247},"end":{"line":44,"column":41,"offset":2284},"indent":[]}}],"position":{"start":{"line":44,"column":4,"offset":2247},"end":{"line":44,"column":41,"offset":2284},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":2244},"end":{"line":44,"column":41,"offset":2284},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":45,"column":4,"offset":2288},"end":{"line":45,"column":60,"offset":2344},"indent":[]}}],"position":{"start":{"line":45,"column":4,"offset":2288},"end":{"line":45,"column":60,"offset":2344},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2285},"end":{"line":45,"column":60,"offset":2344},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2168},"end":{"line":45,"column":60,"offset":2344},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":47,"column":2,"offset":2347},"end":{"line":47,"column":64,"offset":2409},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2346},"end":{"line":47,"column":96,"offset":2441},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2346},"end":{"line":47,"column":96,"offset":2441},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":49,"column":1,"offset":2443},"end":{"line":49,"column":204,"offset":2646},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2443},"end":{"line":49,"column":204,"offset":2646},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":51,"column":6,"offset":2653},"end":{"line":51,"column":24,"offset":2671},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2648},"end":{"line":51,"column":24,"offset":2671},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":53,"column":1,"offset":2673},"end":{"line":53,"column":95,"offset":2767},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":53,"column":95,"offset":2767},"end":{"line":53,"column":110,"offset":2782},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":53,"column":110,"offset":2782},"end":{"line":53,"column":222,"offset":2894},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2673},"end":{"line":53,"column":222,"offset":2894},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":55,"column":1,"offset":2896},"end":{"line":63,"column":4,"offset":3005},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":65,"column":6,"offset":3012},"end":{"line":65,"column":31,"offset":3037},"indent":[]}}],"position":{"start":{"line":65,"column":1,"offset":3007},"end":{"line":65,"column":31,"offset":3037},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":67,"column":1,"offset":3039},"end":{"line":67,"column":79,"offset":3117},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":67,"column":79,"offset":3117},"end":{"line":67,"column":95,"offset":3133},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":67,"column":95,"offset":3133},"end":{"line":67,"column":137,"offset":3175},"indent":[]}}],"position":{"start":{"line":67,"column":1,"offset":3039},"end":{"line":67,"column":137,"offset":3175},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":69,"column":1,"offset":3177},"end":{"line":79,"column":4,"offset":3545},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":81,"column":5,"offset":3551},"end":{"line":81,"column":30,"offset":3576},"indent":[]}}],"position":{"start":{"line":81,"column":1,"offset":3547},"end":{"line":81,"column":30,"offset":3576},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":83,"column":1,"offset":3578},"end":{"line":83,"column":464,"offset":4041},"indent":[]}}],"position":{"start":{"line":83,"column":1,"offset":3578},"end":{"line":83,"column":464,"offset":4041},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":85,"column":1,"offset":4043},"end":{"line":85,"column":61,"offset":4103},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":4043},"end":{"line":85,"column":61,"offset":4103},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":87,"column":5,"offset":4109},"end":{"line":87,"column":28,"offset":4132},"indent":[]}}],"position":{"start":{"line":87,"column":1,"offset":4105},"end":{"line":87,"column":28,"offset":4132},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":89,"column":1,"offset":4134},"end":{"line":89,"column":95,"offset":4228},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":89,"column":95,"offset":4228},"end":{"line":89,"column":100,"offset":4233},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":89,"column":100,"offset":4233},"end":{"line":89,"column":101,"offset":4234},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":4134},"end":{"line":89,"column":101,"offset":4234},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":91,"column":1,"offset":4236},"end":{"line":95,"column":4,"offset":4353},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":97,"column":1,"offset":4355},"end":{"line":97,"column":80,"offset":4434},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":97,"column":80,"offset":4434},"end":{"line":97,"column":101,"offset":4455},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":97,"column":101,"offset":4455},"end":{"line":97,"column":162,"offset":4516},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4355},"end":{"line":97,"column":162,"offset":4516},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":99,"column":1,"offset":4518},"end":{"line":102,"column":4,"offset":4607},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":104,"column":4,"offset":4612},"end":{"line":104,"column":12,"offset":4620},"indent":[]}}],"position":{"start":{"line":104,"column":1,"offset":4609},"end":{"line":104,"column":12,"offset":4620},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":106,"column":1,"offset":4622},"end":{"line":106,"column":193,"offset":4814},"indent":[]}}],"position":{"start":{"line":106,"column":1,"offset":4622},"end":{"line":106,"column":193,"offset":4814},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":108,"column":4,"offset":4819},"end":{"line":108,"column":62,"offset":4877},"indent":[]}}],"position":{"start":{"line":108,"column":4,"offset":4819},"end":{"line":108,"column":62,"offset":4877},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":4816},"end":{"line":108,"column":62,"offset":4877},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":109,"column":4,"offset":4881},"end":{"line":109,"column":69,"offset":4946},"indent":[]}}],"position":{"start":{"line":109,"column":4,"offset":4881},"end":{"line":109,"column":69,"offset":4946},"indent":[]}}],"position":{"start":{"line":109,"column":1,"offset":4878},"end":{"line":109,"column":69,"offset":4946},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":4816},"end":{"line":109,"column":69,"offset":4946},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":111,"column":1,"offset":4948},"end":{"line":111,"column":99,"offset":5046},"indent":[]}}],"position":{"start":{"line":111,"column":1,"offset":4948},"end":{"line":111,"column":99,"offset":5046},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":113,"column":5,"offset":5052},"end":{"line":113,"column":14,"offset":5061},"indent":[]}}],"position":{"start":{"line":113,"column":1,"offset":5048},"end":{"line":113,"column":14,"offset":5061},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":115,"column":1,"offset":5063},"end":{"line":115,"column":71,"offset":5133},"indent":[]}}],"position":{"start":{"line":115,"column":1,"offset":5063},"end":{"line":115,"column":71,"offset":5133},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":117,"column":3,"offset":5137},"end":{"line":117,"column":47,"offset":5181},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":117,"column":47,"offset":5181},"end":{"line":117,"column":79,"offset":5213},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":117,"column":79,"offset":5213},"end":{"line":117,"column":198,"offset":5332},"indent":[]}}],"position":{"start":{"line":117,"column":3,"offset":5137},"end":{"line":117,"column":198,"offset":5332},"indent":[]}}],"position":{"start":{"line":117,"column":1,"offset":5135},"end":{"line":117,"column":198,"offset":5332},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":119,"column":1,"offset":5334},"end":{"line":121,"column":4,"offset":5397},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":123,"column":5,"offset":5403},"end":{"line":123,"column":14,"offset":5412},"indent":[]}}],"position":{"start":{"line":123,"column":1,"offset":5399},"end":{"line":123,"column":14,"offset":5412},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":125,"column":1,"offset":5414},"end":{"line":125,"column":56,"offset":5469},"indent":[]}}],"position":{"start":{"line":125,"column":1,"offset":5414},"end":{"line":125,"column":56,"offset":5469},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":126,"column":3,"offset":5472},"end":{"line":126,"column":52,"offset":5521},"indent":[]}}],"position":{"start":{"line":126,"column":3,"offset":5472},"end":{"line":126,"column":52,"offset":5521},"indent":[]}}],"position":{"start":{"line":126,"column":3,"offset":5472},"end":{"line":126,"column":52,"offset":5521},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5470},"end":{"line":126,"column":52,"offset":5521},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":128,"column":1,"offset":5523},"end":{"line":128,"column":3,"offset":5525},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":128,"column":3,"offset":5525},"end":{"line":128,"column":9,"offset":5531},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":128,"column":9,"offset":5531},"end":{"line":128,"column":223,"offset":5745},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5523},"end":{"line":128,"column":223,"offset":5745},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":130,"column":3,"offset":5749},"end":{"line":130,"column":159,"offset":5905},"indent":[]}}],"position":{"start":{"line":130,"column":3,"offset":5749},"end":{"line":130,"column":159,"offset":5905},"indent":[]}}],"position":{"start":{"line":130,"column":1,"offset":5747},"end":{"line":130,"column":159,"offset":5905},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":132,"column":1,"offset":5907},"end":{"line":135,"column":4,"offset":6084},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":137,"column":1,"offset":6086},"end":{"line":137,"column":160,"offset":6245},"indent":[]}}],"position":{"start":{"line":137,"column":1,"offset":6086},"end":{"line":137,"column":160,"offset":6245},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":139,"column":3,"offset":6249},"end":{"line":139,"column":31,"offset":6277},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":139,"column":31,"offset":6277},"end":{"line":139,"column":101,"offset":6347},"indent":[]}}],"position":{"start":{"line":139,"column":3,"offset":6249},"end":{"line":139,"column":101,"offset":6347},"indent":[]}}],"position":{"start":{"line":139,"column":1,"offset":6247},"end":{"line":139,"column":101,"offset":6347},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":141,"column":1,"offset":6349},"end":{"line":144,"column":4,"offset":6521},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":146,"column":1,"offset":6523},"end":{"line":146,"column":73,"offset":6595},"indent":[]}}],"position":{"start":{"line":146,"column":1,"offset":6523},"end":{"line":146,"column":73,"offset":6595},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":149,"column":3,"offset":6600},"end":{"line":149,"column":31,"offset":6628},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":149,"column":31,"offset":6628},"end":{"line":149,"column":101,"offset":6698},"indent":[]}}],"position":{"start":{"line":149,"column":3,"offset":6600},"end":{"line":149,"column":101,"offset":6698},"indent":[]}}],"position":{"start":{"line":149,"column":1,"offset":6598},"end":{"line":149,"column":101,"offset":6698},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":151,"column":1,"offset":6700},"end":{"line":154,"column":4,"offset":6872},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":156,"column":1,"offset":6874},"end":{"line":156,"column":62,"offset":6935},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":156,"column":63,"offset":6936},"end":{"line":156,"column":75,"offset":6948},"indent":[]}}],"position":{"start":{"line":156,"column":62,"offset":6935},"end":{"line":156,"column":143,"offset":7016},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":156,"column":143,"offset":7016},"end":{"line":156,"column":150,"offset":7023},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":156,"column":150,"offset":7023},"end":{"line":156,"column":169,"offset":7042},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":156,"column":169,"offset":7042},"end":{"line":156,"column":170,"offset":7043},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6874},"end":{"line":156,"column":170,"offset":7043},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":158,"column":1,"offset":7045},"end":{"line":160,"column":4,"offset":7072},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":162,"column":1,"offset":7074},"end":{"line":162,"column":58,"offset":7131},"indent":[]}}],"position":{"start":{"line":162,"column":1,"offset":7074},"end":{"line":162,"column":58,"offset":7131},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":164,"column":1,"offset":7133},"end":{"line":167,"column":4,"offset":7203},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":169,"column":5,"offset":7209},"end":{"line":169,"column":8,"offset":7212},"indent":[]}}],"position":{"start":{"line":169,"column":1,"offset":7205},"end":{"line":169,"column":8,"offset":7212},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":171,"column":1,"offset":7214},"end":{"line":171,"column":280,"offset":7493},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":7214},"end":{"line":171,"column":280,"offset":7493},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":173,"column":1,"offset":7495},"end":{"line":173,"column":37,"offset":7531},"indent":[]}}],"position":{"start":{"line":173,"column":1,"offset":7495},"end":{"line":173,"column":37,"offset":7531},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":175,"column":1,"offset":7533},"end":{"line":177,"column":4,"offset":7706},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":179,"column":1,"offset":7708},"end":{"line":179,"column":25,"offset":7732},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7708},"end":{"line":179,"column":25,"offset":7732},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":181,"column":1,"offset":7734},"end":{"line":184,"column":4,"offset":7838},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":186,"column":1,"offset":7840},"end":{"line":186,"column":118,"offset":7957},"indent":[]}}],"position":{"start":{"line":186,"column":1,"offset":7840},"end":{"line":186,"column":118,"offset":7957},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":188,"column":1,"offset":7959},"end":{"line":208,"column":4,"offset":8466},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":210,"column":1,"offset":8468},"end":{"line":210,"column":14,"offset":8481},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":8468},"end":{"line":210,"column":14,"offset":8481},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":212,"column":1,"offset":8483},"end":{"line":214,"column":4,"offset":8519},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":216,"column":1,"offset":8521},"end":{"line":216,"column":91,"offset":8611},"indent":[]}}],"position":{"start":{"line":216,"column":1,"offset":8521},"end":{"line":216,"column":91,"offset":8611},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":218,"column":1,"offset":8613},"end":{"line":226,"column":4,"offset":8986},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":228,"column":1,"offset":8988},"end":{"line":228,"column":145,"offset":9132},"indent":[]}}],"position":{"start":{"line":228,"column":1,"offset":8988},"end":{"line":228,"column":145,"offset":9132},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":230,"column":5,"offset":9138},"end":{"line":230,"column":17,"offset":9150},"indent":[]}}],"position":{"start":{"line":230,"column":1,"offset":9134},"end":{"line":230,"column":17,"offset":9150},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":232,"column":1,"offset":9152},"end":{"line":232,"column":300,"offset":9451},"indent":[]}}],"position":{"start":{"line":232,"column":1,"offset":9152},"end":{"line":232,"column":300,"offset":9451},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":234,"column":1,"offset":9453},"end":{"line":234,"column":178,"offset":9630},"indent":[]}}],"position":{"start":{"line":234,"column":1,"offset":9453},"end":{"line":234,"column":178,"offset":9630},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":236,"column":1,"offset":9632},"end":{"line":236,"column":48,"offset":9679},"indent":[]}}],"position":{"start":{"line":236,"column":1,"offset":9632},"end":{"line":236,"column":48,"offset":9679},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":238,"column":1,"offset":9681},"end":{"line":240,"column":4,"offset":9721},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":242,"column":1,"offset":9723},"end":{"line":242,"column":104,"offset":9826},"indent":[]}}],"position":{"start":{"line":242,"column":1,"offset":9723},"end":{"line":242,"column":104,"offset":9826},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":244,"column":1,"offset":9828},"end":{"line":252,"column":4,"offset":10098},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":254,"column":1,"offset":10100},"end":{"line":254,"column":28,"offset":10127},"indent":[]}}],"position":{"start":{"line":254,"column":1,"offset":10100},"end":{"line":254,"column":28,"offset":10127},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":256,"column":1,"offset":10129},"end":{"line":258,"column":4,"offset":10173},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":260,"column":1,"offset":10175},"end":{"line":260,"column":48,"offset":10222},"indent":[]}}],"position":{"start":{"line":260,"column":1,"offset":10175},"end":{"line":260,"column":48,"offset":10222},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":262,"column":1,"offset":10224},"end":{"line":264,"column":4,"offset":10246},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":266,"column":1,"offset":10248},"end":{"line":266,"column":72,"offset":10319},"indent":[]}}],"position":{"start":{"line":266,"column":1,"offset":10248},"end":{"line":266,"column":72,"offset":10319},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":268,"column":1,"offset":10321},"end":{"line":270,"column":4,"offset":10378},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":272,"column":4,"offset":10383},"end":{"line":272,"column":10,"offset":10389},"indent":[]}}],"position":{"start":{"line":272,"column":1,"offset":10380},"end":{"line":272,"column":10,"offset":10389},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":274,"column":1,"offset":10391},"end":{"line":274,"column":337,"offset":10727},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":274,"column":338,"offset":10728},"end":{"line":274,"column":352,"offset":10742},"indent":[]}}],"position":{"start":{"line":274,"column":337,"offset":10727},"end":{"line":274,"column":388,"offset":10778},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":274,"column":388,"offset":10778},"end":{"line":274,"column":389,"offset":10779},"indent":[]}}],"position":{"start":{"line":274,"column":1,"offset":10391},"end":{"line":274,"column":389,"offset":10779},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":276,"column":5,"offset":10785},"end":{"line":276,"column":18,"offset":10798},"indent":[]}}],"position":{"start":{"line":276,"column":1,"offset":10781},"end":{"line":276,"column":18,"offset":10798},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":278,"column":3,"offset":10802},"end":{"line":278,"column":50,"offset":10849},"indent":[]}}],"position":{"start":{"line":278,"column":3,"offset":10802},"end":{"line":278,"column":50,"offset":10849},"indent":[]}}],"position":{"start":{"line":278,"column":1,"offset":10800},"end":{"line":278,"column":50,"offset":10849},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":280,"column":5,"offset":10855},"end":{"line":280,"column":11,"offset":10861},"indent":[]}}],"position":{"start":{"line":280,"column":1,"offset":10851},"end":{"line":280,"column":11,"offset":10861},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":282,"column":1,"offset":10863},"end":{"line":282,"column":64,"offset":10926},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":282,"column":65,"offset":10927},"end":{"line":282,"column":86,"offset":10948},"indent":[]}}],"position":{"start":{"line":282,"column":64,"offset":10926},"end":{"line":282,"column":126,"offset":10988},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":282,"column":126,"offset":10988},"end":{"line":282,"column":127,"offset":10989},"indent":[]}}],"position":{"start":{"line":282,"column":1,"offset":10863},"end":{"line":282,"column":127,"offset":10989},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":284,"column":5,"offset":10995},"end":{"line":284,"column":26,"offset":11016},"indent":[]}}],"position":{"start":{"line":284,"column":1,"offset":10991},"end":{"line":284,"column":26,"offset":11016},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":286,"column":1,"offset":11018},"end":{"line":286,"column":126,"offset":11143},"indent":[]}}],"position":{"start":{"line":286,"column":1,"offset":11018},"end":{"line":286,"column":126,"offset":11143},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":288,"column":1,"offset":11145},"end":{"line":290,"column":4,"offset":11184},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":292,"column":1,"offset":11186},"end":{"line":292,"column":187,"offset":11372},"indent":[]}}],"position":{"start":{"line":292,"column":1,"offset":11186},"end":{"line":292,"column":187,"offset":11372},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":294,"column":1,"offset":11374},"end":{"line":296,"column":4,"offset":11452},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":298,"column":1,"offset":11454},"end":{"line":298,"column":153,"offset":11606},"indent":[]}}],"position":{"start":{"line":298,"column":1,"offset":11454},"end":{"line":298,"column":153,"offset":11606},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":300,"column":1,"offset":11608},"end":{"line":303,"column":4,"offset":11755},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":305,"column":1,"offset":11757},"end":{"line":305,"column":100,"offset":11856},"indent":[]}}],"position":{"start":{"line":305,"column":1,"offset":11757},"end":{"line":305,"column":100,"offset":11856},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":306,"column":1,"offset":11857},"end":{"line":310,"column":4,"offset":11926},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":312,"column":5,"offset":11932},"end":{"line":312,"column":12,"offset":11939},"indent":[]}}],"position":{"start":{"line":312,"column":1,"offset":11928},"end":{"line":312,"column":12,"offset":11939},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":314,"column":1,"offset":11941},"end":{"line":314,"column":64,"offset":12004},"indent":[]}}],"position":{"start":{"line":314,"column":1,"offset":11941},"end":{"line":314,"column":64,"offset":12004},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":315,"column":3,"offset":12007},"end":{"line":315,"column":25,"offset":12029},"indent":[]}}],"position":{"start":{"line":315,"column":3,"offset":12007},"end":{"line":315,"column":25,"offset":12029},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12005},"end":{"line":315,"column":25,"offset":12029},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":316,"column":3,"offset":12032},"end":{"line":316,"column":59,"offset":12088},"indent":[]}}],"position":{"start":{"line":316,"column":3,"offset":12032},"end":{"line":316,"column":59,"offset":12088},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12030},"end":{"line":316,"column":59,"offset":12088},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12005},"end":{"line":316,"column":59,"offset":12088},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":318,"column":4,"offset":12093},"end":{"line":318,"column":11,"offset":12100},"indent":[]}}],"position":{"start":{"line":318,"column":1,"offset":12090},"end":{"line":318,"column":11,"offset":12100},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":320,"column":1,"offset":12102},"end":{"line":320,"column":283,"offset":12384},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":12102},"end":{"line":320,"column":283,"offset":12384},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":322,"column":3,"offset":12388},"end":{"line":322,"column":54,"offset":12439},"indent":[]}}],"position":{"start":{"line":322,"column":3,"offset":12388},"end":{"line":322,"column":54,"offset":12439},"indent":[]}}],"position":{"start":{"line":322,"column":1,"offset":12386},"end":{"line":322,"column":54,"offset":12439},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":324,"column":5,"offset":12445},"end":{"line":324,"column":14,"offset":12454},"indent":[]}}],"position":{"start":{"line":324,"column":1,"offset":12441},"end":{"line":324,"column":14,"offset":12454},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":326,"column":1,"offset":12456},"end":{"line":326,"column":68,"offset":12523},"indent":[]}}],"position":{"start":{"line":326,"column":1,"offset":12456},"end":{"line":326,"column":68,"offset":12523},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":328,"column":1,"offset":12525},"end":{"line":331,"column":4,"offset":12676},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":333,"column":1,"offset":12678},"end":{"line":333,"column":46,"offset":12723},"indent":[]}}],"position":{"start":{"line":333,"column":1,"offset":12678},"end":{"line":333,"column":46,"offset":12723},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":335,"column":3,"offset":12727},"end":{"line":335,"column":103,"offset":12827},"indent":[]}}],"position":{"start":{"line":335,"column":3,"offset":12727},"end":{"line":335,"column":103,"offset":12827},"indent":[]}}],"position":{"start":{"line":335,"column":1,"offset":12725},"end":{"line":335,"column":103,"offset":12827},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":337,"column":1,"offset":12829},"end":{"line":342,"column":4,"offset":13039},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":344,"column":1,"offset":13041},"end":{"line":344,"column":151,"offset":13191},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13041},"end":{"line":344,"column":151,"offset":13191},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":346,"column":3,"offset":13195},"end":{"line":346,"column":22,"offset":13214},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":346,"column":22,"offset":13214},"end":{"line":346,"column":26,"offset":13218},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":346,"column":26,"offset":13218},"end":{"line":346,"column":40,"offset":13232},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":346,"column":40,"offset":13232},"end":{"line":346,"column":50,"offset":13242},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":346,"column":50,"offset":13242},"end":{"line":346,"column":98,"offset":13290},"indent":[]}}],"position":{"start":{"line":346,"column":3,"offset":13195},"end":{"line":346,"column":98,"offset":13290},"indent":[]}}],"position":{"start":{"line":346,"column":1,"offset":13193},"end":{"line":346,"column":98,"offset":13290},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":348,"column":1,"offset":13292},"end":{"line":352,"column":4,"offset":13454},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":354,"column":1,"offset":13456},"end":{"line":354,"column":72,"offset":13527},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":354,"column":72,"offset":13527},"end":{"line":354,"column":84,"offset":13539},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":354,"column":84,"offset":13539},"end":{"line":354,"column":102,"offset":13557},"indent":[]}}],"position":{"start":{"line":354,"column":1,"offset":13456},"end":{"line":354,"column":102,"offset":13557},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":356,"column":1,"offset":13559},"end":{"line":359,"column":4,"offset":13633},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":361,"column":5,"offset":13639},"end":{"line":361,"column":8,"offset":13642},"indent":[]}}],"position":{"start":{"line":361,"column":1,"offset":13635},"end":{"line":361,"column":8,"offset":13642},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":363,"column":1,"offset":13644},"end":{"line":363,"column":176,"offset":13819},"indent":[]}}],"position":{"start":{"line":363,"column":1,"offset":13644},"end":{"line":363,"column":176,"offset":13819},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":365,"column":1,"offset":13821},"end":{"line":372,"column":4,"offset":14118},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":374,"column":1,"offset":14120},"end":{"line":374,"column":60,"offset":14179},"indent":[]}}],"position":{"start":{"line":374,"column":1,"offset":14120},"end":{"line":374,"column":60,"offset":14179},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":376,"column":1,"offset":14181},"end":{"line":380,"column":4,"offset":14307},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":382,"column":1,"offset":14309},"end":{"line":382,"column":63,"offset":14371},"indent":[]}}],"position":{"start":{"line":382,"column":1,"offset":14309},"end":{"line":382,"column":63,"offset":14371},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":384,"column":1,"offset":14373},"end":{"line":404,"column":4,"offset":14880},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":406,"column":1,"offset":14882},"end":{"line":406,"column":99,"offset":14980},"indent":[]}}],"position":{"start":{"line":406,"column":1,"offset":14882},"end":{"line":406,"column":99,"offset":14980},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":408,"column":1,"offset":14982},"end":{"line":411,"column":4,"offset":15084},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":413,"column":1,"offset":15086},"end":{"line":413,"column":37,"offset":15122},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":413,"column":37,"offset":15122},"end":{"line":413,"column":47,"offset":15132},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":413,"column":47,"offset":15132},"end":{"line":413,"column":89,"offset":15174},"indent":[]}}],"position":{"start":{"line":413,"column":1,"offset":15086},"end":{"line":413,"column":89,"offset":15174},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":415,"column":1,"offset":15176},"end":{"line":419,"column":4,"offset":15301},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":421,"column":1,"offset":15303},"end":{"line":421,"column":78,"offset":15380},"indent":[]}}],"position":{"start":{"line":421,"column":1,"offset":15303},"end":{"line":421,"column":78,"offset":15380},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":423,"column":1,"offset":15382},"end":{"line":427,"column":4,"offset":15486},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":429,"column":1,"offset":15488},"end":{"line":429,"column":75,"offset":15562},"indent":[]}}],"position":{"start":{"line":429,"column":1,"offset":15488},"end":{"line":429,"column":75,"offset":15562},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":431,"column":1,"offset":15564},"end":{"line":435,"column":4,"offset":15637},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":437,"column":1,"offset":15639},"end":{"line":437,"column":145,"offset":15783},"indent":[]}}],"position":{"start":{"line":437,"column":1,"offset":15639},"end":{"line":437,"column":145,"offset":15783},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":439,"column":5,"offset":15789},"end":{"line":439,"column":17,"offset":15801},"indent":[]}}],"position":{"start":{"line":439,"column":1,"offset":15785},"end":{"line":439,"column":17,"offset":15801},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":441,"column":1,"offset":15803},"end":{"line":441,"column":300,"offset":16102},"indent":[]}}],"position":{"start":{"line":441,"column":1,"offset":15803},"end":{"line":441,"column":300,"offset":16102},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":443,"column":1,"offset":16104},"end":{"line":443,"column":178,"offset":16281},"indent":[]}}],"position":{"start":{"line":443,"column":1,"offset":16104},"end":{"line":443,"column":178,"offset":16281},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":445,"column":1,"offset":16283},"end":{"line":445,"column":48,"offset":16330},"indent":[]}}],"position":{"start":{"line":445,"column":1,"offset":16283},"end":{"line":445,"column":48,"offset":16330},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":447,"column":1,"offset":16332},"end":{"line":449,"column":4,"offset":16376},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":451,"column":1,"offset":16378},"end":{"line":451,"column":104,"offset":16481},"indent":[]}}],"position":{"start":{"line":451,"column":1,"offset":16378},"end":{"line":451,"column":104,"offset":16481},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":453,"column":1,"offset":16483},"end":{"line":461,"column":4,"offset":16753},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":463,"column":1,"offset":16755},"end":{"line":463,"column":28,"offset":16782},"indent":[]}}],"position":{"start":{"line":463,"column":1,"offset":16755},"end":{"line":463,"column":28,"offset":16782},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":465,"column":1,"offset":16784},"end":{"line":467,"column":4,"offset":16832},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":469,"column":1,"offset":16834},"end":{"line":469,"column":48,"offset":16881},"indent":[]}}],"position":{"start":{"line":469,"column":1,"offset":16834},"end":{"line":469,"column":48,"offset":16881},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":471,"column":1,"offset":16883},"end":{"line":473,"column":4,"offset":16905},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":475,"column":1,"offset":16907},"end":{"line":475,"column":72,"offset":16978},"indent":[]}}],"position":{"start":{"line":475,"column":1,"offset":16907},"end":{"line":475,"column":72,"offset":16978},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":477,"column":1,"offset":16980},"end":{"line":479,"column":4,"offset":17041},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":482,"column":1,"offset":17044},"end":{"line":482,"column":31,"offset":17074},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":482,"column":31,"offset":17074}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  4. \n
  5. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  6. \n
  7. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  8. \n
\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Docker`}

\n

{`A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974269000,"key":"gatsby-plugin-mdx-entire-payload-5fff2e2486c2b57ea3b1c5c110cf7a7a-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":9,"offset":451},"indent":[]}}],"position":{"start":{"line":14,"column":4,"offset":446},"end":{"line":14,"column":41,"offset":483},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":14,"column":41,"offset":483},"end":{"line":14,"column":116,"offset":558},"indent":[]}}],"position":{"start":{"line":14,"column":4,"offset":446},"end":{"line":14,"column":116,"offset":558},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":116,"offset":558},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":15,"column":5,"offset":563},"end":{"line":15,"column":13,"offset":571},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":562},"end":{"line":15,"column":49,"offset":607},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":15,"column":49,"offset":607},"end":{"line":15,"column":139,"offset":697},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":562},"end":{"line":15,"column":139,"offset":697},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":559},"end":{"line":15,"column":139,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":702},"end":{"line":16,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":701},"end":{"line":16,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":742},"end":{"line":16,"column":121,"offset":818},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":701},"end":{"line":16,"column":121,"offset":818},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":698},"end":{"line":16,"column":121,"offset":818},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":17,"column":5,"offset":823},"end":{"line":17,"column":12,"offset":830},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":822},"end":{"line":17,"column":47,"offset":865},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":17,"column":47,"offset":865},"end":{"line":17,"column":179,"offset":997},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":822},"end":{"line":17,"column":179,"offset":997},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":819},"end":{"line":17,"column":179,"offset":997},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":17,"column":179,"offset":997},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":19,"column":4,"offset":1002},"end":{"line":19,"column":8,"offset":1006},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":999},"end":{"line":19,"column":8,"offset":1006},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":21,"column":1,"offset":1008},"end":{"line":21,"column":229,"offset":1236},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":1008},"end":{"line":21,"column":229,"offset":1236},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":23,"column":1,"offset":1238},"end":{"line":23,"column":197,"offset":1434},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":1238},"end":{"line":23,"column":197,"offset":1434},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":25,"column":5,"offset":1440},"end":{"line":25,"column":11,"offset":1446},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1436},"end":{"line":25,"column":11,"offset":1446},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":27,"column":1,"offset":1448},"end":{"line":27,"column":63,"offset":1510},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":27,"column":64,"offset":1511},"end":{"line":27,"column":85,"offset":1532},"indent":[]}}],"position":{"start":{"line":27,"column":63,"offset":1510},"end":{"line":27,"column":123,"offset":1570},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":27,"column":123,"offset":1570},"end":{"line":27,"column":124,"offset":1571},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1448},"end":{"line":27,"column":124,"offset":1571},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos installer","position":{"start":{"line":29,"column":5,"offset":1577},"end":{"line":29,"column":23,"offset":1595},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1573},"end":{"line":29,"column":23,"offset":1595},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":31,"column":1,"offset":1597},"end":{"line":31,"column":228,"offset":1824},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1597},"end":{"line":31,"column":228,"offset":1824},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":33,"column":1,"offset":1826},"end":{"line":33,"column":67,"offset":1892},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1826},"end":{"line":33,"column":67,"offset":1892},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":35,"column":1,"offset":1894},"end":{"line":35,"column":50,"offset":1943},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1894},"end":{"line":35,"column":50,"offset":1943},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":37,"column":3,"offset":1947},"end":{"line":37,"column":49,"offset":1993},"indent":[]}}],"position":{"start":{"line":37,"column":3,"offset":1947},"end":{"line":37,"column":49,"offset":1993},"indent":[]}}],"position":{"start":{"line":37,"column":3,"offset":1947},"end":{"line":37,"column":49,"offset":1993},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1945},"end":{"line":37,"column":49,"offset":1993},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":39,"column":5,"offset":1999},"end":{"line":39,"column":11,"offset":2005},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1995},"end":{"line":39,"column":11,"offset":2005},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":41,"column":1,"offset":2007},"end":{"line":41,"column":160,"offset":2166},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":2007},"end":{"line":41,"column":160,"offset":2166},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":43,"column":4,"offset":2171},"end":{"line":43,"column":13,"offset":2180},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":43,"column":14,"offset":2181},"end":{"line":43,"column":28,"offset":2195},"indent":[]}}],"position":{"start":{"line":43,"column":13,"offset":2180},"end":{"line":43,"column":75,"offset":2242},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":43,"column":75,"offset":2242},"end":{"line":43,"column":76,"offset":2243},"indent":[]}}],"position":{"start":{"line":43,"column":4,"offset":2171},"end":{"line":43,"column":76,"offset":2243},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2168},"end":{"line":43,"column":76,"offset":2243},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":44,"column":4,"offset":2247},"end":{"line":44,"column":41,"offset":2284},"indent":[]}}],"position":{"start":{"line":44,"column":4,"offset":2247},"end":{"line":44,"column":41,"offset":2284},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":2244},"end":{"line":44,"column":41,"offset":2284},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":45,"column":4,"offset":2288},"end":{"line":45,"column":60,"offset":2344},"indent":[]}}],"position":{"start":{"line":45,"column":4,"offset":2288},"end":{"line":45,"column":60,"offset":2344},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2285},"end":{"line":45,"column":60,"offset":2344},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2168},"end":{"line":45,"column":60,"offset":2344},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":47,"column":2,"offset":2347},"end":{"line":47,"column":64,"offset":2409},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2346},"end":{"line":47,"column":96,"offset":2441},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2346},"end":{"line":47,"column":96,"offset":2441},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":49,"column":1,"offset":2443},"end":{"line":49,"column":204,"offset":2646},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2443},"end":{"line":49,"column":204,"offset":2646},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":51,"column":6,"offset":2653},"end":{"line":51,"column":24,"offset":2671},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2648},"end":{"line":51,"column":24,"offset":2671},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":53,"column":1,"offset":2673},"end":{"line":53,"column":95,"offset":2767},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":53,"column":95,"offset":2767},"end":{"line":53,"column":110,"offset":2782},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":53,"column":110,"offset":2782},"end":{"line":53,"column":222,"offset":2894},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2673},"end":{"line":53,"column":222,"offset":2894},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":55,"column":1,"offset":2896},"end":{"line":63,"column":4,"offset":3005},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":65,"column":6,"offset":3012},"end":{"line":65,"column":31,"offset":3037},"indent":[]}}],"position":{"start":{"line":65,"column":1,"offset":3007},"end":{"line":65,"column":31,"offset":3037},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":67,"column":1,"offset":3039},"end":{"line":67,"column":79,"offset":3117},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":67,"column":79,"offset":3117},"end":{"line":67,"column":95,"offset":3133},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":67,"column":95,"offset":3133},"end":{"line":67,"column":137,"offset":3175},"indent":[]}}],"position":{"start":{"line":67,"column":1,"offset":3039},"end":{"line":67,"column":137,"offset":3175},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":69,"column":1,"offset":3177},"end":{"line":79,"column":4,"offset":3545},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":81,"column":5,"offset":3551},"end":{"line":81,"column":30,"offset":3576},"indent":[]}}],"position":{"start":{"line":81,"column":1,"offset":3547},"end":{"line":81,"column":30,"offset":3576},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":83,"column":1,"offset":3578},"end":{"line":83,"column":464,"offset":4041},"indent":[]}}],"position":{"start":{"line":83,"column":1,"offset":3578},"end":{"line":83,"column":464,"offset":4041},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":85,"column":1,"offset":4043},"end":{"line":85,"column":61,"offset":4103},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":4043},"end":{"line":85,"column":61,"offset":4103},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":87,"column":5,"offset":4109},"end":{"line":87,"column":28,"offset":4132},"indent":[]}}],"position":{"start":{"line":87,"column":1,"offset":4105},"end":{"line":87,"column":28,"offset":4132},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":89,"column":1,"offset":4134},"end":{"line":89,"column":95,"offset":4228},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":89,"column":95,"offset":4228},"end":{"line":89,"column":100,"offset":4233},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":89,"column":100,"offset":4233},"end":{"line":89,"column":101,"offset":4234},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":4134},"end":{"line":89,"column":101,"offset":4234},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":91,"column":1,"offset":4236},"end":{"line":95,"column":4,"offset":4353},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":97,"column":1,"offset":4355},"end":{"line":97,"column":80,"offset":4434},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":97,"column":80,"offset":4434},"end":{"line":97,"column":101,"offset":4455},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":97,"column":101,"offset":4455},"end":{"line":97,"column":162,"offset":4516},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4355},"end":{"line":97,"column":162,"offset":4516},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":99,"column":1,"offset":4518},"end":{"line":102,"column":4,"offset":4607},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":104,"column":4,"offset":4612},"end":{"line":104,"column":12,"offset":4620},"indent":[]}}],"position":{"start":{"line":104,"column":1,"offset":4609},"end":{"line":104,"column":12,"offset":4620},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":106,"column":1,"offset":4622},"end":{"line":106,"column":193,"offset":4814},"indent":[]}}],"position":{"start":{"line":106,"column":1,"offset":4622},"end":{"line":106,"column":193,"offset":4814},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":108,"column":4,"offset":4819},"end":{"line":108,"column":62,"offset":4877},"indent":[]}}],"position":{"start":{"line":108,"column":4,"offset":4819},"end":{"line":108,"column":62,"offset":4877},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":4816},"end":{"line":108,"column":62,"offset":4877},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":109,"column":4,"offset":4881},"end":{"line":109,"column":69,"offset":4946},"indent":[]}}],"position":{"start":{"line":109,"column":4,"offset":4881},"end":{"line":109,"column":69,"offset":4946},"indent":[]}}],"position":{"start":{"line":109,"column":1,"offset":4878},"end":{"line":109,"column":69,"offset":4946},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":4816},"end":{"line":109,"column":69,"offset":4946},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":111,"column":1,"offset":4948},"end":{"line":111,"column":99,"offset":5046},"indent":[]}}],"position":{"start":{"line":111,"column":1,"offset":4948},"end":{"line":111,"column":99,"offset":5046},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":113,"column":5,"offset":5052},"end":{"line":113,"column":14,"offset":5061},"indent":[]}}],"position":{"start":{"line":113,"column":1,"offset":5048},"end":{"line":113,"column":14,"offset":5061},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":115,"column":1,"offset":5063},"end":{"line":115,"column":71,"offset":5133},"indent":[]}}],"position":{"start":{"line":115,"column":1,"offset":5063},"end":{"line":115,"column":71,"offset":5133},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":117,"column":3,"offset":5137},"end":{"line":117,"column":47,"offset":5181},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":117,"column":47,"offset":5181},"end":{"line":117,"column":79,"offset":5213},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":117,"column":79,"offset":5213},"end":{"line":117,"column":198,"offset":5332},"indent":[]}}],"position":{"start":{"line":117,"column":3,"offset":5137},"end":{"line":117,"column":198,"offset":5332},"indent":[]}}],"position":{"start":{"line":117,"column":1,"offset":5135},"end":{"line":117,"column":198,"offset":5332},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":119,"column":1,"offset":5334},"end":{"line":121,"column":4,"offset":5397},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":123,"column":5,"offset":5403},"end":{"line":123,"column":14,"offset":5412},"indent":[]}}],"position":{"start":{"line":123,"column":1,"offset":5399},"end":{"line":123,"column":14,"offset":5412},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":125,"column":1,"offset":5414},"end":{"line":125,"column":56,"offset":5469},"indent":[]}}],"position":{"start":{"line":125,"column":1,"offset":5414},"end":{"line":125,"column":56,"offset":5469},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":126,"column":3,"offset":5472},"end":{"line":126,"column":52,"offset":5521},"indent":[]}}],"position":{"start":{"line":126,"column":3,"offset":5472},"end":{"line":126,"column":52,"offset":5521},"indent":[]}}],"position":{"start":{"line":126,"column":3,"offset":5472},"end":{"line":126,"column":52,"offset":5521},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5470},"end":{"line":126,"column":52,"offset":5521},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":128,"column":1,"offset":5523},"end":{"line":128,"column":3,"offset":5525},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":128,"column":3,"offset":5525},"end":{"line":128,"column":9,"offset":5531},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":128,"column":9,"offset":5531},"end":{"line":128,"column":223,"offset":5745},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5523},"end":{"line":128,"column":223,"offset":5745},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":130,"column":3,"offset":5749},"end":{"line":130,"column":159,"offset":5905},"indent":[]}}],"position":{"start":{"line":130,"column":3,"offset":5749},"end":{"line":130,"column":159,"offset":5905},"indent":[]}}],"position":{"start":{"line":130,"column":1,"offset":5747},"end":{"line":130,"column":159,"offset":5905},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":132,"column":1,"offset":5907},"end":{"line":135,"column":4,"offset":6084},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":137,"column":1,"offset":6086},"end":{"line":137,"column":160,"offset":6245},"indent":[]}}],"position":{"start":{"line":137,"column":1,"offset":6086},"end":{"line":137,"column":160,"offset":6245},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":139,"column":3,"offset":6249},"end":{"line":139,"column":31,"offset":6277},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":139,"column":31,"offset":6277},"end":{"line":139,"column":101,"offset":6347},"indent":[]}}],"position":{"start":{"line":139,"column":3,"offset":6249},"end":{"line":139,"column":101,"offset":6347},"indent":[]}}],"position":{"start":{"line":139,"column":1,"offset":6247},"end":{"line":139,"column":101,"offset":6347},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":141,"column":1,"offset":6349},"end":{"line":144,"column":4,"offset":6521},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":146,"column":1,"offset":6523},"end":{"line":146,"column":73,"offset":6595},"indent":[]}}],"position":{"start":{"line":146,"column":1,"offset":6523},"end":{"line":146,"column":73,"offset":6595},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":149,"column":3,"offset":6600},"end":{"line":149,"column":31,"offset":6628},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":149,"column":31,"offset":6628},"end":{"line":149,"column":101,"offset":6698},"indent":[]}}],"position":{"start":{"line":149,"column":3,"offset":6600},"end":{"line":149,"column":101,"offset":6698},"indent":[]}}],"position":{"start":{"line":149,"column":1,"offset":6598},"end":{"line":149,"column":101,"offset":6698},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":151,"column":1,"offset":6700},"end":{"line":154,"column":4,"offset":6872},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":156,"column":1,"offset":6874},"end":{"line":156,"column":62,"offset":6935},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":156,"column":63,"offset":6936},"end":{"line":156,"column":75,"offset":6948},"indent":[]}}],"position":{"start":{"line":156,"column":62,"offset":6935},"end":{"line":156,"column":143,"offset":7016},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":156,"column":143,"offset":7016},"end":{"line":156,"column":150,"offset":7023},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":156,"column":150,"offset":7023},"end":{"line":156,"column":169,"offset":7042},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":156,"column":169,"offset":7042},"end":{"line":156,"column":170,"offset":7043},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6874},"end":{"line":156,"column":170,"offset":7043},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":158,"column":1,"offset":7045},"end":{"line":160,"column":4,"offset":7072},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":162,"column":1,"offset":7074},"end":{"line":162,"column":58,"offset":7131},"indent":[]}}],"position":{"start":{"line":162,"column":1,"offset":7074},"end":{"line":162,"column":58,"offset":7131},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":164,"column":1,"offset":7133},"end":{"line":167,"column":4,"offset":7203},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":169,"column":5,"offset":7209},"end":{"line":169,"column":8,"offset":7212},"indent":[]}}],"position":{"start":{"line":169,"column":1,"offset":7205},"end":{"line":169,"column":8,"offset":7212},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":171,"column":1,"offset":7214},"end":{"line":171,"column":280,"offset":7493},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":7214},"end":{"line":171,"column":280,"offset":7493},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":173,"column":1,"offset":7495},"end":{"line":173,"column":37,"offset":7531},"indent":[]}}],"position":{"start":{"line":173,"column":1,"offset":7495},"end":{"line":173,"column":37,"offset":7531},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":175,"column":1,"offset":7533},"end":{"line":177,"column":4,"offset":7706},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":179,"column":1,"offset":7708},"end":{"line":179,"column":25,"offset":7732},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7708},"end":{"line":179,"column":25,"offset":7732},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":181,"column":1,"offset":7734},"end":{"line":184,"column":4,"offset":7838},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":186,"column":1,"offset":7840},"end":{"line":186,"column":118,"offset":7957},"indent":[]}}],"position":{"start":{"line":186,"column":1,"offset":7840},"end":{"line":186,"column":118,"offset":7957},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":188,"column":1,"offset":7959},"end":{"line":208,"column":4,"offset":8466},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":210,"column":1,"offset":8468},"end":{"line":210,"column":14,"offset":8481},"indent":[]}}],"position":{"start":{"line":210,"column":1,"offset":8468},"end":{"line":210,"column":14,"offset":8481},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":212,"column":1,"offset":8483},"end":{"line":214,"column":4,"offset":8519},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":216,"column":1,"offset":8521},"end":{"line":216,"column":91,"offset":8611},"indent":[]}}],"position":{"start":{"line":216,"column":1,"offset":8521},"end":{"line":216,"column":91,"offset":8611},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":218,"column":1,"offset":8613},"end":{"line":226,"column":4,"offset":8986},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":228,"column":1,"offset":8988},"end":{"line":228,"column":145,"offset":9132},"indent":[]}}],"position":{"start":{"line":228,"column":1,"offset":8988},"end":{"line":228,"column":145,"offset":9132},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":230,"column":5,"offset":9138},"end":{"line":230,"column":17,"offset":9150},"indent":[]}}],"position":{"start":{"line":230,"column":1,"offset":9134},"end":{"line":230,"column":17,"offset":9150},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":232,"column":1,"offset":9152},"end":{"line":232,"column":300,"offset":9451},"indent":[]}}],"position":{"start":{"line":232,"column":1,"offset":9152},"end":{"line":232,"column":300,"offset":9451},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":234,"column":1,"offset":9453},"end":{"line":234,"column":178,"offset":9630},"indent":[]}}],"position":{"start":{"line":234,"column":1,"offset":9453},"end":{"line":234,"column":178,"offset":9630},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":236,"column":1,"offset":9632},"end":{"line":236,"column":48,"offset":9679},"indent":[]}}],"position":{"start":{"line":236,"column":1,"offset":9632},"end":{"line":236,"column":48,"offset":9679},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":238,"column":1,"offset":9681},"end":{"line":240,"column":4,"offset":9721},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":242,"column":1,"offset":9723},"end":{"line":242,"column":104,"offset":9826},"indent":[]}}],"position":{"start":{"line":242,"column":1,"offset":9723},"end":{"line":242,"column":104,"offset":9826},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":244,"column":1,"offset":9828},"end":{"line":252,"column":4,"offset":10098},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":254,"column":1,"offset":10100},"end":{"line":254,"column":28,"offset":10127},"indent":[]}}],"position":{"start":{"line":254,"column":1,"offset":10100},"end":{"line":254,"column":28,"offset":10127},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":256,"column":1,"offset":10129},"end":{"line":258,"column":4,"offset":10173},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":260,"column":1,"offset":10175},"end":{"line":260,"column":48,"offset":10222},"indent":[]}}],"position":{"start":{"line":260,"column":1,"offset":10175},"end":{"line":260,"column":48,"offset":10222},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":262,"column":1,"offset":10224},"end":{"line":264,"column":4,"offset":10246},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":266,"column":1,"offset":10248},"end":{"line":266,"column":72,"offset":10319},"indent":[]}}],"position":{"start":{"line":266,"column":1,"offset":10248},"end":{"line":266,"column":72,"offset":10319},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":268,"column":1,"offset":10321},"end":{"line":270,"column":4,"offset":10378},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":272,"column":4,"offset":10383},"end":{"line":272,"column":10,"offset":10389},"indent":[]}}],"position":{"start":{"line":272,"column":1,"offset":10380},"end":{"line":272,"column":10,"offset":10389},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":274,"column":1,"offset":10391},"end":{"line":274,"column":337,"offset":10727},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":274,"column":338,"offset":10728},"end":{"line":274,"column":352,"offset":10742},"indent":[]}}],"position":{"start":{"line":274,"column":337,"offset":10727},"end":{"line":274,"column":388,"offset":10778},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":274,"column":388,"offset":10778},"end":{"line":274,"column":389,"offset":10779},"indent":[]}}],"position":{"start":{"line":274,"column":1,"offset":10391},"end":{"line":274,"column":389,"offset":10779},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":276,"column":5,"offset":10785},"end":{"line":276,"column":18,"offset":10798},"indent":[]}}],"position":{"start":{"line":276,"column":1,"offset":10781},"end":{"line":276,"column":18,"offset":10798},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":278,"column":3,"offset":10802},"end":{"line":278,"column":50,"offset":10849},"indent":[]}}],"position":{"start":{"line":278,"column":3,"offset":10802},"end":{"line":278,"column":50,"offset":10849},"indent":[]}}],"position":{"start":{"line":278,"column":1,"offset":10800},"end":{"line":278,"column":50,"offset":10849},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":280,"column":5,"offset":10855},"end":{"line":280,"column":11,"offset":10861},"indent":[]}}],"position":{"start":{"line":280,"column":1,"offset":10851},"end":{"line":280,"column":11,"offset":10861},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":282,"column":1,"offset":10863},"end":{"line":282,"column":64,"offset":10926},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":282,"column":65,"offset":10927},"end":{"line":282,"column":86,"offset":10948},"indent":[]}}],"position":{"start":{"line":282,"column":64,"offset":10926},"end":{"line":282,"column":126,"offset":10988},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":282,"column":126,"offset":10988},"end":{"line":282,"column":127,"offset":10989},"indent":[]}}],"position":{"start":{"line":282,"column":1,"offset":10863},"end":{"line":282,"column":127,"offset":10989},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":284,"column":5,"offset":10995},"end":{"line":284,"column":26,"offset":11016},"indent":[]}}],"position":{"start":{"line":284,"column":1,"offset":10991},"end":{"line":284,"column":26,"offset":11016},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":286,"column":1,"offset":11018},"end":{"line":286,"column":126,"offset":11143},"indent":[]}}],"position":{"start":{"line":286,"column":1,"offset":11018},"end":{"line":286,"column":126,"offset":11143},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":288,"column":1,"offset":11145},"end":{"line":290,"column":4,"offset":11184},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":292,"column":1,"offset":11186},"end":{"line":292,"column":187,"offset":11372},"indent":[]}}],"position":{"start":{"line":292,"column":1,"offset":11186},"end":{"line":292,"column":187,"offset":11372},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":294,"column":1,"offset":11374},"end":{"line":296,"column":4,"offset":11452},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":298,"column":1,"offset":11454},"end":{"line":298,"column":153,"offset":11606},"indent":[]}}],"position":{"start":{"line":298,"column":1,"offset":11454},"end":{"line":298,"column":153,"offset":11606},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":300,"column":1,"offset":11608},"end":{"line":303,"column":4,"offset":11755},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":305,"column":1,"offset":11757},"end":{"line":305,"column":100,"offset":11856},"indent":[]}}],"position":{"start":{"line":305,"column":1,"offset":11757},"end":{"line":305,"column":100,"offset":11856},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":306,"column":1,"offset":11857},"end":{"line":310,"column":4,"offset":11926},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":312,"column":5,"offset":11932},"end":{"line":312,"column":12,"offset":11939},"indent":[]}}],"position":{"start":{"line":312,"column":1,"offset":11928},"end":{"line":312,"column":12,"offset":11939},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":314,"column":1,"offset":11941},"end":{"line":314,"column":64,"offset":12004},"indent":[]}}],"position":{"start":{"line":314,"column":1,"offset":11941},"end":{"line":314,"column":64,"offset":12004},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":315,"column":3,"offset":12007},"end":{"line":315,"column":25,"offset":12029},"indent":[]}}],"position":{"start":{"line":315,"column":3,"offset":12007},"end":{"line":315,"column":25,"offset":12029},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12005},"end":{"line":315,"column":25,"offset":12029},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":316,"column":3,"offset":12032},"end":{"line":316,"column":59,"offset":12088},"indent":[]}}],"position":{"start":{"line":316,"column":3,"offset":12032},"end":{"line":316,"column":59,"offset":12088},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12030},"end":{"line":316,"column":59,"offset":12088},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12005},"end":{"line":316,"column":59,"offset":12088},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":318,"column":4,"offset":12093},"end":{"line":318,"column":11,"offset":12100},"indent":[]}}],"position":{"start":{"line":318,"column":1,"offset":12090},"end":{"line":318,"column":11,"offset":12100},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":320,"column":1,"offset":12102},"end":{"line":320,"column":283,"offset":12384},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":12102},"end":{"line":320,"column":283,"offset":12384},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":322,"column":3,"offset":12388},"end":{"line":322,"column":54,"offset":12439},"indent":[]}}],"position":{"start":{"line":322,"column":3,"offset":12388},"end":{"line":322,"column":54,"offset":12439},"indent":[]}}],"position":{"start":{"line":322,"column":1,"offset":12386},"end":{"line":322,"column":54,"offset":12439},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":324,"column":5,"offset":12445},"end":{"line":324,"column":14,"offset":12454},"indent":[]}}],"position":{"start":{"line":324,"column":1,"offset":12441},"end":{"line":324,"column":14,"offset":12454},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":326,"column":1,"offset":12456},"end":{"line":326,"column":68,"offset":12523},"indent":[]}}],"position":{"start":{"line":326,"column":1,"offset":12456},"end":{"line":326,"column":68,"offset":12523},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":328,"column":1,"offset":12525},"end":{"line":331,"column":4,"offset":12676},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":333,"column":1,"offset":12678},"end":{"line":333,"column":46,"offset":12723},"indent":[]}}],"position":{"start":{"line":333,"column":1,"offset":12678},"end":{"line":333,"column":46,"offset":12723},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":335,"column":3,"offset":12727},"end":{"line":335,"column":103,"offset":12827},"indent":[]}}],"position":{"start":{"line":335,"column":3,"offset":12727},"end":{"line":335,"column":103,"offset":12827},"indent":[]}}],"position":{"start":{"line":335,"column":1,"offset":12725},"end":{"line":335,"column":103,"offset":12827},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":337,"column":1,"offset":12829},"end":{"line":342,"column":4,"offset":13039},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":344,"column":1,"offset":13041},"end":{"line":344,"column":151,"offset":13191},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13041},"end":{"line":344,"column":151,"offset":13191},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":346,"column":3,"offset":13195},"end":{"line":346,"column":22,"offset":13214},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":346,"column":22,"offset":13214},"end":{"line":346,"column":26,"offset":13218},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":346,"column":26,"offset":13218},"end":{"line":346,"column":40,"offset":13232},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":346,"column":40,"offset":13232},"end":{"line":346,"column":50,"offset":13242},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":346,"column":50,"offset":13242},"end":{"line":346,"column":98,"offset":13290},"indent":[]}}],"position":{"start":{"line":346,"column":3,"offset":13195},"end":{"line":346,"column":98,"offset":13290},"indent":[]}}],"position":{"start":{"line":346,"column":1,"offset":13193},"end":{"line":346,"column":98,"offset":13290},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":348,"column":1,"offset":13292},"end":{"line":352,"column":4,"offset":13454},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":354,"column":1,"offset":13456},"end":{"line":354,"column":72,"offset":13527},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":354,"column":72,"offset":13527},"end":{"line":354,"column":84,"offset":13539},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":354,"column":84,"offset":13539},"end":{"line":354,"column":102,"offset":13557},"indent":[]}}],"position":{"start":{"line":354,"column":1,"offset":13456},"end":{"line":354,"column":102,"offset":13557},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":356,"column":1,"offset":13559},"end":{"line":359,"column":4,"offset":13633},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":361,"column":5,"offset":13639},"end":{"line":361,"column":8,"offset":13642},"indent":[]}}],"position":{"start":{"line":361,"column":1,"offset":13635},"end":{"line":361,"column":8,"offset":13642},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":363,"column":1,"offset":13644},"end":{"line":363,"column":176,"offset":13819},"indent":[]}}],"position":{"start":{"line":363,"column":1,"offset":13644},"end":{"line":363,"column":176,"offset":13819},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":365,"column":1,"offset":13821},"end":{"line":372,"column":4,"offset":14118},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":374,"column":1,"offset":14120},"end":{"line":374,"column":60,"offset":14179},"indent":[]}}],"position":{"start":{"line":374,"column":1,"offset":14120},"end":{"line":374,"column":60,"offset":14179},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":376,"column":1,"offset":14181},"end":{"line":380,"column":4,"offset":14307},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":382,"column":1,"offset":14309},"end":{"line":382,"column":63,"offset":14371},"indent":[]}}],"position":{"start":{"line":382,"column":1,"offset":14309},"end":{"line":382,"column":63,"offset":14371},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":384,"column":1,"offset":14373},"end":{"line":404,"column":4,"offset":14880},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":406,"column":1,"offset":14882},"end":{"line":406,"column":99,"offset":14980},"indent":[]}}],"position":{"start":{"line":406,"column":1,"offset":14882},"end":{"line":406,"column":99,"offset":14980},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":408,"column":1,"offset":14982},"end":{"line":411,"column":4,"offset":15084},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":413,"column":1,"offset":15086},"end":{"line":413,"column":37,"offset":15122},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":413,"column":37,"offset":15122},"end":{"line":413,"column":47,"offset":15132},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":413,"column":47,"offset":15132},"end":{"line":413,"column":89,"offset":15174},"indent":[]}}],"position":{"start":{"line":413,"column":1,"offset":15086},"end":{"line":413,"column":89,"offset":15174},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":415,"column":1,"offset":15176},"end":{"line":419,"column":4,"offset":15301},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":421,"column":1,"offset":15303},"end":{"line":421,"column":78,"offset":15380},"indent":[]}}],"position":{"start":{"line":421,"column":1,"offset":15303},"end":{"line":421,"column":78,"offset":15380},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":423,"column":1,"offset":15382},"end":{"line":427,"column":4,"offset":15486},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":429,"column":1,"offset":15488},"end":{"line":429,"column":75,"offset":15562},"indent":[]}}],"position":{"start":{"line":429,"column":1,"offset":15488},"end":{"line":429,"column":75,"offset":15562},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":431,"column":1,"offset":15564},"end":{"line":435,"column":4,"offset":15637},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":437,"column":1,"offset":15639},"end":{"line":437,"column":145,"offset":15783},"indent":[]}}],"position":{"start":{"line":437,"column":1,"offset":15639},"end":{"line":437,"column":145,"offset":15783},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":439,"column":5,"offset":15789},"end":{"line":439,"column":17,"offset":15801},"indent":[]}}],"position":{"start":{"line":439,"column":1,"offset":15785},"end":{"line":439,"column":17,"offset":15801},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":441,"column":1,"offset":15803},"end":{"line":441,"column":300,"offset":16102},"indent":[]}}],"position":{"start":{"line":441,"column":1,"offset":15803},"end":{"line":441,"column":300,"offset":16102},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":443,"column":1,"offset":16104},"end":{"line":443,"column":178,"offset":16281},"indent":[]}}],"position":{"start":{"line":443,"column":1,"offset":16104},"end":{"line":443,"column":178,"offset":16281},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":445,"column":1,"offset":16283},"end":{"line":445,"column":48,"offset":16330},"indent":[]}}],"position":{"start":{"line":445,"column":1,"offset":16283},"end":{"line":445,"column":48,"offset":16330},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":447,"column":1,"offset":16332},"end":{"line":449,"column":4,"offset":16376},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":451,"column":1,"offset":16378},"end":{"line":451,"column":104,"offset":16481},"indent":[]}}],"position":{"start":{"line":451,"column":1,"offset":16378},"end":{"line":451,"column":104,"offset":16481},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":453,"column":1,"offset":16483},"end":{"line":461,"column":4,"offset":16753},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":463,"column":1,"offset":16755},"end":{"line":463,"column":28,"offset":16782},"indent":[]}}],"position":{"start":{"line":463,"column":1,"offset":16755},"end":{"line":463,"column":28,"offset":16782},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":465,"column":1,"offset":16784},"end":{"line":467,"column":4,"offset":16832},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":469,"column":1,"offset":16834},"end":{"line":469,"column":48,"offset":16881},"indent":[]}}],"position":{"start":{"line":469,"column":1,"offset":16834},"end":{"line":469,"column":48,"offset":16881},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":471,"column":1,"offset":16883},"end":{"line":473,"column":4,"offset":16905},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":475,"column":1,"offset":16907},"end":{"line":475,"column":72,"offset":16978},"indent":[]}}],"position":{"start":{"line":475,"column":1,"offset":16907},"end":{"line":475,"column":72,"offset":16978},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":477,"column":1,"offset":16980},"end":{"line":479,"column":4,"offset":17041},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":482,"column":1,"offset":17044},"end":{"line":482,"column":31,"offset":17074},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":482,"column":31,"offset":17074}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  4. \n
  5. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  6. \n
  7. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  8. \n
\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Docker`}

\n

{`A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-da466c249906f950dfe169c53e70109c.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-da466c249906f950dfe169c53e70109c.json new file mode 100644 index 0000000..7bcc0cc --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-da466c249906f950dfe169c53e70109c.json @@ -0,0 +1 @@ +{"expireTime":9007200842068781000,"key":"gatsby-plugin-mdx-entire-payload-7945686752947ca1e0289e544f535442-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4679},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":80,"offset":4760},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4760},"end":{"line":107,"column":101,"offset":4781},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4781},"end":{"line":107,"column":162,"offset":4842},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":162,"offset":4842},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4844},"end":{"line":112,"column":4,"offset":4933},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4938},"end":{"line":114,"column":10,"offset":4944},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4935},"end":{"line":114,"column":10,"offset":4944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":339,"offset":5284},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":340,"offset":5285},"end":{"line":116,"column":354,"offset":5299},"indent":[]}}],"position":{"start":{"line":116,"column":339,"offset":5284},"end":{"line":116,"column":390,"offset":5335},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":390,"offset":5335},"end":{"line":116,"column":391,"offset":5336},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":391,"offset":5336},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5342},"end":{"line":118,"column":18,"offset":5355},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5338},"end":{"line":118,"column":18,"offset":5355},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5357},"end":{"line":120,"column":50,"offset":5406},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5412},"end":{"line":122,"column":11,"offset":5418},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5408},"end":{"line":122,"column":11,"offset":5418},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":64,"offset":5483},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5484},"end":{"line":124,"column":86,"offset":5505},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5483},"end":{"line":124,"column":126,"offset":5545},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5545},"end":{"line":124,"column":127,"offset":5546},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":127,"offset":5546},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5552},"end":{"line":126,"column":26,"offset":5573},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5548},"end":{"line":126,"column":26,"offset":5573},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5702},"end":{"line":132,"column":4,"offset":5741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5931},"end":{"line":138,"column":4,"offset":6009},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6165},"end":{"line":145,"column":4,"offset":6312},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6414},"end":{"line":152,"column":4,"offset":6483},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6489},"end":{"line":154,"column":12,"offset":6496},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6485},"end":{"line":154,"column":12,"offset":6496},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":157,"column":25,"offset":6586},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6587},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":158,"column":59,"offset":6645},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":160,"column":4,"offset":6650},"end":{"line":160,"column":10,"offset":6656},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":6647},"end":{"line":160,"column":10,"offset":6656},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.","position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":310,"offset":6967},"indent":[]}}],"position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":310,"offset":6967},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To fill the gap, regarding the latter, we can rely on another solution called ","position":{"start":{"line":164,"column":1,"offset":6969},"end":{"line":164,"column":79,"offset":7047},"indent":[]}},{"type":"link","title":null,"url":"https://balena.io","children":[{"type":"text","value":"Balena.io","position":{"start":{"line":164,"column":80,"offset":7048},"end":{"line":164,"column":89,"offset":7057},"indent":[]}}],"position":{"start":{"line":164,"column":79,"offset":7047},"end":{"line":164,"column":109,"offset":7077},"indent":[]}},{"type":"text","value":". Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can support this.","position":{"start":{"line":164,"column":109,"offset":7077},"end":{"line":164,"column":332,"offset":7300},"indent":[]}}],"position":{"start":{"line":164,"column":1,"offset":6969},"end":{"line":164,"column":332,"offset":7300},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On top of supporting a lot of boars,","position":{"start":{"line":166,"column":1,"offset":7302},"end":{"line":166,"column":37,"offset":7338},"indent":[]}}],"position":{"start":{"line":166,"column":1,"offset":7302},"end":{"line":166,"column":37,"offset":7338},"indent":[]}},{"type":"thematicBreak","position":{"start":{"line":168,"column":1,"offset":7340},"end":{"line":168,"column":4,"offset":7343},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":170,"column":3,"offset":7347},"end":{"line":170,"column":11,"offset":7355},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7345},"end":{"line":170,"column":11,"offset":7355},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":172,"column":1,"offset":7357},"end":{"line":172,"column":133,"offset":7489},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7357},"end":{"line":172,"column":133,"offset":7489},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":174,"column":4,"offset":7494},"end":{"line":174,"column":12,"offset":7502},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7491},"end":{"line":174,"column":12,"offset":7502},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":176,"column":1,"offset":7504},"end":{"line":176,"column":193,"offset":7696},"indent":[]}}],"position":{"start":{"line":176,"column":1,"offset":7504},"end":{"line":176,"column":193,"offset":7696},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":178,"column":4,"offset":7701},"end":{"line":178,"column":62,"offset":7759},"indent":[]}}],"position":{"start":{"line":178,"column":4,"offset":7701},"end":{"line":178,"column":62,"offset":7759},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7698},"end":{"line":178,"column":62,"offset":7759},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":179,"column":4,"offset":7763},"end":{"line":179,"column":69,"offset":7828},"indent":[]}}],"position":{"start":{"line":179,"column":4,"offset":7763},"end":{"line":179,"column":69,"offset":7828},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7760},"end":{"line":179,"column":69,"offset":7828},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7698},"end":{"line":179,"column":69,"offset":7828},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":181,"column":1,"offset":7830},"end":{"line":181,"column":99,"offset":7928},"indent":[]}}],"position":{"start":{"line":181,"column":1,"offset":7830},"end":{"line":181,"column":99,"offset":7928},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":183,"column":5,"offset":7934},"end":{"line":183,"column":14,"offset":7943},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":7930},"end":{"line":183,"column":14,"offset":7943},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":185,"column":1,"offset":7945},"end":{"line":185,"column":71,"offset":8015},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":7945},"end":{"line":185,"column":71,"offset":8015},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":187,"column":3,"offset":8019},"end":{"line":187,"column":47,"offset":8063},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":187,"column":47,"offset":8063},"end":{"line":187,"column":79,"offset":8095},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":187,"column":79,"offset":8095},"end":{"line":187,"column":198,"offset":8214},"indent":[]}}],"position":{"start":{"line":187,"column":3,"offset":8019},"end":{"line":187,"column":198,"offset":8214},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":8017},"end":{"line":187,"column":198,"offset":8214},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":189,"column":1,"offset":8216},"end":{"line":191,"column":4,"offset":8279},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":193,"column":5,"offset":8285},"end":{"line":193,"column":14,"offset":8294},"indent":[]}}],"position":{"start":{"line":193,"column":1,"offset":8281},"end":{"line":193,"column":14,"offset":8294},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":195,"column":1,"offset":8296},"end":{"line":195,"column":56,"offset":8351},"indent":[]}}],"position":{"start":{"line":195,"column":1,"offset":8296},"end":{"line":195,"column":56,"offset":8351},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":196,"column":3,"offset":8354},"end":{"line":196,"column":52,"offset":8403},"indent":[]}}],"position":{"start":{"line":196,"column":3,"offset":8354},"end":{"line":196,"column":52,"offset":8403},"indent":[]}}],"position":{"start":{"line":196,"column":3,"offset":8354},"end":{"line":196,"column":52,"offset":8403},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8352},"end":{"line":196,"column":52,"offset":8403},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":198,"column":1,"offset":8405},"end":{"line":198,"column":3,"offset":8407},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":198,"column":3,"offset":8407},"end":{"line":198,"column":9,"offset":8413},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":198,"column":9,"offset":8413},"end":{"line":198,"column":223,"offset":8627},"indent":[]}}],"position":{"start":{"line":198,"column":1,"offset":8405},"end":{"line":198,"column":223,"offset":8627},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":200,"column":3,"offset":8631},"end":{"line":200,"column":159,"offset":8787},"indent":[]}}],"position":{"start":{"line":200,"column":3,"offset":8631},"end":{"line":200,"column":159,"offset":8787},"indent":[]}}],"position":{"start":{"line":200,"column":1,"offset":8629},"end":{"line":200,"column":159,"offset":8787},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":202,"column":1,"offset":8789},"end":{"line":205,"column":4,"offset":8966},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":207,"column":1,"offset":8968},"end":{"line":207,"column":160,"offset":9127},"indent":[]}}],"position":{"start":{"line":207,"column":1,"offset":8968},"end":{"line":207,"column":160,"offset":9127},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":209,"column":3,"offset":9131},"end":{"line":209,"column":31,"offset":9159},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":209,"column":31,"offset":9159},"end":{"line":209,"column":101,"offset":9229},"indent":[]}}],"position":{"start":{"line":209,"column":3,"offset":9131},"end":{"line":209,"column":101,"offset":9229},"indent":[]}}],"position":{"start":{"line":209,"column":1,"offset":9129},"end":{"line":209,"column":101,"offset":9229},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":211,"column":1,"offset":9231},"end":{"line":214,"column":4,"offset":9403},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":216,"column":1,"offset":9405},"end":{"line":216,"column":73,"offset":9477},"indent":[]}}],"position":{"start":{"line":216,"column":1,"offset":9405},"end":{"line":216,"column":73,"offset":9477},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":219,"column":3,"offset":9482},"end":{"line":219,"column":31,"offset":9510},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":219,"column":31,"offset":9510},"end":{"line":219,"column":101,"offset":9580},"indent":[]}}],"position":{"start":{"line":219,"column":3,"offset":9482},"end":{"line":219,"column":101,"offset":9580},"indent":[]}}],"position":{"start":{"line":219,"column":1,"offset":9480},"end":{"line":219,"column":101,"offset":9580},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":221,"column":1,"offset":9582},"end":{"line":224,"column":4,"offset":9754},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":226,"column":1,"offset":9756},"end":{"line":226,"column":62,"offset":9817},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":226,"column":63,"offset":9818},"end":{"line":226,"column":75,"offset":9830},"indent":[]}}],"position":{"start":{"line":226,"column":62,"offset":9817},"end":{"line":226,"column":143,"offset":9898},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":226,"column":143,"offset":9898},"end":{"line":226,"column":150,"offset":9905},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":226,"column":150,"offset":9905},"end":{"line":226,"column":169,"offset":9924},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":226,"column":169,"offset":9924},"end":{"line":226,"column":170,"offset":9925},"indent":[]}}],"position":{"start":{"line":226,"column":1,"offset":9756},"end":{"line":226,"column":170,"offset":9925},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":228,"column":1,"offset":9927},"end":{"line":230,"column":4,"offset":9954},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":232,"column":1,"offset":9956},"end":{"line":232,"column":58,"offset":10013},"indent":[]}}],"position":{"start":{"line":232,"column":1,"offset":9956},"end":{"line":232,"column":58,"offset":10013},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":234,"column":1,"offset":10015},"end":{"line":237,"column":4,"offset":10085},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":239,"column":5,"offset":10091},"end":{"line":239,"column":8,"offset":10094},"indent":[]}}],"position":{"start":{"line":239,"column":1,"offset":10087},"end":{"line":239,"column":8,"offset":10094},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":241,"column":1,"offset":10096},"end":{"line":241,"column":280,"offset":10375},"indent":[]}}],"position":{"start":{"line":241,"column":1,"offset":10096},"end":{"line":241,"column":280,"offset":10375},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":243,"column":1,"offset":10377},"end":{"line":243,"column":37,"offset":10413},"indent":[]}}],"position":{"start":{"line":243,"column":1,"offset":10377},"end":{"line":243,"column":37,"offset":10413},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":245,"column":1,"offset":10415},"end":{"line":247,"column":4,"offset":10588},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":249,"column":1,"offset":10590},"end":{"line":249,"column":25,"offset":10614},"indent":[]}}],"position":{"start":{"line":249,"column":1,"offset":10590},"end":{"line":249,"column":25,"offset":10614},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":251,"column":1,"offset":10616},"end":{"line":254,"column":4,"offset":10720},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":256,"column":1,"offset":10722},"end":{"line":256,"column":118,"offset":10839},"indent":[]}}],"position":{"start":{"line":256,"column":1,"offset":10722},"end":{"line":256,"column":118,"offset":10839},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":258,"column":1,"offset":10841},"end":{"line":278,"column":4,"offset":11348},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":280,"column":1,"offset":11350},"end":{"line":280,"column":14,"offset":11363},"indent":[]}}],"position":{"start":{"line":280,"column":1,"offset":11350},"end":{"line":280,"column":14,"offset":11363},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":282,"column":1,"offset":11365},"end":{"line":284,"column":4,"offset":11401},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":286,"column":1,"offset":11403},"end":{"line":286,"column":91,"offset":11493},"indent":[]}}],"position":{"start":{"line":286,"column":1,"offset":11403},"end":{"line":286,"column":91,"offset":11493},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":288,"column":1,"offset":11495},"end":{"line":296,"column":4,"offset":11868},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":298,"column":1,"offset":11870},"end":{"line":298,"column":145,"offset":12014},"indent":[]}}],"position":{"start":{"line":298,"column":1,"offset":11870},"end":{"line":298,"column":145,"offset":12014},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":300,"column":5,"offset":12020},"end":{"line":300,"column":17,"offset":12032},"indent":[]}}],"position":{"start":{"line":300,"column":1,"offset":12016},"end":{"line":300,"column":17,"offset":12032},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":302,"column":1,"offset":12034},"end":{"line":302,"column":300,"offset":12333},"indent":[]}}],"position":{"start":{"line":302,"column":1,"offset":12034},"end":{"line":302,"column":300,"offset":12333},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":304,"column":1,"offset":12335},"end":{"line":304,"column":178,"offset":12512},"indent":[]}}],"position":{"start":{"line":304,"column":1,"offset":12335},"end":{"line":304,"column":178,"offset":12512},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":306,"column":1,"offset":12514},"end":{"line":306,"column":48,"offset":12561},"indent":[]}}],"position":{"start":{"line":306,"column":1,"offset":12514},"end":{"line":306,"column":48,"offset":12561},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":308,"column":1,"offset":12563},"end":{"line":310,"column":4,"offset":12603},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":312,"column":1,"offset":12605},"end":{"line":312,"column":104,"offset":12708},"indent":[]}}],"position":{"start":{"line":312,"column":1,"offset":12605},"end":{"line":312,"column":104,"offset":12708},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":314,"column":1,"offset":12710},"end":{"line":322,"column":4,"offset":12980},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":324,"column":1,"offset":12982},"end":{"line":324,"column":28,"offset":13009},"indent":[]}}],"position":{"start":{"line":324,"column":1,"offset":12982},"end":{"line":324,"column":28,"offset":13009},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":326,"column":1,"offset":13011},"end":{"line":328,"column":4,"offset":13055},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":330,"column":1,"offset":13057},"end":{"line":330,"column":48,"offset":13104},"indent":[]}}],"position":{"start":{"line":330,"column":1,"offset":13057},"end":{"line":330,"column":48,"offset":13104},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":332,"column":1,"offset":13106},"end":{"line":334,"column":4,"offset":13128},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":336,"column":1,"offset":13130},"end":{"line":336,"column":72,"offset":13201},"indent":[]}}],"position":{"start":{"line":336,"column":1,"offset":13130},"end":{"line":336,"column":72,"offset":13201},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":338,"column":1,"offset":13203},"end":{"line":340,"column":4,"offset":13260},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":342,"column":4,"offset":13265},"end":{"line":342,"column":11,"offset":13272},"indent":[]}}],"position":{"start":{"line":342,"column":1,"offset":13262},"end":{"line":342,"column":11,"offset":13272},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":344,"column":1,"offset":13274},"end":{"line":344,"column":283,"offset":13556},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13274},"end":{"line":344,"column":283,"offset":13556},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":346,"column":3,"offset":13560},"end":{"line":346,"column":54,"offset":13611},"indent":[]}}],"position":{"start":{"line":346,"column":3,"offset":13560},"end":{"line":346,"column":54,"offset":13611},"indent":[]}}],"position":{"start":{"line":346,"column":1,"offset":13558},"end":{"line":346,"column":54,"offset":13611},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":348,"column":5,"offset":13617},"end":{"line":348,"column":14,"offset":13626},"indent":[]}}],"position":{"start":{"line":348,"column":1,"offset":13613},"end":{"line":348,"column":14,"offset":13626},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":350,"column":1,"offset":13628},"end":{"line":350,"column":68,"offset":13695},"indent":[]}}],"position":{"start":{"line":350,"column":1,"offset":13628},"end":{"line":350,"column":68,"offset":13695},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":352,"column":1,"offset":13697},"end":{"line":355,"column":4,"offset":13848},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":357,"column":1,"offset":13850},"end":{"line":357,"column":46,"offset":13895},"indent":[]}}],"position":{"start":{"line":357,"column":1,"offset":13850},"end":{"line":357,"column":46,"offset":13895},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":359,"column":3,"offset":13899},"end":{"line":359,"column":103,"offset":13999},"indent":[]}}],"position":{"start":{"line":359,"column":3,"offset":13899},"end":{"line":359,"column":103,"offset":13999},"indent":[]}}],"position":{"start":{"line":359,"column":1,"offset":13897},"end":{"line":359,"column":103,"offset":13999},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":361,"column":1,"offset":14001},"end":{"line":366,"column":4,"offset":14211},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":368,"column":1,"offset":14213},"end":{"line":368,"column":151,"offset":14363},"indent":[]}}],"position":{"start":{"line":368,"column":1,"offset":14213},"end":{"line":368,"column":151,"offset":14363},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":370,"column":3,"offset":14367},"end":{"line":370,"column":22,"offset":14386},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":370,"column":22,"offset":14386},"end":{"line":370,"column":26,"offset":14390},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":370,"column":26,"offset":14390},"end":{"line":370,"column":40,"offset":14404},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":370,"column":40,"offset":14404},"end":{"line":370,"column":50,"offset":14414},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":370,"column":50,"offset":14414},"end":{"line":370,"column":98,"offset":14462},"indent":[]}}],"position":{"start":{"line":370,"column":3,"offset":14367},"end":{"line":370,"column":98,"offset":14462},"indent":[]}}],"position":{"start":{"line":370,"column":1,"offset":14365},"end":{"line":370,"column":98,"offset":14462},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":372,"column":1,"offset":14464},"end":{"line":376,"column":4,"offset":14626},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":378,"column":1,"offset":14628},"end":{"line":378,"column":72,"offset":14699},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":378,"column":72,"offset":14699},"end":{"line":378,"column":84,"offset":14711},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":378,"column":84,"offset":14711},"end":{"line":378,"column":102,"offset":14729},"indent":[]}}],"position":{"start":{"line":378,"column":1,"offset":14628},"end":{"line":378,"column":102,"offset":14729},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":380,"column":1,"offset":14731},"end":{"line":383,"column":4,"offset":14805},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":385,"column":5,"offset":14811},"end":{"line":385,"column":8,"offset":14814},"indent":[]}}],"position":{"start":{"line":385,"column":1,"offset":14807},"end":{"line":385,"column":8,"offset":14814},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":387,"column":1,"offset":14816},"end":{"line":387,"column":176,"offset":14991},"indent":[]}}],"position":{"start":{"line":387,"column":1,"offset":14816},"end":{"line":387,"column":176,"offset":14991},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":389,"column":1,"offset":14993},"end":{"line":396,"column":4,"offset":15290},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":398,"column":1,"offset":15292},"end":{"line":398,"column":60,"offset":15351},"indent":[]}}],"position":{"start":{"line":398,"column":1,"offset":15292},"end":{"line":398,"column":60,"offset":15351},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":400,"column":1,"offset":15353},"end":{"line":404,"column":4,"offset":15479},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":406,"column":1,"offset":15481},"end":{"line":406,"column":63,"offset":15543},"indent":[]}}],"position":{"start":{"line":406,"column":1,"offset":15481},"end":{"line":406,"column":63,"offset":15543},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":408,"column":1,"offset":15545},"end":{"line":428,"column":4,"offset":16052},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":430,"column":1,"offset":16054},"end":{"line":430,"column":99,"offset":16152},"indent":[]}}],"position":{"start":{"line":430,"column":1,"offset":16054},"end":{"line":430,"column":99,"offset":16152},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":432,"column":1,"offset":16154},"end":{"line":435,"column":4,"offset":16256},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":437,"column":1,"offset":16258},"end":{"line":437,"column":37,"offset":16294},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":437,"column":37,"offset":16294},"end":{"line":437,"column":47,"offset":16304},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":437,"column":47,"offset":16304},"end":{"line":437,"column":89,"offset":16346},"indent":[]}}],"position":{"start":{"line":437,"column":1,"offset":16258},"end":{"line":437,"column":89,"offset":16346},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":439,"column":1,"offset":16348},"end":{"line":443,"column":4,"offset":16473},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":445,"column":1,"offset":16475},"end":{"line":445,"column":78,"offset":16552},"indent":[]}}],"position":{"start":{"line":445,"column":1,"offset":16475},"end":{"line":445,"column":78,"offset":16552},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":447,"column":1,"offset":16554},"end":{"line":451,"column":4,"offset":16658},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":453,"column":1,"offset":16660},"end":{"line":453,"column":75,"offset":16734},"indent":[]}}],"position":{"start":{"line":453,"column":1,"offset":16660},"end":{"line":453,"column":75,"offset":16734},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":455,"column":1,"offset":16736},"end":{"line":459,"column":4,"offset":16809},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":461,"column":1,"offset":16811},"end":{"line":461,"column":145,"offset":16955},"indent":[]}}],"position":{"start":{"line":461,"column":1,"offset":16811},"end":{"line":461,"column":145,"offset":16955},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":463,"column":5,"offset":16961},"end":{"line":463,"column":17,"offset":16973},"indent":[]}}],"position":{"start":{"line":463,"column":1,"offset":16957},"end":{"line":463,"column":17,"offset":16973},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":465,"column":1,"offset":16975},"end":{"line":465,"column":300,"offset":17274},"indent":[]}}],"position":{"start":{"line":465,"column":1,"offset":16975},"end":{"line":465,"column":300,"offset":17274},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":467,"column":1,"offset":17276},"end":{"line":467,"column":178,"offset":17453},"indent":[]}}],"position":{"start":{"line":467,"column":1,"offset":17276},"end":{"line":467,"column":178,"offset":17453},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":469,"column":1,"offset":17455},"end":{"line":469,"column":48,"offset":17502},"indent":[]}}],"position":{"start":{"line":469,"column":1,"offset":17455},"end":{"line":469,"column":48,"offset":17502},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":471,"column":1,"offset":17504},"end":{"line":473,"column":4,"offset":17548},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":475,"column":1,"offset":17550},"end":{"line":475,"column":104,"offset":17653},"indent":[]}}],"position":{"start":{"line":475,"column":1,"offset":17550},"end":{"line":475,"column":104,"offset":17653},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":477,"column":1,"offset":17655},"end":{"line":485,"column":4,"offset":17925},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":487,"column":1,"offset":17927},"end":{"line":487,"column":28,"offset":17954},"indent":[]}}],"position":{"start":{"line":487,"column":1,"offset":17927},"end":{"line":487,"column":28,"offset":17954},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":489,"column":1,"offset":17956},"end":{"line":491,"column":4,"offset":18004},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":493,"column":1,"offset":18006},"end":{"line":493,"column":48,"offset":18053},"indent":[]}}],"position":{"start":{"line":493,"column":1,"offset":18006},"end":{"line":493,"column":48,"offset":18053},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":495,"column":1,"offset":18055},"end":{"line":497,"column":4,"offset":18077},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":499,"column":1,"offset":18079},"end":{"line":499,"column":72,"offset":18150},"indent":[]}}],"position":{"start":{"line":499,"column":1,"offset":18079},"end":{"line":499,"column":72,"offset":18150},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":501,"column":1,"offset":18152},"end":{"line":503,"column":4,"offset":18213},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":506,"column":1,"offset":18216},"end":{"line":506,"column":31,"offset":18246},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":506,"column":31,"offset":18246}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.`}

\n

{`To fill the gap, regarding the latter, we can rely on another solution called `}{`Balena.io`}{`. Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can support this.`}

\n

{`On top of supporting a lot of boars,`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-dffd70628d0005fccd26c6a05f8c2b37.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-dffd70628d0005fccd26c6a05f8c2b37.json new file mode 100644 index 0000000..7cebef4 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-dffd70628d0005fccd26c6a05f8c2b37.json @@ -0,0 +1 @@ +{"expireTime":9007200842319644000,"key":"gatsby-plugin-mdx-entire-payload-ac07c4c1a891750442aa283f46a4d432-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4679},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":80,"offset":4760},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4760},"end":{"line":107,"column":101,"offset":4781},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4781},"end":{"line":107,"column":162,"offset":4842},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":162,"offset":4842},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4844},"end":{"line":112,"column":4,"offset":4933},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4938},"end":{"line":114,"column":10,"offset":4944},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4935},"end":{"line":114,"column":10,"offset":4944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":339,"offset":5284},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":340,"offset":5285},"end":{"line":116,"column":354,"offset":5299},"indent":[]}}],"position":{"start":{"line":116,"column":339,"offset":5284},"end":{"line":116,"column":390,"offset":5335},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":390,"offset":5335},"end":{"line":116,"column":391,"offset":5336},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":391,"offset":5336},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5342},"end":{"line":118,"column":18,"offset":5355},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5338},"end":{"line":118,"column":18,"offset":5355},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5357},"end":{"line":120,"column":50,"offset":5406},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5412},"end":{"line":122,"column":11,"offset":5418},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5408},"end":{"line":122,"column":11,"offset":5418},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":64,"offset":5483},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5484},"end":{"line":124,"column":86,"offset":5505},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5483},"end":{"line":124,"column":126,"offset":5545},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5545},"end":{"line":124,"column":127,"offset":5546},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":127,"offset":5546},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5552},"end":{"line":126,"column":26,"offset":5573},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5548},"end":{"line":126,"column":26,"offset":5573},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5702},"end":{"line":132,"column":4,"offset":5741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5931},"end":{"line":138,"column":4,"offset":6009},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6165},"end":{"line":145,"column":4,"offset":6312},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6414},"end":{"line":152,"column":4,"offset":6483},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6489},"end":{"line":154,"column":12,"offset":6496},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6485},"end":{"line":154,"column":12,"offset":6496},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example:","position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":65,"offset":6562},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":65,"offset":6562},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":157,"column":3,"offset":6565},"end":{"line":157,"column":25,"offset":6587},"indent":[]}}],"position":{"start":{"line":157,"column":3,"offset":6565},"end":{"line":157,"column":25,"offset":6587},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6563},"end":{"line":157,"column":25,"offset":6587},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":158,"column":3,"offset":6590},"end":{"line":158,"column":59,"offset":6646},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6590},"end":{"line":158,"column":59,"offset":6646},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6588},"end":{"line":158,"column":59,"offset":6646},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6563},"end":{"line":158,"column":59,"offset":6646},"indent":[1]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name kerberos-camera1 \\\n-p 80:80 -p 8889:8889 \\\n-v ~/config:/etc/opt/kerberosio/config \\\n-v ~/capture:/etc/opt/kerberosio/capture \\\n-v ~/logs:/etc/opt/kerberosio/logs \\\n-v ~/webconfig:/var/www/web/config \\\n-d kerberos/kerberos","position":{"start":{"line":160,"column":1,"offset":6648},"end":{"line":168,"column":4,"offset":6897},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Learn more about volumes in this tutorial.","position":{"start":{"line":170,"column":1,"offset":6899},"end":{"line":170,"column":43,"offset":6941},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":6899},"end":{"line":170,"column":43,"offset":6941},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":173,"column":4,"offset":6947},"end":{"line":173,"column":10,"offset":6953},"indent":[]}}],"position":{"start":{"line":173,"column":1,"offset":6944},"end":{"line":173,"column":10,"offset":6953},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.","position":{"start":{"line":175,"column":1,"offset":6955},"end":{"line":175,"column":310,"offset":7264},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":6955},"end":{"line":175,"column":310,"offset":7264},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To fill the gap, regarding the latter, we can rely on another solution called ","position":{"start":{"line":177,"column":1,"offset":7266},"end":{"line":177,"column":79,"offset":7344},"indent":[]}},{"type":"link","title":null,"url":"https://balena.io","children":[{"type":"text","value":"Balena.io","position":{"start":{"line":177,"column":80,"offset":7345},"end":{"line":177,"column":89,"offset":7354},"indent":[]}}],"position":{"start":{"line":177,"column":79,"offset":7344},"end":{"line":177,"column":109,"offset":7374},"indent":[]}},{"type":"text","value":". Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).","position":{"start":{"line":177,"column":109,"offset":7374},"end":{"line":177,"column":386,"offset":7651},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7266},"end":{"line":177,"column":386,"offset":7651},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"On top of supporting a lot of boars,","position":{"start":{"line":179,"column":1,"offset":7653},"end":{"line":179,"column":37,"offset":7689},"indent":[]}}],"position":{"start":{"line":179,"column":1,"offset":7653},"end":{"line":179,"column":37,"offset":7689},"indent":[]}},{"type":"thematicBreak","position":{"start":{"line":181,"column":1,"offset":7691},"end":{"line":181,"column":4,"offset":7694},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":183,"column":3,"offset":7698},"end":{"line":183,"column":11,"offset":7706},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":7696},"end":{"line":183,"column":11,"offset":7706},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":185,"column":1,"offset":7708},"end":{"line":185,"column":133,"offset":7840},"indent":[]}}],"position":{"start":{"line":185,"column":1,"offset":7708},"end":{"line":185,"column":133,"offset":7840},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":187,"column":4,"offset":7845},"end":{"line":187,"column":12,"offset":7853},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":7842},"end":{"line":187,"column":12,"offset":7853},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":189,"column":1,"offset":7855},"end":{"line":189,"column":193,"offset":8047},"indent":[]}}],"position":{"start":{"line":189,"column":1,"offset":7855},"end":{"line":189,"column":193,"offset":8047},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":191,"column":4,"offset":8052},"end":{"line":191,"column":62,"offset":8110},"indent":[]}}],"position":{"start":{"line":191,"column":4,"offset":8052},"end":{"line":191,"column":62,"offset":8110},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":8049},"end":{"line":191,"column":62,"offset":8110},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":192,"column":4,"offset":8114},"end":{"line":192,"column":69,"offset":8179},"indent":[]}}],"position":{"start":{"line":192,"column":4,"offset":8114},"end":{"line":192,"column":69,"offset":8179},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":8111},"end":{"line":192,"column":69,"offset":8179},"indent":[]}}],"position":{"start":{"line":191,"column":1,"offset":8049},"end":{"line":192,"column":69,"offset":8179},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":194,"column":1,"offset":8181},"end":{"line":194,"column":99,"offset":8279},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":8181},"end":{"line":194,"column":99,"offset":8279},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":196,"column":5,"offset":8285},"end":{"line":196,"column":14,"offset":8294},"indent":[]}}],"position":{"start":{"line":196,"column":1,"offset":8281},"end":{"line":196,"column":14,"offset":8294},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":198,"column":1,"offset":8296},"end":{"line":198,"column":71,"offset":8366},"indent":[]}}],"position":{"start":{"line":198,"column":1,"offset":8296},"end":{"line":198,"column":71,"offset":8366},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":200,"column":3,"offset":8370},"end":{"line":200,"column":47,"offset":8414},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":200,"column":47,"offset":8414},"end":{"line":200,"column":79,"offset":8446},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":200,"column":79,"offset":8446},"end":{"line":200,"column":198,"offset":8565},"indent":[]}}],"position":{"start":{"line":200,"column":3,"offset":8370},"end":{"line":200,"column":198,"offset":8565},"indent":[]}}],"position":{"start":{"line":200,"column":1,"offset":8368},"end":{"line":200,"column":198,"offset":8565},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":202,"column":1,"offset":8567},"end":{"line":204,"column":4,"offset":8630},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":206,"column":5,"offset":8636},"end":{"line":206,"column":14,"offset":8645},"indent":[]}}],"position":{"start":{"line":206,"column":1,"offset":8632},"end":{"line":206,"column":14,"offset":8645},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":208,"column":1,"offset":8647},"end":{"line":208,"column":56,"offset":8702},"indent":[]}}],"position":{"start":{"line":208,"column":1,"offset":8647},"end":{"line":208,"column":56,"offset":8702},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":209,"column":3,"offset":8705},"end":{"line":209,"column":52,"offset":8754},"indent":[]}}],"position":{"start":{"line":209,"column":3,"offset":8705},"end":{"line":209,"column":52,"offset":8754},"indent":[]}}],"position":{"start":{"line":209,"column":3,"offset":8705},"end":{"line":209,"column":52,"offset":8754},"indent":[]}}],"position":{"start":{"line":209,"column":1,"offset":8703},"end":{"line":209,"column":52,"offset":8754},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":211,"column":1,"offset":8756},"end":{"line":211,"column":3,"offset":8758},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":211,"column":3,"offset":8758},"end":{"line":211,"column":9,"offset":8764},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":211,"column":9,"offset":8764},"end":{"line":211,"column":223,"offset":8978},"indent":[]}}],"position":{"start":{"line":211,"column":1,"offset":8756},"end":{"line":211,"column":223,"offset":8978},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":213,"column":3,"offset":8982},"end":{"line":213,"column":159,"offset":9138},"indent":[]}}],"position":{"start":{"line":213,"column":3,"offset":8982},"end":{"line":213,"column":159,"offset":9138},"indent":[]}}],"position":{"start":{"line":213,"column":1,"offset":8980},"end":{"line":213,"column":159,"offset":9138},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":215,"column":1,"offset":9140},"end":{"line":218,"column":4,"offset":9317},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":220,"column":1,"offset":9319},"end":{"line":220,"column":160,"offset":9478},"indent":[]}}],"position":{"start":{"line":220,"column":1,"offset":9319},"end":{"line":220,"column":160,"offset":9478},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":222,"column":3,"offset":9482},"end":{"line":222,"column":31,"offset":9510},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":222,"column":31,"offset":9510},"end":{"line":222,"column":101,"offset":9580},"indent":[]}}],"position":{"start":{"line":222,"column":3,"offset":9482},"end":{"line":222,"column":101,"offset":9580},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":9480},"end":{"line":222,"column":101,"offset":9580},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":224,"column":1,"offset":9582},"end":{"line":227,"column":4,"offset":9754},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":229,"column":1,"offset":9756},"end":{"line":229,"column":73,"offset":9828},"indent":[]}}],"position":{"start":{"line":229,"column":1,"offset":9756},"end":{"line":229,"column":73,"offset":9828},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":232,"column":3,"offset":9833},"end":{"line":232,"column":31,"offset":9861},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":232,"column":31,"offset":9861},"end":{"line":232,"column":101,"offset":9931},"indent":[]}}],"position":{"start":{"line":232,"column":3,"offset":9833},"end":{"line":232,"column":101,"offset":9931},"indent":[]}}],"position":{"start":{"line":232,"column":1,"offset":9831},"end":{"line":232,"column":101,"offset":9931},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":234,"column":1,"offset":9933},"end":{"line":237,"column":4,"offset":10105},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":239,"column":1,"offset":10107},"end":{"line":239,"column":62,"offset":10168},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":239,"column":63,"offset":10169},"end":{"line":239,"column":75,"offset":10181},"indent":[]}}],"position":{"start":{"line":239,"column":62,"offset":10168},"end":{"line":239,"column":143,"offset":10249},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":239,"column":143,"offset":10249},"end":{"line":239,"column":150,"offset":10256},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":239,"column":150,"offset":10256},"end":{"line":239,"column":169,"offset":10275},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":239,"column":169,"offset":10275},"end":{"line":239,"column":170,"offset":10276},"indent":[]}}],"position":{"start":{"line":239,"column":1,"offset":10107},"end":{"line":239,"column":170,"offset":10276},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":241,"column":1,"offset":10278},"end":{"line":243,"column":4,"offset":10305},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":245,"column":1,"offset":10307},"end":{"line":245,"column":58,"offset":10364},"indent":[]}}],"position":{"start":{"line":245,"column":1,"offset":10307},"end":{"line":245,"column":58,"offset":10364},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":247,"column":1,"offset":10366},"end":{"line":250,"column":4,"offset":10436},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":252,"column":5,"offset":10442},"end":{"line":252,"column":8,"offset":10445},"indent":[]}}],"position":{"start":{"line":252,"column":1,"offset":10438},"end":{"line":252,"column":8,"offset":10445},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":254,"column":1,"offset":10447},"end":{"line":254,"column":280,"offset":10726},"indent":[]}}],"position":{"start":{"line":254,"column":1,"offset":10447},"end":{"line":254,"column":280,"offset":10726},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":256,"column":1,"offset":10728},"end":{"line":256,"column":37,"offset":10764},"indent":[]}}],"position":{"start":{"line":256,"column":1,"offset":10728},"end":{"line":256,"column":37,"offset":10764},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":258,"column":1,"offset":10766},"end":{"line":260,"column":4,"offset":10939},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":262,"column":1,"offset":10941},"end":{"line":262,"column":25,"offset":10965},"indent":[]}}],"position":{"start":{"line":262,"column":1,"offset":10941},"end":{"line":262,"column":25,"offset":10965},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":264,"column":1,"offset":10967},"end":{"line":267,"column":4,"offset":11071},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":269,"column":1,"offset":11073},"end":{"line":269,"column":118,"offset":11190},"indent":[]}}],"position":{"start":{"line":269,"column":1,"offset":11073},"end":{"line":269,"column":118,"offset":11190},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":271,"column":1,"offset":11192},"end":{"line":291,"column":4,"offset":11699},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":293,"column":1,"offset":11701},"end":{"line":293,"column":14,"offset":11714},"indent":[]}}],"position":{"start":{"line":293,"column":1,"offset":11701},"end":{"line":293,"column":14,"offset":11714},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":295,"column":1,"offset":11716},"end":{"line":297,"column":4,"offset":11752},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":299,"column":1,"offset":11754},"end":{"line":299,"column":91,"offset":11844},"indent":[]}}],"position":{"start":{"line":299,"column":1,"offset":11754},"end":{"line":299,"column":91,"offset":11844},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":301,"column":1,"offset":11846},"end":{"line":309,"column":4,"offset":12219},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":311,"column":1,"offset":12221},"end":{"line":311,"column":145,"offset":12365},"indent":[]}}],"position":{"start":{"line":311,"column":1,"offset":12221},"end":{"line":311,"column":145,"offset":12365},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":313,"column":5,"offset":12371},"end":{"line":313,"column":17,"offset":12383},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":12367},"end":{"line":313,"column":17,"offset":12383},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":315,"column":1,"offset":12385},"end":{"line":315,"column":300,"offset":12684},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12385},"end":{"line":315,"column":300,"offset":12684},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":317,"column":1,"offset":12686},"end":{"line":317,"column":178,"offset":12863},"indent":[]}}],"position":{"start":{"line":317,"column":1,"offset":12686},"end":{"line":317,"column":178,"offset":12863},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":319,"column":1,"offset":12865},"end":{"line":319,"column":48,"offset":12912},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":12865},"end":{"line":319,"column":48,"offset":12912},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":321,"column":1,"offset":12914},"end":{"line":323,"column":4,"offset":12954},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":325,"column":1,"offset":12956},"end":{"line":325,"column":104,"offset":13059},"indent":[]}}],"position":{"start":{"line":325,"column":1,"offset":12956},"end":{"line":325,"column":104,"offset":13059},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":327,"column":1,"offset":13061},"end":{"line":335,"column":4,"offset":13331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":337,"column":1,"offset":13333},"end":{"line":337,"column":28,"offset":13360},"indent":[]}}],"position":{"start":{"line":337,"column":1,"offset":13333},"end":{"line":337,"column":28,"offset":13360},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":339,"column":1,"offset":13362},"end":{"line":341,"column":4,"offset":13406},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":343,"column":1,"offset":13408},"end":{"line":343,"column":48,"offset":13455},"indent":[]}}],"position":{"start":{"line":343,"column":1,"offset":13408},"end":{"line":343,"column":48,"offset":13455},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":345,"column":1,"offset":13457},"end":{"line":347,"column":4,"offset":13479},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":349,"column":1,"offset":13481},"end":{"line":349,"column":72,"offset":13552},"indent":[]}}],"position":{"start":{"line":349,"column":1,"offset":13481},"end":{"line":349,"column":72,"offset":13552},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":351,"column":1,"offset":13554},"end":{"line":353,"column":4,"offset":13611},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":355,"column":4,"offset":13616},"end":{"line":355,"column":11,"offset":13623},"indent":[]}}],"position":{"start":{"line":355,"column":1,"offset":13613},"end":{"line":355,"column":11,"offset":13623},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":357,"column":1,"offset":13625},"end":{"line":357,"column":283,"offset":13907},"indent":[]}}],"position":{"start":{"line":357,"column":1,"offset":13625},"end":{"line":357,"column":283,"offset":13907},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":359,"column":3,"offset":13911},"end":{"line":359,"column":54,"offset":13962},"indent":[]}}],"position":{"start":{"line":359,"column":3,"offset":13911},"end":{"line":359,"column":54,"offset":13962},"indent":[]}}],"position":{"start":{"line":359,"column":1,"offset":13909},"end":{"line":359,"column":54,"offset":13962},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":361,"column":5,"offset":13968},"end":{"line":361,"column":14,"offset":13977},"indent":[]}}],"position":{"start":{"line":361,"column":1,"offset":13964},"end":{"line":361,"column":14,"offset":13977},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":363,"column":1,"offset":13979},"end":{"line":363,"column":68,"offset":14046},"indent":[]}}],"position":{"start":{"line":363,"column":1,"offset":13979},"end":{"line":363,"column":68,"offset":14046},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":365,"column":1,"offset":14048},"end":{"line":368,"column":4,"offset":14199},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":370,"column":1,"offset":14201},"end":{"line":370,"column":46,"offset":14246},"indent":[]}}],"position":{"start":{"line":370,"column":1,"offset":14201},"end":{"line":370,"column":46,"offset":14246},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":372,"column":3,"offset":14250},"end":{"line":372,"column":103,"offset":14350},"indent":[]}}],"position":{"start":{"line":372,"column":3,"offset":14250},"end":{"line":372,"column":103,"offset":14350},"indent":[]}}],"position":{"start":{"line":372,"column":1,"offset":14248},"end":{"line":372,"column":103,"offset":14350},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":374,"column":1,"offset":14352},"end":{"line":379,"column":4,"offset":14562},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":381,"column":1,"offset":14564},"end":{"line":381,"column":151,"offset":14714},"indent":[]}}],"position":{"start":{"line":381,"column":1,"offset":14564},"end":{"line":381,"column":151,"offset":14714},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":383,"column":3,"offset":14718},"end":{"line":383,"column":22,"offset":14737},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":383,"column":22,"offset":14737},"end":{"line":383,"column":26,"offset":14741},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":383,"column":26,"offset":14741},"end":{"line":383,"column":40,"offset":14755},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":383,"column":40,"offset":14755},"end":{"line":383,"column":50,"offset":14765},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":383,"column":50,"offset":14765},"end":{"line":383,"column":98,"offset":14813},"indent":[]}}],"position":{"start":{"line":383,"column":3,"offset":14718},"end":{"line":383,"column":98,"offset":14813},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14716},"end":{"line":383,"column":98,"offset":14813},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":385,"column":1,"offset":14815},"end":{"line":389,"column":4,"offset":14977},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":391,"column":1,"offset":14979},"end":{"line":391,"column":72,"offset":15050},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":391,"column":72,"offset":15050},"end":{"line":391,"column":84,"offset":15062},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":391,"column":84,"offset":15062},"end":{"line":391,"column":102,"offset":15080},"indent":[]}}],"position":{"start":{"line":391,"column":1,"offset":14979},"end":{"line":391,"column":102,"offset":15080},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":393,"column":1,"offset":15082},"end":{"line":396,"column":4,"offset":15156},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":398,"column":5,"offset":15162},"end":{"line":398,"column":8,"offset":15165},"indent":[]}}],"position":{"start":{"line":398,"column":1,"offset":15158},"end":{"line":398,"column":8,"offset":15165},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":400,"column":1,"offset":15167},"end":{"line":400,"column":176,"offset":15342},"indent":[]}}],"position":{"start":{"line":400,"column":1,"offset":15167},"end":{"line":400,"column":176,"offset":15342},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":402,"column":1,"offset":15344},"end":{"line":409,"column":4,"offset":15641},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":411,"column":1,"offset":15643},"end":{"line":411,"column":60,"offset":15702},"indent":[]}}],"position":{"start":{"line":411,"column":1,"offset":15643},"end":{"line":411,"column":60,"offset":15702},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":413,"column":1,"offset":15704},"end":{"line":417,"column":4,"offset":15830},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":419,"column":1,"offset":15832},"end":{"line":419,"column":63,"offset":15894},"indent":[]}}],"position":{"start":{"line":419,"column":1,"offset":15832},"end":{"line":419,"column":63,"offset":15894},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":421,"column":1,"offset":15896},"end":{"line":441,"column":4,"offset":16403},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":443,"column":1,"offset":16405},"end":{"line":443,"column":99,"offset":16503},"indent":[]}}],"position":{"start":{"line":443,"column":1,"offset":16405},"end":{"line":443,"column":99,"offset":16503},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":445,"column":1,"offset":16505},"end":{"line":448,"column":4,"offset":16607},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":450,"column":1,"offset":16609},"end":{"line":450,"column":37,"offset":16645},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":450,"column":37,"offset":16645},"end":{"line":450,"column":47,"offset":16655},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":450,"column":47,"offset":16655},"end":{"line":450,"column":89,"offset":16697},"indent":[]}}],"position":{"start":{"line":450,"column":1,"offset":16609},"end":{"line":450,"column":89,"offset":16697},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":452,"column":1,"offset":16699},"end":{"line":456,"column":4,"offset":16824},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":458,"column":1,"offset":16826},"end":{"line":458,"column":78,"offset":16903},"indent":[]}}],"position":{"start":{"line":458,"column":1,"offset":16826},"end":{"line":458,"column":78,"offset":16903},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":460,"column":1,"offset":16905},"end":{"line":464,"column":4,"offset":17009},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":466,"column":1,"offset":17011},"end":{"line":466,"column":75,"offset":17085},"indent":[]}}],"position":{"start":{"line":466,"column":1,"offset":17011},"end":{"line":466,"column":75,"offset":17085},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":468,"column":1,"offset":17087},"end":{"line":472,"column":4,"offset":17160},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":474,"column":1,"offset":17162},"end":{"line":474,"column":145,"offset":17306},"indent":[]}}],"position":{"start":{"line":474,"column":1,"offset":17162},"end":{"line":474,"column":145,"offset":17306},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":476,"column":5,"offset":17312},"end":{"line":476,"column":17,"offset":17324},"indent":[]}}],"position":{"start":{"line":476,"column":1,"offset":17308},"end":{"line":476,"column":17,"offset":17324},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":478,"column":1,"offset":17326},"end":{"line":478,"column":300,"offset":17625},"indent":[]}}],"position":{"start":{"line":478,"column":1,"offset":17326},"end":{"line":478,"column":300,"offset":17625},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":480,"column":1,"offset":17627},"end":{"line":480,"column":178,"offset":17804},"indent":[]}}],"position":{"start":{"line":480,"column":1,"offset":17627},"end":{"line":480,"column":178,"offset":17804},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":482,"column":1,"offset":17806},"end":{"line":482,"column":48,"offset":17853},"indent":[]}}],"position":{"start":{"line":482,"column":1,"offset":17806},"end":{"line":482,"column":48,"offset":17853},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":484,"column":1,"offset":17855},"end":{"line":486,"column":4,"offset":17899},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":488,"column":1,"offset":17901},"end":{"line":488,"column":104,"offset":18004},"indent":[]}}],"position":{"start":{"line":488,"column":1,"offset":17901},"end":{"line":488,"column":104,"offset":18004},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":490,"column":1,"offset":18006},"end":{"line":498,"column":4,"offset":18276},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":500,"column":1,"offset":18278},"end":{"line":500,"column":28,"offset":18305},"indent":[]}}],"position":{"start":{"line":500,"column":1,"offset":18278},"end":{"line":500,"column":28,"offset":18305},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":502,"column":1,"offset":18307},"end":{"line":504,"column":4,"offset":18355},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":506,"column":1,"offset":18357},"end":{"line":506,"column":48,"offset":18404},"indent":[]}}],"position":{"start":{"line":506,"column":1,"offset":18357},"end":{"line":506,"column":48,"offset":18404},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":508,"column":1,"offset":18406},"end":{"line":510,"column":4,"offset":18428},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":512,"column":1,"offset":18430},"end":{"line":512,"column":72,"offset":18501},"indent":[]}}],"position":{"start":{"line":512,"column":1,"offset":18430},"end":{"line":512,"column":72,"offset":18501},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":514,"column":1,"offset":18503},"end":{"line":516,"column":4,"offset":18564},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":519,"column":1,"offset":18567},"end":{"line":519,"column":31,"offset":18597},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":519,"column":31,"offset":18597}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example:`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`kerberos`}{`-`}{`camera1`}{` \\\\`}{`\n`}{`-`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/config:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`config`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/capture:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`capture`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/logs:/`}{`etc`}{`/`}{`opt`}{`/`}{`kerberosio`}{`/`}{`logs`}{` \\\\`}{`\n`}{`-`}{`v`}{` ~/webconfig:/`}{`var`}{`/`}{`www`}{`/web/config \\\\`}{`\n`}{`-`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`Learn more about volumes in this tutorial.`}

\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board.`}

\n

{`To fill the gap, regarding the latter, we can rely on another solution called `}{`Balena.io`}{`. Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows).`}

\n

{`On top of supporting a lot of boars,`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-e84cb24fa982c1f2afd788562ec84293.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-e84cb24fa982c1f2afd788562ec84293.json new file mode 100644 index 0000000..d33c1f2 --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-e84cb24fa982c1f2afd788562ec84293.json @@ -0,0 +1 @@ +{"expireTime":9007200842068565000,"key":"gatsby-plugin-mdx-entire-payload-a34b19bf8640ae759c3161f95b2171b3-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":4,"offset":1137},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Plug and play","position":{"start":{"line":25,"column":3,"offset":1141},"end":{"line":25,"column":16,"offset":1154},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1139},"end":{"line":25,"column":16,"offset":1154},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.","position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1156},"end":{"line":27,"column":156,"offset":1311},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":29,"column":4,"offset":1316},"end":{"line":29,"column":8,"offset":1320},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1313},"end":{"line":29,"column":8,"offset":1320},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1322},"end":{"line":31,"column":229,"offset":1550},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1552},"end":{"line":33,"column":197,"offset":1748},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":35,"column":5,"offset":1754},"end":{"line":35,"column":11,"offset":1760},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1750},"end":{"line":35,"column":11,"offset":1760},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":63,"offset":1824},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":37,"column":64,"offset":1825},"end":{"line":37,"column":85,"offset":1846},"indent":[]}}],"position":{"start":{"line":37,"column":63,"offset":1824},"end":{"line":37,"column":123,"offset":1884},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":37,"column":123,"offset":1884},"end":{"line":37,"column":124,"offset":1885},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1762},"end":{"line":37,"column":124,"offset":1885},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos Open Source installer","position":{"start":{"line":39,"column":5,"offset":1891},"end":{"line":39,"column":35,"offset":1921},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":1887},"end":{"line":39,"column":35,"offset":1921},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":1923},"end":{"line":41,"column":228,"offset":2150},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2152},"end":{"line":43,"column":67,"offset":2218},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2220},"end":{"line":45,"column":50,"offset":2269},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":3,"offset":2273},"end":{"line":47,"column":49,"offset":2319},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2271},"end":{"line":47,"column":49,"offset":2319},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":49,"column":5,"offset":2325},"end":{"line":49,"column":11,"offset":2331},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2321},"end":{"line":49,"column":11,"offset":2331},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2333},"end":{"line":51,"column":160,"offset":2492},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":13,"offset":2506},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":53,"column":14,"offset":2507},"end":{"line":53,"column":28,"offset":2521},"indent":[]}}],"position":{"start":{"line":53,"column":13,"offset":2506},"end":{"line":53,"column":75,"offset":2568},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":53,"column":75,"offset":2568},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":4,"offset":2497},"end":{"line":53,"column":76,"offset":2569},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":53,"column":76,"offset":2569},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":4,"offset":2573},"end":{"line":54,"column":41,"offset":2610},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2570},"end":{"line":54,"column":41,"offset":2610},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":4,"offset":2614},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2611},"end":{"line":55,"column":60,"offset":2670},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2494},"end":{"line":55,"column":60,"offset":2670},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":57,"column":2,"offset":2673},"end":{"line":57,"column":64,"offset":2735},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2672},"end":{"line":57,"column":96,"offset":2767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}}],"position":{"start":{"line":59,"column":1,"offset":2769},"end":{"line":59,"column":204,"offset":2972},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":61,"column":6,"offset":2979},"end":{"line":61,"column":24,"offset":2997},"indent":[]}}],"position":{"start":{"line":61,"column":1,"offset":2974},"end":{"line":61,"column":24,"offset":2997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":95,"offset":3093},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":63,"column":95,"offset":3093},"end":{"line":63,"column":110,"offset":3108},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":63,"column":110,"offset":3108},"end":{"line":63,"column":222,"offset":3220},"indent":[]}}],"position":{"start":{"line":63,"column":1,"offset":2999},"end":{"line":63,"column":222,"offset":3220},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":65,"column":1,"offset":3222},"end":{"line":73,"column":4,"offset":3331},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":75,"column":6,"offset":3338},"end":{"line":75,"column":31,"offset":3363},"indent":[]}}],"position":{"start":{"line":75,"column":1,"offset":3333},"end":{"line":75,"column":31,"offset":3363},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":79,"offset":3443},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":77,"column":79,"offset":3443},"end":{"line":77,"column":95,"offset":3459},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":77,"column":95,"offset":3459},"end":{"line":77,"column":137,"offset":3501},"indent":[]}}],"position":{"start":{"line":77,"column":1,"offset":3365},"end":{"line":77,"column":137,"offset":3501},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":79,"column":1,"offset":3503},"end":{"line":89,"column":4,"offset":3871},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":3877},"end":{"line":91,"column":30,"offset":3902},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":3873},"end":{"line":91,"column":30,"offset":3902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":3904},"end":{"line":93,"column":464,"offset":4367},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}}],"position":{"start":{"line":95,"column":1,"offset":4369},"end":{"line":95,"column":61,"offset":4429},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":97,"column":5,"offset":4435},"end":{"line":97,"column":28,"offset":4458},"indent":[]}}],"position":{"start":{"line":97,"column":1,"offset":4431},"end":{"line":97,"column":28,"offset":4458},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":95,"offset":4554},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":99,"column":95,"offset":4554},"end":{"line":99,"column":100,"offset":4559},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":99,"column":100,"offset":4559},"end":{"line":99,"column":101,"offset":4560},"indent":[]}}],"position":{"start":{"line":99,"column":1,"offset":4460},"end":{"line":99,"column":101,"offset":4560},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":101,"column":1,"offset":4562},"end":{"line":105,"column":4,"offset":4679},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":80,"offset":4760},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":107,"column":80,"offset":4760},"end":{"line":107,"column":101,"offset":4781},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":107,"column":101,"offset":4781},"end":{"line":107,"column":162,"offset":4842},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4681},"end":{"line":107,"column":162,"offset":4842},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":109,"column":1,"offset":4844},"end":{"line":112,"column":4,"offset":4933},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":114,"column":4,"offset":4938},"end":{"line":114,"column":10,"offset":4944},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":4935},"end":{"line":114,"column":10,"offset":4944},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":339,"offset":5284},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":116,"column":340,"offset":5285},"end":{"line":116,"column":354,"offset":5299},"indent":[]}}],"position":{"start":{"line":116,"column":339,"offset":5284},"end":{"line":116,"column":390,"offset":5335},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":116,"column":390,"offset":5335},"end":{"line":116,"column":391,"offset":5336},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":4946},"end":{"line":116,"column":391,"offset":5336},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":118,"column":5,"offset":5342},"end":{"line":118,"column":18,"offset":5355},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5338},"end":{"line":118,"column":18,"offset":5355},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":3,"offset":5359},"end":{"line":120,"column":50,"offset":5406},"indent":[]}}],"position":{"start":{"line":120,"column":1,"offset":5357},"end":{"line":120,"column":50,"offset":5406},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":122,"column":5,"offset":5412},"end":{"line":122,"column":11,"offset":5418},"indent":[]}}],"position":{"start":{"line":122,"column":1,"offset":5408},"end":{"line":122,"column":11,"offset":5418},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":64,"offset":5483},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":124,"column":65,"offset":5484},"end":{"line":124,"column":86,"offset":5505},"indent":[]}}],"position":{"start":{"line":124,"column":64,"offset":5483},"end":{"line":124,"column":126,"offset":5545},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":124,"column":126,"offset":5545},"end":{"line":124,"column":127,"offset":5546},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5420},"end":{"line":124,"column":127,"offset":5546},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":126,"column":5,"offset":5552},"end":{"line":126,"column":26,"offset":5573},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5548},"end":{"line":126,"column":26,"offset":5573},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}}],"position":{"start":{"line":128,"column":1,"offset":5575},"end":{"line":128,"column":126,"offset":5700},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":130,"column":1,"offset":5702},"end":{"line":132,"column":4,"offset":5741},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5743},"end":{"line":134,"column":187,"offset":5929},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":136,"column":1,"offset":5931},"end":{"line":138,"column":4,"offset":6009},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6011},"end":{"line":140,"column":153,"offset":6163},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":142,"column":1,"offset":6165},"end":{"line":145,"column":4,"offset":6312},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6314},"end":{"line":147,"column":100,"offset":6413},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":148,"column":1,"offset":6414},"end":{"line":152,"column":4,"offset":6483},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":154,"column":5,"offset":6489},"end":{"line":154,"column":12,"offset":6496},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6485},"end":{"line":154,"column":12,"offset":6496},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6498},"end":{"line":156,"column":64,"offset":6561},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":3,"offset":6564},"end":{"line":157,"column":25,"offset":6586},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":157,"column":25,"offset":6586},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":3,"offset":6589},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":158,"column":1,"offset":6587},"end":{"line":158,"column":59,"offset":6645},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6562},"end":{"line":158,"column":59,"offset":6645},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":160,"column":4,"offset":6650},"end":{"line":160,"column":10,"offset":6656},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":6647},"end":{"line":160,"column":10,"offset":6656},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. By default we only support the Raspberry Pi baord, however ","position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":189,"offset":6846},"indent":[]}}],"position":{"start":{"line":162,"column":1,"offset":6658},"end":{"line":162,"column":189,"offset":6846},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Especially in the worl\n even on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.","position":{"start":{"line":164,"column":1,"offset":6848},"end":{"line":165,"column":128,"offset":6998},"indent":[1]}}],"position":{"start":{"line":164,"column":1,"offset":6848},"end":{"line":165,"column":128,"offset":6998},"indent":[1]}},{"type":"thematicBreak","position":{"start":{"line":167,"column":1,"offset":7000},"end":{"line":167,"column":4,"offset":7003},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":169,"column":3,"offset":7007},"end":{"line":169,"column":11,"offset":7015},"indent":[]}}],"position":{"start":{"line":169,"column":1,"offset":7005},"end":{"line":169,"column":11,"offset":7015},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.","position":{"start":{"line":171,"column":1,"offset":7017},"end":{"line":171,"column":133,"offset":7149},"indent":[]}}],"position":{"start":{"line":171,"column":1,"offset":7017},"end":{"line":171,"column":133,"offset":7149},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":173,"column":4,"offset":7154},"end":{"line":173,"column":12,"offset":7162},"indent":[]}}],"position":{"start":{"line":173,"column":1,"offset":7151},"end":{"line":173,"column":12,"offset":7162},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":175,"column":1,"offset":7164},"end":{"line":175,"column":193,"offset":7356},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7164},"end":{"line":175,"column":193,"offset":7356},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":177,"column":4,"offset":7361},"end":{"line":177,"column":62,"offset":7419},"indent":[]}}],"position":{"start":{"line":177,"column":4,"offset":7361},"end":{"line":177,"column":62,"offset":7419},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7358},"end":{"line":177,"column":62,"offset":7419},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":178,"column":4,"offset":7423},"end":{"line":178,"column":69,"offset":7488},"indent":[]}}],"position":{"start":{"line":178,"column":4,"offset":7423},"end":{"line":178,"column":69,"offset":7488},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7420},"end":{"line":178,"column":69,"offset":7488},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7358},"end":{"line":178,"column":69,"offset":7488},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":180,"column":1,"offset":7490},"end":{"line":180,"column":99,"offset":7588},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7490},"end":{"line":180,"column":99,"offset":7588},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":182,"column":5,"offset":7594},"end":{"line":182,"column":14,"offset":7603},"indent":[]}}],"position":{"start":{"line":182,"column":1,"offset":7590},"end":{"line":182,"column":14,"offset":7603},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":184,"column":1,"offset":7605},"end":{"line":184,"column":71,"offset":7675},"indent":[]}}],"position":{"start":{"line":184,"column":1,"offset":7605},"end":{"line":184,"column":71,"offset":7675},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":186,"column":3,"offset":7679},"end":{"line":186,"column":47,"offset":7723},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":186,"column":47,"offset":7723},"end":{"line":186,"column":79,"offset":7755},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":186,"column":79,"offset":7755},"end":{"line":186,"column":198,"offset":7874},"indent":[]}}],"position":{"start":{"line":186,"column":3,"offset":7679},"end":{"line":186,"column":198,"offset":7874},"indent":[]}}],"position":{"start":{"line":186,"column":1,"offset":7677},"end":{"line":186,"column":198,"offset":7874},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":188,"column":1,"offset":7876},"end":{"line":190,"column":4,"offset":7939},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":192,"column":5,"offset":7945},"end":{"line":192,"column":14,"offset":7954},"indent":[]}}],"position":{"start":{"line":192,"column":1,"offset":7941},"end":{"line":192,"column":14,"offset":7954},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":194,"column":1,"offset":7956},"end":{"line":194,"column":56,"offset":8011},"indent":[]}}],"position":{"start":{"line":194,"column":1,"offset":7956},"end":{"line":194,"column":56,"offset":8011},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":195,"column":3,"offset":8014},"end":{"line":195,"column":52,"offset":8063},"indent":[]}}],"position":{"start":{"line":195,"column":3,"offset":8014},"end":{"line":195,"column":52,"offset":8063},"indent":[]}}],"position":{"start":{"line":195,"column":3,"offset":8014},"end":{"line":195,"column":52,"offset":8063},"indent":[]}}],"position":{"start":{"line":195,"column":1,"offset":8012},"end":{"line":195,"column":52,"offset":8063},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":197,"column":1,"offset":8065},"end":{"line":197,"column":3,"offset":8067},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":197,"column":3,"offset":8067},"end":{"line":197,"column":9,"offset":8073},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":197,"column":9,"offset":8073},"end":{"line":197,"column":223,"offset":8287},"indent":[]}}],"position":{"start":{"line":197,"column":1,"offset":8065},"end":{"line":197,"column":223,"offset":8287},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":199,"column":3,"offset":8291},"end":{"line":199,"column":159,"offset":8447},"indent":[]}}],"position":{"start":{"line":199,"column":3,"offset":8291},"end":{"line":199,"column":159,"offset":8447},"indent":[]}}],"position":{"start":{"line":199,"column":1,"offset":8289},"end":{"line":199,"column":159,"offset":8447},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":201,"column":1,"offset":8449},"end":{"line":204,"column":4,"offset":8626},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":206,"column":1,"offset":8628},"end":{"line":206,"column":160,"offset":8787},"indent":[]}}],"position":{"start":{"line":206,"column":1,"offset":8628},"end":{"line":206,"column":160,"offset":8787},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":208,"column":3,"offset":8791},"end":{"line":208,"column":31,"offset":8819},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":208,"column":31,"offset":8819},"end":{"line":208,"column":101,"offset":8889},"indent":[]}}],"position":{"start":{"line":208,"column":3,"offset":8791},"end":{"line":208,"column":101,"offset":8889},"indent":[]}}],"position":{"start":{"line":208,"column":1,"offset":8789},"end":{"line":208,"column":101,"offset":8889},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":210,"column":1,"offset":8891},"end":{"line":213,"column":4,"offset":9063},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":215,"column":1,"offset":9065},"end":{"line":215,"column":73,"offset":9137},"indent":[]}}],"position":{"start":{"line":215,"column":1,"offset":9065},"end":{"line":215,"column":73,"offset":9137},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":218,"column":3,"offset":9142},"end":{"line":218,"column":31,"offset":9170},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":218,"column":31,"offset":9170},"end":{"line":218,"column":101,"offset":9240},"indent":[]}}],"position":{"start":{"line":218,"column":3,"offset":9142},"end":{"line":218,"column":101,"offset":9240},"indent":[]}}],"position":{"start":{"line":218,"column":1,"offset":9140},"end":{"line":218,"column":101,"offset":9240},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":220,"column":1,"offset":9242},"end":{"line":223,"column":4,"offset":9414},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":225,"column":1,"offset":9416},"end":{"line":225,"column":62,"offset":9477},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":225,"column":63,"offset":9478},"end":{"line":225,"column":75,"offset":9490},"indent":[]}}],"position":{"start":{"line":225,"column":62,"offset":9477},"end":{"line":225,"column":143,"offset":9558},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":225,"column":143,"offset":9558},"end":{"line":225,"column":150,"offset":9565},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":225,"column":150,"offset":9565},"end":{"line":225,"column":169,"offset":9584},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":225,"column":169,"offset":9584},"end":{"line":225,"column":170,"offset":9585},"indent":[]}}],"position":{"start":{"line":225,"column":1,"offset":9416},"end":{"line":225,"column":170,"offset":9585},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":227,"column":1,"offset":9587},"end":{"line":229,"column":4,"offset":9614},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":231,"column":1,"offset":9616},"end":{"line":231,"column":58,"offset":9673},"indent":[]}}],"position":{"start":{"line":231,"column":1,"offset":9616},"end":{"line":231,"column":58,"offset":9673},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":233,"column":1,"offset":9675},"end":{"line":236,"column":4,"offset":9745},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":238,"column":5,"offset":9751},"end":{"line":238,"column":8,"offset":9754},"indent":[]}}],"position":{"start":{"line":238,"column":1,"offset":9747},"end":{"line":238,"column":8,"offset":9754},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":240,"column":1,"offset":9756},"end":{"line":240,"column":280,"offset":10035},"indent":[]}}],"position":{"start":{"line":240,"column":1,"offset":9756},"end":{"line":240,"column":280,"offset":10035},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":242,"column":1,"offset":10037},"end":{"line":242,"column":37,"offset":10073},"indent":[]}}],"position":{"start":{"line":242,"column":1,"offset":10037},"end":{"line":242,"column":37,"offset":10073},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":244,"column":1,"offset":10075},"end":{"line":246,"column":4,"offset":10248},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":248,"column":1,"offset":10250},"end":{"line":248,"column":25,"offset":10274},"indent":[]}}],"position":{"start":{"line":248,"column":1,"offset":10250},"end":{"line":248,"column":25,"offset":10274},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":250,"column":1,"offset":10276},"end":{"line":253,"column":4,"offset":10380},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":255,"column":1,"offset":10382},"end":{"line":255,"column":118,"offset":10499},"indent":[]}}],"position":{"start":{"line":255,"column":1,"offset":10382},"end":{"line":255,"column":118,"offset":10499},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":257,"column":1,"offset":10501},"end":{"line":277,"column":4,"offset":11008},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":279,"column":1,"offset":11010},"end":{"line":279,"column":14,"offset":11023},"indent":[]}}],"position":{"start":{"line":279,"column":1,"offset":11010},"end":{"line":279,"column":14,"offset":11023},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":281,"column":1,"offset":11025},"end":{"line":283,"column":4,"offset":11061},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":285,"column":1,"offset":11063},"end":{"line":285,"column":91,"offset":11153},"indent":[]}}],"position":{"start":{"line":285,"column":1,"offset":11063},"end":{"line":285,"column":91,"offset":11153},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":287,"column":1,"offset":11155},"end":{"line":295,"column":4,"offset":11528},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":297,"column":1,"offset":11530},"end":{"line":297,"column":145,"offset":11674},"indent":[]}}],"position":{"start":{"line":297,"column":1,"offset":11530},"end":{"line":297,"column":145,"offset":11674},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":299,"column":5,"offset":11680},"end":{"line":299,"column":17,"offset":11692},"indent":[]}}],"position":{"start":{"line":299,"column":1,"offset":11676},"end":{"line":299,"column":17,"offset":11692},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":301,"column":1,"offset":11694},"end":{"line":301,"column":300,"offset":11993},"indent":[]}}],"position":{"start":{"line":301,"column":1,"offset":11694},"end":{"line":301,"column":300,"offset":11993},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":303,"column":1,"offset":11995},"end":{"line":303,"column":178,"offset":12172},"indent":[]}}],"position":{"start":{"line":303,"column":1,"offset":11995},"end":{"line":303,"column":178,"offset":12172},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":305,"column":1,"offset":12174},"end":{"line":305,"column":48,"offset":12221},"indent":[]}}],"position":{"start":{"line":305,"column":1,"offset":12174},"end":{"line":305,"column":48,"offset":12221},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":307,"column":1,"offset":12223},"end":{"line":309,"column":4,"offset":12263},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":311,"column":1,"offset":12265},"end":{"line":311,"column":104,"offset":12368},"indent":[]}}],"position":{"start":{"line":311,"column":1,"offset":12265},"end":{"line":311,"column":104,"offset":12368},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":313,"column":1,"offset":12370},"end":{"line":321,"column":4,"offset":12640},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":323,"column":1,"offset":12642},"end":{"line":323,"column":28,"offset":12669},"indent":[]}}],"position":{"start":{"line":323,"column":1,"offset":12642},"end":{"line":323,"column":28,"offset":12669},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":325,"column":1,"offset":12671},"end":{"line":327,"column":4,"offset":12715},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":329,"column":1,"offset":12717},"end":{"line":329,"column":48,"offset":12764},"indent":[]}}],"position":{"start":{"line":329,"column":1,"offset":12717},"end":{"line":329,"column":48,"offset":12764},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":331,"column":1,"offset":12766},"end":{"line":333,"column":4,"offset":12788},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":335,"column":1,"offset":12790},"end":{"line":335,"column":72,"offset":12861},"indent":[]}}],"position":{"start":{"line":335,"column":1,"offset":12790},"end":{"line":335,"column":72,"offset":12861},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":337,"column":1,"offset":12863},"end":{"line":339,"column":4,"offset":12920},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":341,"column":4,"offset":12925},"end":{"line":341,"column":11,"offset":12932},"indent":[]}}],"position":{"start":{"line":341,"column":1,"offset":12922},"end":{"line":341,"column":11,"offset":12932},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":343,"column":1,"offset":12934},"end":{"line":343,"column":283,"offset":13216},"indent":[]}}],"position":{"start":{"line":343,"column":1,"offset":12934},"end":{"line":343,"column":283,"offset":13216},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":345,"column":3,"offset":13220},"end":{"line":345,"column":54,"offset":13271},"indent":[]}}],"position":{"start":{"line":345,"column":3,"offset":13220},"end":{"line":345,"column":54,"offset":13271},"indent":[]}}],"position":{"start":{"line":345,"column":1,"offset":13218},"end":{"line":345,"column":54,"offset":13271},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":347,"column":5,"offset":13277},"end":{"line":347,"column":14,"offset":13286},"indent":[]}}],"position":{"start":{"line":347,"column":1,"offset":13273},"end":{"line":347,"column":14,"offset":13286},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":349,"column":1,"offset":13288},"end":{"line":349,"column":68,"offset":13355},"indent":[]}}],"position":{"start":{"line":349,"column":1,"offset":13288},"end":{"line":349,"column":68,"offset":13355},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":351,"column":1,"offset":13357},"end":{"line":354,"column":4,"offset":13508},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":356,"column":1,"offset":13510},"end":{"line":356,"column":46,"offset":13555},"indent":[]}}],"position":{"start":{"line":356,"column":1,"offset":13510},"end":{"line":356,"column":46,"offset":13555},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":358,"column":3,"offset":13559},"end":{"line":358,"column":103,"offset":13659},"indent":[]}}],"position":{"start":{"line":358,"column":3,"offset":13559},"end":{"line":358,"column":103,"offset":13659},"indent":[]}}],"position":{"start":{"line":358,"column":1,"offset":13557},"end":{"line":358,"column":103,"offset":13659},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":360,"column":1,"offset":13661},"end":{"line":365,"column":4,"offset":13871},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":367,"column":1,"offset":13873},"end":{"line":367,"column":151,"offset":14023},"indent":[]}}],"position":{"start":{"line":367,"column":1,"offset":13873},"end":{"line":367,"column":151,"offset":14023},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":369,"column":3,"offset":14027},"end":{"line":369,"column":22,"offset":14046},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":369,"column":22,"offset":14046},"end":{"line":369,"column":26,"offset":14050},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":369,"column":26,"offset":14050},"end":{"line":369,"column":40,"offset":14064},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":369,"column":40,"offset":14064},"end":{"line":369,"column":50,"offset":14074},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":369,"column":50,"offset":14074},"end":{"line":369,"column":98,"offset":14122},"indent":[]}}],"position":{"start":{"line":369,"column":3,"offset":14027},"end":{"line":369,"column":98,"offset":14122},"indent":[]}}],"position":{"start":{"line":369,"column":1,"offset":14025},"end":{"line":369,"column":98,"offset":14122},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":371,"column":1,"offset":14124},"end":{"line":375,"column":4,"offset":14286},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":377,"column":1,"offset":14288},"end":{"line":377,"column":72,"offset":14359},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":377,"column":72,"offset":14359},"end":{"line":377,"column":84,"offset":14371},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":377,"column":84,"offset":14371},"end":{"line":377,"column":102,"offset":14389},"indent":[]}}],"position":{"start":{"line":377,"column":1,"offset":14288},"end":{"line":377,"column":102,"offset":14389},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":379,"column":1,"offset":14391},"end":{"line":382,"column":4,"offset":14465},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":384,"column":5,"offset":14471},"end":{"line":384,"column":8,"offset":14474},"indent":[]}}],"position":{"start":{"line":384,"column":1,"offset":14467},"end":{"line":384,"column":8,"offset":14474},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":386,"column":1,"offset":14476},"end":{"line":386,"column":176,"offset":14651},"indent":[]}}],"position":{"start":{"line":386,"column":1,"offset":14476},"end":{"line":386,"column":176,"offset":14651},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":388,"column":1,"offset":14653},"end":{"line":395,"column":4,"offset":14950},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":397,"column":1,"offset":14952},"end":{"line":397,"column":60,"offset":15011},"indent":[]}}],"position":{"start":{"line":397,"column":1,"offset":14952},"end":{"line":397,"column":60,"offset":15011},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":399,"column":1,"offset":15013},"end":{"line":403,"column":4,"offset":15139},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":405,"column":1,"offset":15141},"end":{"line":405,"column":63,"offset":15203},"indent":[]}}],"position":{"start":{"line":405,"column":1,"offset":15141},"end":{"line":405,"column":63,"offset":15203},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":407,"column":1,"offset":15205},"end":{"line":427,"column":4,"offset":15712},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":429,"column":1,"offset":15714},"end":{"line":429,"column":99,"offset":15812},"indent":[]}}],"position":{"start":{"line":429,"column":1,"offset":15714},"end":{"line":429,"column":99,"offset":15812},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":431,"column":1,"offset":15814},"end":{"line":434,"column":4,"offset":15916},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":436,"column":1,"offset":15918},"end":{"line":436,"column":37,"offset":15954},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":436,"column":37,"offset":15954},"end":{"line":436,"column":47,"offset":15964},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":436,"column":47,"offset":15964},"end":{"line":436,"column":89,"offset":16006},"indent":[]}}],"position":{"start":{"line":436,"column":1,"offset":15918},"end":{"line":436,"column":89,"offset":16006},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":438,"column":1,"offset":16008},"end":{"line":442,"column":4,"offset":16133},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":444,"column":1,"offset":16135},"end":{"line":444,"column":78,"offset":16212},"indent":[]}}],"position":{"start":{"line":444,"column":1,"offset":16135},"end":{"line":444,"column":78,"offset":16212},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":446,"column":1,"offset":16214},"end":{"line":450,"column":4,"offset":16318},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":452,"column":1,"offset":16320},"end":{"line":452,"column":75,"offset":16394},"indent":[]}}],"position":{"start":{"line":452,"column":1,"offset":16320},"end":{"line":452,"column":75,"offset":16394},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":454,"column":1,"offset":16396},"end":{"line":458,"column":4,"offset":16469},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":460,"column":1,"offset":16471},"end":{"line":460,"column":145,"offset":16615},"indent":[]}}],"position":{"start":{"line":460,"column":1,"offset":16471},"end":{"line":460,"column":145,"offset":16615},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":462,"column":5,"offset":16621},"end":{"line":462,"column":17,"offset":16633},"indent":[]}}],"position":{"start":{"line":462,"column":1,"offset":16617},"end":{"line":462,"column":17,"offset":16633},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":464,"column":1,"offset":16635},"end":{"line":464,"column":300,"offset":16934},"indent":[]}}],"position":{"start":{"line":464,"column":1,"offset":16635},"end":{"line":464,"column":300,"offset":16934},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":466,"column":1,"offset":16936},"end":{"line":466,"column":178,"offset":17113},"indent":[]}}],"position":{"start":{"line":466,"column":1,"offset":16936},"end":{"line":466,"column":178,"offset":17113},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":468,"column":1,"offset":17115},"end":{"line":468,"column":48,"offset":17162},"indent":[]}}],"position":{"start":{"line":468,"column":1,"offset":17115},"end":{"line":468,"column":48,"offset":17162},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":470,"column":1,"offset":17164},"end":{"line":472,"column":4,"offset":17208},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":474,"column":1,"offset":17210},"end":{"line":474,"column":104,"offset":17313},"indent":[]}}],"position":{"start":{"line":474,"column":1,"offset":17210},"end":{"line":474,"column":104,"offset":17313},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":476,"column":1,"offset":17315},"end":{"line":484,"column":4,"offset":17585},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":486,"column":1,"offset":17587},"end":{"line":486,"column":28,"offset":17614},"indent":[]}}],"position":{"start":{"line":486,"column":1,"offset":17587},"end":{"line":486,"column":28,"offset":17614},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":488,"column":1,"offset":17616},"end":{"line":490,"column":4,"offset":17664},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":492,"column":1,"offset":17666},"end":{"line":492,"column":48,"offset":17713},"indent":[]}}],"position":{"start":{"line":492,"column":1,"offset":17666},"end":{"line":492,"column":48,"offset":17713},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":494,"column":1,"offset":17715},"end":{"line":496,"column":4,"offset":17737},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":498,"column":1,"offset":17739},"end":{"line":498,"column":72,"offset":17810},"indent":[]}}],"position":{"start":{"line":498,"column":1,"offset":17739},"end":{"line":498,"column":72,"offset":17810},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":500,"column":1,"offset":17812},"end":{"line":502,"column":4,"offset":17873},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":505,"column":1,"offset":17876},"end":{"line":505,"column":31,"offset":17906},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":505,"column":31,"offset":17906}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug and play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n
\n

{`Plug and play`}

\n

{`Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running.`}

\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos Open Source installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Docker`}

\n

{`A Docker image (amd64, armv7, arm64) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. By default we only support the Raspberry Pi baord, however `}

\n

{`Especially in the worl\neven on a Raspberry Pi. However some you might need more control and flexibility. This is where Balena comes into the picture.`}

\n
\n

{`Advanced`}

\n

{`Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment.`}

\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-e8aa2a80b6d8b25efef29267ee82ea19.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-e8aa2a80b6d8b25efef29267ee82ea19.json index 547cdd7..4498809 100644 --- a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-e8aa2a80b6d8b25efef29267ee82ea19.json +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-e8aa2a80b6d8b25efef29267ee82ea19.json @@ -1 +1 @@ -{"expireTime":9007200841014174000,"key":"gatsby-plugin-mdx-entire-payload-a79531575b5a9e24fdd84c6824bcabed-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import { Playground, Props } from 'docz'","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":41,"offset":199},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":10,"column":3,"offset":203},"end":{"line":10,"column":12,"offset":212},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":201},"end":{"line":10,"column":12,"offset":212},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The machinery is the processing engine of Kerberos Open Source. It's an image processing framework, written in C++, who benefits from other third party libraries (OpenCV, etc). It takes images from the type of camera (USB-, IP- or RPi-camera) you've configured in the configuration files and executes one ore more algorithms and post-processes (e.g. save a snapshot). The configuration files allow you to define the type of camera, post-processes, conditions and much more; it's highly configurable. It's important to note that the machinery, out-of-the-box, can handle only one camera at a time.","position":{"start":{"line":12,"column":1,"offset":214},"end":{"line":12,"column":597,"offset":810},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":214},"end":{"line":12,"column":597,"offset":810},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Project structure","position":{"start":{"line":14,"column":4,"offset":815},"end":{"line":14,"column":21,"offset":832},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":812},"end":{"line":14,"column":21,"offset":832},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The machinery is an image processing framework which is devided into four steps:","position":{"start":{"line":16,"column":1,"offset":834},"end":{"line":16,"column":81,"offset":914},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":834},"end":{"line":16,"column":81,"offset":914},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"condition","position":{"start":{"line":18,"column":3,"offset":918},"end":{"line":18,"column":12,"offset":927},"indent":[]}}],"position":{"start":{"line":18,"column":3,"offset":918},"end":{"line":18,"column":12,"offset":927},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":916},"end":{"line":18,"column":12,"offset":927},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"algorithm","position":{"start":{"line":19,"column":3,"offset":930},"end":{"line":19,"column":12,"offset":939},"indent":[]}}],"position":{"start":{"line":19,"column":3,"offset":930},"end":{"line":19,"column":12,"offset":939},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":928},"end":{"line":19,"column":12,"offset":939},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"expositor","position":{"start":{"line":20,"column":3,"offset":942},"end":{"line":20,"column":12,"offset":951},"indent":[]}}],"position":{"start":{"line":20,"column":3,"offset":942},"end":{"line":20,"column":12,"offset":951},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":940},"end":{"line":20,"column":12,"offset":951},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"heuristic","position":{"start":{"line":21,"column":3,"offset":954},"end":{"line":21,"column":12,"offset":963},"indent":[]}}],"position":{"start":{"line":21,"column":3,"offset":954},"end":{"line":21,"column":12,"offset":963},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":952},"end":{"line":21,"column":12,"offset":963},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":916},"end":{"line":21,"column":12,"offset":963},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"The steps belong to a four passway; illustrated on the image below. In each cycle a sequence of images is processed. Each step will process the sequence, and will return some result to the next step. For example: an algorithm will process the images and returns an array to the Expositor, which contains boolean values. The steps are loosly coupled, so they have simple conventions, just like the example before.","position":{"start":{"line":23,"column":1,"offset":965},"end":{"line":23,"column":413,"offset":1377},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":965},"end":{"line":23,"column":413,"offset":1377},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Thanks to the loosly coupling, each step can be developed indepently. So algorithms, expositors, heuristics and conditions can be switched on the fly. This makes it easier for other developers who want to contribute to the machinery. They can create a new algorithm without knowing how a specific expositor or heuristic works. They just need to be aware of the convention an algorithm should meet.","position":{"start":{"line":25,"column":1,"offset":1379},"end":{"line":25,"column":398,"offset":1776},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1379},"end":{"line":25,"column":398,"offset":1776},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/machinery/project_structure.png","alt":"machinery project structure","position":{"start":{"line":27,"column":1,"offset":1778},"end":{"line":27,"column":84,"offset":1861},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1778},"end":{"line":27,"column":84,"offset":1861},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"These different steps can be configured by editing a couple of configurationn files located at ","position":{"start":{"line":29,"column":1,"offset":1863},"end":{"line":29,"column":96,"offset":1958},"indent":[]}},{"type":"inlineCode","value":"config/","position":{"start":{"line":29,"column":96,"offset":1958},"end":{"line":29,"column":105,"offset":1967},"indent":[]}},{"type":"text","value":". The main configuration file ","position":{"start":{"line":29,"column":105,"offset":1967},"end":{"line":29,"column":135,"offset":1997},"indent":[]}},{"type":"inlineCode","value":"config/config.xml","position":{"start":{"line":29,"column":135,"offset":1997},"end":{"line":29,"column":154,"offset":2016},"indent":[]}},{"type":"text","value":" looks like this:","position":{"start":{"line":29,"column":154,"offset":2016},"end":{"line":29,"column":171,"offset":2033},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1863},"end":{"line":29,"column":171,"offset":2033},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n \n frontdoor\n false\n Europe-Brussels\n RaspiCamera\n Mjpg\n Enabled\n DifferentialCollins\n Hull\n Sequence\n Video\n S3\n \n","position":{"start":{"line":31,"column":1,"offset":2035},"end":{"line":48,"column":4,"offset":2690},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Capture","position":{"start":{"line":50,"column":4,"offset":2695},"end":{"line":50,"column":11,"offset":2702},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":2692},"end":{"line":50,"column":11,"offset":2702},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can choose which capture device you will be using, you can use your old USB webcam, the popular Raspberry Pi camera or a state-of-the-art IP camera. The capture device will take pictures and deliver them to the algorithm if the conditions (the first step of the four passway) are valid.","position":{"start":{"line":52,"column":1,"offset":2704},"end":{"line":52,"column":291,"offset":2994},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2704},"end":{"line":52,"column":291,"offset":2994},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can change the capture device by changing the ","position":{"start":{"line":54,"column":1,"offset":2996},"end":{"line":54,"column":51,"offset":3046},"indent":[]}},{"type":"inlineCode","value":"config/config.xml","position":{"start":{"line":54,"column":51,"offset":3046},"end":{"line":54,"column":70,"offset":3065},"indent":[]}},{"type":"text","value":" file, and choose one of the following:","position":{"start":{"line":54,"column":70,"offset":3065},"end":{"line":54,"column":109,"offset":3104},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2996},"end":{"line":54,"column":109,"offset":3104},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"USBCamera","position":{"start":{"line":55,"column":3,"offset":3107},"end":{"line":55,"column":12,"offset":3116},"indent":[]}}],"position":{"start":{"line":55,"column":3,"offset":3107},"end":{"line":55,"column":12,"offset":3116},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":3105},"end":{"line":55,"column":12,"offset":3116},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"RaspiCamera","position":{"start":{"line":56,"column":3,"offset":3119},"end":{"line":56,"column":14,"offset":3130},"indent":[]}}],"position":{"start":{"line":56,"column":3,"offset":3119},"end":{"line":56,"column":14,"offset":3130},"indent":[]}}],"position":{"start":{"line":56,"column":1,"offset":3117},"end":{"line":56,"column":14,"offset":3130},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"IPCamera","position":{"start":{"line":57,"column":3,"offset":3133},"end":{"line":57,"column":11,"offset":3141},"indent":[]}}],"position":{"start":{"line":57,"column":3,"offset":3133},"end":{"line":57,"column":11,"offset":3141},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":3131},"end":{"line":57,"column":11,"offset":3141},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":3105},"end":{"line":57,"column":11,"offset":3141},"indent":[1,1]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n \n ...\n RaspiCamera\n ...\n \n","position":{"start":{"line":59,"column":1,"offset":3143},"end":{"line":68,"column":4,"offset":3295},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"USB camera","position":{"start":{"line":70,"column":5,"offset":3301},"end":{"line":70,"column":15,"offset":3311},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":3297},"end":{"line":70,"column":15,"offset":3311},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The machinery supports a whole range of USB cameras. You will find a complete list here. Make sure you have updated the web interface, to make the machinery aware you will be using an USB camera.","position":{"start":{"line":72,"column":1,"offset":3313},"end":{"line":72,"column":196,"offset":3508},"indent":[]}}],"position":{"start":{"line":72,"column":1,"offset":3313},"end":{"line":72,"column":196,"offset":3508},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":74,"column":6,"offset":3515},"end":{"line":74,"column":16,"offset":3525},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":3510},"end":{"line":74,"column":16,"offset":3525},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the USB camera can be found in the ","position":{"start":{"line":76,"column":1,"offset":3527},"end":{"line":76,"column":54,"offset":3580},"indent":[]}},{"type":"inlineCode","value":"config/capture.xml","position":{"start":{"line":76,"column":54,"offset":3580},"end":{"line":76,"column":74,"offset":3600},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":76,"column":74,"offset":3600},"end":{"line":76,"column":179,"offset":3705},"indent":[]}}],"position":{"start":{"line":76,"column":1,"offset":3527},"end":{"line":76,"column":179,"offset":3705},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n 1280\n 720\n 0\n 0\n 0\n \n","position":{"start":{"line":78,"column":1,"offset":3707},"end":{"line":88,"column":4,"offset":3985},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Framewidth and -height","position":{"start":{"line":90,"column":7,"offset":3993},"end":{"line":90,"column":29,"offset":4015},"indent":[]}}],"position":{"start":{"line":90,"column":1,"offset":3987},"end":{"line":90,"column":29,"offset":4015},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can set the resolution of the capture device, make sure the resolution you've defined is valid with your camera. Please check the specs of the USB camera you're using.","position":{"start":{"line":92,"column":1,"offset":4017},"end":{"line":92,"column":172,"offset":4188},"indent":[]}}],"position":{"start":{"line":92,"column":1,"offset":4017},"end":{"line":92,"column":172,"offset":4188},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Device number","position":{"start":{"line":94,"column":7,"offset":4196},"end":{"line":94,"column":20,"offset":4209},"indent":[]}}],"position":{"start":{"line":94,"column":1,"offset":4190},"end":{"line":94,"column":20,"offset":4209},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If more than one device is connected, you can specify the index of the USB-camera. The index is an integer (1-5).","position":{"start":{"line":96,"column":1,"offset":4211},"end":{"line":96,"column":114,"offset":4324},"indent":[]}}],"position":{"start":{"line":96,"column":1,"offset":4211},"end":{"line":96,"column":114,"offset":4324},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Delay","position":{"start":{"line":98,"column":7,"offset":4332},"end":{"line":98,"column":12,"offset":4337},"indent":[]}}],"position":{"start":{"line":98,"column":1,"offset":4326},"end":{"line":98,"column":12,"offset":4337},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can provide a delay/interval (milliseconds) between two captures.","position":{"start":{"line":100,"column":1,"offset":4339},"end":{"line":100,"column":70,"offset":4408},"indent":[]}}],"position":{"start":{"line":100,"column":1,"offset":4339},"end":{"line":100,"column":70,"offset":4408},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Angle","position":{"start":{"line":102,"column":7,"offset":4416},"end":{"line":102,"column":12,"offset":4421},"indent":[]}}],"position":{"start":{"line":102,"column":1,"offset":4410},"end":{"line":102,"column":12,"offset":4421},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By defining an angle (degrees), you can rotate the images taken by the capture device. For example if you would mount the camera upside down, than you could enter the value 180 as the angle; this will flip the images.","position":{"start":{"line":104,"column":1,"offset":4423},"end":{"line":104,"column":218,"offset":4640},"indent":[]}}],"position":{"start":{"line":104,"column":1,"offset":4423},"end":{"line":104,"column":218,"offset":4640},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Raspberry Pi Camera Module","position":{"start":{"line":106,"column":5,"offset":4646},"end":{"line":106,"column":31,"offset":4672},"indent":[]}}],"position":{"start":{"line":106,"column":1,"offset":4642},"end":{"line":106,"column":31,"offset":4672},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can use the Raspberry Pi Camera Module with the machinery. You just need to attach the camera module and you're ready to go. The Raspberry Pi Camera Module is enabled by default in the web.","position":{"start":{"line":108,"column":1,"offset":4674},"end":{"line":108,"column":194,"offset":4867},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":4674},"end":{"line":108,"column":194,"offset":4867},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":110,"column":6,"offset":4874},"end":{"line":110,"column":16,"offset":4884},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4869},"end":{"line":110,"column":16,"offset":4884},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Raspberry Pi Camera Module can be found in the config/capture.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":112,"column":1,"offset":4886},"end":{"line":112,"column":193,"offset":5078},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":4886},"end":{"line":112,"column":193,"offset":5078},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n 640\n 480\n 1400\n 0\n 30\n 0\n 0\n 0\n 50\n \n","position":{"start":{"line":114,"column":1,"offset":5080},"end":{"line":128,"column":4,"offset":5534},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Framewidth and -height","position":{"start":{"line":130,"column":7,"offset":5542},"end":{"line":130,"column":29,"offset":5564},"indent":[]}}],"position":{"start":{"line":130,"column":1,"offset":5536},"end":{"line":130,"column":29,"offset":5564},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can set the resolution of the camera module, make sure the resolution you've defined is valid.","position":{"start":{"line":132,"column":1,"offset":5566},"end":{"line":132,"column":99,"offset":5664},"indent":[]}}],"position":{"start":{"line":132,"column":1,"offset":5566},"end":{"line":132,"column":99,"offset":5664},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Delay","position":{"start":{"line":134,"column":7,"offset":5672},"end":{"line":134,"column":12,"offset":5677},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5666},"end":{"line":134,"column":12,"offset":5677},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can provide a delay/interval (milliseconds) between two captures.","position":{"start":{"line":136,"column":1,"offset":5679},"end":{"line":136,"column":70,"offset":5748},"indent":[]}}],"position":{"start":{"line":136,"column":1,"offset":5679},"end":{"line":136,"column":70,"offset":5748},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Angle","position":{"start":{"line":138,"column":7,"offset":5756},"end":{"line":138,"column":12,"offset":5761},"indent":[]}}],"position":{"start":{"line":138,"column":1,"offset":5750},"end":{"line":138,"column":12,"offset":5761},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By defining an angle (degrees), you can rotate the images taken by the capture device. For example if you would mount the camera upside down, than you could enter the value 180 as the angle; this will flip the images.","position":{"start":{"line":140,"column":1,"offset":5763},"end":{"line":140,"column":218,"offset":5980},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":5763},"end":{"line":140,"column":218,"offset":5980},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Framerate","position":{"start":{"line":142,"column":7,"offset":5988},"end":{"line":142,"column":16,"offset":5997},"indent":[]}}],"position":{"start":{"line":142,"column":1,"offset":5982},"end":{"line":142,"column":16,"offset":5997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The number of frames captures per second. Please note that this parameter will also be used if you're recording video. E.g. if you set this parameter to 20, you're recorded videos will also be 20 FPS.","position":{"start":{"line":144,"column":1,"offset":5999},"end":{"line":144,"column":201,"offset":6199},"indent":[]}}],"position":{"start":{"line":144,"column":1,"offset":5999},"end":{"line":144,"column":201,"offset":6199},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Sharpness, saturation, contrast, brightness","position":{"start":{"line":146,"column":7,"offset":6207},"end":{"line":146,"column":50,"offset":6250},"indent":[]}}],"position":{"start":{"line":146,"column":1,"offset":6201},"end":{"line":146,"column":50,"offset":6250},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Camera properties which you can specify to tune the settings to your needs.","position":{"start":{"line":148,"column":1,"offset":6252},"end":{"line":148,"column":76,"offset":6327},"indent":[]}}],"position":{"start":{"line":148,"column":1,"offset":6252},"end":{"line":148,"column":76,"offset":6327},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"IP camera","position":{"start":{"line":150,"column":5,"offset":6333},"end":{"line":150,"column":14,"offset":6342},"indent":[]}}],"position":{"start":{"line":150,"column":1,"offset":6329},"end":{"line":150,"column":14,"offset":6342},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The machinery can be used with any IP camera, that provides a RTSP (or MJPEG) stream. Make sure that you know the correct URL of your IP camera, you can ","position":{"start":{"line":152,"column":1,"offset":6344},"end":{"line":152,"column":154,"offset":6497},"indent":[]}},{"type":"link","title":null,"url":"http://www.ispyconnect.com/sources.aspx","children":[{"type":"text","value":"find a list here","position":{"start":{"line":152,"column":155,"offset":6498},"end":{"line":152,"column":171,"offset":6514},"indent":[]}}],"position":{"start":{"line":152,"column":154,"offset":6497},"end":{"line":152,"column":213,"offset":6556},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":152,"column":213,"offset":6556},"end":{"line":152,"column":214,"offset":6557},"indent":[]}}],"position":{"start":{"line":152,"column":1,"offset":6344},"end":{"line":152,"column":214,"offset":6557},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":154,"column":6,"offset":6564},"end":{"line":154,"column":16,"offset":6574},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6559},"end":{"line":154,"column":16,"offset":6574},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the IP capture device can be found in the ","position":{"start":{"line":156,"column":1,"offset":6576},"end":{"line":156,"column":61,"offset":6636},"indent":[]}},{"type":"inlineCode","value":"config/capture.xml","position":{"start":{"line":156,"column":61,"offset":6636},"end":{"line":156,"column":81,"offset":6656},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":156,"column":81,"offset":6656},"end":{"line":156,"column":186,"offset":6761},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6576},"end":{"line":156,"column":186,"offset":6761},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n http://username:password@ipaddress/image.jpg\n 800\n 640\n 0\n 0\n \n","position":{"start":{"line":158,"column":1,"offset":6763},"end":{"line":168,"column":4,"offset":7061},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"URL","position":{"start":{"line":170,"column":7,"offset":7069},"end":{"line":170,"column":10,"offset":7072},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7063},"end":{"line":170,"column":10,"offset":7072},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To use your IP camera, you should provide a valid RTSP (or MJPEG) URL. The machinery will take snapshots from this stream.","position":{"start":{"line":172,"column":1,"offset":7074},"end":{"line":172,"column":123,"offset":7196},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7074},"end":{"line":172,"column":123,"offset":7196},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Framewidth and -height","position":{"start":{"line":174,"column":7,"offset":7204},"end":{"line":174,"column":29,"offset":7226},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7198},"end":{"line":174,"column":29,"offset":7226},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can set the resolution of the capture device, make sure the resolution you've defined is equal to the resolution you've defined in your IP-camera software.","position":{"start":{"line":176,"column":1,"offset":7228},"end":{"line":176,"column":160,"offset":7387},"indent":[]}}],"position":{"start":{"line":176,"column":1,"offset":7228},"end":{"line":176,"column":160,"offset":7387},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Delay","position":{"start":{"line":178,"column":7,"offset":7395},"end":{"line":178,"column":12,"offset":7400},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7389},"end":{"line":178,"column":12,"offset":7400},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can provide a delay/interval (milliseconds) between two captures.","position":{"start":{"line":180,"column":1,"offset":7402},"end":{"line":180,"column":70,"offset":7471},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7402},"end":{"line":180,"column":70,"offset":7471},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Angle","position":{"start":{"line":182,"column":7,"offset":7479},"end":{"line":182,"column":12,"offset":7484},"indent":[]}}],"position":{"start":{"line":182,"column":1,"offset":7473},"end":{"line":182,"column":12,"offset":7484},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By defining an angle (degrees), you can rotate the images taken by the capture device. For example if you would mount the camera upside down, than you could enter the value 180 as the angle; this will flip the images.","position":{"start":{"line":184,"column":1,"offset":7486},"end":{"line":184,"column":218,"offset":7703},"indent":[]}}],"position":{"start":{"line":184,"column":1,"offset":7486},"end":{"line":184,"column":218,"offset":7703},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Condition","position":{"start":{"line":186,"column":4,"offset":7708},"end":{"line":186,"column":13,"offset":7717},"indent":[]}}],"position":{"start":{"line":186,"column":1,"offset":7705},"end":{"line":186,"column":13,"offset":7717},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The condition is the first step of the four passway. In this step the machinery will determine if it's allowed to proceed to the next step. For example a condition can be a time constraint, a brightness threshold, etc; multiple conditions can be selected.","position":{"start":{"line":188,"column":1,"offset":7719},"end":{"line":188,"column":256,"offset":7974},"indent":[]}}],"position":{"start":{"line":188,"column":1,"offset":7719},"end":{"line":188,"column":256,"offset":7974},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n \n ...\n Enabled\n ...\n \n","position":{"start":{"line":190,"column":1,"offset":7976},"end":{"line":199,"column":4,"offset":8146},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Enabled","position":{"start":{"line":201,"column":5,"offset":8152},"end":{"line":201,"column":12,"offset":8159},"indent":[]}}],"position":{"start":{"line":201,"column":1,"offset":8148},"end":{"line":201,"column":12,"offset":8159},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be helpful to enable or disable the machinery at specific times. Therefore the time condition makes it possible to select a time range for each day of the week. When the current time is within the time range, the machinery will be enabled.","position":{"start":{"line":203,"column":1,"offset":8161},"end":{"line":203,"column":247,"offset":8407},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":8161},"end":{"line":203,"column":247,"offset":8407},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":205,"column":6,"offset":8414},"end":{"line":205,"column":16,"offset":8424},"indent":[]}}],"position":{"start":{"line":205,"column":1,"offset":8409},"end":{"line":205,"column":16,"offset":8424},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Enabled condition can be found in the ","position":{"start":{"line":207,"column":1,"offset":8426},"end":{"line":207,"column":61,"offset":8486},"indent":[]}},{"type":"inlineCode","value":"config/condition.xml","position":{"start":{"line":207,"column":61,"offset":8486},"end":{"line":207,"column":83,"offset":8508},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":207,"column":83,"offset":8508},"end":{"line":207,"column":188,"offset":8613},"indent":[]}}],"position":{"start":{"line":207,"column":1,"offset":8426},"end":{"line":207,"column":188,"offset":8613},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n true\n 5000\n \n","position":{"start":{"line":209,"column":1,"offset":8615},"end":{"line":216,"column":4,"offset":8753},"indent":[1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Active","position":{"start":{"line":218,"column":7,"offset":8761},"end":{"line":218,"column":13,"offset":8767},"indent":[]}}],"position":{"start":{"line":218,"column":1,"offset":8755},"end":{"line":218,"column":13,"offset":8767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The active field is boolean value (true/false). When the active field is true, the machinery is enabled, if not it's disabled.","position":{"start":{"line":220,"column":1,"offset":8769},"end":{"line":220,"column":127,"offset":8895},"indent":[]}}],"position":{"start":{"line":220,"column":1,"offset":8769},"end":{"line":220,"column":127,"offset":8895},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Delay","position":{"start":{"line":222,"column":7,"offset":8903},"end":{"line":222,"column":12,"offset":8908},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":8897},"end":{"line":222,"column":12,"offset":8908},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The delay value is used when the condition failed, so when the current time isn't in the selected time range for that day. In that case the machinery will idle for the specified delay time. The value of the delay is expressed in miliseconds.","position":{"start":{"line":224,"column":1,"offset":8910},"end":{"line":224,"column":242,"offset":9151},"indent":[]}}],"position":{"start":{"line":224,"column":1,"offset":8910},"end":{"line":224,"column":242,"offset":9151},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Time","position":{"start":{"line":226,"column":5,"offset":9157},"end":{"line":226,"column":9,"offset":9161},"indent":[]}}],"position":{"start":{"line":226,"column":1,"offset":9153},"end":{"line":226,"column":9,"offset":9161},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be helpful to enable or disable the machinery at specific times. Therefore the time condition makes it possible to select a time range for each day of the week. When the current time is within the time range, the machinery will be enabled.","position":{"start":{"line":228,"column":1,"offset":9163},"end":{"line":228,"column":247,"offset":9409},"indent":[]}}],"position":{"start":{"line":228,"column":1,"offset":9163},"end":{"line":228,"column":247,"offset":9409},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":230,"column":6,"offset":9416},"end":{"line":230,"column":16,"offset":9426},"indent":[]}}],"position":{"start":{"line":230,"column":1,"offset":9411},"end":{"line":230,"column":16,"offset":9426},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Time condition can be found in the ","position":{"start":{"line":232,"column":1,"offset":9428},"end":{"line":232,"column":58,"offset":9485},"indent":[]}},{"type":"inlineCode","value":"config/condition.xml","position":{"start":{"line":232,"column":58,"offset":9485},"end":{"line":232,"column":80,"offset":9507},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":232,"column":80,"offset":9507},"end":{"line":232,"column":185,"offset":9612},"indent":[]}}],"position":{"start":{"line":232,"column":1,"offset":9428},"end":{"line":232,"column":185,"offset":9612},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n","position":{"start":{"line":234,"column":1,"offset":9614},"end":{"line":241,"column":4,"offset":9813},"indent":[1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Times","position":{"start":{"line":243,"column":7,"offset":9821},"end":{"line":243,"column":12,"offset":9826},"indent":[]}}],"position":{"start":{"line":243,"column":1,"offset":9815},"end":{"line":243,"column":12,"offset":9826},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The times property contains a list of times, delimited by a \"-\". The first item in the list will specify the time range for the first day of the week (Monday), the last item for the last day of the week (Sunday). The begin- and end-time, for a specific day, are delimited by a \",\" where the first element will specify that start time and the second one specifies the end time.","position":{"start":{"line":245,"column":1,"offset":9828},"end":{"line":245,"column":377,"offset":10204},"indent":[]}}],"position":{"start":{"line":245,"column":1,"offset":9828},"end":{"line":245,"column":377,"offset":10204},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Delay","position":{"start":{"line":247,"column":7,"offset":10212},"end":{"line":247,"column":12,"offset":10217},"indent":[]}}],"position":{"start":{"line":247,"column":1,"offset":10206},"end":{"line":247,"column":12,"offset":10217},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The delay value is used when the condition failed, so when the current time isn't in the selected time range for that day. In that case the machinery will idle for the specified delay time. The value of the delay is expressed in miliseconds.","position":{"start":{"line":249,"column":1,"offset":10219},"end":{"line":249,"column":242,"offset":10460},"indent":[]}}],"position":{"start":{"line":249,"column":1,"offset":10219},"end":{"line":249,"column":242,"offset":10460},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Algorithm","position":{"start":{"line":251,"column":4,"offset":10465},"end":{"line":251,"column":13,"offset":10474},"indent":[]}}],"position":{"start":{"line":251,"column":1,"offset":10462},"end":{"line":251,"column":13,"offset":10474},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The algorithm is the second step of the four passway. An algorithm will execute some kind of function on a sequence of images, and end up with a black and white image; just like the image below. An example of an algorithm would be one that does motion detection or one that would detect cats or dogs (using TensorFlow, ar any other Deep Learning framework).","position":{"start":{"line":253,"column":1,"offset":10476},"end":{"line":253,"column":358,"offset":10833},"indent":[]}}],"position":{"start":{"line":253,"column":1,"offset":10476},"end":{"line":253,"column":358,"offset":10833},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/machinery/algorithm.png","alt":"machinery algorithm","position":{"start":{"line":255,"column":1,"offset":10835},"end":{"line":255,"column":68,"offset":10902},"indent":[]}}],"position":{"start":{"line":255,"column":1,"offset":10835},"end":{"line":255,"column":68,"offset":10902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The white pixels on the image will indicate the object of interest. For example, when looking for motion, the pixels that have been changed; it depends on what the algorithm is looking for. The black pixels are background pixels.","position":{"start":{"line":257,"column":1,"offset":10904},"end":{"line":257,"column":230,"offset":11133},"indent":[]}}],"position":{"start":{"line":257,"column":1,"offset":10904},"end":{"line":257,"column":230,"offset":11133},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The only convention that an algorithm should meet is that it should return a black and white image to the next step; the expositor. And of course that it requires a sequence of images as a parameter. Besides those conventions, an algorithm can do everything it wants to do. So you could create your own cat detection algorithm, marker detection, etc.","position":{"start":{"line":259,"column":1,"offset":11135},"end":{"line":259,"column":351,"offset":11485},"indent":[]}}],"position":{"start":{"line":259,"column":1,"offset":11135},"end":{"line":259,"column":351,"offset":11485},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can select the algortihm in the ","position":{"start":{"line":261,"column":1,"offset":11487},"end":{"line":261,"column":37,"offset":11523},"indent":[]}},{"type":"inlineCode","value":"config/config.xml","position":{"start":{"line":261,"column":37,"offset":11523},"end":{"line":261,"column":56,"offset":11542},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":261,"column":56,"offset":11542},"end":{"line":261,"column":57,"offset":11543},"indent":[]}}],"position":{"start":{"line":261,"column":1,"offset":11487},"end":{"line":261,"column":57,"offset":11543},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n \n ...\n DifferentialCollins\n ...\n \n","position":{"start":{"line":263,"column":1,"offset":11545},"end":{"line":272,"column":4,"offset":11711},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Differential images","position":{"start":{"line":274,"column":5,"offset":11717},"end":{"line":274,"column":24,"offset":11736},"indent":[]}}],"position":{"start":{"line":274,"column":1,"offset":11713},"end":{"line":274,"column":24,"offset":11736},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This algorithm is a very simple method to detect motion; in terms of understanding but also processing. Just like the name says, it's the result of comparing images. When the images are compared, we know the pixels that have been changed and if the amount of pixels that changed is big enough, one can say that something happened and thus motion was detected.","position":{"start":{"line":276,"column":1,"offset":11738},"end":{"line":276,"column":360,"offset":12097},"indent":[]}}],"position":{"start":{"line":276,"column":1,"offset":11738},"end":{"line":276,"column":360,"offset":12097},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To get a more technical explanation: the algoritm will substract 2 or more images, and once that is done it will end up with a black and white image. The white pixels will mark the pixels that where different/changed and the black pixels are the pixels that have not changed; background pixels. Please note that there are several different combinations of substracting images. However for the machinery, we will use the method of Collins et al. as this method erases the phenomenon \"ghosting\".","position":{"start":{"line":278,"column":1,"offset":12099},"end":{"line":278,"column":494,"offset":12592},"indent":[]}}],"position":{"start":{"line":278,"column":1,"offset":12099},"end":{"line":278,"column":494,"offset":12592},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/machinery/differential_images.png","alt":"machinery differential","position":{"start":{"line":280,"column":1,"offset":12594},"end":{"line":280,"column":81,"offset":12674},"indent":[]}}],"position":{"start":{"line":280,"column":1,"offset":12594},"end":{"line":280,"column":81,"offset":12674},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"In the image above the method of Collins et al. is illustrated. For this method we will process three images. The images are a sequence (from left to right), so the first (A) image was taken before the second (B) one, and the second (B) before the third (C) one. Next we will do a first comparision (C-B) of the third (C) image and the second (B) image, and after that we will do a second comparison (C-A) of the third (C) image and first (A) image.","position":{"start":{"line":282,"column":1,"offset":12676},"end":{"line":282,"column":450,"offset":13125},"indent":[]}}],"position":{"start":{"line":282,"column":1,"offset":12676},"end":{"line":282,"column":450,"offset":13125},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"After the comparison we will end up with two difference images (C-B) and (C-A); both will mark the white pixels as changed pixels and black as non-changed pixels. To finish the algorithm we will do a logical AND-operation of the two difference images; this will give us the final black and white image ((C-B)&&(C-A)).","position":{"start":{"line":284,"column":1,"offset":13127},"end":{"line":284,"column":318,"offset":13444},"indent":[]}}],"position":{"start":{"line":284,"column":1,"offset":13127},"end":{"line":284,"column":318,"offset":13444},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The main idea of the Colins et al. method, is that it will erase \"ghosting\". In the last step we are doing a logical AND-operation, by doing this we will only keep the pixels, that changed in the first two images; therefore we can elimante false positives.","position":{"start":{"line":286,"column":1,"offset":13446},"end":{"line":286,"column":257,"offset":13702},"indent":[]}}],"position":{"start":{"line":286,"column":1,"offset":13446},"end":{"line":286,"column":257,"offset":13702},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":288,"column":6,"offset":13709},"end":{"line":288,"column":16,"offset":13719},"indent":[]}}],"position":{"start":{"line":288,"column":1,"offset":13704},"end":{"line":288,"column":16,"offset":13719},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Differential images algorithm can be found in the config/algorithm.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":290,"column":1,"offset":13721},"end":{"line":290,"column":198,"offset":13918},"indent":[]}}],"position":{"start":{"line":290,"column":1,"offset":13721},"end":{"line":290,"column":198,"offset":13918},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n 5\n 20\n \n","position":{"start":{"line":292,"column":1,"offset":13920},"end":{"line":299,"column":4,"offset":14085},"indent":[1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Erode","position":{"start":{"line":301,"column":7,"offset":14093},"end":{"line":301,"column":12,"offset":14098},"indent":[]}}],"position":{"start":{"line":301,"column":1,"offset":14087},"end":{"line":301,"column":12,"offset":14098},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The erode parameter represents a structural element (a morphological operation), which will be used to minimize the changed pixels; more information about eroding can be found here. The idea of the eroding is that pixels which are isolated will be removed; this means that when only one pixel changed, that pixel will reverted to the non-changed state. But for example when a large change happens and a lot of adjacent pixels are changed, the eroding will not be able to revert them.","position":{"start":{"line":303,"column":1,"offset":14100},"end":{"line":303,"column":484,"offset":14583},"indent":[]}}],"position":{"start":{"line":303,"column":1,"offset":14100},"end":{"line":303,"column":484,"offset":14583},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The higher the number of the erode parameter, the more aggressive the eroding will be. So high erode values, will make it possible that also large changes will be reverted to the non-changed state.","position":{"start":{"line":305,"column":1,"offset":14585},"end":{"line":305,"column":198,"offset":14782},"indent":[]}}],"position":{"start":{"line":305,"column":1,"offset":14585},"end":{"line":305,"column":198,"offset":14782},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Threshold","position":{"start":{"line":307,"column":7,"offset":14790},"end":{"line":307,"column":16,"offset":14799},"indent":[]}}],"position":{"start":{"line":307,"column":1,"offset":14784},"end":{"line":307,"column":16,"offset":14799},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When doing the comparison of two images, we won't end up with a clean black and white image. In most of the cases the values will be between 0 and 255; so gray values. This means that the value 0 will mean that both pixels where the same in both image, and values 255 mean that both pixels where totally different in both images. Of course we will also have values between 0-255, so pixels that are a little bit different in both images. So to make the resulting black and white image, we will need to apply a threshold value.","position":{"start":{"line":309,"column":1,"offset":14801},"end":{"line":309,"column":527,"offset":15327},"indent":[]}}],"position":{"start":{"line":309,"column":1,"offset":14801},"end":{"line":309,"column":527,"offset":15327},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The threshold will specify how much a pixel has to be different in the two images. So for example when the threshold is 30, it means that the difference between two pixels has to be equal or more then 30. The higher the threshold the more the pixel needs to be different, to be marked as changed.","position":{"start":{"line":311,"column":1,"offset":15329},"end":{"line":311,"column":297,"offset":15625},"indent":[]}}],"position":{"start":{"line":311,"column":1,"offset":15329},"end":{"line":311,"column":297,"offset":15625},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Expositor","position":{"start":{"line":313,"column":4,"offset":15630},"end":{"line":313,"column":13,"offset":15639},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":15627},"end":{"line":313,"column":13,"offset":15639},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"After the algorithm is executed, the expositor will determine, a region, where the changes were detected. An expositor can constrain a region in terms of selecting a hull or defining a rectangle.","position":{"start":{"line":315,"column":1,"offset":15641},"end":{"line":315,"column":196,"offset":15836},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":15641},"end":{"line":315,"column":196,"offset":15836},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"An expositor receives a black and white image as parameter and should modify a JSON object with all the information it processed. The JSON object must include: the bounding rectangle(s) of the positions where the pixels of interest are located and the number of pixels of interest. But can also include other optional parameters.","position":{"start":{"line":317,"column":1,"offset":15838},"end":{"line":317,"column":330,"offset":16167},"indent":[]}}],"position":{"start":{"line":317,"column":1,"offset":15838},"end":{"line":317,"column":330,"offset":16167},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can change the expositor by changing the ","position":{"start":{"line":319,"column":1,"offset":16169},"end":{"line":319,"column":46,"offset":16214},"indent":[]}},{"type":"inlineCode","value":"config/config.xml","position":{"start":{"line":319,"column":46,"offset":16214},"end":{"line":319,"column":65,"offset":16233},"indent":[]}},{"type":"text","value":" file, and choose one of the following:","position":{"start":{"line":319,"column":65,"offset":16233},"end":{"line":319,"column":104,"offset":16272},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":16169},"end":{"line":319,"column":104,"offset":16272},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Hull","position":{"start":{"line":320,"column":3,"offset":16275},"end":{"line":320,"column":7,"offset":16279},"indent":[]}}],"position":{"start":{"line":320,"column":3,"offset":16275},"end":{"line":320,"column":7,"offset":16279},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":16273},"end":{"line":320,"column":7,"offset":16279},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Rectangle","position":{"start":{"line":321,"column":3,"offset":16282},"end":{"line":321,"column":12,"offset":16291},"indent":[]}}],"position":{"start":{"line":321,"column":3,"offset":16282},"end":{"line":321,"column":12,"offset":16291},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":16280},"end":{"line":321,"column":12,"offset":16291},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":16273},"end":{"line":321,"column":12,"offset":16291},"indent":[1]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n \n ...\n Hull\n ...\n \n","position":{"start":{"line":323,"column":1,"offset":16293},"end":{"line":332,"column":4,"offset":16444},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Rectangle","position":{"start":{"line":334,"column":5,"offset":16450},"end":{"line":334,"column":14,"offset":16459},"indent":[]}}],"position":{"start":{"line":334,"column":1,"offset":16446},"end":{"line":334,"column":14,"offset":16459},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This is a trivial expositor. A rectangle region can be defined to constrain the locations of pixels of interest. The rectangle repositor will return the region of the pixels of interest.","position":{"start":{"line":336,"column":1,"offset":16461},"end":{"line":336,"column":187,"offset":16647},"indent":[]}}],"position":{"start":{"line":336,"column":1,"offset":16461},"end":{"line":336,"column":187,"offset":16647},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":338,"column":6,"offset":16654},"end":{"line":338,"column":16,"offset":16664},"indent":[]}}],"position":{"start":{"line":338,"column":1,"offset":16649},"end":{"line":338,"column":16,"offset":16664},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the rectangle expositor can be found in the config/expositor.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":340,"column":1,"offset":16666},"end":{"line":340,"column":188,"offset":16853},"indent":[]}}],"position":{"start":{"line":340,"column":1,"offset":16666},"end":{"line":340,"column":188,"offset":16853},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n \n 0\n 0\n 1280\n 720\n \n \n","position":{"start":{"line":342,"column":1,"offset":16855},"end":{"line":353,"column":4,"offset":17077},"indent":[1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Region","position":{"start":{"line":355,"column":7,"offset":17085},"end":{"line":355,"column":13,"offset":17091},"indent":[]}}],"position":{"start":{"line":355,"column":1,"offset":17079},"end":{"line":355,"column":13,"offset":17091},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The region parameter contains 4 values; x1, y1, x2 and y2 respectively. The values x1 and y1 indicate the x- and y-coordinate of the left upper starting point. The values x2 and y2 are the bottom right coordinates. A virtual rectangle will be drawn from (x1,y1) to (x2,y2). Pixels of interest that lie within this rectangle are valid pixels; if not they are invalid.","position":{"start":{"line":357,"column":1,"offset":17093},"end":{"line":357,"column":367,"offset":17459},"indent":[]}}],"position":{"start":{"line":357,"column":1,"offset":17093},"end":{"line":357,"column":367,"offset":17459},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Hull","position":{"start":{"line":359,"column":5,"offset":17465},"end":{"line":359,"column":9,"offset":17469},"indent":[]}}],"position":{"start":{"line":359,"column":1,"offset":17461},"end":{"line":359,"column":9,"offset":17469},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This hull is a more complex expositor than the rectangle. A hull can be selected with the web, you can select one or more coordinates to create a flexible region. The coordinates can be adjusted afterwards and be removed by double clicking on the coordinate. You can expand the hull by removing the start coordinate, which is marked by the white bullet.","position":{"start":{"line":361,"column":1,"offset":17471},"end":{"line":361,"column":354,"offset":17824},"indent":[]}}],"position":{"start":{"line":361,"column":1,"offset":17471},"end":{"line":361,"column":354,"offset":17824},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/machinery/hull.png","alt":"machinery hull","position":{"start":{"line":363,"column":1,"offset":17826},"end":{"line":363,"column":58,"offset":17883},"indent":[]}}],"position":{"start":{"line":363,"column":1,"offset":17826},"end":{"line":363,"column":58,"offset":17883},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":365,"column":6,"offset":17890},"end":{"line":365,"column":16,"offset":17900},"indent":[]}}],"position":{"start":{"line":365,"column":1,"offset":17885},"end":{"line":365,"column":16,"offset":17900},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the hull expositor can be found in the config/expositor.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":367,"column":1,"offset":17902},"end":{"line":367,"column":183,"offset":18084},"indent":[]}}],"position":{"start":{"line":367,"column":1,"offset":17902},"end":{"line":367,"column":183,"offset":18084},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n 347,361|627,266|975,328|1091,328|1148,413|1158,516|1121,534|962,567|699,648|531,700|243,613|423,550|665,453|850,470|666,361|467,385|325,460|165,372\n \n","position":{"start":{"line":369,"column":1,"offset":18086},"end":{"line":375,"column":4,"offset":18332},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Region","position":{"start":{"line":377,"column":7,"offset":18340},"end":{"line":377,"column":13,"offset":18346},"indent":[]}}],"position":{"start":{"line":377,"column":1,"offset":18334},"end":{"line":377,"column":13,"offset":18346},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The region parameter contains n values. Each value represents a coordinate (x,y) and are seperated by the \"|\" delimiter. These coordinates are used to calculate the concave hull. Pixels of interest that lie within the concave hull are valid pixels; if not they are invalid.","position":{"start":{"line":378,"column":1,"offset":18347},"end":{"line":378,"column":274,"offset":18620},"indent":[]}}],"position":{"start":{"line":378,"column":1,"offset":18347},"end":{"line":378,"column":274,"offset":18620},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Heuristic","position":{"start":{"line":380,"column":4,"offset":18625},"end":{"line":380,"column":13,"offset":18634},"indent":[]}}],"position":{"start":{"line":380,"column":1,"offset":18622},"end":{"line":380,"column":13,"offset":18634},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The heuristic is the last step in the four passway which will decide if the detection is valid or not. It will do this by using information from the previous steps (the expositor and the algorithm); e.g. number of changed pixels.","position":{"start":{"line":382,"column":1,"offset":18636},"end":{"line":382,"column":230,"offset":18865},"indent":[]}}],"position":{"start":{"line":382,"column":1,"offset":18636},"end":{"line":382,"column":230,"offset":18865},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can change the heuristic by changing the ","position":{"start":{"line":384,"column":1,"offset":18867},"end":{"line":384,"column":46,"offset":18912},"indent":[]}},{"type":"inlineCode","value":"config/config.xml","position":{"start":{"line":384,"column":46,"offset":18912},"end":{"line":384,"column":65,"offset":18931},"indent":[]}},{"type":"text","value":" file, and choose one of the following:","position":{"start":{"line":384,"column":65,"offset":18931},"end":{"line":384,"column":104,"offset":18970},"indent":[]}}],"position":{"start":{"line":384,"column":1,"offset":18867},"end":{"line":384,"column":104,"offset":18970},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Sequence","position":{"start":{"line":385,"column":3,"offset":18973},"end":{"line":385,"column":11,"offset":18981},"indent":[]}}],"position":{"start":{"line":385,"column":3,"offset":18973},"end":{"line":385,"column":11,"offset":18981},"indent":[]}}],"position":{"start":{"line":385,"column":1,"offset":18971},"end":{"line":385,"column":11,"offset":18981},"indent":[]}}],"position":{"start":{"line":385,"column":1,"offset":18971},"end":{"line":385,"column":11,"offset":18981},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n \n ...\n Sequence\n ...\n \n","position":{"start":{"line":387,"column":1,"offset":18983},"end":{"line":396,"column":4,"offset":19138},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Sequence","position":{"start":{"line":398,"column":5,"offset":19144},"end":{"line":398,"column":13,"offset":19152},"indent":[]}}],"position":{"start":{"line":398,"column":1,"offset":19140},"end":{"line":398,"column":13,"offset":19152},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This is a trivial heuristic. The sequence heuristic will store a single integer in memory, that will count the numbers of valid detections. When the heuristic will detect a false detection, it will decrease the count. The sequence heuristic will return true, if a threshold is reached; for example when something was detected three times in a row.","position":{"start":{"line":400,"column":1,"offset":19154},"end":{"line":400,"column":348,"offset":19501},"indent":[]}}],"position":{"start":{"line":400,"column":1,"offset":19154},"end":{"line":400,"column":348,"offset":19501},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":402,"column":6,"offset":19508},"end":{"line":402,"column":16,"offset":19518},"indent":[]}}],"position":{"start":{"line":402,"column":1,"offset":19503},"end":{"line":402,"column":16,"offset":19518},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Sequence heuristic can be found in the config/heuristic.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":404,"column":1,"offset":19520},"end":{"line":404,"column":187,"offset":19706},"indent":[]}}],"position":{"start":{"line":404,"column":1,"offset":19520},"end":{"line":404,"column":187,"offset":19706},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n 1\n 1\n 2000\n \n","position":{"start":{"line":406,"column":1,"offset":19708},"end":{"line":414,"column":4,"offset":19940},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Minimum changes","position":{"start":{"line":416,"column":7,"offset":19948},"end":{"line":416,"column":22,"offset":19963},"indent":[]}}],"position":{"start":{"line":416,"column":1,"offset":19942},"end":{"line":416,"column":22,"offset":19963},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The heuristic will only return true if enough changes have been detected. The minimum of changes indicates the minimum number of pixels that have to been changed, to be a valid detection.","position":{"start":{"line":418,"column":1,"offset":19965},"end":{"line":418,"column":188,"offset":20152},"indent":[]}}],"position":{"start":{"line":418,"column":1,"offset":19965},"end":{"line":418,"column":188,"offset":20152},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Minimum durations","position":{"start":{"line":420,"column":7,"offset":20160},"end":{"line":420,"column":24,"offset":20177},"indent":[]}}],"position":{"start":{"line":420,"column":1,"offset":20154},"end":{"line":420,"column":24,"offset":20177},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The minimum number of detections in a row to be a valid detection.","position":{"start":{"line":422,"column":1,"offset":20179},"end":{"line":422,"column":67,"offset":20245},"indent":[]}}],"position":{"start":{"line":422,"column":1,"offset":20179},"end":{"line":422,"column":67,"offset":20245},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"No motion delay time","position":{"start":{"line":424,"column":7,"offset":20253},"end":{"line":424,"column":27,"offset":20273},"indent":[]}}],"position":{"start":{"line":424,"column":1,"offset":20247},"end":{"line":424,"column":27,"offset":20273},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When the heuristic failed, due to not enough pixels changed or not x detections in a row, the heuristic will idle for some time.","position":{"start":{"line":426,"column":1,"offset":20275},"end":{"line":426,"column":129,"offset":20403},"indent":[]}}],"position":{"start":{"line":426,"column":1,"offset":20275},"end":{"line":426,"column":129,"offset":20403},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Output","position":{"start":{"line":428,"column":4,"offset":20408},"end":{"line":428,"column":10,"offset":20414},"indent":[]}}],"position":{"start":{"line":428,"column":1,"offset":20405},"end":{"line":428,"column":10,"offset":20414},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If the heuristic determined that the evaluation was valid, one or more output operations can be executed. You configure which ooutput operations that will be executed, by modifying the configuration file or using the web interface.","position":{"start":{"line":430,"column":1,"offset":20416},"end":{"line":430,"column":232,"offset":20647},"indent":[]}}],"position":{"start":{"line":430,"column":1,"offset":20416},"end":{"line":430,"column":232,"offset":20647},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n \n ...\n Video\n ...\n \n","position":{"start":{"line":432,"column":1,"offset":20649},"end":{"line":441,"column":4,"offset":20796},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"You can choose which output devices you will be using. If you select multiple outputs, seperate them with an ","position":{"start":{"line":443,"column":1,"offset":20798},"end":{"line":443,"column":110,"offset":20907},"indent":[]}},{"type":"inlineCode","value":",","position":{"start":{"line":443,"column":110,"offset":20907},"end":{"line":443,"column":113,"offset":20910},"indent":[]}},{"type":"text","value":". You can change the output device by changing the ","position":{"start":{"line":443,"column":113,"offset":20910},"end":{"line":443,"column":164,"offset":20961},"indent":[]}},{"type":"inlineCode","value":"config/config.xml","position":{"start":{"line":443,"column":164,"offset":20961},"end":{"line":443,"column":183,"offset":20980},"indent":[]}},{"type":"text","value":" file, and choose one of the following:","position":{"start":{"line":443,"column":183,"offset":20980},"end":{"line":443,"column":222,"offset":21019},"indent":[]}}],"position":{"start":{"line":443,"column":1,"offset":20798},"end":{"line":443,"column":222,"offset":21019},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Disk","position":{"start":{"line":444,"column":3,"offset":21022},"end":{"line":444,"column":7,"offset":21026},"indent":[]}}],"position":{"start":{"line":444,"column":3,"offset":21022},"end":{"line":444,"column":7,"offset":21026},"indent":[]}}],"position":{"start":{"line":444,"column":1,"offset":21020},"end":{"line":444,"column":7,"offset":21026},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Video","position":{"start":{"line":445,"column":3,"offset":21029},"end":{"line":445,"column":8,"offset":21034},"indent":[]}}],"position":{"start":{"line":445,"column":3,"offset":21029},"end":{"line":445,"column":8,"offset":21034},"indent":[]}}],"position":{"start":{"line":445,"column":1,"offset":21027},"end":{"line":445,"column":8,"offset":21034},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"GPIO","position":{"start":{"line":446,"column":3,"offset":21037},"end":{"line":446,"column":7,"offset":21041},"indent":[]}}],"position":{"start":{"line":446,"column":3,"offset":21037},"end":{"line":446,"column":7,"offset":21041},"indent":[]}}],"position":{"start":{"line":446,"column":1,"offset":21035},"end":{"line":446,"column":7,"offset":21041},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"TCPSocket","position":{"start":{"line":447,"column":3,"offset":21044},"end":{"line":447,"column":12,"offset":21053},"indent":[]}}],"position":{"start":{"line":447,"column":3,"offset":21044},"end":{"line":447,"column":12,"offset":21053},"indent":[]}}],"position":{"start":{"line":447,"column":1,"offset":21042},"end":{"line":447,"column":12,"offset":21053},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Webhook","position":{"start":{"line":448,"column":3,"offset":21056},"end":{"line":448,"column":10,"offset":21063},"indent":[]}}],"position":{"start":{"line":448,"column":3,"offset":21056},"end":{"line":448,"column":10,"offset":21063},"indent":[]}}],"position":{"start":{"line":448,"column":1,"offset":21054},"end":{"line":448,"column":10,"offset":21063},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"MQTT","position":{"start":{"line":449,"column":3,"offset":21066},"end":{"line":449,"column":7,"offset":21070},"indent":[]}}],"position":{"start":{"line":449,"column":3,"offset":21066},"end":{"line":449,"column":7,"offset":21070},"indent":[]}}],"position":{"start":{"line":449,"column":1,"offset":21064},"end":{"line":449,"column":7,"offset":21070},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Script","position":{"start":{"line":450,"column":3,"offset":21073},"end":{"line":450,"column":9,"offset":21079},"indent":[]}}],"position":{"start":{"line":450,"column":3,"offset":21073},"end":{"line":450,"column":9,"offset":21079},"indent":[]}}],"position":{"start":{"line":450,"column":1,"offset":21071},"end":{"line":450,"column":9,"offset":21079},"indent":[]}}],"position":{"start":{"line":444,"column":1,"offset":21020},"end":{"line":450,"column":9,"offset":21079},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Disk","position":{"start":{"line":452,"column":5,"offset":21085},"end":{"line":452,"column":9,"offset":21089},"indent":[]}}],"position":{"start":{"line":452,"column":1,"offset":21081},"end":{"line":452,"column":9,"offset":21089},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"An image can be saved to disk.","position":{"start":{"line":454,"column":1,"offset":21091},"end":{"line":454,"column":31,"offset":21121},"indent":[]}}],"position":{"start":{"line":454,"column":1,"offset":21091},"end":{"line":454,"column":31,"offset":21121},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":456,"column":6,"offset":21128},"end":{"line":456,"column":16,"offset":21138},"indent":[]}}],"position":{"start":{"line":456,"column":1,"offset":21123},"end":{"line":456,"column":16,"offset":21138},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Disk output device can be found in the ","position":{"start":{"line":458,"column":1,"offset":21140},"end":{"line":458,"column":62,"offset":21201},"indent":[]}},{"type":"inlineCode","value":"config/io.xml","position":{"start":{"line":458,"column":62,"offset":21201},"end":{"line":458,"column":77,"offset":21216},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":458,"column":77,"offset":21216},"end":{"line":458,"column":182,"offset":21321},"indent":[]}}],"position":{"start":{"line":458,"column":1,"offset":21140},"end":{"line":458,"column":182,"offset":21321},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n timestamp_microseconds_instanceName_regionCoordinates_numberOfChanges_token.jpg\n /etc/opt/kerberosio/capture/\n false\n white\n false\n 0\n \n","position":{"start":{"line":460,"column":1,"offset":21323},"end":{"line":471,"column":4,"offset":21754},"indent":[1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"File format","position":{"start":{"line":473,"column":7,"offset":21762},"end":{"line":473,"column":18,"offset":21773},"indent":[]}}],"position":{"start":{"line":473,"column":1,"offset":21756},"end":{"line":473,"column":18,"offset":21773},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The format that will be used for the name of the image. One or more variables can be defined and will be replaced by the machinery. Note that when you're using a variables name in the file format, that this name should be defined in the JSON object.","position":{"start":{"line":475,"column":1,"offset":21775},"end":{"line":475,"column":250,"offset":22024},"indent":[]}}],"position":{"start":{"line":475,"column":1,"offset":21775},"end":{"line":475,"column":250,"offset":22024},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Directory","position":{"start":{"line":477,"column":7,"offset":22032},"end":{"line":477,"column":16,"offset":22041},"indent":[]}}],"position":{"start":{"line":477,"column":1,"offset":22026},"end":{"line":477,"column":16,"offset":22041},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The directory where the image will be saved to. By default images are saved to the /etc/opt/kerberosio/capture directory.","position":{"start":{"line":479,"column":1,"offset":22043},"end":{"line":479,"column":122,"offset":22164},"indent":[]}}],"position":{"start":{"line":479,"column":1,"offset":22043},"end":{"line":479,"column":122,"offset":22164},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Mark with timestamp","position":{"start":{"line":481,"column":7,"offset":22172},"end":{"line":481,"column":26,"offset":22191},"indent":[]}}],"position":{"start":{"line":481,"column":1,"offset":22166},"end":{"line":481,"column":26,"offset":22191},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When this settings is set to true, the image is marked with a timestamp.","position":{"start":{"line":483,"column":1,"offset":22193},"end":{"line":483,"column":73,"offset":22265},"indent":[]}}],"position":{"start":{"line":483,"column":1,"offset":22193},"end":{"line":483,"column":73,"offset":22265},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Timestamp color","position":{"start":{"line":485,"column":7,"offset":22273},"end":{"line":485,"column":22,"offset":22288},"indent":[]}}],"position":{"start":{"line":485,"column":1,"offset":22267},"end":{"line":485,"column":22,"offset":22288},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A color can be defined for timestamp: white, black, red, green and blue.","position":{"start":{"line":486,"column":1,"offset":22289},"end":{"line":486,"column":73,"offset":22361},"indent":[]}}],"position":{"start":{"line":486,"column":1,"offset":22289},"end":{"line":486,"column":73,"offset":22361},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Privacy","position":{"start":{"line":488,"column":7,"offset":22369},"end":{"line":488,"column":14,"offset":22376},"indent":[]}}],"position":{"start":{"line":488,"column":1,"offset":22363},"end":{"line":488,"column":14,"offset":22376},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The privacy mode can be activated to remove some parts from the image. This especially helpful if you want to filter out public areas. When this option is enabled you will seee that after configuring the Hull expositor, you'll see that the pixels outside your region of interest (Hull) are made black.","position":{"start":{"line":489,"column":1,"offset":22377},"end":{"line":489,"column":303,"offset":22679},"indent":[]}}],"position":{"start":{"line":489,"column":1,"offset":22377},"end":{"line":489,"column":303,"offset":22679},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Throttler","position":{"start":{"line":491,"column":7,"offset":22687},"end":{"line":491,"column":16,"offset":22696},"indent":[]}}],"position":{"start":{"line":491,"column":1,"offset":22681},"end":{"line":491,"column":16,"offset":22696},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Disk will only be triggered once in 5 seconds, nevertheless more detections occurred.","position":{"start":{"line":492,"column":1,"offset":22697},"end":{"line":492,"column":187,"offset":22883},"indent":[]}}],"position":{"start":{"line":492,"column":1,"offset":22697},"end":{"line":492,"column":187,"offset":22883},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Video","position":{"start":{"line":494,"column":5,"offset":22889},"end":{"line":494,"column":10,"offset":22894},"indent":[]}}],"position":{"start":{"line":494,"column":1,"offset":22885},"end":{"line":494,"column":10,"offset":22894},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When a valid event is detected, a video will be recorded for x seconds. When more valid events are detected, while a video is recording, the video file will further record for x seconds; so no new video file be recorded, but the existing one will be expanded.","position":{"start":{"line":495,"column":1,"offset":22895},"end":{"line":495,"column":260,"offset":23154},"indent":[]}}],"position":{"start":{"line":495,"column":1,"offset":22895},"end":{"line":495,"column":260,"offset":23154},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":497,"column":6,"offset":23161},"end":{"line":497,"column":16,"offset":23171},"indent":[]}}],"position":{"start":{"line":497,"column":1,"offset":23156},"end":{"line":497,"column":16,"offset":23171},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Video output device can be found in the ","position":{"start":{"line":498,"column":1,"offset":23172},"end":{"line":498,"column":63,"offset":23234},"indent":[]}},{"type":"inlineCode","value":"config/io.xml","position":{"start":{"line":498,"column":63,"offset":23234},"end":{"line":498,"column":78,"offset":23249},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":498,"column":78,"offset":23249},"end":{"line":498,"column":183,"offset":23354},"indent":[]}}],"position":{"start":{"line":498,"column":1,"offset":23172},"end":{"line":498,"column":183,"offset":23354},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n","position":{"start":{"line":500,"column":1,"offset":23356},"end":{"line":518,"column":4,"offset":24146},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"FPS","position":{"start":{"line":520,"column":7,"offset":24154},"end":{"line":520,"column":10,"offset":24157},"indent":[]}}],"position":{"start":{"line":520,"column":1,"offset":24148},"end":{"line":520,"column":10,"offset":24157},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The frames per second of the video being recorded. Please note that this number is limited and depends heavily on your hardware setup. You'll be receiving following warning in the systems logs, if the machinery can't write the desired FPS.","position":{"start":{"line":521,"column":1,"offset":24158},"end":{"line":521,"column":240,"offset":24397},"indent":[]}}],"position":{"start":{"line":521,"column":1,"offset":24158},"end":{"line":521,"column":240,"offset":24397},"indent":[]}},{"type":"code","lang":"text","meta":null,"value":"[trivial] IoVideo: framerate is too fast, can't record video at this speed (8/FPS)","position":{"start":{"line":523,"column":1,"offset":24399},"end":{"line":525,"column":4,"offset":24493},"indent":[1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Record after","position":{"start":{"line":526,"column":7,"offset":24500},"end":{"line":526,"column":19,"offset":24512},"indent":[]}}],"position":{"start":{"line":526,"column":1,"offset":24494},"end":{"line":526,"column":19,"offset":24512},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The number of seconds recorded after the last valid event was detected. This means that when a video is already recording, and a valid event was detected, the video will be expanded with x more seconds.","position":{"start":{"line":527,"column":1,"offset":24513},"end":{"line":527,"column":203,"offset":24715},"indent":[]}}],"position":{"start":{"line":527,"column":1,"offset":24513},"end":{"line":527,"column":203,"offset":24715},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Extensions","position":{"start":{"line":529,"column":7,"offset":24723},"end":{"line":529,"column":17,"offset":24733},"indent":[]}}],"position":{"start":{"line":529,"column":1,"offset":24717},"end":{"line":529,"column":17,"offset":24733},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The extension or container of the video file. We highly recommend to use the MP4 container if you want cross-browser support. Leave this setting by default, if you don't know what you're doing.","position":{"start":{"line":530,"column":1,"offset":24734},"end":{"line":530,"column":194,"offset":24927},"indent":[]}}],"position":{"start":{"line":530,"column":1,"offset":24734},"end":{"line":530,"column":194,"offset":24927},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Codec","position":{"start":{"line":532,"column":7,"offset":24935},"end":{"line":532,"column":12,"offset":24940},"indent":[]}}],"position":{"start":{"line":532,"column":1,"offset":24929},"end":{"line":532,"column":12,"offset":24940},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The codec that is used to encode the video file.","position":{"start":{"line":533,"column":1,"offset":24941},"end":{"line":533,"column":49,"offset":24989},"indent":[]}}],"position":{"start":{"line":533,"column":1,"offset":24941},"end":{"line":533,"column":49,"offset":24989},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"File format","position":{"start":{"line":535,"column":7,"offset":24997},"end":{"line":535,"column":18,"offset":25008},"indent":[]}}],"position":{"start":{"line":535,"column":1,"offset":24991},"end":{"line":535,"column":18,"offset":25008},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The format that will be used for the name of the image. One or more variables can be defined and will be replaced by the machinery. Note that when you're using a variables name in the file format, that this name should be defined in the JSON object.","position":{"start":{"line":536,"column":1,"offset":25009},"end":{"line":536,"column":250,"offset":25258},"indent":[]}}],"position":{"start":{"line":536,"column":1,"offset":25009},"end":{"line":536,"column":250,"offset":25258},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Directory","position":{"start":{"line":538,"column":7,"offset":25266},"end":{"line":538,"column":16,"offset":25275},"indent":[]}}],"position":{"start":{"line":538,"column":1,"offset":25260},"end":{"line":538,"column":16,"offset":25275},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The directory where the videos will be saved. By default videos are saved to the /etc/opt/kerberosio/capture directory.","position":{"start":{"line":539,"column":1,"offset":25276},"end":{"line":539,"column":120,"offset":25395},"indent":[]}}],"position":{"start":{"line":539,"column":1,"offset":25276},"end":{"line":539,"column":120,"offset":25395},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Hardware directory","position":{"start":{"line":541,"column":7,"offset":25403},"end":{"line":541,"column":25,"offset":25421},"indent":[]}}],"position":{"start":{"line":541,"column":1,"offset":25397},"end":{"line":541,"column":25,"offset":25421},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When using onboard hardware encoding (e.g. with Raspberry Pi camera), h264 video files are generated and stored in this directory. Afterwards these h264 files will be containerized to mp4 files, and stored in the Directory path.","position":{"start":{"line":542,"column":1,"offset":25422},"end":{"line":542,"column":229,"offset":25650},"indent":[]}}],"position":{"start":{"line":542,"column":1,"offset":25422},"end":{"line":542,"column":229,"offset":25650},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Enable Hardware encoding","position":{"start":{"line":544,"column":7,"offset":25658},"end":{"line":544,"column":31,"offset":25682},"indent":[]}}],"position":{"start":{"line":544,"column":1,"offset":25652},"end":{"line":544,"column":31,"offset":25682},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A boolean which can enable or disable hardware encoding. Please note that this option is enabled by default, but does not mean that it will work if you choose to use an USB camera.","position":{"start":{"line":545,"column":1,"offset":25683},"end":{"line":545,"column":181,"offset":25863},"indent":[]}}],"position":{"start":{"line":545,"column":1,"offset":25683},"end":{"line":545,"column":181,"offset":25863},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Mark with timestamp","position":{"start":{"line":547,"column":7,"offset":25871},"end":{"line":547,"column":26,"offset":25890},"indent":[]}}],"position":{"start":{"line":547,"column":1,"offset":25865},"end":{"line":547,"column":26,"offset":25890},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When this settings is set to true, the video is marked with a timestamp (similar to the Disk device).","position":{"start":{"line":548,"column":1,"offset":25891},"end":{"line":548,"column":102,"offset":25992},"indent":[]}}],"position":{"start":{"line":548,"column":1,"offset":25891},"end":{"line":548,"column":102,"offset":25992},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Timestamp color","position":{"start":{"line":550,"column":7,"offset":26000},"end":{"line":550,"column":22,"offset":26015},"indent":[]}}],"position":{"start":{"line":550,"column":1,"offset":25994},"end":{"line":550,"column":22,"offset":26015},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A color can be defined for timestamp: white, black, red, green and blue.","position":{"start":{"line":551,"column":1,"offset":26016},"end":{"line":551,"column":73,"offset":26088},"indent":[]}}],"position":{"start":{"line":551,"column":1,"offset":26016},"end":{"line":551,"column":73,"offset":26088},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Privacy","position":{"start":{"line":553,"column":7,"offset":26096},"end":{"line":553,"column":14,"offset":26103},"indent":[]}}],"position":{"start":{"line":553,"column":1,"offset":26090},"end":{"line":553,"column":14,"offset":26103},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The privacy mode can be activated to remove some parts from the video. This especially helpful if you want to filter out public areas.","position":{"start":{"line":554,"column":1,"offset":26104},"end":{"line":554,"column":135,"offset":26238},"indent":[]}}],"position":{"start":{"line":554,"column":1,"offset":26104},"end":{"line":554,"column":135,"offset":26238},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Video privacy","position":{"start":{"line":556,"column":7,"offset":26246},"end":{"line":556,"column":20,"offset":26259},"indent":[]}}],"position":{"start":{"line":556,"column":1,"offset":26240},"end":{"line":556,"column":20,"offset":26259},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"After updating the configuration, you'll see that the pixels outside your region of interest (ROI) are made black; the image below illustrates this.","position":{"start":{"line":557,"column":1,"offset":26260},"end":{"line":557,"column":149,"offset":26408},"indent":[]}}],"position":{"start":{"line":557,"column":1,"offset":26260},"end":{"line":557,"column":149,"offset":26408},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Throttler","position":{"start":{"line":559,"column":7,"offset":26416},"end":{"line":559,"column":16,"offset":26425},"indent":[]}}],"position":{"start":{"line":559,"column":1,"offset":26410},"end":{"line":559,"column":16,"offset":26425},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Video will only be triggered once in 5 seconds, nevertheless more detections occurred.","position":{"start":{"line":560,"column":1,"offset":26426},"end":{"line":560,"column":188,"offset":26613},"indent":[]}}],"position":{"start":{"line":560,"column":1,"offset":26426},"end":{"line":560,"column":188,"offset":26613},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"TCP/IP client","position":{"start":{"line":562,"column":5,"offset":26619},"end":{"line":562,"column":18,"offset":26632},"indent":[]}}],"position":{"start":{"line":562,"column":1,"offset":26615},"end":{"line":562,"column":18,"offset":26632},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The TCP/IP client will send a TCP packet to a server.","position":{"start":{"line":564,"column":1,"offset":26634},"end":{"line":564,"column":54,"offset":26687},"indent":[]}}],"position":{"start":{"line":564,"column":1,"offset":26634},"end":{"line":564,"column":54,"offset":26687},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":566,"column":6,"offset":26694},"end":{"line":566,"column":16,"offset":26704},"indent":[]}}],"position":{"start":{"line":566,"column":1,"offset":26689},"end":{"line":566,"column":16,"offset":26704},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the TCP/IP client can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":567,"column":1,"offset":26705},"end":{"line":567,"column":175,"offset":26879},"indent":[]}}],"position":{"start":{"line":567,"column":1,"offset":26705},"end":{"line":567,"column":175,"offset":26879},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n 127.0.0.1\n 1337\n it's so fluffy\n 0\n \n","position":{"start":{"line":569,"column":1,"offset":26881},"end":{"line":578,"column":4,"offset":27107},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Server","position":{"start":{"line":580,"column":7,"offset":27115},"end":{"line":580,"column":13,"offset":27121},"indent":[]}}],"position":{"start":{"line":580,"column":1,"offset":27109},"end":{"line":580,"column":13,"offset":27121},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The IP of the TCP server.","position":{"start":{"line":581,"column":1,"offset":27122},"end":{"line":581,"column":26,"offset":27147},"indent":[]}}],"position":{"start":{"line":581,"column":1,"offset":27122},"end":{"line":581,"column":26,"offset":27147},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Port","position":{"start":{"line":583,"column":7,"offset":27155},"end":{"line":583,"column":11,"offset":27159},"indent":[]}}],"position":{"start":{"line":583,"column":1,"offset":27149},"end":{"line":583,"column":11,"offset":27159},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This is the port of the TCP server.","position":{"start":{"line":584,"column":1,"offset":27160},"end":{"line":584,"column":36,"offset":27195},"indent":[]}}],"position":{"start":{"line":584,"column":1,"offset":27160},"end":{"line":584,"column":36,"offset":27195},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Message","position":{"start":{"line":586,"column":7,"offset":27203},"end":{"line":586,"column":14,"offset":27210},"indent":[]}}],"position":{"start":{"line":586,"column":1,"offset":27197},"end":{"line":586,"column":14,"offset":27210},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can send some data to a TCP server.","position":{"start":{"line":587,"column":1,"offset":27211},"end":{"line":587,"column":40,"offset":27250},"indent":[]}}],"position":{"start":{"line":587,"column":1,"offset":27211},"end":{"line":587,"column":40,"offset":27250},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Throttler","position":{"start":{"line":589,"column":7,"offset":27258},"end":{"line":589,"column":16,"offset":27267},"indent":[]}}],"position":{"start":{"line":589,"column":1,"offset":27252},"end":{"line":589,"column":16,"offset":27267},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the TCP will only be triggered once in 5 seconds, nevertheless more detections occurred.","position":{"start":{"line":590,"column":1,"offset":27268},"end":{"line":590,"column":186,"offset":27453},"indent":[]}}],"position":{"start":{"line":590,"column":1,"offset":27268},"end":{"line":590,"column":186,"offset":27453},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"GPIO","position":{"start":{"line":592,"column":5,"offset":27459},"end":{"line":592,"column":9,"offset":27463},"indent":[]}}],"position":{"start":{"line":592,"column":1,"offset":27455},"end":{"line":592,"column":9,"offset":27463},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A GPIO pin can be set as output device.","position":{"start":{"line":593,"column":1,"offset":27464},"end":{"line":593,"column":40,"offset":27503},"indent":[]}}],"position":{"start":{"line":593,"column":1,"offset":27464},"end":{"line":593,"column":40,"offset":27503},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":595,"column":6,"offset":27510},"end":{"line":595,"column":16,"offset":27520},"indent":[]}}],"position":{"start":{"line":595,"column":1,"offset":27505},"end":{"line":595,"column":16,"offset":27520},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the GPIO pin can be found in the ","position":{"start":{"line":596,"column":1,"offset":27521},"end":{"line":596,"column":52,"offset":27572},"indent":[]}},{"type":"inlineCode","value":"config/io.xml","position":{"start":{"line":596,"column":52,"offset":27572},"end":{"line":596,"column":67,"offset":27587},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":596,"column":67,"offset":27587},"end":{"line":596,"column":172,"offset":27692},"indent":[]}}],"position":{"start":{"line":596,"column":1,"offset":27521},"end":{"line":596,"column":172,"offset":27692},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n 17\n 5\n 100000\n 0\n \n","position":{"start":{"line":598,"column":1,"offset":27694},"end":{"line":607,"column":4,"offset":27900},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Pin","position":{"start":{"line":609,"column":7,"offset":27908},"end":{"line":609,"column":10,"offset":27911},"indent":[]}}],"position":{"start":{"line":609,"column":1,"offset":27902},"end":{"line":609,"column":10,"offset":27911},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The pin that will be triggered.","position":{"start":{"line":610,"column":1,"offset":27912},"end":{"line":610,"column":32,"offset":27943},"indent":[]}}],"position":{"start":{"line":610,"column":1,"offset":27912},"end":{"line":610,"column":32,"offset":27943},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Periods","position":{"start":{"line":612,"column":7,"offset":27951},"end":{"line":612,"column":14,"offset":27958},"indent":[]}}],"position":{"start":{"line":612,"column":1,"offset":27945},"end":{"line":612,"column":14,"offset":27958},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The number of times the pin will be triggered.","position":{"start":{"line":613,"column":1,"offset":27959},"end":{"line":613,"column":47,"offset":28005},"indent":[]}}],"position":{"start":{"line":613,"column":1,"offset":27959},"end":{"line":613,"column":47,"offset":28005},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Period time","position":{"start":{"line":615,"column":7,"offset":28013},"end":{"line":615,"column":18,"offset":28024},"indent":[]}}],"position":{"start":{"line":615,"column":1,"offset":28007},"end":{"line":615,"column":18,"offset":28024},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The time in microseconds that the pin will be set high.","position":{"start":{"line":616,"column":1,"offset":28025},"end":{"line":616,"column":56,"offset":28080},"indent":[]}}],"position":{"start":{"line":616,"column":1,"offset":28025},"end":{"line":616,"column":56,"offset":28080},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Throttler","position":{"start":{"line":618,"column":7,"offset":28088},"end":{"line":618,"column":16,"offset":28097},"indent":[]}}],"position":{"start":{"line":618,"column":1,"offset":28082},"end":{"line":618,"column":16,"offset":28097},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the GPIO will only be triggered once in 5 seconds, nevertheless more detections occurred.","position":{"start":{"line":619,"column":1,"offset":28098},"end":{"line":619,"column":187,"offset":28284},"indent":[]}}],"position":{"start":{"line":619,"column":1,"offset":28098},"end":{"line":619,"column":187,"offset":28284},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Webhook","position":{"start":{"line":621,"column":6,"offset":28291},"end":{"line":621,"column":13,"offset":28298},"indent":[]}}],"position":{"start":{"line":621,"column":1,"offset":28286},"end":{"line":621,"column":13,"offset":28298},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Detailed information (a JSON object) is send as a POST request to a webhook. The JSON object contains the number of changes, the region, the URL of the image, etc. This is useful if you want to integrate with your own application.","position":{"start":{"line":622,"column":1,"offset":28299},"end":{"line":622,"column":231,"offset":28529},"indent":[]}}],"position":{"start":{"line":622,"column":1,"offset":28299},"end":{"line":622,"column":231,"offset":28529},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Make sure that the Webhook comes after the Disk device, otherwise the URL of the image is not included.","position":{"start":{"line":624,"column":1,"offset":28531},"end":{"line":624,"column":104,"offset":28634},"indent":[]}}],"position":{"start":{"line":624,"column":1,"offset":28531},"end":{"line":624,"column":104,"offset":28634},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":626,"column":6,"offset":28641},"end":{"line":626,"column":16,"offset":28651},"indent":[]}}],"position":{"start":{"line":626,"column":1,"offset":28636},"end":{"line":626,"column":16,"offset":28651},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the webhook can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":627,"column":1,"offset":28652},"end":{"line":627,"column":169,"offset":28820},"indent":[]}}],"position":{"start":{"line":627,"column":1,"offset":28652},"end":{"line":627,"column":169,"offset":28820},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n http://kerberos.web/api/v1/webhook\n 0\n \n","position":{"start":{"line":629,"column":1,"offset":28822},"end":{"line":636,"column":4,"offset":28975},"indent":[1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Url","position":{"start":{"line":638,"column":7,"offset":28983},"end":{"line":638,"column":10,"offset":28986},"indent":[]}}],"position":{"start":{"line":638,"column":1,"offset":28977},"end":{"line":638,"column":10,"offset":28986},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This is the URL, to which the machinery will send a JSON object (as a POST request).","position":{"start":{"line":639,"column":1,"offset":28987},"end":{"line":639,"column":85,"offset":29071},"indent":[]}}],"position":{"start":{"line":639,"column":1,"offset":28987},"end":{"line":639,"column":85,"offset":29071},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Throttler","position":{"start":{"line":641,"column":7,"offset":29079},"end":{"line":641,"column":16,"offset":29088},"indent":[]}}],"position":{"start":{"line":641,"column":1,"offset":29073},"end":{"line":641,"column":16,"offset":29088},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Webhook will only be triggered once in 5 seconds, nevertheless more detections occurred.","position":{"start":{"line":642,"column":1,"offset":29089},"end":{"line":642,"column":190,"offset":29278},"indent":[]}}],"position":{"start":{"line":642,"column":1,"offset":29089},"end":{"line":642,"column":190,"offset":29278},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Output","position":{"start":{"line":644,"column":7,"offset":29286},"end":{"line":644,"column":13,"offset":29292},"indent":[]}}],"position":{"start":{"line":644,"column":1,"offset":29280},"end":{"line":644,"column":13,"offset":29292},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A JSON object is POSTed to the url you've defined.","position":{"start":{"line":645,"column":1,"offset":29293},"end":{"line":645,"column":51,"offset":29343},"indent":[]}}],"position":{"start":{"line":645,"column":1,"offset":29293},"end":{"line":645,"column":51,"offset":29343},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"[\n 'regionCoordinates' : [618, 317, 703, 493],\n 'numberOfChanges' : 5446,\n 'timestamp' : '1465894497',\n 'microseconds' : '5-97451',\n 'token' : 695,\n 'pathToImage' : '1465894497_5-97451_frontdoor_618-317-703-493_5446_695.jpg',\n 'instanceName' : 'frontdoor',\n]","position":{"start":{"line":647,"column":1,"offset":29345},"end":{"line":657,"column":4,"offset":29622},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Script","position":{"start":{"line":659,"column":5,"offset":29628},"end":{"line":659,"column":11,"offset":29634},"indent":[]}}],"position":{"start":{"line":659,"column":1,"offset":29624},"end":{"line":659,"column":11,"offset":29634},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A bash script can be executed after a valid event was detected. A JSON object is send in the first parameter to the script you've defined.","position":{"start":{"line":660,"column":1,"offset":29635},"end":{"line":660,"column":139,"offset":29773},"indent":[]}}],"position":{"start":{"line":660,"column":1,"offset":29635},"end":{"line":660,"column":139,"offset":29773},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":662,"column":6,"offset":29780},"end":{"line":662,"column":16,"offset":29790},"indent":[]}}],"position":{"start":{"line":662,"column":1,"offset":29775},"end":{"line":662,"column":16,"offset":29790},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Script output device can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":663,"column":1,"offset":29791},"end":{"line":663,"column":182,"offset":29972},"indent":[]}}],"position":{"start":{"line":663,"column":1,"offset":29791},"end":{"line":663,"column":182,"offset":29972},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n","position":{"start":{"line":665,"column":1,"offset":29974},"end":{"line":672,"column":4,"offset":30127},"indent":[1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Path","position":{"start":{"line":674,"column":7,"offset":30135},"end":{"line":674,"column":11,"offset":30139},"indent":[]}}],"position":{"start":{"line":674,"column":1,"offset":30129},"end":{"line":674,"column":11,"offset":30139},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The location of the script that will be executed on detection.","position":{"start":{"line":675,"column":1,"offset":30140},"end":{"line":675,"column":63,"offset":30202},"indent":[]}}],"position":{"start":{"line":675,"column":1,"offset":30140},"end":{"line":675,"column":63,"offset":30202},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Throttler","position":{"start":{"line":677,"column":7,"offset":30210},"end":{"line":677,"column":16,"offset":30219},"indent":[]}}],"position":{"start":{"line":677,"column":1,"offset":30204},"end":{"line":677,"column":16,"offset":30219},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Script will only be triggered once in 5 seconds, nevertheless more detections occurred.","position":{"start":{"line":678,"column":1,"offset":30220},"end":{"line":678,"column":189,"offset":30408},"indent":[]}}],"position":{"start":{"line":678,"column":1,"offset":30220},"end":{"line":678,"column":189,"offset":30408},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Example","position":{"start":{"line":680,"column":7,"offset":30416},"end":{"line":680,"column":14,"offset":30423},"indent":[]}}],"position":{"start":{"line":680,"column":1,"offset":30410},"end":{"line":680,"column":14,"offset":30423},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default the script will point to /etc/opt/kerberosio/scripts/run.sh, which contains a template how you should start your script. Note that when using KiOS, this script will be read-only, copy it to the /data folder and change the path parameter.","position":{"start":{"line":681,"column":1,"offset":30424},"end":{"line":681,"column":249,"offset":30672},"indent":[]}}],"position":{"start":{"line":681,"column":1,"offset":30424},"end":{"line":681,"column":249,"offset":30672},"indent":[]}},{"type":"code","lang":"python","meta":null,"value":"#!/bin/bash\n# -------------------------------------------\n# This is an example script which illustrates\n# how to use the Script IO device.\n#\n# --------------------------------------\n# The first parameter is the JSON object\n#\n# e.g. {\"regionCoordinates\":[308,250,346,329],\"numberOfChanges\":194,\"timestamp\":\"1486049622\",\"microseconds\":\"6-161868\",\"token\":344,\"pathToImage\":\"1486049622_6-161868_frontdoor_308-250-346-329_194_344.jpg\",\"instanceName\":\"frontdoor\"}\nJSON=$1\n# -------------------------------------------\n# You can use python to parse the JSON object\n# and get the required fields\nname=$(echo $JSON | python -c \"import sys, json; print json.load(sys.stdin)['instanceName']\")\ncoordinates=$(echo $JSON | python -c \"import sys, json; print json.load(sys.stdin)['regionCoordinates']\")\nchanges=$(echo $JSON | pythfon -c \"import sys, json; print json.load(sys.stdin)['numberOfChanges']\")\nimage=$(echo $JSON | python -c \"import sys, json; print json.load(sys.stdin)['pathToImage']\")\nThe idea is that you can use Python in your bash script, to parse the JSON object send as first parameter. Afterwards you can do with the output what you want.","position":{"start":{"line":683,"column":1,"offset":30674},"end":{"line":702,"column":4,"offset":31830},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"MQTT","position":{"start":{"line":704,"column":5,"offset":31836},"end":{"line":704,"column":9,"offset":31840},"indent":[]}}],"position":{"start":{"line":704,"column":1,"offset":31832},"end":{"line":704,"column":9,"offset":31840},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"MQTT protocol is a light-weight Machine to Machine (M2M) protocol widely used in Internet of things.\nDetailed information (a JSON object) is published to an MQTT topic. The JSON object contains the number of changes, the region, the URL of the image, etc.","position":{"start":{"line":705,"column":1,"offset":31841},"end":{"line":706,"column":155,"offset":32096},"indent":[1]}}],"position":{"start":{"line":705,"column":1,"offset":31841},"end":{"line":706,"column":155,"offset":32096},"indent":[1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":708,"column":6,"offset":32103},"end":{"line":708,"column":16,"offset":32113},"indent":[]}}],"position":{"start":{"line":708,"column":1,"offset":32098},"end":{"line":708,"column":16,"offset":32113},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the MQTT output can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":709,"column":1,"offset":32114},"end":{"line":709,"column":173,"offset":32286},"indent":[]}}],"position":{"start":{"line":709,"column":1,"offset":32114},"end":{"line":709,"column":173,"offset":32286},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n false\n false\n 127.0.0.1\n 1883\n kios/mqtt\n \n \n 0\n \n","position":{"start":{"line":711,"column":1,"offset":32288},"end":{"line":724,"column":4,"offset":32652},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Secure","position":{"start":{"line":726,"column":7,"offset":32660},"end":{"line":726,"column":13,"offset":32666},"indent":[]}}],"position":{"start":{"line":726,"column":1,"offset":32654},"end":{"line":726,"column":13,"offset":32666},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If checked, enable SSL/TLS support. Please note that when SSL/TLS support is enabled, the server certificate issuer is verified against the CA (Certification Authority) files available in /etc/ssl/certs.","position":{"start":{"line":727,"column":1,"offset":32667},"end":{"line":727,"column":204,"offset":32870},"indent":[]}}],"position":{"start":{"line":727,"column":1,"offset":32667},"end":{"line":727,"column":204,"offset":32870},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Verifycn","position":{"start":{"line":729,"column":7,"offset":32878},"end":{"line":729,"column":15,"offset":32886},"indent":[]}}],"position":{"start":{"line":729,"column":1,"offset":32872},"end":{"line":729,"column":15,"offset":32886},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If checked, the MQTT server FQDN or ip address must match the CN (Common Name) of the server certificate.","position":{"start":{"line":730,"column":1,"offset":32887},"end":{"line":730,"column":106,"offset":32992},"indent":[]}}],"position":{"start":{"line":730,"column":1,"offset":32887},"end":{"line":730,"column":106,"offset":32992},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Server","position":{"start":{"line":732,"column":7,"offset":33000},"end":{"line":732,"column":13,"offset":33006},"indent":[]}}],"position":{"start":{"line":732,"column":1,"offset":32994},"end":{"line":732,"column":13,"offset":33006},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"IP address or FQDN of the MQTT broker.","position":{"start":{"line":733,"column":1,"offset":33007},"end":{"line":733,"column":39,"offset":33045},"indent":[]}}],"position":{"start":{"line":733,"column":1,"offset":33007},"end":{"line":733,"column":39,"offset":33045},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Port","position":{"start":{"line":735,"column":7,"offset":33053},"end":{"line":735,"column":11,"offset":33057},"indent":[]}}],"position":{"start":{"line":735,"column":1,"offset":33047},"end":{"line":735,"column":11,"offset":33057},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"TCP port of the MQTT broker.","position":{"start":{"line":736,"column":1,"offset":33058},"end":{"line":736,"column":29,"offset":33086},"indent":[]}}],"position":{"start":{"line":736,"column":1,"offset":33058},"end":{"line":736,"column":29,"offset":33086},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Topic","position":{"start":{"line":738,"column":7,"offset":33094},"end":{"line":738,"column":12,"offset":33099},"indent":[]}}],"position":{"start":{"line":738,"column":1,"offset":33088},"end":{"line":738,"column":12,"offset":33099},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The topic to publish to.","position":{"start":{"line":739,"column":1,"offset":33100},"end":{"line":739,"column":25,"offset":33124},"indent":[]}}],"position":{"start":{"line":739,"column":1,"offset":33100},"end":{"line":739,"column":25,"offset":33124},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Username","position":{"start":{"line":741,"column":7,"offset":33132},"end":{"line":741,"column":15,"offset":33140},"indent":[]}}],"position":{"start":{"line":741,"column":1,"offset":33126},"end":{"line":741,"column":15,"offset":33140},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The username for authenticating to the MQTT broker. This is only supported by brokers that implement the MQTT spec v3.1. If username is not set (empty), the password argument is ignored. This is only needed if the MQTT broker is configured for authentication.","position":{"start":{"line":742,"column":1,"offset":33141},"end":{"line":742,"column":260,"offset":33400},"indent":[]}}],"position":{"start":{"line":742,"column":1,"offset":33141},"end":{"line":742,"column":260,"offset":33400},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Password","position":{"start":{"line":744,"column":7,"offset":33408},"end":{"line":744,"column":15,"offset":33416},"indent":[]}}],"position":{"start":{"line":744,"column":1,"offset":33402},"end":{"line":744,"column":15,"offset":33416},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The password to use, together with the username, for authenticating to the MQTT broker. This is only supported by brokers that implement the MQTT spec v3.1. This is only needed if the MQTT broker is configured for authentication.","position":{"start":{"line":745,"column":1,"offset":33417},"end":{"line":745,"column":230,"offset":33646},"indent":[]}}],"position":{"start":{"line":745,"column":1,"offset":33417},"end":{"line":745,"column":230,"offset":33646},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Throttler","position":{"start":{"line":747,"column":7,"offset":33654},"end":{"line":747,"column":16,"offset":33663},"indent":[]}}],"position":{"start":{"line":747,"column":1,"offset":33648},"end":{"line":747,"column":16,"offset":33663},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the MQTT will only be triggered once in 5 seconds, nevertheless more detections occurred.","position":{"start":{"line":748,"column":1,"offset":33664},"end":{"line":748,"column":187,"offset":33850},"indent":[]}}],"position":{"start":{"line":748,"column":1,"offset":33664},"end":{"line":748,"column":187,"offset":33850},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Output","position":{"start":{"line":750,"column":7,"offset":33858},"end":{"line":750,"column":13,"offset":33864},"indent":[]}}],"position":{"start":{"line":750,"column":1,"offset":33852},"end":{"line":750,"column":13,"offset":33864},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A JSON object is published to the topic of the MQTT broker you have configured.","position":{"start":{"line":751,"column":1,"offset":33865},"end":{"line":751,"column":80,"offset":33944},"indent":[]}}],"position":{"start":{"line":751,"column":1,"offset":33865},"end":{"line":751,"column":80,"offset":33944},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"[\n 'regionCoordinates' : [618, 317, 703, 493],\n 'numberOfChanges' : 5446,\n 'timestamp' : '1465894497',\n 'microseconds' : '5-97451',\n 'token' : 695,\n 'pathToImage' : '1465894497_5-97451_frontdoor_618-317-703-493_5446_695.jpg',\n 'instanceName' : 'frontdoor',\n]","position":{"start":{"line":753,"column":1,"offset":33946},"end":{"line":763,"column":4,"offset":34223},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Example","position":{"start":{"line":765,"column":7,"offset":34231},"end":{"line":765,"column":14,"offset":34238},"indent":[]}}],"position":{"start":{"line":765,"column":1,"offset":34225},"end":{"line":765,"column":14,"offset":34238},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It is possible to subscribe multiple distributed IoT devices to the same MQTT topic and perform specific actions upon the detection of a motion. Devices with more resources could fetch the image to perform further elaboration.","position":{"start":{"line":766,"column":1,"offset":34239},"end":{"line":766,"column":227,"offset":34465},"indent":[]}}],"position":{"start":{"line":766,"column":1,"offset":34239},"end":{"line":766,"column":227,"offset":34465},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Streaming","position":{"start":{"line":768,"column":4,"offset":34470},"end":{"line":768,"column":13,"offset":34479},"indent":[]}}],"position":{"start":{"line":768,"column":1,"offset":34467},"end":{"line":768,"column":13,"offset":34479},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The machinery has the ability to stream your capture device as a MJPG stream.","position":{"start":{"line":770,"column":1,"offset":34481},"end":{"line":770,"column":78,"offset":34558},"indent":[]}}],"position":{"start":{"line":770,"column":1,"offset":34481},"end":{"line":770,"column":78,"offset":34558},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":772,"column":5,"offset":34564},"end":{"line":772,"column":15,"offset":34574},"indent":[]}}],"position":{"start":{"line":772,"column":1,"offset":34560},"end":{"line":772,"column":15,"offset":34574},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters for the supported streaming protocols can be found in the ","position":{"start":{"line":774,"column":1,"offset":34576},"end":{"line":774,"column":74,"offset":34649},"indent":[]}},{"type":"inlineCode","value":"config/stream.xml","position":{"start":{"line":774,"column":74,"offset":34649},"end":{"line":774,"column":93,"offset":34668},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file; at the moment of writing only a MJPG stream is supported.","position":{"start":{"line":774,"column":93,"offset":34668},"end":{"line":774,"column":256,"offset":34831},"indent":[]}}],"position":{"start":{"line":774,"column":1,"offset":34576},"end":{"line":774,"column":256,"offset":34831},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n\t\n \ttrue\n \t8889\n \t75\n \t\n \t75\n \n","position":{"start":{"line":776,"column":1,"offset":34833},"end":{"line":786,"column":4,"offset":35099},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Enabled","position":{"start":{"line":788,"column":6,"offset":35106},"end":{"line":788,"column":13,"offset":35113},"indent":[]}}],"position":{"start":{"line":788,"column":1,"offset":35101},"end":{"line":788,"column":13,"offset":35113},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A boolean which turns ON/OFF the stream. This is interesting when working with IP cameras, where you already have an RTSP/MJPG stream from the camera itself.","position":{"start":{"line":790,"column":1,"offset":35115},"end":{"line":790,"column":158,"offset":35272},"indent":[]}}],"position":{"start":{"line":790,"column":1,"offset":35115},"end":{"line":790,"column":158,"offset":35272},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Stream Port","position":{"start":{"line":792,"column":6,"offset":35279},"end":{"line":792,"column":17,"offset":35290},"indent":[]}}],"position":{"start":{"line":792,"column":1,"offset":35274},"end":{"line":792,"column":17,"offset":35290},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The port on which the stream is available.","position":{"start":{"line":794,"column":1,"offset":35292},"end":{"line":794,"column":43,"offset":35334},"indent":[]}}],"position":{"start":{"line":794,"column":1,"offset":35292},"end":{"line":794,"column":43,"offset":35334},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Quality","position":{"start":{"line":796,"column":6,"offset":35341},"end":{"line":796,"column":13,"offset":35348},"indent":[]}}],"position":{"start":{"line":796,"column":1,"offset":35336},"end":{"line":796,"column":13,"offset":35348},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The quality is a value between ","position":{"start":{"line":798,"column":1,"offset":35350},"end":{"line":798,"column":32,"offset":35381},"indent":[]}},{"type":"linkReference","identifier":"0-100","label":"0-100","referenceType":"shortcut","children":[{"type":"text","value":"0-100","position":{"start":{"line":798,"column":33,"offset":35382},"end":{"line":798,"column":38,"offset":35387},"indent":[]}}],"position":{"start":{"line":798,"column":32,"offset":35381},"end":{"line":798,"column":39,"offset":35388},"indent":[]}},{"type":"text","value":". The lower the quality, the more the image will be compressed. If you're using the RaspberryPi Camera module, this option will be ignored.","position":{"start":{"line":798,"column":39,"offset":35388},"end":{"line":798,"column":178,"offset":35527},"indent":[]}}],"position":{"start":{"line":798,"column":1,"offset":35350},"end":{"line":798,"column":178,"offset":35527},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Username/password","position":{"start":{"line":800,"column":6,"offset":35534},"end":{"line":800,"column":23,"offset":35551},"indent":[]}}],"position":{"start":{"line":800,"column":1,"offset":35529},"end":{"line":800,"column":23,"offset":35551},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can secure the MJPEG streaming with a username and password. These credentials will be used to authorize your requests using Basic Authentication. Please note that once enabled, the live stream on the dashboard page can fail; however it will work if you open it directly in your browser or ip camera client. The format of the streaming url, after authentication enabled, will look as following:","position":{"start":{"line":802,"column":1,"offset":35553},"end":{"line":802,"column":399,"offset":35951},"indent":[]}}],"position":{"start":{"line":802,"column":1,"offset":35553},"end":{"line":802,"column":399,"offset":35951},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://username:password@ip-camera:8899","position":{"start":{"line":804,"column":1,"offset":35953},"end":{"line":806,"column":4,"offset":36002},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":809,"column":1,"offset":36005},"end":{"line":809,"column":31,"offset":36035},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":809,"column":31,"offset":36035}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport { Playground, Props } from 'docz'\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Machinery`}

\n

{`The machinery is the processing engine of Kerberos Open Source. It's an image processing framework, written in C++, who benefits from other third party libraries (OpenCV, etc). It takes images from the type of camera (USB-, IP- or RPi-camera) you've configured in the configuration files and executes one ore more algorithms and post-processes (e.g. save a snapshot). The configuration files allow you to define the type of camera, post-processes, conditions and much more; it's highly configurable. It's important to note that the machinery, out-of-the-box, can handle only one camera at a time.`}

\n

{`Project structure`}

\n

{`The machinery is an image processing framework which is devided into four steps:`}

\n
    \n
  • {`condition`}
  • \n
  • {`algorithm`}
  • \n
  • {`expositor`}
  • \n
  • {`heuristic`}
  • \n
\n

{`The steps belong to a four passway; illustrated on the image below. In each cycle a sequence of images is processed. Each step will process the sequence, and will return some result to the next step. For example: an algorithm will process the images and returns an array to the Expositor, which contains boolean values. The steps are loosly coupled, so they have simple conventions, just like the example before.`}

\n

{`Thanks to the loosly coupling, each step can be developed indepently. So algorithms, expositors, heuristics and conditions can be switched on the fly. This makes it easier for other developers who want to contribute to the machinery. They can create a new algorithm without knowing how a specific expositor or heuristic works. They just need to be aware of the convention an algorithm should meet.`}

\n

\"machinery

\n

{`These different steps can be configured by editing a couple of configurationn files located at `}{`config/`}{`. The main configuration file `}{`config/config.xml`}{` looks like this:`}

\n
{`{`xml`}{` version`}{`=`}{`\"1.0\"`}{`?>`}{`\n`}{`<`}{`kerberos`}{`>`}{`\n`}{`  `}{`<`}{`instance`}{`>`}{`\n`}{`    `}{`<`}{`name`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`frontdoor`}{`{`name`}{`>`}{`\n`}{`    `}{`<`}{`logging`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`false`}{`{`logging`}{`>`}{`\n`}{`    `}{`<`}{`timezone`}{` `}{`type`}{`=`}{`\"timezone\"`}{`>`}{`Europe-Brussels`}{`{`timezone`}{`>`}{`\n`}{`    `}{`<`}{`capture`}{` `}{`file`}{`=`}{`\"capture.xml\"`}{`>`}{`RaspiCamera`}{`{`capture`}{`>`}{`\n`}{`    `}{`<`}{`stream`}{` `}{`file`}{`=`}{`\"stream.xml\"`}{`>`}{`Mjpg`}{`{`stream`}{`>`}{`\n`}{`    `}{`<`}{`condition`}{` `}{`file`}{`=`}{`\"condition.xml\"`}{` `}{`type`}{`=`}{`\"multiple\"`}{`>`}{`Enabled`}{`{`condition`}{`>`}{`\n`}{`    `}{`<`}{`algorithm`}{` `}{`file`}{`=`}{`\"algorithm.xml\"`}{`>`}{`DifferentialCollins`}{`{`algorithm`}{`>`}{`\n`}{`    `}{`<`}{`expositor`}{` `}{`file`}{`=`}{`\"expositor.xml\"`}{`>`}{`Hull`}{`{`expositor`}{`>`}{`\n`}{`    `}{`<`}{`heuristic`}{` `}{`file`}{`=`}{`\"heuristic.xml\"`}{`>`}{`Sequence`}{`{`heuristic`}{`>`}{`\n`}{`    `}{`<`}{`io`}{` `}{`file`}{`=`}{`\"io.xml\"`}{` `}{`type`}{`=`}{`\"multiple\"`}{`>`}{`Video`}{`{`io`}{`>`}{`\n`}{`    `}{`<`}{`cloud`}{` `}{`file`}{`=`}{`\"cloud.xml\"`}{`>`}{`S3`}{`{`cloud`}{`>`}{`\n`}{`  `}{`{`instance`}{`>`}{`\n`}{`{`kerberos`}{`>`}
\n

{`Capture`}

\n

{`You can choose which capture device you will be using, you can use your old USB webcam, the popular Raspberry Pi camera or a state-of-the-art IP camera. The capture device will take pictures and deliver them to the algorithm if the conditions (the first step of the four passway) are valid.`}

\n

{`You can change the capture device by changing the `}{`config/config.xml`}{` file, and choose one of the following:`}

\n
    \n
  • {`USBCamera`}
  • \n
  • {`RaspiCamera`}
  • \n
  • {`IPCamera`}
  • \n
\n
{`{`xml`}{` version`}{`=`}{`\"1.0\"`}{`?>`}{`\n`}{`<`}{`kerberos`}{`>`}{`\n`}{`  `}{`<`}{`instance`}{`>`}{`\n`}{`    ...`}{`\n`}{`    `}{`<`}{`capture`}{` `}{`file`}{`=`}{`\"capture.xml\"`}{`>`}{`RaspiCamera`}{`{`capture`}{`>`}{`\n`}{`    ...`}{`\n`}{`  `}{`{`instance`}{`>`}{`\n`}{`{`kerberos`}{`>`}
\n

{`USB camera`}

\n

{`The machinery supports a whole range of USB cameras. You will find a complete list here. Make sure you have updated the web interface, to make the machinery aware you will be using an USB camera.`}

\n

{`Parameters`}

\n

{`The parameters of the USB camera can be found in the `}{`config/capture.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`captures`}{`>`}{`\n`}{`  `}{`<`}{`USBCamera`}{`>`}{`\n`}{`    `}{`<`}{`frameWidth`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`1280`}{`{`frameWidth`}{`>`}{`\n`}{`    `}{`<`}{`frameHeight`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`720`}{`{`frameHeight`}{`>`}{`\n`}{`    `}{`<`}{`deviceNumber`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`deviceNumber`}{`>`}{`\n`}{`    `}{`<`}{`delay`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`delay`}{`>`}{`\n`}{`    `}{`<`}{`angle`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`angle`}{`>`}{`\n`}{`  `}{`{`USBCamera`}{`>`}{`\n`}{`{`captures`}{`>`}
\n
{`Framewidth and -height`}
\n

{`You can set the resolution of the capture device, make sure the resolution you've defined is valid with your camera. Please check the specs of the USB camera you're using.`}

\n
{`Device number`}
\n

{`If more than one device is connected, you can specify the index of the USB-camera. The index is an integer (1-5).`}

\n
{`Delay`}
\n

{`You can provide a delay/interval (milliseconds) between two captures.`}

\n
{`Angle`}
\n

{`By defining an angle (degrees), you can rotate the images taken by the capture device. For example if you would mount the camera upside down, than you could enter the value 180 as the angle; this will flip the images.`}

\n

{`Raspberry Pi Camera Module`}

\n

{`You can use the Raspberry Pi Camera Module with the machinery. You just need to attach the camera module and you're ready to go. The Raspberry Pi Camera Module is enabled by default in the web.`}

\n

{`Parameters`}

\n

{`The parameters of the Raspberry Pi Camera Module can be found in the config/capture.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`captures`}{`>`}{`\n`}{`  `}{`<`}{`RaspiCamera`}{`>`}{`\n`}{`    `}{`<`}{`frameWidth`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`640`}{`{`frameWidth`}{`>`}{`\n`}{`    `}{`<`}{`frameHeight`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`480`}{`{`frameHeight`}{`>`}{`\n`}{`    `}{`<`}{`delay`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`1400`}{`{`delay`}{`>`}{`\n`}{`    `}{`<`}{`angle`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`angle`}{`>`}{`\n`}{`    `}{`<`}{`framerate`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`30`}{`{`framerate`}{`>`}{`\n`}{`    `}{`<`}{`sharpness`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`sharpness`}{`>`}{`\n`}{`    `}{`<`}{`saturation`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`saturation`}{`>`}{`\n`}{`    `}{`<`}{`contrast`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`contrast`}{`>`}{`\n`}{`    `}{`<`}{`brightness`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`50`}{`{`brightness`}{`>`}{`\n`}{`  `}{`{`RaspiCamera`}{`>`}{`\n`}{`{`captures`}{`>`}
\n
{`Framewidth and -height`}
\n

{`You can set the resolution of the camera module, make sure the resolution you've defined is valid.`}

\n
{`Delay`}
\n

{`You can provide a delay/interval (milliseconds) between two captures.`}

\n
{`Angle`}
\n

{`By defining an angle (degrees), you can rotate the images taken by the capture device. For example if you would mount the camera upside down, than you could enter the value 180 as the angle; this will flip the images.`}

\n
{`Framerate`}
\n

{`The number of frames captures per second. Please note that this parameter will also be used if you're recording video. E.g. if you set this parameter to 20, you're recorded videos will also be 20 FPS.`}

\n
{`Sharpness, saturation, contrast, brightness`}
\n

{`Camera properties which you can specify to tune the settings to your needs.`}

\n

{`IP camera`}

\n

{`The machinery can be used with any IP camera, that provides a RTSP (or MJPEG) stream. Make sure that you know the correct URL of your IP camera, you can `}{`find a list here`}{`.`}

\n

{`Parameters`}

\n

{`The parameters of the IP capture device can be found in the `}{`config/capture.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`captures`}{`>`}{`\n`}{`  `}{`<`}{`IPCamera`}{`>`}{`\n`}{`    `}{`<`}{`url`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`http://username:password@ipaddress/image.jpg`}{`{`url`}{`>`}{`\n`}{`    `}{`<`}{`frameWidth`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`800`}{`{`frameWidth`}{`>`}{`\n`}{`    `}{`<`}{`frameHeight`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`640`}{`{`frameHeight`}{`>`}{`\n`}{`    `}{`<`}{`delay`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`delay`}{`>`}{`\n`}{`    `}{`<`}{`angle`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`angle`}{`>`}{`\n`}{`  `}{`{`IPCamera`}{`>`}{`\n`}{`{`captures`}{`>`}
\n
{`URL`}
\n

{`To use your IP camera, you should provide a valid RTSP (or MJPEG) URL. The machinery will take snapshots from this stream.`}

\n
{`Framewidth and -height`}
\n

{`You can set the resolution of the capture device, make sure the resolution you've defined is equal to the resolution you've defined in your IP-camera software.`}

\n
{`Delay`}
\n

{`You can provide a delay/interval (milliseconds) between two captures.`}

\n
{`Angle`}
\n

{`By defining an angle (degrees), you can rotate the images taken by the capture device. For example if you would mount the camera upside down, than you could enter the value 180 as the angle; this will flip the images.`}

\n

{`Condition`}

\n

{`The condition is the first step of the four passway. In this step the machinery will determine if it's allowed to proceed to the next step. For example a condition can be a time constraint, a brightness threshold, etc; multiple conditions can be selected.`}

\n
{`{`xml`}{` version`}{`=`}{`\"1.0\"`}{`?>`}{`\n`}{`<`}{`kerberos`}{`>`}{`\n`}{`  `}{`<`}{`instance`}{`>`}{`\n`}{`    ...`}{`\n`}{`    `}{`<`}{`condition`}{` `}{`file`}{`=`}{`\"condition.xml\"`}{` `}{`type`}{`=`}{`\"multiple\"`}{`>`}{`Enabled`}{`{`condition`}{`>`}{`\n`}{`    ...`}{`\n`}{`  `}{`{`instance`}{`>`}{`\n`}{`{`kerberos`}{`>`}
\n

{`Enabled`}

\n

{`It can be helpful to enable or disable the machinery at specific times. Therefore the time condition makes it possible to select a time range for each day of the week. When the current time is within the time range, the machinery will be enabled.`}

\n

{`Parameters`}

\n

{`The parameters of the Enabled condition can be found in the `}{`config/condition.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`conditions`}{`>`}{`\n`}{`  `}{`<`}{`Enabled`}{`>`}{`\n`}{`    `}{`<`}{`active`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`true`}{`{`active`}{`>`}{`\n`}{`    `}{`<`}{`delay`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`5000`}{`{`delay`}{`>`}{`\n`}{`  `}{`{`Enabled`}{`>`}{`\n`}{`{`conditions`}{`>`}
\n
{`Active`}
\n

{`The active field is boolean value (true/false). When the active field is true, the machinery is enabled, if not it's disabled.`}

\n
{`Delay`}
\n

{`The delay value is used when the condition failed, so when the current time isn't in the selected time range for that day. In that case the machinery will idle for the specified delay time. The value of the delay is expressed in miliseconds.`}

\n

{`Time`}

\n

{`It can be helpful to enable or disable the machinery at specific times. Therefore the time condition makes it possible to select a time range for each day of the week. When the current time is within the time range, the machinery will be enabled.`}

\n

{`Parameters`}

\n

{`The parameters of the Time condition can be found in the `}{`config/condition.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`conditions`}{`>`}{`\n`}{`  `}{`<`}{`Time`}{`>`}{`\n`}{`    `}{`<`}{`times`}{` `}{`type`}{`=`}{`\"timeselection\"`}{`>`}{`13:00,15:00-0:01,20:58-0:01,20:59-0:01,19:20-0:01,21:59-0,0-0,0`}{`{`times`}{`>`}{`\n`}{`    `}{`<`}{`delay`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`10000`}{`{`delay`}{`>`}{`\n`}{`  `}{`{`Time`}{`>`}{`\n`}{`{`conditions`}{`>`}
\n
{`Times`}
\n

{`The times property contains a list of times, delimited by a \"-\". The first item in the list will specify the time range for the first day of the week (Monday), the last item for the last day of the week (Sunday). The begin- and end-time, for a specific day, are delimited by a \",\" where the first element will specify that start time and the second one specifies the end time.`}

\n
{`Delay`}
\n

{`The delay value is used when the condition failed, so when the current time isn't in the selected time range for that day. In that case the machinery will idle for the specified delay time. The value of the delay is expressed in miliseconds.`}

\n

{`Algorithm`}

\n

{`The algorithm is the second step of the four passway. An algorithm will execute some kind of function on a sequence of images, and end up with a black and white image; just like the image below. An example of an algorithm would be one that does motion detection or one that would detect cats or dogs (using TensorFlow, ar any other Deep Learning framework).`}

\n

\"machinery

\n

{`The white pixels on the image will indicate the object of interest. For example, when looking for motion, the pixels that have been changed; it depends on what the algorithm is looking for. The black pixels are background pixels.`}

\n

{`The only convention that an algorithm should meet is that it should return a black and white image to the next step; the expositor. And of course that it requires a sequence of images as a parameter. Besides those conventions, an algorithm can do everything it wants to do. So you could create your own cat detection algorithm, marker detection, etc.`}

\n

{`You can select the algortihm in the `}{`config/config.xml`}{`.`}

\n
{`{`xml`}{` version`}{`=`}{`\"1.0\"`}{`?>`}{`\n`}{`<`}{`kerberos`}{`>`}{`\n`}{`  `}{`<`}{`instance`}{`>`}{`\n`}{`    ...`}{`\n`}{`    `}{`<`}{`algorithm`}{` `}{`file`}{`=`}{`\"algorithm.xml\"`}{`>`}{`DifferentialCollins`}{`{`algorithm`}{`>`}{`\n`}{`    ...`}{`\n`}{`  `}{`{`instance`}{`>`}{`\n`}{`{`kerberos`}{`>`}
\n

{`Differential images`}

\n

{`This algorithm is a very simple method to detect motion; in terms of understanding but also processing. Just like the name says, it's the result of comparing images. When the images are compared, we know the pixels that have been changed and if the amount of pixels that changed is big enough, one can say that something happened and thus motion was detected.`}

\n

{`To get a more technical explanation: the algoritm will substract 2 or more images, and once that is done it will end up with a black and white image. The white pixels will mark the pixels that where different/changed and the black pixels are the pixels that have not changed; background pixels. Please note that there are several different combinations of substracting images. However for the machinery, we will use the method of Collins et al. as this method erases the phenomenon \"ghosting\".`}

\n

\"machinery

\n

{`In the image above the method of Collins et al. is illustrated. For this method we will process three images. The images are a sequence (from left to right), so the first (A) image was taken before the second (B) one, and the second (B) before the third (C) one. Next we will do a first comparision (C-B) of the third (C) image and the second (B) image, and after that we will do a second comparison (C-A) of the third (C) image and first (A) image.`}

\n

{`After the comparison we will end up with two difference images (C-B) and (C-A); both will mark the white pixels as changed pixels and black as non-changed pixels. To finish the algorithm we will do a logical AND-operation of the two difference images; this will give us the final black and white image ((C-B)&&(C-A)).`}

\n

{`The main idea of the Colins et al. method, is that it will erase \"ghosting\". In the last step we are doing a logical AND-operation, by doing this we will only keep the pixels, that changed in the first two images; therefore we can elimante false positives.`}

\n

{`Parameters`}

\n

{`The parameters of the Differential images algorithm can be found in the config/algorithm.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`algorithms`}{`>`}{`\n`}{`  `}{`<`}{`DifferentialCollins`}{`>`}{`\n`}{`    `}{`<`}{`erode`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`5`}{`{`erode`}{`>`}{`\n`}{`    `}{`<`}{`threshold`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`20`}{`{`threshold`}{`>`}{`\n`}{`  `}{`{`DifferentialCollins`}{`>`}{`\n`}{`{`algorithms`}{`>`}
\n
{`Erode`}
\n

{`The erode parameter represents a structural element (a morphological operation), which will be used to minimize the changed pixels; more information about eroding can be found here. The idea of the eroding is that pixels which are isolated will be removed; this means that when only one pixel changed, that pixel will reverted to the non-changed state. But for example when a large change happens and a lot of adjacent pixels are changed, the eroding will not be able to revert them.`}

\n

{`The higher the number of the erode parameter, the more aggressive the eroding will be. So high erode values, will make it possible that also large changes will be reverted to the non-changed state.`}

\n
{`Threshold`}
\n

{`When doing the comparison of two images, we won't end up with a clean black and white image. In most of the cases the values will be between 0 and 255; so gray values. This means that the value 0 will mean that both pixels where the same in both image, and values 255 mean that both pixels where totally different in both images. Of course we will also have values between 0-255, so pixels that are a little bit different in both images. So to make the resulting black and white image, we will need to apply a threshold value.`}

\n

{`The threshold will specify how much a pixel has to be different in the two images. So for example when the threshold is 30, it means that the difference between two pixels has to be equal or more then 30. The higher the threshold the more the pixel needs to be different, to be marked as changed.`}

\n

{`Expositor`}

\n

{`After the algorithm is executed, the expositor will determine, a region, where the changes were detected. An expositor can constrain a region in terms of selecting a hull or defining a rectangle.`}

\n

{`An expositor receives a black and white image as parameter and should modify a JSON object with all the information it processed. The JSON object must include: the bounding rectangle(s) of the positions where the pixels of interest are located and the number of pixels of interest. But can also include other optional parameters.`}

\n

{`You can change the expositor by changing the `}{`config/config.xml`}{` file, and choose one of the following:`}

\n
    \n
  • {`Hull`}
  • \n
  • {`Rectangle`}
  • \n
\n
{`{`xml`}{` version`}{`=`}{`\"1.0\"`}{`?>`}{`\n`}{`<`}{`kerberos`}{`>`}{`\n`}{`  `}{`<`}{`instance`}{`>`}{`\n`}{`    ...`}{`\n`}{`    `}{`<`}{`expositor`}{` `}{`file`}{`=`}{`\"expositor.xml\"`}{`>`}{`Hull`}{`{`expositor`}{`>`}{`\n`}{`    ...`}{`\n`}{`  `}{`{`instance`}{`>`}{`\n`}{`{`kerberos`}{`>`}
\n

{`Rectangle`}

\n

{`This is a trivial expositor. A rectangle region can be defined to constrain the locations of pixels of interest. The rectangle repositor will return the region of the pixels of interest.`}

\n

{`Parameters`}

\n

{`The parameters of the rectangle expositor can be found in the config/expositor.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`expositors`}{`>`}{`\n`}{`  `}{`<`}{`Rectangle`}{`>`}{`\n`}{`    `}{`<`}{`region`}{`>`}{`\n`}{`      `}{`<`}{`x1`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`x1`}{`>`}{`\n`}{`      `}{`<`}{`y1`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`y1`}{`>`}{`\n`}{`      `}{`<`}{`x2`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`1280`}{`{`x2`}{`>`}{`\n`}{`      `}{`<`}{`y2`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`720`}{`{`y2`}{`>`}{`\n`}{`    `}{`{`region`}{`>`}{`\n`}{`  `}{`{`Rectangle`}{`>`}{`\n`}{`{`expositors`}{`>`}
\n
{`Region`}
\n

{`The region parameter contains 4 values; x1, y1, x2 and y2 respectively. The values x1 and y1 indicate the x- and y-coordinate of the left upper starting point. The values x2 and y2 are the bottom right coordinates. A virtual rectangle will be drawn from (x1,y1) to (x2,y2). Pixels of interest that lie within this rectangle are valid pixels; if not they are invalid.`}

\n

{`Hull`}

\n

{`This hull is a more complex expositor than the rectangle. A hull can be selected with the web, you can select one or more coordinates to create a flexible region. The coordinates can be adjusted afterwards and be removed by double clicking on the coordinate. You can expand the hull by removing the start coordinate, which is marked by the white bullet.`}

\n

\"machinery

\n

{`Parameters`}

\n

{`The parameters of the hull expositor can be found in the config/expositor.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`expositors`}{`>`}{`\n`}{`  `}{`<`}{`Hull`}{`>`}{`\n`}{`    `}{`<`}{`region`}{` `}{`type`}{`=`}{`\"hullselection\"`}{`>`}{`347,361|627,266|975,328|1091,328|1148,413|1158,516|1121,534|962,567|699,648|531,700|243,613|423,550|665,453|850,470|666,361|467,385|325,460|165,372`}{`{`region`}{`>`}{`\n`}{`  `}{`{`Hull`}{`>`}{`\n`}{`{`expositors`}{`>`}
\n
{`Region`}
\n

{`The region parameter contains n values. Each value represents a coordinate (x,y) and are seperated by the \"|\" delimiter. These coordinates are used to calculate the concave hull. Pixels of interest that lie within the concave hull are valid pixels; if not they are invalid.`}

\n

{`Heuristic`}

\n

{`The heuristic is the last step in the four passway which will decide if the detection is valid or not. It will do this by using information from the previous steps (the expositor and the algorithm); e.g. number of changed pixels.`}

\n

{`You can change the heuristic by changing the `}{`config/config.xml`}{` file, and choose one of the following:`}

\n
    \n
  • {`Sequence`}
  • \n
\n
{`{`xml`}{` version`}{`=`}{`\"1.0\"`}{`?>`}{`\n`}{`<`}{`kerberos`}{`>`}{`\n`}{`  `}{`<`}{`instance`}{`>`}{`\n`}{`    ...`}{`\n`}{`    `}{`<`}{`heuristic`}{` `}{`file`}{`=`}{`\"heuristic.xml\"`}{`>`}{`Sequence`}{`{`heuristic`}{`>`}{`\n`}{`    ...`}{`\n`}{`  `}{`{`instance`}{`>`}{`\n`}{`{`kerberos`}{`>`}
\n

{`Sequence`}

\n

{`This is a trivial heuristic. The sequence heuristic will store a single integer in memory, that will count the numbers of valid detections. When the heuristic will detect a false detection, it will decrease the count. The sequence heuristic will return true, if a threshold is reached; for example when something was detected three times in a row.`}

\n

{`Parameters`}

\n

{`The parameters of the Sequence heuristic can be found in the config/heuristic.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`heuristics`}{`>`}{`\n`}{`<`}{`Sequence`}{`>`}{`\n`}{`    `}{`<`}{`minimumChanges`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`1`}{`{`minimumChanges`}{`>`}{`\n`}{`    `}{`<`}{`minimumDuration`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`1`}{`{`minimumDuration`}{`>`}{`\n`}{`    `}{`<`}{`noMotionDelayTime`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`2000`}{`{`noMotionDelayTime`}{`>`}{`\n`}{`  `}{`{`Sequence`}{`>`}{`\n`}{`{`heuristics`}{`>`}
\n
{`Minimum changes`}
\n

{`The heuristic will only return true if enough changes have been detected. The minimum of changes indicates the minimum number of pixels that have to been changed, to be a valid detection.`}

\n
{`Minimum durations`}
\n

{`The minimum number of detections in a row to be a valid detection.`}

\n
{`No motion delay time`}
\n

{`When the heuristic failed, due to not enough pixels changed or not x detections in a row, the heuristic will idle for some time.`}

\n

{`Output`}

\n

{`If the heuristic determined that the evaluation was valid, one or more output operations can be executed. You configure which ooutput operations that will be executed, by modifying the configuration file or using the web interface.`}

\n
{`{`xml`}{` version`}{`=`}{`\"1.0\"`}{`?>`}{`\n`}{`<`}{`kerberos`}{`>`}{`\n`}{`  `}{`<`}{`instance`}{`>`}{`\n`}{`    ...`}{`\n`}{`    `}{`<`}{`io`}{` `}{`file`}{`=`}{`\"io.xml\"`}{` `}{`type`}{`=`}{`\"multiple\"`}{`>`}{`Video`}{`{`io`}{`>`}{`\n`}{`    ...`}{`\n`}{`  `}{`{`instance`}{`>`}{`\n`}{`{`kerberos`}{`>`}
\n

{`You can choose which output devices you will be using. If you select multiple outputs, seperate them with an `}{`,`}{`. You can change the output device by changing the `}{`config/config.xml`}{` file, and choose one of the following:`}

\n
    \n
  • {`Disk`}
  • \n
  • {`Video`}
  • \n
  • {`GPIO`}
  • \n
  • {`TCPSocket`}
  • \n
  • {`Webhook`}
  • \n
  • {`MQTT`}
  • \n
  • {`Script`}
  • \n
\n

{`Disk`}

\n

{`An image can be saved to disk.`}

\n

{`Parameters`}

\n

{`The parameters of the Disk output device can be found in the `}{`config/io.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`ios`}{`>`}{`\n`}{`  `}{`<`}{`Disk`}{`>`}{`\n`}{`    `}{`<`}{`fileFormat`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`timestamp_microseconds_instanceName_regionCoordinates_numberOfChanges_token.jpg`}{`{`fileFormat`}{`>`}{`\n`}{`    `}{`<`}{`directory`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`/etc/opt/kerberosio/capture/`}{`{`directory`}{`>`}{`\n`}{`    `}{`<`}{`markWithTimestamp`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`false`}{`{`markWithTimestamp`}{`>`}{`\n`}{`    `}{`<`}{`timestampColor`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`white`}{`{`timestampColor`}{`>`}{`\n`}{`    `}{`<`}{`privacy`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`false`}{`{`privacy`}{`>`}{`\n`}{`    `}{`<`}{`throttler`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`throttler`}{`>`}{`\n`}{`  `}{`{`Disk`}{`>`}{`\n`}{`{`ios`}{`>`}
\n
{`File format`}
\n

{`The format that will be used for the name of the image. One or more variables can be defined and will be replaced by the machinery. Note that when you're using a variables name in the file format, that this name should be defined in the JSON object.`}

\n
{`Directory`}
\n

{`The directory where the image will be saved to. By default images are saved to the /etc/opt/kerberosio/capture directory.`}

\n
{`Mark with timestamp`}
\n

{`When this settings is set to true, the image is marked with a timestamp.`}

\n
{`Timestamp color`}
\n

{`A color can be defined for timestamp: white, black, red, green and blue.`}

\n
{`Privacy`}
\n

{`The privacy mode can be activated to remove some parts from the image. This especially helpful if you want to filter out public areas. When this option is enabled you will seee that after configuring the Hull expositor, you'll see that the pixels outside your region of interest (Hull) are made black.`}

\n
{`Throttler`}
\n

{`Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Disk will only be triggered once in 5 seconds, nevertheless more detections occurred.`}

\n

{`Video`}

\n

{`When a valid event is detected, a video will be recorded for x seconds. When more valid events are detected, while a video is recording, the video file will further record for x seconds; so no new video file be recorded, but the existing one will be expanded.`}

\n

{`Parameters`}

\n

{`The parameters of the Video output device can be found in the `}{`config/io.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`ios`}{`>`}{`\n`}{`  `}{`<`}{`Video`}{`>`}{`\n`}{`    `}{`<`}{`fps`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`3`}{`{`fps`}{`>`}{`\n`}{`    `}{`<`}{`recordAfter`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`5`}{`{`recordAfter`}{`>`}{`\n`}{`    `}{`<`}{`maxDuration`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`120`}{`{`maxDuration`}{`>`}{`\n`}{`    `}{`<`}{`extension`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`mp4`}{`{`extension`}{`>`}{`\n`}{`    `}{`<`}{`codec`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`h264`}{`{`codec`}{`>`}{`\n`}{`    `}{`<`}{`fileFormat`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`timestamp_microseconds_instanceName_regionCoordinates_numberOfChanges_token`}{`{`fileFormat`}{`>`}{`\n`}{`    `}{`<`}{`directory`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`/etc/opt/kerberosio/capture/`}{`{`directory`}{`>`}{`\n`}{`    `}{`<`}{`hardwareDirectory`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`/etc/opt/kerberosio/h264/`}{`{`hardwareDirectory`}{`>`}{`\n`}{`    `}{`<`}{`enableHardwareEncoding`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`true`}{`{`enableHardwareEncoding`}{`>`}{`\n`}{`    `}{`<`}{`markWithTimestamp`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`false`}{`{`markWithTimestamp`}{`>`}{`\n`}{`    `}{`<`}{`timestampColor`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`white`}{`{`timestampColor`}{`>`}{`\n`}{`    `}{`<`}{`privacy`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`false`}{`{`privacy`}{`>`}{`\n`}{`    `}{`<`}{`throttler`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`throttler`}{`>`}{`\n`}{`  `}{`{`Video`}{`>`}{`\n`}{`{`ios`}{`>`}
\n
{`FPS`}
\n

{`The frames per second of the video being recorded. Please note that this number is limited and depends heavily on your hardware setup. You'll be receiving following warning in the systems logs, if the machinery can't write the desired FPS.`}

\n
{`[trivial] IoVideo: framerate is too fast, can't record video at this speed (8/FPS)`}
\n
{`Record after`}
\n

{`The number of seconds recorded after the last valid event was detected. This means that when a video is already recording, and a valid event was detected, the video will be expanded with x more seconds.`}

\n
{`Extensions`}
\n

{`The extension or container of the video file. We highly recommend to use the MP4 container if you want cross-browser support. Leave this setting by default, if you don't know what you're doing.`}

\n
{`Codec`}
\n

{`The codec that is used to encode the video file.`}

\n
{`File format`}
\n

{`The format that will be used for the name of the image. One or more variables can be defined and will be replaced by the machinery. Note that when you're using a variables name in the file format, that this name should be defined in the JSON object.`}

\n
{`Directory`}
\n

{`The directory where the videos will be saved. By default videos are saved to the /etc/opt/kerberosio/capture directory.`}

\n
{`Hardware directory`}
\n

{`When using onboard hardware encoding (e.g. with Raspberry Pi camera), h264 video files are generated and stored in this directory. Afterwards these h264 files will be containerized to mp4 files, and stored in the Directory path.`}

\n
{`Enable Hardware encoding`}
\n

{`A boolean which can enable or disable hardware encoding. Please note that this option is enabled by default, but does not mean that it will work if you choose to use an USB camera.`}

\n
{`Mark with timestamp`}
\n

{`When this settings is set to true, the video is marked with a timestamp (similar to the Disk device).`}

\n
{`Timestamp color`}
\n

{`A color can be defined for timestamp: white, black, red, green and blue.`}

\n
{`Privacy`}
\n

{`The privacy mode can be activated to remove some parts from the video. This especially helpful if you want to filter out public areas.`}

\n
{`Video privacy`}
\n

{`After updating the configuration, you'll see that the pixels outside your region of interest (ROI) are made black; the image below illustrates this.`}

\n
{`Throttler`}
\n

{`Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Video will only be triggered once in 5 seconds, nevertheless more detections occurred.`}

\n

{`TCP/IP client`}

\n

{`The TCP/IP client will send a TCP packet to a server.`}

\n

{`Parameters`}

\n

{`The parameters of the TCP/IP client can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`ios`}{`>`}{`\n`}{`  `}{`<`}{`TCPSocket`}{`>`}{`\n`}{`    `}{`<`}{`server`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`127.0.0.1`}{`{`server`}{`>`}{`\n`}{`    `}{`<`}{`port`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`1337`}{`{`port`}{`>`}{`\n`}{`    `}{`<`}{`message`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`it's so fluffy`}{`{`message`}{`>`}{`\n`}{`    `}{`<`}{`throttler`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`throttler`}{`>`}{`\n`}{`  `}{`{`TCPSocket`}{`>`}{`\n`}{`{`ios`}{`>`}
\n
{`Server`}
\n

{`The IP of the TCP server.`}

\n
{`Port`}
\n

{`This is the port of the TCP server.`}

\n
{`Message`}
\n

{`You can send some data to a TCP server.`}

\n
{`Throttler`}
\n

{`Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the TCP will only be triggered once in 5 seconds, nevertheless more detections occurred.`}

\n

{`GPIO`}

\n

{`A GPIO pin can be set as output device.`}

\n

{`Parameters`}

\n

{`The parameters of the GPIO pin can be found in the `}{`config/io.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`ios`}{`>`}{`\n`}{`  `}{`<`}{`GPIO`}{`>`}{`\n`}{`    `}{`<`}{`pin`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`17`}{`{`pin`}{`>`}{`\n`}{`    `}{`<`}{`periods`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`5`}{`{`periods`}{`>`}{`\n`}{`    `}{`<`}{`periodTime`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`100000`}{`{`periodTime`}{`>`}{`\n`}{`    `}{`<`}{`throttler`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`throttler`}{`>`}{`\n`}{`  `}{`{`GPIO`}{`>`}{`\n`}{`{`ios`}{`>`}
\n
{`Pin`}
\n

{`The pin that will be triggered.`}

\n
{`Periods`}
\n

{`The number of times the pin will be triggered.`}

\n
{`Period time`}
\n

{`The time in microseconds that the pin will be set high.`}

\n
{`Throttler`}
\n

{`Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the GPIO will only be triggered once in 5 seconds, nevertheless more detections occurred.`}

\n

{`Webhook`}

\n

{`Detailed information (a JSON object) is send as a POST request to a webhook. The JSON object contains the number of changes, the region, the URL of the image, etc. This is useful if you want to integrate with your own application.`}

\n

{`Make sure that the Webhook comes after the Disk device, otherwise the URL of the image is not included.`}

\n

{`Parameters`}

\n

{`The parameters of the webhook can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`ios`}{`>`}{`\n`}{`  `}{`<`}{`Webhook`}{`>`}{`\n`}{`    `}{`<`}{`url`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`http://kerberos.web/api/v1/webhook`}{`{`url`}{`>`}{`\n`}{`    `}{`<`}{`throttler`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`throttler`}{`>`}{`\n`}{`  `}{`{`Webhook`}{`>`}{`\n`}{`{`ios`}{`>`}
\n
{`Url`}
\n

{`This is the URL, to which the machinery will send a JSON object (as a POST request).`}

\n
{`Throttler`}
\n

{`Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Webhook will only be triggered once in 5 seconds, nevertheless more detections occurred.`}

\n
{`Output`}
\n

{`A JSON object is POSTed to the url you've defined.`}

\n
{`[`}{`\n`}{`  `}{`'regionCoordinates'`}{` `}{`:`}{` [`}{`618`}{`, `}{`317`}{`, `}{`703`}{`, `}{`493`}{`],`}{`\n`}{`  `}{`'numberOfChanges'`}{` `}{`:`}{` `}{`5446`}{`,`}{`\n`}{`  `}{`'timestamp'`}{` `}{`:`}{` `}{`'`}{`1465894497`}{`'`}{`,`}{`\n`}{`  `}{`'microseconds'`}{` `}{`:`}{` `}{`'`}{`5-97451`}{`'`}{`,`}{`\n`}{`  `}{`'token'`}{` `}{`:`}{` `}{`695`}{`,`}{`\n`}{`  `}{`'pathToImage'`}{` `}{`:`}{` `}{`'`}{`1465894497`}{`_`}{`5-97451`}{`_frontdoor_`}{`618-317-703-493`}{`_`}{`5446`}{`_`}{`695`}{`.jpg'`}{`,`}{`\n`}{`  `}{`'instanceName'`}{` `}{`:`}{` `}{`'frontdoor'`}{`,`}{`\n`}{`]`}
\n

{`Script`}

\n

{`A bash script can be executed after a valid event was detected. A JSON object is send in the first parameter to the script you've defined.`}

\n

{`Parameters`}

\n

{`The parameters of the Script output device can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`ios`}{`>`}{`\n`}{`  `}{`<`}{`Script`}{`>`}{`\n`}{`    `}{`<`}{`path`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`/etc/opt/kerberosio/scripts/run.sh`}{`{`path`}{`>`}{`\n`}{`    `}{`<`}{`throttler`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`throttler`}{`>`}{`\n`}{`  `}{`{`Script`}{`>`}{`\n`}{`{`ios`}{`>`}
\n
{`Path`}
\n

{`The location of the script that will be executed on detection.`}

\n
{`Throttler`}
\n

{`Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Script will only be triggered once in 5 seconds, nevertheless more detections occurred.`}

\n
{`Example`}
\n

{`By default the script will point to /etc/opt/kerberosio/scripts/run.sh, which contains a template how you should start your script. Note that when using KiOS, this script will be read-only, copy it to the /data folder and change the path parameter.`}

\n
{`#!/bin/bash`}{`\n`}{`# -------------------------------------------`}{`\n`}{`# This is an example script which illustrates`}{`\n`}{`# how to use the Script IO device.`}{`\n`}{`#`}{`\n`}{`# --------------------------------------`}{`\n`}{`# The first parameter is the JSON object`}{`\n`}{`#`}{`\n`}{`# e.g. {\"regionCoordinates\":[308,250,346,329],\"numberOfChanges\":194,\"timestamp\":\"1486049622\",\"microseconds\":\"6-161868\",\"token\":344,\"pathToImage\":\"1486049622_6-161868_frontdoor_308-250-346-329_194_344.jpg\",\"instanceName\":\"frontdoor\"}`}{`\n`}{`JSON=`}{`$`}{`1`}{`\n`}{`# -------------------------------------------`}{`\n`}{`# You can use python to parse the JSON object`}{`\n`}{`# and get the required fields`}{`\n`}{`name=`}{`$`}{`(echo `}{`$`}{`JSON | python -c `}{`\"import sys, json; print json.load(sys.stdin)['instanceName']\"`}{`)`}{`\n`}{`coordinates=`}{`$`}{`(echo `}{`$`}{`JSON | python -c `}{`\"import sys, json; print json.load(sys.stdin)['regionCoordinates']\"`}{`)`}{`\n`}{`changes=`}{`$`}{`(echo `}{`$`}{`JSON | pythfon -c `}{`\"import sys, json; print json.load(sys.stdin)['numberOfChanges']\"`}{`)`}{`\n`}{`image=`}{`$`}{`(echo `}{`$`}{`JSON | python -c `}{`\"import sys, json; print json.load(sys.stdin)['pathToImage']\"`}{`)`}{`\n`}{`The idea `}{`is`}{` that you can use Python `}{`in`}{` your bash script, to parse the JSON `}{`object`}{` send `}{`as`}{` first parameter. Afterwards you can do `}{`with`}{` the output what you want.`}
\n

{`MQTT`}

\n

{`MQTT protocol is a light-weight Machine to Machine (M2M) protocol widely used in Internet of things.\nDetailed information (a JSON object) is published to an MQTT topic. The JSON object contains the number of changes, the region, the URL of the image, etc.`}

\n

{`Parameters`}

\n

{`The parameters of the MQTT output can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`ios`}{`\n`}{`  {`>`}{`\n`}{`    `}{`<`}{`secure`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`false`}{`{`secure`}{`>`}{`\n`}{`    `}{`<`}{`verifycn`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`false`}{`{`verifycn`}{`>`}{`\n`}{`    `}{`<`}{`server`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`127.0.0.1`}{`{`server`}{`>`}{`\n`}{`    `}{`<`}{`port`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`1883`}{`{`port`}{`>`}{`\n`}{`    `}{`<`}{`topic`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`kios/mqtt`}{`{`topic`}{`>`}{`\n`}{`    `}{`<`}{`username`}{` `}{`type`}{`=`}{`\"text\"`}{`>{`username`}{`>`}{`\n`}{`    `}{`<`}{`password`}{` `}{`type`}{`=`}{`\"text\"`}{`>{`password`}{`>`}{`\n`}{`    `}{`<`}{`throttler`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`throttler`}{`>`}{`\n`}{`  `}{`{`MQTT`}{`>`}{`\n`}{`{`ios`}{`>`}
\n
{`Secure`}
\n

{`If checked, enable SSL/TLS support. Please note that when SSL/TLS support is enabled, the server certificate issuer is verified against the CA (Certification Authority) files available in /etc/ssl/certs.`}

\n
{`Verifycn`}
\n

{`If checked, the MQTT server FQDN or ip address must match the CN (Common Name) of the server certificate.`}

\n
{`Server`}
\n

{`IP address or FQDN of the MQTT broker.`}

\n
{`Port`}
\n

{`TCP port of the MQTT broker.`}

\n
{`Topic`}
\n

{`The topic to publish to.`}

\n
{`Username`}
\n

{`The username for authenticating to the MQTT broker. This is only supported by brokers that implement the MQTT spec v3.1. If username is not set (empty), the password argument is ignored. This is only needed if the MQTT broker is configured for authentication.`}

\n
{`Password`}
\n

{`The password to use, together with the username, for authenticating to the MQTT broker. This is only supported by brokers that implement the MQTT spec v3.1. This is only needed if the MQTT broker is configured for authentication.`}

\n
{`Throttler`}
\n

{`Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the MQTT will only be triggered once in 5 seconds, nevertheless more detections occurred.`}

\n
{`Output`}
\n

{`A JSON object is published to the topic of the MQTT broker you have configured.`}

\n
{`[`}{`\n`}{`  `}{`'regionCoordinates'`}{` `}{`:`}{` [`}{`618`}{`, `}{`317`}{`, `}{`703`}{`, `}{`493`}{`],`}{`\n`}{`  `}{`'numberOfChanges'`}{` `}{`:`}{` `}{`5446`}{`,`}{`\n`}{`  `}{`'timestamp'`}{` `}{`:`}{` `}{`'`}{`1465894497`}{`'`}{`,`}{`\n`}{`  `}{`'microseconds'`}{` `}{`:`}{` `}{`'`}{`5-97451`}{`'`}{`,`}{`\n`}{`  `}{`'token'`}{` `}{`:`}{` `}{`695`}{`,`}{`\n`}{`  `}{`'pathToImage'`}{` `}{`:`}{` `}{`'`}{`1465894497`}{`_`}{`5-97451`}{`_frontdoor_`}{`618-317-703-493`}{`_`}{`5446`}{`_`}{`695`}{`.jpg'`}{`,`}{`\n`}{`  `}{`'instanceName'`}{` `}{`:`}{` `}{`'frontdoor'`}{`,`}{`\n`}{`]`}
\n
{`Example`}
\n

{`It is possible to subscribe multiple distributed IoT devices to the same MQTT topic and perform specific actions upon the detection of a motion. Devices with more resources could fetch the image to perform further elaboration.`}

\n

{`Streaming`}

\n

{`The machinery has the ability to stream your capture device as a MJPG stream.`}

\n

{`Parameters`}

\n

{`The parameters for the supported streaming protocols can be found in the `}{`config/stream.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file; at the moment of writing only a MJPG stream is supported.`}

\n
{`<`}{`streams`}{`>`}{`\n`}{`\t`}{`<`}{`Mjpg`}{`>`}{`\n`}{`    \t`}{`<`}{`enabled`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`true`}{`{`enabled`}{`>`}{`\n`}{`    \t`}{`<`}{`streamPort`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`8889`}{`{`streamPort`}{`>`}{`\n`}{`    \t`}{`<`}{`quality`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`75`}{`{`quality`}{`>`}{`\n`}{`    \t`}{`<`}{`username`}{` `}{`type`}{`=`}{`\"number\"`}{`>{`username`}{`>`}{`\n`}{`    \t`}{`<`}{`password`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`75`}{`{`password`}{`>`}{`\n`}{`    `}{`{`Mjpg`}{`>`}{`\n`}{`{`streams`}{`>`}
\n

{`Enabled`}

\n

{`A boolean which turns ON/OFF the stream. This is interesting when working with IP cameras, where you already have an RTSP/MJPG stream from the camera itself.`}

\n

{`Stream Port`}

\n

{`The port on which the stream is available.`}

\n

{`Quality`}

\n

{`The quality is a value between `}{`[0-100]`}{`. The lower the quality, the more the image will be compressed. If you're using the RaspberryPi Camera module, this option will be ignored.`}

\n

{`Username/password`}

\n

{`You can secure the MJPEG streaming with a username and password. These credentials will be used to authorize your requests using Basic Authentication. Please note that once enabled, the live stream on the dashboard page can fail; however it will work if you open it directly in your browser or ip camera client. The format of the streaming url, after authentication enabled, will look as following:`}

\n
{`http:`}{`//username:password@ip-camera:8899`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file +{"expireTime":9007200841974267000,"key":"gatsby-plugin-mdx-entire-payload-a79531575b5a9e24fdd84c6824bcabed-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import { Playground, Props } from 'docz'","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":41,"offset":199},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":10,"column":3,"offset":203},"end":{"line":10,"column":12,"offset":212},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":201},"end":{"line":10,"column":12,"offset":212},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The machinery is the processing engine of Kerberos Open Source. It's an image processing framework, written in C++, who benefits from other third party libraries (OpenCV, etc). It takes images from the type of camera (USB-, IP- or RPi-camera) you've configured in the configuration files and executes one ore more algorithms and post-processes (e.g. save a snapshot). The configuration files allow you to define the type of camera, post-processes, conditions and much more; it's highly configurable. It's important to note that the machinery, out-of-the-box, can handle only one camera at a time.","position":{"start":{"line":12,"column":1,"offset":214},"end":{"line":12,"column":597,"offset":810},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":214},"end":{"line":12,"column":597,"offset":810},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Project structure","position":{"start":{"line":14,"column":4,"offset":815},"end":{"line":14,"column":21,"offset":832},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":812},"end":{"line":14,"column":21,"offset":832},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The machinery is an image processing framework which is devided into four steps:","position":{"start":{"line":16,"column":1,"offset":834},"end":{"line":16,"column":81,"offset":914},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":834},"end":{"line":16,"column":81,"offset":914},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"condition","position":{"start":{"line":18,"column":3,"offset":918},"end":{"line":18,"column":12,"offset":927},"indent":[]}}],"position":{"start":{"line":18,"column":3,"offset":918},"end":{"line":18,"column":12,"offset":927},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":916},"end":{"line":18,"column":12,"offset":927},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"algorithm","position":{"start":{"line":19,"column":3,"offset":930},"end":{"line":19,"column":12,"offset":939},"indent":[]}}],"position":{"start":{"line":19,"column":3,"offset":930},"end":{"line":19,"column":12,"offset":939},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":928},"end":{"line":19,"column":12,"offset":939},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"expositor","position":{"start":{"line":20,"column":3,"offset":942},"end":{"line":20,"column":12,"offset":951},"indent":[]}}],"position":{"start":{"line":20,"column":3,"offset":942},"end":{"line":20,"column":12,"offset":951},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":940},"end":{"line":20,"column":12,"offset":951},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"heuristic","position":{"start":{"line":21,"column":3,"offset":954},"end":{"line":21,"column":12,"offset":963},"indent":[]}}],"position":{"start":{"line":21,"column":3,"offset":954},"end":{"line":21,"column":12,"offset":963},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":952},"end":{"line":21,"column":12,"offset":963},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":916},"end":{"line":21,"column":12,"offset":963},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"The steps belong to a four passway; illustrated on the image below. In each cycle a sequence of images is processed. Each step will process the sequence, and will return some result to the next step. For example: an algorithm will process the images and returns an array to the Expositor, which contains boolean values. The steps are loosly coupled, so they have simple conventions, just like the example before.","position":{"start":{"line":23,"column":1,"offset":965},"end":{"line":23,"column":413,"offset":1377},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":965},"end":{"line":23,"column":413,"offset":1377},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Thanks to the loosly coupling, each step can be developed indepently. So algorithms, expositors, heuristics and conditions can be switched on the fly. This makes it easier for other developers who want to contribute to the machinery. They can create a new algorithm without knowing how a specific expositor or heuristic works. They just need to be aware of the convention an algorithm should meet.","position":{"start":{"line":25,"column":1,"offset":1379},"end":{"line":25,"column":398,"offset":1776},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1379},"end":{"line":25,"column":398,"offset":1776},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/machinery/project_structure.png","alt":"machinery project structure","position":{"start":{"line":27,"column":1,"offset":1778},"end":{"line":27,"column":84,"offset":1861},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1778},"end":{"line":27,"column":84,"offset":1861},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"These different steps can be configured by editing a couple of configurationn files located at ","position":{"start":{"line":29,"column":1,"offset":1863},"end":{"line":29,"column":96,"offset":1958},"indent":[]}},{"type":"inlineCode","value":"config/","position":{"start":{"line":29,"column":96,"offset":1958},"end":{"line":29,"column":105,"offset":1967},"indent":[]}},{"type":"text","value":". The main configuration file ","position":{"start":{"line":29,"column":105,"offset":1967},"end":{"line":29,"column":135,"offset":1997},"indent":[]}},{"type":"inlineCode","value":"config/config.xml","position":{"start":{"line":29,"column":135,"offset":1997},"end":{"line":29,"column":154,"offset":2016},"indent":[]}},{"type":"text","value":" looks like this:","position":{"start":{"line":29,"column":154,"offset":2016},"end":{"line":29,"column":171,"offset":2033},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1863},"end":{"line":29,"column":171,"offset":2033},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n \n frontdoor\n false\n Europe-Brussels\n RaspiCamera\n Mjpg\n Enabled\n DifferentialCollins\n Hull\n Sequence\n Video\n S3\n \n","position":{"start":{"line":31,"column":1,"offset":2035},"end":{"line":48,"column":4,"offset":2690},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Capture","position":{"start":{"line":50,"column":4,"offset":2695},"end":{"line":50,"column":11,"offset":2702},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":2692},"end":{"line":50,"column":11,"offset":2702},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can choose which capture device you will be using, you can use your old USB webcam, the popular Raspberry Pi camera or a state-of-the-art IP camera. The capture device will take pictures and deliver them to the algorithm if the conditions (the first step of the four passway) are valid.","position":{"start":{"line":52,"column":1,"offset":2704},"end":{"line":52,"column":291,"offset":2994},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2704},"end":{"line":52,"column":291,"offset":2994},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can change the capture device by changing the ","position":{"start":{"line":54,"column":1,"offset":2996},"end":{"line":54,"column":51,"offset":3046},"indent":[]}},{"type":"inlineCode","value":"config/config.xml","position":{"start":{"line":54,"column":51,"offset":3046},"end":{"line":54,"column":70,"offset":3065},"indent":[]}},{"type":"text","value":" file, and choose one of the following:","position":{"start":{"line":54,"column":70,"offset":3065},"end":{"line":54,"column":109,"offset":3104},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2996},"end":{"line":54,"column":109,"offset":3104},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"USBCamera","position":{"start":{"line":55,"column":3,"offset":3107},"end":{"line":55,"column":12,"offset":3116},"indent":[]}}],"position":{"start":{"line":55,"column":3,"offset":3107},"end":{"line":55,"column":12,"offset":3116},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":3105},"end":{"line":55,"column":12,"offset":3116},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"RaspiCamera","position":{"start":{"line":56,"column":3,"offset":3119},"end":{"line":56,"column":14,"offset":3130},"indent":[]}}],"position":{"start":{"line":56,"column":3,"offset":3119},"end":{"line":56,"column":14,"offset":3130},"indent":[]}}],"position":{"start":{"line":56,"column":1,"offset":3117},"end":{"line":56,"column":14,"offset":3130},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"IPCamera","position":{"start":{"line":57,"column":3,"offset":3133},"end":{"line":57,"column":11,"offset":3141},"indent":[]}}],"position":{"start":{"line":57,"column":3,"offset":3133},"end":{"line":57,"column":11,"offset":3141},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":3131},"end":{"line":57,"column":11,"offset":3141},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":3105},"end":{"line":57,"column":11,"offset":3141},"indent":[1,1]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n \n ...\n RaspiCamera\n ...\n \n","position":{"start":{"line":59,"column":1,"offset":3143},"end":{"line":68,"column":4,"offset":3295},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"USB camera","position":{"start":{"line":70,"column":5,"offset":3301},"end":{"line":70,"column":15,"offset":3311},"indent":[]}}],"position":{"start":{"line":70,"column":1,"offset":3297},"end":{"line":70,"column":15,"offset":3311},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The machinery supports a whole range of USB cameras. You will find a complete list here. Make sure you have updated the web interface, to make the machinery aware you will be using an USB camera.","position":{"start":{"line":72,"column":1,"offset":3313},"end":{"line":72,"column":196,"offset":3508},"indent":[]}}],"position":{"start":{"line":72,"column":1,"offset":3313},"end":{"line":72,"column":196,"offset":3508},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":74,"column":6,"offset":3515},"end":{"line":74,"column":16,"offset":3525},"indent":[]}}],"position":{"start":{"line":74,"column":1,"offset":3510},"end":{"line":74,"column":16,"offset":3525},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the USB camera can be found in the ","position":{"start":{"line":76,"column":1,"offset":3527},"end":{"line":76,"column":54,"offset":3580},"indent":[]}},{"type":"inlineCode","value":"config/capture.xml","position":{"start":{"line":76,"column":54,"offset":3580},"end":{"line":76,"column":74,"offset":3600},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":76,"column":74,"offset":3600},"end":{"line":76,"column":179,"offset":3705},"indent":[]}}],"position":{"start":{"line":76,"column":1,"offset":3527},"end":{"line":76,"column":179,"offset":3705},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n 1280\n 720\n 0\n 0\n 0\n \n","position":{"start":{"line":78,"column":1,"offset":3707},"end":{"line":88,"column":4,"offset":3985},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Framewidth and -height","position":{"start":{"line":90,"column":7,"offset":3993},"end":{"line":90,"column":29,"offset":4015},"indent":[]}}],"position":{"start":{"line":90,"column":1,"offset":3987},"end":{"line":90,"column":29,"offset":4015},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can set the resolution of the capture device, make sure the resolution you've defined is valid with your camera. Please check the specs of the USB camera you're using.","position":{"start":{"line":92,"column":1,"offset":4017},"end":{"line":92,"column":172,"offset":4188},"indent":[]}}],"position":{"start":{"line":92,"column":1,"offset":4017},"end":{"line":92,"column":172,"offset":4188},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Device number","position":{"start":{"line":94,"column":7,"offset":4196},"end":{"line":94,"column":20,"offset":4209},"indent":[]}}],"position":{"start":{"line":94,"column":1,"offset":4190},"end":{"line":94,"column":20,"offset":4209},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If more than one device is connected, you can specify the index of the USB-camera. The index is an integer (1-5).","position":{"start":{"line":96,"column":1,"offset":4211},"end":{"line":96,"column":114,"offset":4324},"indent":[]}}],"position":{"start":{"line":96,"column":1,"offset":4211},"end":{"line":96,"column":114,"offset":4324},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Delay","position":{"start":{"line":98,"column":7,"offset":4332},"end":{"line":98,"column":12,"offset":4337},"indent":[]}}],"position":{"start":{"line":98,"column":1,"offset":4326},"end":{"line":98,"column":12,"offset":4337},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can provide a delay/interval (milliseconds) between two captures.","position":{"start":{"line":100,"column":1,"offset":4339},"end":{"line":100,"column":70,"offset":4408},"indent":[]}}],"position":{"start":{"line":100,"column":1,"offset":4339},"end":{"line":100,"column":70,"offset":4408},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Angle","position":{"start":{"line":102,"column":7,"offset":4416},"end":{"line":102,"column":12,"offset":4421},"indent":[]}}],"position":{"start":{"line":102,"column":1,"offset":4410},"end":{"line":102,"column":12,"offset":4421},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By defining an angle (degrees), you can rotate the images taken by the capture device. For example if you would mount the camera upside down, than you could enter the value 180 as the angle; this will flip the images.","position":{"start":{"line":104,"column":1,"offset":4423},"end":{"line":104,"column":218,"offset":4640},"indent":[]}}],"position":{"start":{"line":104,"column":1,"offset":4423},"end":{"line":104,"column":218,"offset":4640},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Raspberry Pi Camera Module","position":{"start":{"line":106,"column":5,"offset":4646},"end":{"line":106,"column":31,"offset":4672},"indent":[]}}],"position":{"start":{"line":106,"column":1,"offset":4642},"end":{"line":106,"column":31,"offset":4672},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can use the Raspberry Pi Camera Module with the machinery. You just need to attach the camera module and you're ready to go. The Raspberry Pi Camera Module is enabled by default in the web.","position":{"start":{"line":108,"column":1,"offset":4674},"end":{"line":108,"column":194,"offset":4867},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":4674},"end":{"line":108,"column":194,"offset":4867},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":110,"column":6,"offset":4874},"end":{"line":110,"column":16,"offset":4884},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4869},"end":{"line":110,"column":16,"offset":4884},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Raspberry Pi Camera Module can be found in the config/capture.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":112,"column":1,"offset":4886},"end":{"line":112,"column":193,"offset":5078},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":4886},"end":{"line":112,"column":193,"offset":5078},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n 640\n 480\n 1400\n 0\n 30\n 0\n 0\n 0\n 50\n \n","position":{"start":{"line":114,"column":1,"offset":5080},"end":{"line":128,"column":4,"offset":5534},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Framewidth and -height","position":{"start":{"line":130,"column":7,"offset":5542},"end":{"line":130,"column":29,"offset":5564},"indent":[]}}],"position":{"start":{"line":130,"column":1,"offset":5536},"end":{"line":130,"column":29,"offset":5564},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can set the resolution of the camera module, make sure the resolution you've defined is valid.","position":{"start":{"line":132,"column":1,"offset":5566},"end":{"line":132,"column":99,"offset":5664},"indent":[]}}],"position":{"start":{"line":132,"column":1,"offset":5566},"end":{"line":132,"column":99,"offset":5664},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Delay","position":{"start":{"line":134,"column":7,"offset":5672},"end":{"line":134,"column":12,"offset":5677},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5666},"end":{"line":134,"column":12,"offset":5677},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can provide a delay/interval (milliseconds) between two captures.","position":{"start":{"line":136,"column":1,"offset":5679},"end":{"line":136,"column":70,"offset":5748},"indent":[]}}],"position":{"start":{"line":136,"column":1,"offset":5679},"end":{"line":136,"column":70,"offset":5748},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Angle","position":{"start":{"line":138,"column":7,"offset":5756},"end":{"line":138,"column":12,"offset":5761},"indent":[]}}],"position":{"start":{"line":138,"column":1,"offset":5750},"end":{"line":138,"column":12,"offset":5761},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By defining an angle (degrees), you can rotate the images taken by the capture device. For example if you would mount the camera upside down, than you could enter the value 180 as the angle; this will flip the images.","position":{"start":{"line":140,"column":1,"offset":5763},"end":{"line":140,"column":218,"offset":5980},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":5763},"end":{"line":140,"column":218,"offset":5980},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Framerate","position":{"start":{"line":142,"column":7,"offset":5988},"end":{"line":142,"column":16,"offset":5997},"indent":[]}}],"position":{"start":{"line":142,"column":1,"offset":5982},"end":{"line":142,"column":16,"offset":5997},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The number of frames captures per second. Please note that this parameter will also be used if you're recording video. E.g. if you set this parameter to 20, you're recorded videos will also be 20 FPS.","position":{"start":{"line":144,"column":1,"offset":5999},"end":{"line":144,"column":201,"offset":6199},"indent":[]}}],"position":{"start":{"line":144,"column":1,"offset":5999},"end":{"line":144,"column":201,"offset":6199},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Sharpness, saturation, contrast, brightness","position":{"start":{"line":146,"column":7,"offset":6207},"end":{"line":146,"column":50,"offset":6250},"indent":[]}}],"position":{"start":{"line":146,"column":1,"offset":6201},"end":{"line":146,"column":50,"offset":6250},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Camera properties which you can specify to tune the settings to your needs.","position":{"start":{"line":148,"column":1,"offset":6252},"end":{"line":148,"column":76,"offset":6327},"indent":[]}}],"position":{"start":{"line":148,"column":1,"offset":6252},"end":{"line":148,"column":76,"offset":6327},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"IP camera","position":{"start":{"line":150,"column":5,"offset":6333},"end":{"line":150,"column":14,"offset":6342},"indent":[]}}],"position":{"start":{"line":150,"column":1,"offset":6329},"end":{"line":150,"column":14,"offset":6342},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The machinery can be used with any IP camera, that provides a RTSP (or MJPEG) stream. Make sure that you know the correct URL of your IP camera, you can ","position":{"start":{"line":152,"column":1,"offset":6344},"end":{"line":152,"column":154,"offset":6497},"indent":[]}},{"type":"link","title":null,"url":"http://www.ispyconnect.com/sources.aspx","children":[{"type":"text","value":"find a list here","position":{"start":{"line":152,"column":155,"offset":6498},"end":{"line":152,"column":171,"offset":6514},"indent":[]}}],"position":{"start":{"line":152,"column":154,"offset":6497},"end":{"line":152,"column":213,"offset":6556},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":152,"column":213,"offset":6556},"end":{"line":152,"column":214,"offset":6557},"indent":[]}}],"position":{"start":{"line":152,"column":1,"offset":6344},"end":{"line":152,"column":214,"offset":6557},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":154,"column":6,"offset":6564},"end":{"line":154,"column":16,"offset":6574},"indent":[]}}],"position":{"start":{"line":154,"column":1,"offset":6559},"end":{"line":154,"column":16,"offset":6574},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the IP capture device can be found in the ","position":{"start":{"line":156,"column":1,"offset":6576},"end":{"line":156,"column":61,"offset":6636},"indent":[]}},{"type":"inlineCode","value":"config/capture.xml","position":{"start":{"line":156,"column":61,"offset":6636},"end":{"line":156,"column":81,"offset":6656},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":156,"column":81,"offset":6656},"end":{"line":156,"column":186,"offset":6761},"indent":[]}}],"position":{"start":{"line":156,"column":1,"offset":6576},"end":{"line":156,"column":186,"offset":6761},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n http://username:password@ipaddress/image.jpg\n 800\n 640\n 0\n 0\n \n","position":{"start":{"line":158,"column":1,"offset":6763},"end":{"line":168,"column":4,"offset":7061},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"URL","position":{"start":{"line":170,"column":7,"offset":7069},"end":{"line":170,"column":10,"offset":7072},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7063},"end":{"line":170,"column":10,"offset":7072},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To use your IP camera, you should provide a valid RTSP (or MJPEG) URL. The machinery will take snapshots from this stream.","position":{"start":{"line":172,"column":1,"offset":7074},"end":{"line":172,"column":123,"offset":7196},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7074},"end":{"line":172,"column":123,"offset":7196},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Framewidth and -height","position":{"start":{"line":174,"column":7,"offset":7204},"end":{"line":174,"column":29,"offset":7226},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7198},"end":{"line":174,"column":29,"offset":7226},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can set the resolution of the capture device, make sure the resolution you've defined is equal to the resolution you've defined in your IP-camera software.","position":{"start":{"line":176,"column":1,"offset":7228},"end":{"line":176,"column":160,"offset":7387},"indent":[]}}],"position":{"start":{"line":176,"column":1,"offset":7228},"end":{"line":176,"column":160,"offset":7387},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Delay","position":{"start":{"line":178,"column":7,"offset":7395},"end":{"line":178,"column":12,"offset":7400},"indent":[]}}],"position":{"start":{"line":178,"column":1,"offset":7389},"end":{"line":178,"column":12,"offset":7400},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can provide a delay/interval (milliseconds) between two captures.","position":{"start":{"line":180,"column":1,"offset":7402},"end":{"line":180,"column":70,"offset":7471},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7402},"end":{"line":180,"column":70,"offset":7471},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Angle","position":{"start":{"line":182,"column":7,"offset":7479},"end":{"line":182,"column":12,"offset":7484},"indent":[]}}],"position":{"start":{"line":182,"column":1,"offset":7473},"end":{"line":182,"column":12,"offset":7484},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By defining an angle (degrees), you can rotate the images taken by the capture device. For example if you would mount the camera upside down, than you could enter the value 180 as the angle; this will flip the images.","position":{"start":{"line":184,"column":1,"offset":7486},"end":{"line":184,"column":218,"offset":7703},"indent":[]}}],"position":{"start":{"line":184,"column":1,"offset":7486},"end":{"line":184,"column":218,"offset":7703},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Condition","position":{"start":{"line":186,"column":4,"offset":7708},"end":{"line":186,"column":13,"offset":7717},"indent":[]}}],"position":{"start":{"line":186,"column":1,"offset":7705},"end":{"line":186,"column":13,"offset":7717},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The condition is the first step of the four passway. In this step the machinery will determine if it's allowed to proceed to the next step. For example a condition can be a time constraint, a brightness threshold, etc; multiple conditions can be selected.","position":{"start":{"line":188,"column":1,"offset":7719},"end":{"line":188,"column":256,"offset":7974},"indent":[]}}],"position":{"start":{"line":188,"column":1,"offset":7719},"end":{"line":188,"column":256,"offset":7974},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n \n ...\n Enabled\n ...\n \n","position":{"start":{"line":190,"column":1,"offset":7976},"end":{"line":199,"column":4,"offset":8146},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Enabled","position":{"start":{"line":201,"column":5,"offset":8152},"end":{"line":201,"column":12,"offset":8159},"indent":[]}}],"position":{"start":{"line":201,"column":1,"offset":8148},"end":{"line":201,"column":12,"offset":8159},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be helpful to enable or disable the machinery at specific times. Therefore the time condition makes it possible to select a time range for each day of the week. When the current time is within the time range, the machinery will be enabled.","position":{"start":{"line":203,"column":1,"offset":8161},"end":{"line":203,"column":247,"offset":8407},"indent":[]}}],"position":{"start":{"line":203,"column":1,"offset":8161},"end":{"line":203,"column":247,"offset":8407},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":205,"column":6,"offset":8414},"end":{"line":205,"column":16,"offset":8424},"indent":[]}}],"position":{"start":{"line":205,"column":1,"offset":8409},"end":{"line":205,"column":16,"offset":8424},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Enabled condition can be found in the ","position":{"start":{"line":207,"column":1,"offset":8426},"end":{"line":207,"column":61,"offset":8486},"indent":[]}},{"type":"inlineCode","value":"config/condition.xml","position":{"start":{"line":207,"column":61,"offset":8486},"end":{"line":207,"column":83,"offset":8508},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":207,"column":83,"offset":8508},"end":{"line":207,"column":188,"offset":8613},"indent":[]}}],"position":{"start":{"line":207,"column":1,"offset":8426},"end":{"line":207,"column":188,"offset":8613},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n true\n 5000\n \n","position":{"start":{"line":209,"column":1,"offset":8615},"end":{"line":216,"column":4,"offset":8753},"indent":[1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Active","position":{"start":{"line":218,"column":7,"offset":8761},"end":{"line":218,"column":13,"offset":8767},"indent":[]}}],"position":{"start":{"line":218,"column":1,"offset":8755},"end":{"line":218,"column":13,"offset":8767},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The active field is boolean value (true/false). When the active field is true, the machinery is enabled, if not it's disabled.","position":{"start":{"line":220,"column":1,"offset":8769},"end":{"line":220,"column":127,"offset":8895},"indent":[]}}],"position":{"start":{"line":220,"column":1,"offset":8769},"end":{"line":220,"column":127,"offset":8895},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Delay","position":{"start":{"line":222,"column":7,"offset":8903},"end":{"line":222,"column":12,"offset":8908},"indent":[]}}],"position":{"start":{"line":222,"column":1,"offset":8897},"end":{"line":222,"column":12,"offset":8908},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The delay value is used when the condition failed, so when the current time isn't in the selected time range for that day. In that case the machinery will idle for the specified delay time. The value of the delay is expressed in miliseconds.","position":{"start":{"line":224,"column":1,"offset":8910},"end":{"line":224,"column":242,"offset":9151},"indent":[]}}],"position":{"start":{"line":224,"column":1,"offset":8910},"end":{"line":224,"column":242,"offset":9151},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Time","position":{"start":{"line":226,"column":5,"offset":9157},"end":{"line":226,"column":9,"offset":9161},"indent":[]}}],"position":{"start":{"line":226,"column":1,"offset":9153},"end":{"line":226,"column":9,"offset":9161},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be helpful to enable or disable the machinery at specific times. Therefore the time condition makes it possible to select a time range for each day of the week. When the current time is within the time range, the machinery will be enabled.","position":{"start":{"line":228,"column":1,"offset":9163},"end":{"line":228,"column":247,"offset":9409},"indent":[]}}],"position":{"start":{"line":228,"column":1,"offset":9163},"end":{"line":228,"column":247,"offset":9409},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":230,"column":6,"offset":9416},"end":{"line":230,"column":16,"offset":9426},"indent":[]}}],"position":{"start":{"line":230,"column":1,"offset":9411},"end":{"line":230,"column":16,"offset":9426},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Time condition can be found in the ","position":{"start":{"line":232,"column":1,"offset":9428},"end":{"line":232,"column":58,"offset":9485},"indent":[]}},{"type":"inlineCode","value":"config/condition.xml","position":{"start":{"line":232,"column":58,"offset":9485},"end":{"line":232,"column":80,"offset":9507},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":232,"column":80,"offset":9507},"end":{"line":232,"column":185,"offset":9612},"indent":[]}}],"position":{"start":{"line":232,"column":1,"offset":9428},"end":{"line":232,"column":185,"offset":9612},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n","position":{"start":{"line":234,"column":1,"offset":9614},"end":{"line":241,"column":4,"offset":9813},"indent":[1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Times","position":{"start":{"line":243,"column":7,"offset":9821},"end":{"line":243,"column":12,"offset":9826},"indent":[]}}],"position":{"start":{"line":243,"column":1,"offset":9815},"end":{"line":243,"column":12,"offset":9826},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The times property contains a list of times, delimited by a \"-\". The first item in the list will specify the time range for the first day of the week (Monday), the last item for the last day of the week (Sunday). The begin- and end-time, for a specific day, are delimited by a \",\" where the first element will specify that start time and the second one specifies the end time.","position":{"start":{"line":245,"column":1,"offset":9828},"end":{"line":245,"column":377,"offset":10204},"indent":[]}}],"position":{"start":{"line":245,"column":1,"offset":9828},"end":{"line":245,"column":377,"offset":10204},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Delay","position":{"start":{"line":247,"column":7,"offset":10212},"end":{"line":247,"column":12,"offset":10217},"indent":[]}}],"position":{"start":{"line":247,"column":1,"offset":10206},"end":{"line":247,"column":12,"offset":10217},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The delay value is used when the condition failed, so when the current time isn't in the selected time range for that day. In that case the machinery will idle for the specified delay time. The value of the delay is expressed in miliseconds.","position":{"start":{"line":249,"column":1,"offset":10219},"end":{"line":249,"column":242,"offset":10460},"indent":[]}}],"position":{"start":{"line":249,"column":1,"offset":10219},"end":{"line":249,"column":242,"offset":10460},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Algorithm","position":{"start":{"line":251,"column":4,"offset":10465},"end":{"line":251,"column":13,"offset":10474},"indent":[]}}],"position":{"start":{"line":251,"column":1,"offset":10462},"end":{"line":251,"column":13,"offset":10474},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The algorithm is the second step of the four passway. An algorithm will execute some kind of function on a sequence of images, and end up with a black and white image; just like the image below. An example of an algorithm would be one that does motion detection or one that would detect cats or dogs (using TensorFlow, ar any other Deep Learning framework).","position":{"start":{"line":253,"column":1,"offset":10476},"end":{"line":253,"column":358,"offset":10833},"indent":[]}}],"position":{"start":{"line":253,"column":1,"offset":10476},"end":{"line":253,"column":358,"offset":10833},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/machinery/algorithm.png","alt":"machinery algorithm","position":{"start":{"line":255,"column":1,"offset":10835},"end":{"line":255,"column":68,"offset":10902},"indent":[]}}],"position":{"start":{"line":255,"column":1,"offset":10835},"end":{"line":255,"column":68,"offset":10902},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The white pixels on the image will indicate the object of interest. For example, when looking for motion, the pixels that have been changed; it depends on what the algorithm is looking for. The black pixels are background pixels.","position":{"start":{"line":257,"column":1,"offset":10904},"end":{"line":257,"column":230,"offset":11133},"indent":[]}}],"position":{"start":{"line":257,"column":1,"offset":10904},"end":{"line":257,"column":230,"offset":11133},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The only convention that an algorithm should meet is that it should return a black and white image to the next step; the expositor. And of course that it requires a sequence of images as a parameter. Besides those conventions, an algorithm can do everything it wants to do. So you could create your own cat detection algorithm, marker detection, etc.","position":{"start":{"line":259,"column":1,"offset":11135},"end":{"line":259,"column":351,"offset":11485},"indent":[]}}],"position":{"start":{"line":259,"column":1,"offset":11135},"end":{"line":259,"column":351,"offset":11485},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can select the algortihm in the ","position":{"start":{"line":261,"column":1,"offset":11487},"end":{"line":261,"column":37,"offset":11523},"indent":[]}},{"type":"inlineCode","value":"config/config.xml","position":{"start":{"line":261,"column":37,"offset":11523},"end":{"line":261,"column":56,"offset":11542},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":261,"column":56,"offset":11542},"end":{"line":261,"column":57,"offset":11543},"indent":[]}}],"position":{"start":{"line":261,"column":1,"offset":11487},"end":{"line":261,"column":57,"offset":11543},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n \n ...\n DifferentialCollins\n ...\n \n","position":{"start":{"line":263,"column":1,"offset":11545},"end":{"line":272,"column":4,"offset":11711},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Differential images","position":{"start":{"line":274,"column":5,"offset":11717},"end":{"line":274,"column":24,"offset":11736},"indent":[]}}],"position":{"start":{"line":274,"column":1,"offset":11713},"end":{"line":274,"column":24,"offset":11736},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This algorithm is a very simple method to detect motion; in terms of understanding but also processing. Just like the name says, it's the result of comparing images. When the images are compared, we know the pixels that have been changed and if the amount of pixels that changed is big enough, one can say that something happened and thus motion was detected.","position":{"start":{"line":276,"column":1,"offset":11738},"end":{"line":276,"column":360,"offset":12097},"indent":[]}}],"position":{"start":{"line":276,"column":1,"offset":11738},"end":{"line":276,"column":360,"offset":12097},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To get a more technical explanation: the algoritm will substract 2 or more images, and once that is done it will end up with a black and white image. The white pixels will mark the pixels that where different/changed and the black pixels are the pixels that have not changed; background pixels. Please note that there are several different combinations of substracting images. However for the machinery, we will use the method of Collins et al. as this method erases the phenomenon \"ghosting\".","position":{"start":{"line":278,"column":1,"offset":12099},"end":{"line":278,"column":494,"offset":12592},"indent":[]}}],"position":{"start":{"line":278,"column":1,"offset":12099},"end":{"line":278,"column":494,"offset":12592},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/machinery/differential_images.png","alt":"machinery differential","position":{"start":{"line":280,"column":1,"offset":12594},"end":{"line":280,"column":81,"offset":12674},"indent":[]}}],"position":{"start":{"line":280,"column":1,"offset":12594},"end":{"line":280,"column":81,"offset":12674},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"In the image above the method of Collins et al. is illustrated. For this method we will process three images. The images are a sequence (from left to right), so the first (A) image was taken before the second (B) one, and the second (B) before the third (C) one. Next we will do a first comparision (C-B) of the third (C) image and the second (B) image, and after that we will do a second comparison (C-A) of the third (C) image and first (A) image.","position":{"start":{"line":282,"column":1,"offset":12676},"end":{"line":282,"column":450,"offset":13125},"indent":[]}}],"position":{"start":{"line":282,"column":1,"offset":12676},"end":{"line":282,"column":450,"offset":13125},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"After the comparison we will end up with two difference images (C-B) and (C-A); both will mark the white pixels as changed pixels and black as non-changed pixels. To finish the algorithm we will do a logical AND-operation of the two difference images; this will give us the final black and white image ((C-B)&&(C-A)).","position":{"start":{"line":284,"column":1,"offset":13127},"end":{"line":284,"column":318,"offset":13444},"indent":[]}}],"position":{"start":{"line":284,"column":1,"offset":13127},"end":{"line":284,"column":318,"offset":13444},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The main idea of the Colins et al. method, is that it will erase \"ghosting\". In the last step we are doing a logical AND-operation, by doing this we will only keep the pixels, that changed in the first two images; therefore we can elimante false positives.","position":{"start":{"line":286,"column":1,"offset":13446},"end":{"line":286,"column":257,"offset":13702},"indent":[]}}],"position":{"start":{"line":286,"column":1,"offset":13446},"end":{"line":286,"column":257,"offset":13702},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":288,"column":6,"offset":13709},"end":{"line":288,"column":16,"offset":13719},"indent":[]}}],"position":{"start":{"line":288,"column":1,"offset":13704},"end":{"line":288,"column":16,"offset":13719},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Differential images algorithm can be found in the config/algorithm.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":290,"column":1,"offset":13721},"end":{"line":290,"column":198,"offset":13918},"indent":[]}}],"position":{"start":{"line":290,"column":1,"offset":13721},"end":{"line":290,"column":198,"offset":13918},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n 5\n 20\n \n","position":{"start":{"line":292,"column":1,"offset":13920},"end":{"line":299,"column":4,"offset":14085},"indent":[1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Erode","position":{"start":{"line":301,"column":7,"offset":14093},"end":{"line":301,"column":12,"offset":14098},"indent":[]}}],"position":{"start":{"line":301,"column":1,"offset":14087},"end":{"line":301,"column":12,"offset":14098},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The erode parameter represents a structural element (a morphological operation), which will be used to minimize the changed pixels; more information about eroding can be found here. The idea of the eroding is that pixels which are isolated will be removed; this means that when only one pixel changed, that pixel will reverted to the non-changed state. But for example when a large change happens and a lot of adjacent pixels are changed, the eroding will not be able to revert them.","position":{"start":{"line":303,"column":1,"offset":14100},"end":{"line":303,"column":484,"offset":14583},"indent":[]}}],"position":{"start":{"line":303,"column":1,"offset":14100},"end":{"line":303,"column":484,"offset":14583},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The higher the number of the erode parameter, the more aggressive the eroding will be. So high erode values, will make it possible that also large changes will be reverted to the non-changed state.","position":{"start":{"line":305,"column":1,"offset":14585},"end":{"line":305,"column":198,"offset":14782},"indent":[]}}],"position":{"start":{"line":305,"column":1,"offset":14585},"end":{"line":305,"column":198,"offset":14782},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Threshold","position":{"start":{"line":307,"column":7,"offset":14790},"end":{"line":307,"column":16,"offset":14799},"indent":[]}}],"position":{"start":{"line":307,"column":1,"offset":14784},"end":{"line":307,"column":16,"offset":14799},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When doing the comparison of two images, we won't end up with a clean black and white image. In most of the cases the values will be between 0 and 255; so gray values. This means that the value 0 will mean that both pixels where the same in both image, and values 255 mean that both pixels where totally different in both images. Of course we will also have values between 0-255, so pixels that are a little bit different in both images. So to make the resulting black and white image, we will need to apply a threshold value.","position":{"start":{"line":309,"column":1,"offset":14801},"end":{"line":309,"column":527,"offset":15327},"indent":[]}}],"position":{"start":{"line":309,"column":1,"offset":14801},"end":{"line":309,"column":527,"offset":15327},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The threshold will specify how much a pixel has to be different in the two images. So for example when the threshold is 30, it means that the difference between two pixels has to be equal or more then 30. The higher the threshold the more the pixel needs to be different, to be marked as changed.","position":{"start":{"line":311,"column":1,"offset":15329},"end":{"line":311,"column":297,"offset":15625},"indent":[]}}],"position":{"start":{"line":311,"column":1,"offset":15329},"end":{"line":311,"column":297,"offset":15625},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Expositor","position":{"start":{"line":313,"column":4,"offset":15630},"end":{"line":313,"column":13,"offset":15639},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":15627},"end":{"line":313,"column":13,"offset":15639},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"After the algorithm is executed, the expositor will determine, a region, where the changes were detected. An expositor can constrain a region in terms of selecting a hull or defining a rectangle.","position":{"start":{"line":315,"column":1,"offset":15641},"end":{"line":315,"column":196,"offset":15836},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":15641},"end":{"line":315,"column":196,"offset":15836},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"An expositor receives a black and white image as parameter and should modify a JSON object with all the information it processed. The JSON object must include: the bounding rectangle(s) of the positions where the pixels of interest are located and the number of pixels of interest. But can also include other optional parameters.","position":{"start":{"line":317,"column":1,"offset":15838},"end":{"line":317,"column":330,"offset":16167},"indent":[]}}],"position":{"start":{"line":317,"column":1,"offset":15838},"end":{"line":317,"column":330,"offset":16167},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can change the expositor by changing the ","position":{"start":{"line":319,"column":1,"offset":16169},"end":{"line":319,"column":46,"offset":16214},"indent":[]}},{"type":"inlineCode","value":"config/config.xml","position":{"start":{"line":319,"column":46,"offset":16214},"end":{"line":319,"column":65,"offset":16233},"indent":[]}},{"type":"text","value":" file, and choose one of the following:","position":{"start":{"line":319,"column":65,"offset":16233},"end":{"line":319,"column":104,"offset":16272},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":16169},"end":{"line":319,"column":104,"offset":16272},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Hull","position":{"start":{"line":320,"column":3,"offset":16275},"end":{"line":320,"column":7,"offset":16279},"indent":[]}}],"position":{"start":{"line":320,"column":3,"offset":16275},"end":{"line":320,"column":7,"offset":16279},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":16273},"end":{"line":320,"column":7,"offset":16279},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Rectangle","position":{"start":{"line":321,"column":3,"offset":16282},"end":{"line":321,"column":12,"offset":16291},"indent":[]}}],"position":{"start":{"line":321,"column":3,"offset":16282},"end":{"line":321,"column":12,"offset":16291},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":16280},"end":{"line":321,"column":12,"offset":16291},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":16273},"end":{"line":321,"column":12,"offset":16291},"indent":[1]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n \n ...\n Hull\n ...\n \n","position":{"start":{"line":323,"column":1,"offset":16293},"end":{"line":332,"column":4,"offset":16444},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Rectangle","position":{"start":{"line":334,"column":5,"offset":16450},"end":{"line":334,"column":14,"offset":16459},"indent":[]}}],"position":{"start":{"line":334,"column":1,"offset":16446},"end":{"line":334,"column":14,"offset":16459},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This is a trivial expositor. A rectangle region can be defined to constrain the locations of pixels of interest. The rectangle repositor will return the region of the pixels of interest.","position":{"start":{"line":336,"column":1,"offset":16461},"end":{"line":336,"column":187,"offset":16647},"indent":[]}}],"position":{"start":{"line":336,"column":1,"offset":16461},"end":{"line":336,"column":187,"offset":16647},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":338,"column":6,"offset":16654},"end":{"line":338,"column":16,"offset":16664},"indent":[]}}],"position":{"start":{"line":338,"column":1,"offset":16649},"end":{"line":338,"column":16,"offset":16664},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the rectangle expositor can be found in the config/expositor.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":340,"column":1,"offset":16666},"end":{"line":340,"column":188,"offset":16853},"indent":[]}}],"position":{"start":{"line":340,"column":1,"offset":16666},"end":{"line":340,"column":188,"offset":16853},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n \n 0\n 0\n 1280\n 720\n \n \n","position":{"start":{"line":342,"column":1,"offset":16855},"end":{"line":353,"column":4,"offset":17077},"indent":[1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Region","position":{"start":{"line":355,"column":7,"offset":17085},"end":{"line":355,"column":13,"offset":17091},"indent":[]}}],"position":{"start":{"line":355,"column":1,"offset":17079},"end":{"line":355,"column":13,"offset":17091},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The region parameter contains 4 values; x1, y1, x2 and y2 respectively. The values x1 and y1 indicate the x- and y-coordinate of the left upper starting point. The values x2 and y2 are the bottom right coordinates. A virtual rectangle will be drawn from (x1,y1) to (x2,y2). Pixels of interest that lie within this rectangle are valid pixels; if not they are invalid.","position":{"start":{"line":357,"column":1,"offset":17093},"end":{"line":357,"column":367,"offset":17459},"indent":[]}}],"position":{"start":{"line":357,"column":1,"offset":17093},"end":{"line":357,"column":367,"offset":17459},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Hull","position":{"start":{"line":359,"column":5,"offset":17465},"end":{"line":359,"column":9,"offset":17469},"indent":[]}}],"position":{"start":{"line":359,"column":1,"offset":17461},"end":{"line":359,"column":9,"offset":17469},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This hull is a more complex expositor than the rectangle. A hull can be selected with the web, you can select one or more coordinates to create a flexible region. The coordinates can be adjusted afterwards and be removed by double clicking on the coordinate. You can expand the hull by removing the start coordinate, which is marked by the white bullet.","position":{"start":{"line":361,"column":1,"offset":17471},"end":{"line":361,"column":354,"offset":17824},"indent":[]}}],"position":{"start":{"line":361,"column":1,"offset":17471},"end":{"line":361,"column":354,"offset":17824},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/machinery/hull.png","alt":"machinery hull","position":{"start":{"line":363,"column":1,"offset":17826},"end":{"line":363,"column":58,"offset":17883},"indent":[]}}],"position":{"start":{"line":363,"column":1,"offset":17826},"end":{"line":363,"column":58,"offset":17883},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":365,"column":6,"offset":17890},"end":{"line":365,"column":16,"offset":17900},"indent":[]}}],"position":{"start":{"line":365,"column":1,"offset":17885},"end":{"line":365,"column":16,"offset":17900},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the hull expositor can be found in the config/expositor.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":367,"column":1,"offset":17902},"end":{"line":367,"column":183,"offset":18084},"indent":[]}}],"position":{"start":{"line":367,"column":1,"offset":17902},"end":{"line":367,"column":183,"offset":18084},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n 347,361|627,266|975,328|1091,328|1148,413|1158,516|1121,534|962,567|699,648|531,700|243,613|423,550|665,453|850,470|666,361|467,385|325,460|165,372\n \n","position":{"start":{"line":369,"column":1,"offset":18086},"end":{"line":375,"column":4,"offset":18332},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Region","position":{"start":{"line":377,"column":7,"offset":18340},"end":{"line":377,"column":13,"offset":18346},"indent":[]}}],"position":{"start":{"line":377,"column":1,"offset":18334},"end":{"line":377,"column":13,"offset":18346},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The region parameter contains n values. Each value represents a coordinate (x,y) and are seperated by the \"|\" delimiter. These coordinates are used to calculate the concave hull. Pixels of interest that lie within the concave hull are valid pixels; if not they are invalid.","position":{"start":{"line":378,"column":1,"offset":18347},"end":{"line":378,"column":274,"offset":18620},"indent":[]}}],"position":{"start":{"line":378,"column":1,"offset":18347},"end":{"line":378,"column":274,"offset":18620},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Heuristic","position":{"start":{"line":380,"column":4,"offset":18625},"end":{"line":380,"column":13,"offset":18634},"indent":[]}}],"position":{"start":{"line":380,"column":1,"offset":18622},"end":{"line":380,"column":13,"offset":18634},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The heuristic is the last step in the four passway which will decide if the detection is valid or not. It will do this by using information from the previous steps (the expositor and the algorithm); e.g. number of changed pixels.","position":{"start":{"line":382,"column":1,"offset":18636},"end":{"line":382,"column":230,"offset":18865},"indent":[]}}],"position":{"start":{"line":382,"column":1,"offset":18636},"end":{"line":382,"column":230,"offset":18865},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can change the heuristic by changing the ","position":{"start":{"line":384,"column":1,"offset":18867},"end":{"line":384,"column":46,"offset":18912},"indent":[]}},{"type":"inlineCode","value":"config/config.xml","position":{"start":{"line":384,"column":46,"offset":18912},"end":{"line":384,"column":65,"offset":18931},"indent":[]}},{"type":"text","value":" file, and choose one of the following:","position":{"start":{"line":384,"column":65,"offset":18931},"end":{"line":384,"column":104,"offset":18970},"indent":[]}}],"position":{"start":{"line":384,"column":1,"offset":18867},"end":{"line":384,"column":104,"offset":18970},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Sequence","position":{"start":{"line":385,"column":3,"offset":18973},"end":{"line":385,"column":11,"offset":18981},"indent":[]}}],"position":{"start":{"line":385,"column":3,"offset":18973},"end":{"line":385,"column":11,"offset":18981},"indent":[]}}],"position":{"start":{"line":385,"column":1,"offset":18971},"end":{"line":385,"column":11,"offset":18981},"indent":[]}}],"position":{"start":{"line":385,"column":1,"offset":18971},"end":{"line":385,"column":11,"offset":18981},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n \n ...\n Sequence\n ...\n \n","position":{"start":{"line":387,"column":1,"offset":18983},"end":{"line":396,"column":4,"offset":19138},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Sequence","position":{"start":{"line":398,"column":5,"offset":19144},"end":{"line":398,"column":13,"offset":19152},"indent":[]}}],"position":{"start":{"line":398,"column":1,"offset":19140},"end":{"line":398,"column":13,"offset":19152},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This is a trivial heuristic. The sequence heuristic will store a single integer in memory, that will count the numbers of valid detections. When the heuristic will detect a false detection, it will decrease the count. The sequence heuristic will return true, if a threshold is reached; for example when something was detected three times in a row.","position":{"start":{"line":400,"column":1,"offset":19154},"end":{"line":400,"column":348,"offset":19501},"indent":[]}}],"position":{"start":{"line":400,"column":1,"offset":19154},"end":{"line":400,"column":348,"offset":19501},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":402,"column":6,"offset":19508},"end":{"line":402,"column":16,"offset":19518},"indent":[]}}],"position":{"start":{"line":402,"column":1,"offset":19503},"end":{"line":402,"column":16,"offset":19518},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Sequence heuristic can be found in the config/heuristic.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":404,"column":1,"offset":19520},"end":{"line":404,"column":187,"offset":19706},"indent":[]}}],"position":{"start":{"line":404,"column":1,"offset":19520},"end":{"line":404,"column":187,"offset":19706},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n 1\n 1\n 2000\n \n","position":{"start":{"line":406,"column":1,"offset":19708},"end":{"line":414,"column":4,"offset":19940},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Minimum changes","position":{"start":{"line":416,"column":7,"offset":19948},"end":{"line":416,"column":22,"offset":19963},"indent":[]}}],"position":{"start":{"line":416,"column":1,"offset":19942},"end":{"line":416,"column":22,"offset":19963},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The heuristic will only return true if enough changes have been detected. The minimum of changes indicates the minimum number of pixels that have to been changed, to be a valid detection.","position":{"start":{"line":418,"column":1,"offset":19965},"end":{"line":418,"column":188,"offset":20152},"indent":[]}}],"position":{"start":{"line":418,"column":1,"offset":19965},"end":{"line":418,"column":188,"offset":20152},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Minimum durations","position":{"start":{"line":420,"column":7,"offset":20160},"end":{"line":420,"column":24,"offset":20177},"indent":[]}}],"position":{"start":{"line":420,"column":1,"offset":20154},"end":{"line":420,"column":24,"offset":20177},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The minimum number of detections in a row to be a valid detection.","position":{"start":{"line":422,"column":1,"offset":20179},"end":{"line":422,"column":67,"offset":20245},"indent":[]}}],"position":{"start":{"line":422,"column":1,"offset":20179},"end":{"line":422,"column":67,"offset":20245},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"No motion delay time","position":{"start":{"line":424,"column":7,"offset":20253},"end":{"line":424,"column":27,"offset":20273},"indent":[]}}],"position":{"start":{"line":424,"column":1,"offset":20247},"end":{"line":424,"column":27,"offset":20273},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When the heuristic failed, due to not enough pixels changed or not x detections in a row, the heuristic will idle for some time.","position":{"start":{"line":426,"column":1,"offset":20275},"end":{"line":426,"column":129,"offset":20403},"indent":[]}}],"position":{"start":{"line":426,"column":1,"offset":20275},"end":{"line":426,"column":129,"offset":20403},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Output","position":{"start":{"line":428,"column":4,"offset":20408},"end":{"line":428,"column":10,"offset":20414},"indent":[]}}],"position":{"start":{"line":428,"column":1,"offset":20405},"end":{"line":428,"column":10,"offset":20414},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If the heuristic determined that the evaluation was valid, one or more output operations can be executed. You configure which ooutput operations that will be executed, by modifying the configuration file or using the web interface.","position":{"start":{"line":430,"column":1,"offset":20416},"end":{"line":430,"column":232,"offset":20647},"indent":[]}}],"position":{"start":{"line":430,"column":1,"offset":20416},"end":{"line":430,"column":232,"offset":20647},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n\n \n ...\n Video\n ...\n \n","position":{"start":{"line":432,"column":1,"offset":20649},"end":{"line":441,"column":4,"offset":20796},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"You can choose which output devices you will be using. If you select multiple outputs, seperate them with an ","position":{"start":{"line":443,"column":1,"offset":20798},"end":{"line":443,"column":110,"offset":20907},"indent":[]}},{"type":"inlineCode","value":",","position":{"start":{"line":443,"column":110,"offset":20907},"end":{"line":443,"column":113,"offset":20910},"indent":[]}},{"type":"text","value":". You can change the output device by changing the ","position":{"start":{"line":443,"column":113,"offset":20910},"end":{"line":443,"column":164,"offset":20961},"indent":[]}},{"type":"inlineCode","value":"config/config.xml","position":{"start":{"line":443,"column":164,"offset":20961},"end":{"line":443,"column":183,"offset":20980},"indent":[]}},{"type":"text","value":" file, and choose one of the following:","position":{"start":{"line":443,"column":183,"offset":20980},"end":{"line":443,"column":222,"offset":21019},"indent":[]}}],"position":{"start":{"line":443,"column":1,"offset":20798},"end":{"line":443,"column":222,"offset":21019},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Disk","position":{"start":{"line":444,"column":3,"offset":21022},"end":{"line":444,"column":7,"offset":21026},"indent":[]}}],"position":{"start":{"line":444,"column":3,"offset":21022},"end":{"line":444,"column":7,"offset":21026},"indent":[]}}],"position":{"start":{"line":444,"column":1,"offset":21020},"end":{"line":444,"column":7,"offset":21026},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Video","position":{"start":{"line":445,"column":3,"offset":21029},"end":{"line":445,"column":8,"offset":21034},"indent":[]}}],"position":{"start":{"line":445,"column":3,"offset":21029},"end":{"line":445,"column":8,"offset":21034},"indent":[]}}],"position":{"start":{"line":445,"column":1,"offset":21027},"end":{"line":445,"column":8,"offset":21034},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"GPIO","position":{"start":{"line":446,"column":3,"offset":21037},"end":{"line":446,"column":7,"offset":21041},"indent":[]}}],"position":{"start":{"line":446,"column":3,"offset":21037},"end":{"line":446,"column":7,"offset":21041},"indent":[]}}],"position":{"start":{"line":446,"column":1,"offset":21035},"end":{"line":446,"column":7,"offset":21041},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"TCPSocket","position":{"start":{"line":447,"column":3,"offset":21044},"end":{"line":447,"column":12,"offset":21053},"indent":[]}}],"position":{"start":{"line":447,"column":3,"offset":21044},"end":{"line":447,"column":12,"offset":21053},"indent":[]}}],"position":{"start":{"line":447,"column":1,"offset":21042},"end":{"line":447,"column":12,"offset":21053},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Webhook","position":{"start":{"line":448,"column":3,"offset":21056},"end":{"line":448,"column":10,"offset":21063},"indent":[]}}],"position":{"start":{"line":448,"column":3,"offset":21056},"end":{"line":448,"column":10,"offset":21063},"indent":[]}}],"position":{"start":{"line":448,"column":1,"offset":21054},"end":{"line":448,"column":10,"offset":21063},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"MQTT","position":{"start":{"line":449,"column":3,"offset":21066},"end":{"line":449,"column":7,"offset":21070},"indent":[]}}],"position":{"start":{"line":449,"column":3,"offset":21066},"end":{"line":449,"column":7,"offset":21070},"indent":[]}}],"position":{"start":{"line":449,"column":1,"offset":21064},"end":{"line":449,"column":7,"offset":21070},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Script","position":{"start":{"line":450,"column":3,"offset":21073},"end":{"line":450,"column":9,"offset":21079},"indent":[]}}],"position":{"start":{"line":450,"column":3,"offset":21073},"end":{"line":450,"column":9,"offset":21079},"indent":[]}}],"position":{"start":{"line":450,"column":1,"offset":21071},"end":{"line":450,"column":9,"offset":21079},"indent":[]}}],"position":{"start":{"line":444,"column":1,"offset":21020},"end":{"line":450,"column":9,"offset":21079},"indent":[1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Disk","position":{"start":{"line":452,"column":5,"offset":21085},"end":{"line":452,"column":9,"offset":21089},"indent":[]}}],"position":{"start":{"line":452,"column":1,"offset":21081},"end":{"line":452,"column":9,"offset":21089},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"An image can be saved to disk.","position":{"start":{"line":454,"column":1,"offset":21091},"end":{"line":454,"column":31,"offset":21121},"indent":[]}}],"position":{"start":{"line":454,"column":1,"offset":21091},"end":{"line":454,"column":31,"offset":21121},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":456,"column":6,"offset":21128},"end":{"line":456,"column":16,"offset":21138},"indent":[]}}],"position":{"start":{"line":456,"column":1,"offset":21123},"end":{"line":456,"column":16,"offset":21138},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Disk output device can be found in the ","position":{"start":{"line":458,"column":1,"offset":21140},"end":{"line":458,"column":62,"offset":21201},"indent":[]}},{"type":"inlineCode","value":"config/io.xml","position":{"start":{"line":458,"column":62,"offset":21201},"end":{"line":458,"column":77,"offset":21216},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":458,"column":77,"offset":21216},"end":{"line":458,"column":182,"offset":21321},"indent":[]}}],"position":{"start":{"line":458,"column":1,"offset":21140},"end":{"line":458,"column":182,"offset":21321},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n timestamp_microseconds_instanceName_regionCoordinates_numberOfChanges_token.jpg\n /etc/opt/kerberosio/capture/\n false\n white\n false\n 0\n \n","position":{"start":{"line":460,"column":1,"offset":21323},"end":{"line":471,"column":4,"offset":21754},"indent":[1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"File format","position":{"start":{"line":473,"column":7,"offset":21762},"end":{"line":473,"column":18,"offset":21773},"indent":[]}}],"position":{"start":{"line":473,"column":1,"offset":21756},"end":{"line":473,"column":18,"offset":21773},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The format that will be used for the name of the image. One or more variables can be defined and will be replaced by the machinery. Note that when you're using a variables name in the file format, that this name should be defined in the JSON object.","position":{"start":{"line":475,"column":1,"offset":21775},"end":{"line":475,"column":250,"offset":22024},"indent":[]}}],"position":{"start":{"line":475,"column":1,"offset":21775},"end":{"line":475,"column":250,"offset":22024},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Directory","position":{"start":{"line":477,"column":7,"offset":22032},"end":{"line":477,"column":16,"offset":22041},"indent":[]}}],"position":{"start":{"line":477,"column":1,"offset":22026},"end":{"line":477,"column":16,"offset":22041},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The directory where the image will be saved to. By default images are saved to the /etc/opt/kerberosio/capture directory.","position":{"start":{"line":479,"column":1,"offset":22043},"end":{"line":479,"column":122,"offset":22164},"indent":[]}}],"position":{"start":{"line":479,"column":1,"offset":22043},"end":{"line":479,"column":122,"offset":22164},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Mark with timestamp","position":{"start":{"line":481,"column":7,"offset":22172},"end":{"line":481,"column":26,"offset":22191},"indent":[]}}],"position":{"start":{"line":481,"column":1,"offset":22166},"end":{"line":481,"column":26,"offset":22191},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When this settings is set to true, the image is marked with a timestamp.","position":{"start":{"line":483,"column":1,"offset":22193},"end":{"line":483,"column":73,"offset":22265},"indent":[]}}],"position":{"start":{"line":483,"column":1,"offset":22193},"end":{"line":483,"column":73,"offset":22265},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Timestamp color","position":{"start":{"line":485,"column":7,"offset":22273},"end":{"line":485,"column":22,"offset":22288},"indent":[]}}],"position":{"start":{"line":485,"column":1,"offset":22267},"end":{"line":485,"column":22,"offset":22288},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A color can be defined for timestamp: white, black, red, green and blue.","position":{"start":{"line":486,"column":1,"offset":22289},"end":{"line":486,"column":73,"offset":22361},"indent":[]}}],"position":{"start":{"line":486,"column":1,"offset":22289},"end":{"line":486,"column":73,"offset":22361},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Privacy","position":{"start":{"line":488,"column":7,"offset":22369},"end":{"line":488,"column":14,"offset":22376},"indent":[]}}],"position":{"start":{"line":488,"column":1,"offset":22363},"end":{"line":488,"column":14,"offset":22376},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The privacy mode can be activated to remove some parts from the image. This especially helpful if you want to filter out public areas. When this option is enabled you will seee that after configuring the Hull expositor, you'll see that the pixels outside your region of interest (Hull) are made black.","position":{"start":{"line":489,"column":1,"offset":22377},"end":{"line":489,"column":303,"offset":22679},"indent":[]}}],"position":{"start":{"line":489,"column":1,"offset":22377},"end":{"line":489,"column":303,"offset":22679},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Throttler","position":{"start":{"line":491,"column":7,"offset":22687},"end":{"line":491,"column":16,"offset":22696},"indent":[]}}],"position":{"start":{"line":491,"column":1,"offset":22681},"end":{"line":491,"column":16,"offset":22696},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Disk will only be triggered once in 5 seconds, nevertheless more detections occurred.","position":{"start":{"line":492,"column":1,"offset":22697},"end":{"line":492,"column":187,"offset":22883},"indent":[]}}],"position":{"start":{"line":492,"column":1,"offset":22697},"end":{"line":492,"column":187,"offset":22883},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Video","position":{"start":{"line":494,"column":5,"offset":22889},"end":{"line":494,"column":10,"offset":22894},"indent":[]}}],"position":{"start":{"line":494,"column":1,"offset":22885},"end":{"line":494,"column":10,"offset":22894},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When a valid event is detected, a video will be recorded for x seconds. When more valid events are detected, while a video is recording, the video file will further record for x seconds; so no new video file be recorded, but the existing one will be expanded.","position":{"start":{"line":495,"column":1,"offset":22895},"end":{"line":495,"column":260,"offset":23154},"indent":[]}}],"position":{"start":{"line":495,"column":1,"offset":22895},"end":{"line":495,"column":260,"offset":23154},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":497,"column":6,"offset":23161},"end":{"line":497,"column":16,"offset":23171},"indent":[]}}],"position":{"start":{"line":497,"column":1,"offset":23156},"end":{"line":497,"column":16,"offset":23171},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Video output device can be found in the ","position":{"start":{"line":498,"column":1,"offset":23172},"end":{"line":498,"column":63,"offset":23234},"indent":[]}},{"type":"inlineCode","value":"config/io.xml","position":{"start":{"line":498,"column":63,"offset":23234},"end":{"line":498,"column":78,"offset":23249},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":498,"column":78,"offset":23249},"end":{"line":498,"column":183,"offset":23354},"indent":[]}}],"position":{"start":{"line":498,"column":1,"offset":23172},"end":{"line":498,"column":183,"offset":23354},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n","position":{"start":{"line":500,"column":1,"offset":23356},"end":{"line":518,"column":4,"offset":24146},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"FPS","position":{"start":{"line":520,"column":7,"offset":24154},"end":{"line":520,"column":10,"offset":24157},"indent":[]}}],"position":{"start":{"line":520,"column":1,"offset":24148},"end":{"line":520,"column":10,"offset":24157},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The frames per second of the video being recorded. Please note that this number is limited and depends heavily on your hardware setup. You'll be receiving following warning in the systems logs, if the machinery can't write the desired FPS.","position":{"start":{"line":521,"column":1,"offset":24158},"end":{"line":521,"column":240,"offset":24397},"indent":[]}}],"position":{"start":{"line":521,"column":1,"offset":24158},"end":{"line":521,"column":240,"offset":24397},"indent":[]}},{"type":"code","lang":"text","meta":null,"value":"[trivial] IoVideo: framerate is too fast, can't record video at this speed (8/FPS)","position":{"start":{"line":523,"column":1,"offset":24399},"end":{"line":525,"column":4,"offset":24493},"indent":[1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Record after","position":{"start":{"line":526,"column":7,"offset":24500},"end":{"line":526,"column":19,"offset":24512},"indent":[]}}],"position":{"start":{"line":526,"column":1,"offset":24494},"end":{"line":526,"column":19,"offset":24512},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The number of seconds recorded after the last valid event was detected. This means that when a video is already recording, and a valid event was detected, the video will be expanded with x more seconds.","position":{"start":{"line":527,"column":1,"offset":24513},"end":{"line":527,"column":203,"offset":24715},"indent":[]}}],"position":{"start":{"line":527,"column":1,"offset":24513},"end":{"line":527,"column":203,"offset":24715},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Extensions","position":{"start":{"line":529,"column":7,"offset":24723},"end":{"line":529,"column":17,"offset":24733},"indent":[]}}],"position":{"start":{"line":529,"column":1,"offset":24717},"end":{"line":529,"column":17,"offset":24733},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The extension or container of the video file. We highly recommend to use the MP4 container if you want cross-browser support. Leave this setting by default, if you don't know what you're doing.","position":{"start":{"line":530,"column":1,"offset":24734},"end":{"line":530,"column":194,"offset":24927},"indent":[]}}],"position":{"start":{"line":530,"column":1,"offset":24734},"end":{"line":530,"column":194,"offset":24927},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Codec","position":{"start":{"line":532,"column":7,"offset":24935},"end":{"line":532,"column":12,"offset":24940},"indent":[]}}],"position":{"start":{"line":532,"column":1,"offset":24929},"end":{"line":532,"column":12,"offset":24940},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The codec that is used to encode the video file.","position":{"start":{"line":533,"column":1,"offset":24941},"end":{"line":533,"column":49,"offset":24989},"indent":[]}}],"position":{"start":{"line":533,"column":1,"offset":24941},"end":{"line":533,"column":49,"offset":24989},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"File format","position":{"start":{"line":535,"column":7,"offset":24997},"end":{"line":535,"column":18,"offset":25008},"indent":[]}}],"position":{"start":{"line":535,"column":1,"offset":24991},"end":{"line":535,"column":18,"offset":25008},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The format that will be used for the name of the image. One or more variables can be defined and will be replaced by the machinery. Note that when you're using a variables name in the file format, that this name should be defined in the JSON object.","position":{"start":{"line":536,"column":1,"offset":25009},"end":{"line":536,"column":250,"offset":25258},"indent":[]}}],"position":{"start":{"line":536,"column":1,"offset":25009},"end":{"line":536,"column":250,"offset":25258},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Directory","position":{"start":{"line":538,"column":7,"offset":25266},"end":{"line":538,"column":16,"offset":25275},"indent":[]}}],"position":{"start":{"line":538,"column":1,"offset":25260},"end":{"line":538,"column":16,"offset":25275},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The directory where the videos will be saved. By default videos are saved to the /etc/opt/kerberosio/capture directory.","position":{"start":{"line":539,"column":1,"offset":25276},"end":{"line":539,"column":120,"offset":25395},"indent":[]}}],"position":{"start":{"line":539,"column":1,"offset":25276},"end":{"line":539,"column":120,"offset":25395},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Hardware directory","position":{"start":{"line":541,"column":7,"offset":25403},"end":{"line":541,"column":25,"offset":25421},"indent":[]}}],"position":{"start":{"line":541,"column":1,"offset":25397},"end":{"line":541,"column":25,"offset":25421},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When using onboard hardware encoding (e.g. with Raspberry Pi camera), h264 video files are generated and stored in this directory. Afterwards these h264 files will be containerized to mp4 files, and stored in the Directory path.","position":{"start":{"line":542,"column":1,"offset":25422},"end":{"line":542,"column":229,"offset":25650},"indent":[]}}],"position":{"start":{"line":542,"column":1,"offset":25422},"end":{"line":542,"column":229,"offset":25650},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Enable Hardware encoding","position":{"start":{"line":544,"column":7,"offset":25658},"end":{"line":544,"column":31,"offset":25682},"indent":[]}}],"position":{"start":{"line":544,"column":1,"offset":25652},"end":{"line":544,"column":31,"offset":25682},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A boolean which can enable or disable hardware encoding. Please note that this option is enabled by default, but does not mean that it will work if you choose to use an USB camera.","position":{"start":{"line":545,"column":1,"offset":25683},"end":{"line":545,"column":181,"offset":25863},"indent":[]}}],"position":{"start":{"line":545,"column":1,"offset":25683},"end":{"line":545,"column":181,"offset":25863},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Mark with timestamp","position":{"start":{"line":547,"column":7,"offset":25871},"end":{"line":547,"column":26,"offset":25890},"indent":[]}}],"position":{"start":{"line":547,"column":1,"offset":25865},"end":{"line":547,"column":26,"offset":25890},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"When this settings is set to true, the video is marked with a timestamp (similar to the Disk device).","position":{"start":{"line":548,"column":1,"offset":25891},"end":{"line":548,"column":102,"offset":25992},"indent":[]}}],"position":{"start":{"line":548,"column":1,"offset":25891},"end":{"line":548,"column":102,"offset":25992},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Timestamp color","position":{"start":{"line":550,"column":7,"offset":26000},"end":{"line":550,"column":22,"offset":26015},"indent":[]}}],"position":{"start":{"line":550,"column":1,"offset":25994},"end":{"line":550,"column":22,"offset":26015},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A color can be defined for timestamp: white, black, red, green and blue.","position":{"start":{"line":551,"column":1,"offset":26016},"end":{"line":551,"column":73,"offset":26088},"indent":[]}}],"position":{"start":{"line":551,"column":1,"offset":26016},"end":{"line":551,"column":73,"offset":26088},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Privacy","position":{"start":{"line":553,"column":7,"offset":26096},"end":{"line":553,"column":14,"offset":26103},"indent":[]}}],"position":{"start":{"line":553,"column":1,"offset":26090},"end":{"line":553,"column":14,"offset":26103},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The privacy mode can be activated to remove some parts from the video. This especially helpful if you want to filter out public areas.","position":{"start":{"line":554,"column":1,"offset":26104},"end":{"line":554,"column":135,"offset":26238},"indent":[]}}],"position":{"start":{"line":554,"column":1,"offset":26104},"end":{"line":554,"column":135,"offset":26238},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Video privacy","position":{"start":{"line":556,"column":7,"offset":26246},"end":{"line":556,"column":20,"offset":26259},"indent":[]}}],"position":{"start":{"line":556,"column":1,"offset":26240},"end":{"line":556,"column":20,"offset":26259},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"After updating the configuration, you'll see that the pixels outside your region of interest (ROI) are made black; the image below illustrates this.","position":{"start":{"line":557,"column":1,"offset":26260},"end":{"line":557,"column":149,"offset":26408},"indent":[]}}],"position":{"start":{"line":557,"column":1,"offset":26260},"end":{"line":557,"column":149,"offset":26408},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Throttler","position":{"start":{"line":559,"column":7,"offset":26416},"end":{"line":559,"column":16,"offset":26425},"indent":[]}}],"position":{"start":{"line":559,"column":1,"offset":26410},"end":{"line":559,"column":16,"offset":26425},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Video will only be triggered once in 5 seconds, nevertheless more detections occurred.","position":{"start":{"line":560,"column":1,"offset":26426},"end":{"line":560,"column":188,"offset":26613},"indent":[]}}],"position":{"start":{"line":560,"column":1,"offset":26426},"end":{"line":560,"column":188,"offset":26613},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"TCP/IP client","position":{"start":{"line":562,"column":5,"offset":26619},"end":{"line":562,"column":18,"offset":26632},"indent":[]}}],"position":{"start":{"line":562,"column":1,"offset":26615},"end":{"line":562,"column":18,"offset":26632},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The TCP/IP client will send a TCP packet to a server.","position":{"start":{"line":564,"column":1,"offset":26634},"end":{"line":564,"column":54,"offset":26687},"indent":[]}}],"position":{"start":{"line":564,"column":1,"offset":26634},"end":{"line":564,"column":54,"offset":26687},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":566,"column":6,"offset":26694},"end":{"line":566,"column":16,"offset":26704},"indent":[]}}],"position":{"start":{"line":566,"column":1,"offset":26689},"end":{"line":566,"column":16,"offset":26704},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the TCP/IP client can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":567,"column":1,"offset":26705},"end":{"line":567,"column":175,"offset":26879},"indent":[]}}],"position":{"start":{"line":567,"column":1,"offset":26705},"end":{"line":567,"column":175,"offset":26879},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n 127.0.0.1\n 1337\n it's so fluffy\n 0\n \n","position":{"start":{"line":569,"column":1,"offset":26881},"end":{"line":578,"column":4,"offset":27107},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Server","position":{"start":{"line":580,"column":7,"offset":27115},"end":{"line":580,"column":13,"offset":27121},"indent":[]}}],"position":{"start":{"line":580,"column":1,"offset":27109},"end":{"line":580,"column":13,"offset":27121},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The IP of the TCP server.","position":{"start":{"line":581,"column":1,"offset":27122},"end":{"line":581,"column":26,"offset":27147},"indent":[]}}],"position":{"start":{"line":581,"column":1,"offset":27122},"end":{"line":581,"column":26,"offset":27147},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Port","position":{"start":{"line":583,"column":7,"offset":27155},"end":{"line":583,"column":11,"offset":27159},"indent":[]}}],"position":{"start":{"line":583,"column":1,"offset":27149},"end":{"line":583,"column":11,"offset":27159},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This is the port of the TCP server.","position":{"start":{"line":584,"column":1,"offset":27160},"end":{"line":584,"column":36,"offset":27195},"indent":[]}}],"position":{"start":{"line":584,"column":1,"offset":27160},"end":{"line":584,"column":36,"offset":27195},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Message","position":{"start":{"line":586,"column":7,"offset":27203},"end":{"line":586,"column":14,"offset":27210},"indent":[]}}],"position":{"start":{"line":586,"column":1,"offset":27197},"end":{"line":586,"column":14,"offset":27210},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can send some data to a TCP server.","position":{"start":{"line":587,"column":1,"offset":27211},"end":{"line":587,"column":40,"offset":27250},"indent":[]}}],"position":{"start":{"line":587,"column":1,"offset":27211},"end":{"line":587,"column":40,"offset":27250},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Throttler","position":{"start":{"line":589,"column":7,"offset":27258},"end":{"line":589,"column":16,"offset":27267},"indent":[]}}],"position":{"start":{"line":589,"column":1,"offset":27252},"end":{"line":589,"column":16,"offset":27267},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the TCP will only be triggered once in 5 seconds, nevertheless more detections occurred.","position":{"start":{"line":590,"column":1,"offset":27268},"end":{"line":590,"column":186,"offset":27453},"indent":[]}}],"position":{"start":{"line":590,"column":1,"offset":27268},"end":{"line":590,"column":186,"offset":27453},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"GPIO","position":{"start":{"line":592,"column":5,"offset":27459},"end":{"line":592,"column":9,"offset":27463},"indent":[]}}],"position":{"start":{"line":592,"column":1,"offset":27455},"end":{"line":592,"column":9,"offset":27463},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A GPIO pin can be set as output device.","position":{"start":{"line":593,"column":1,"offset":27464},"end":{"line":593,"column":40,"offset":27503},"indent":[]}}],"position":{"start":{"line":593,"column":1,"offset":27464},"end":{"line":593,"column":40,"offset":27503},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":595,"column":6,"offset":27510},"end":{"line":595,"column":16,"offset":27520},"indent":[]}}],"position":{"start":{"line":595,"column":1,"offset":27505},"end":{"line":595,"column":16,"offset":27520},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the GPIO pin can be found in the ","position":{"start":{"line":596,"column":1,"offset":27521},"end":{"line":596,"column":52,"offset":27572},"indent":[]}},{"type":"inlineCode","value":"config/io.xml","position":{"start":{"line":596,"column":52,"offset":27572},"end":{"line":596,"column":67,"offset":27587},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":596,"column":67,"offset":27587},"end":{"line":596,"column":172,"offset":27692},"indent":[]}}],"position":{"start":{"line":596,"column":1,"offset":27521},"end":{"line":596,"column":172,"offset":27692},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n 17\n 5\n 100000\n 0\n \n","position":{"start":{"line":598,"column":1,"offset":27694},"end":{"line":607,"column":4,"offset":27900},"indent":[1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Pin","position":{"start":{"line":609,"column":7,"offset":27908},"end":{"line":609,"column":10,"offset":27911},"indent":[]}}],"position":{"start":{"line":609,"column":1,"offset":27902},"end":{"line":609,"column":10,"offset":27911},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The pin that will be triggered.","position":{"start":{"line":610,"column":1,"offset":27912},"end":{"line":610,"column":32,"offset":27943},"indent":[]}}],"position":{"start":{"line":610,"column":1,"offset":27912},"end":{"line":610,"column":32,"offset":27943},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Periods","position":{"start":{"line":612,"column":7,"offset":27951},"end":{"line":612,"column":14,"offset":27958},"indent":[]}}],"position":{"start":{"line":612,"column":1,"offset":27945},"end":{"line":612,"column":14,"offset":27958},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The number of times the pin will be triggered.","position":{"start":{"line":613,"column":1,"offset":27959},"end":{"line":613,"column":47,"offset":28005},"indent":[]}}],"position":{"start":{"line":613,"column":1,"offset":27959},"end":{"line":613,"column":47,"offset":28005},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Period time","position":{"start":{"line":615,"column":7,"offset":28013},"end":{"line":615,"column":18,"offset":28024},"indent":[]}}],"position":{"start":{"line":615,"column":1,"offset":28007},"end":{"line":615,"column":18,"offset":28024},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The time in microseconds that the pin will be set high.","position":{"start":{"line":616,"column":1,"offset":28025},"end":{"line":616,"column":56,"offset":28080},"indent":[]}}],"position":{"start":{"line":616,"column":1,"offset":28025},"end":{"line":616,"column":56,"offset":28080},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Throttler","position":{"start":{"line":618,"column":7,"offset":28088},"end":{"line":618,"column":16,"offset":28097},"indent":[]}}],"position":{"start":{"line":618,"column":1,"offset":28082},"end":{"line":618,"column":16,"offset":28097},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the GPIO will only be triggered once in 5 seconds, nevertheless more detections occurred.","position":{"start":{"line":619,"column":1,"offset":28098},"end":{"line":619,"column":187,"offset":28284},"indent":[]}}],"position":{"start":{"line":619,"column":1,"offset":28098},"end":{"line":619,"column":187,"offset":28284},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Webhook","position":{"start":{"line":621,"column":6,"offset":28291},"end":{"line":621,"column":13,"offset":28298},"indent":[]}}],"position":{"start":{"line":621,"column":1,"offset":28286},"end":{"line":621,"column":13,"offset":28298},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Detailed information (a JSON object) is send as a POST request to a webhook. The JSON object contains the number of changes, the region, the URL of the image, etc. This is useful if you want to integrate with your own application.","position":{"start":{"line":622,"column":1,"offset":28299},"end":{"line":622,"column":231,"offset":28529},"indent":[]}}],"position":{"start":{"line":622,"column":1,"offset":28299},"end":{"line":622,"column":231,"offset":28529},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Make sure that the Webhook comes after the Disk device, otherwise the URL of the image is not included.","position":{"start":{"line":624,"column":1,"offset":28531},"end":{"line":624,"column":104,"offset":28634},"indent":[]}}],"position":{"start":{"line":624,"column":1,"offset":28531},"end":{"line":624,"column":104,"offset":28634},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":626,"column":6,"offset":28641},"end":{"line":626,"column":16,"offset":28651},"indent":[]}}],"position":{"start":{"line":626,"column":1,"offset":28636},"end":{"line":626,"column":16,"offset":28651},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the webhook can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":627,"column":1,"offset":28652},"end":{"line":627,"column":169,"offset":28820},"indent":[]}}],"position":{"start":{"line":627,"column":1,"offset":28652},"end":{"line":627,"column":169,"offset":28820},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n http://kerberos.web/api/v1/webhook\n 0\n \n","position":{"start":{"line":629,"column":1,"offset":28822},"end":{"line":636,"column":4,"offset":28975},"indent":[1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Url","position":{"start":{"line":638,"column":7,"offset":28983},"end":{"line":638,"column":10,"offset":28986},"indent":[]}}],"position":{"start":{"line":638,"column":1,"offset":28977},"end":{"line":638,"column":10,"offset":28986},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"This is the URL, to which the machinery will send a JSON object (as a POST request).","position":{"start":{"line":639,"column":1,"offset":28987},"end":{"line":639,"column":85,"offset":29071},"indent":[]}}],"position":{"start":{"line":639,"column":1,"offset":28987},"end":{"line":639,"column":85,"offset":29071},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Throttler","position":{"start":{"line":641,"column":7,"offset":29079},"end":{"line":641,"column":16,"offset":29088},"indent":[]}}],"position":{"start":{"line":641,"column":1,"offset":29073},"end":{"line":641,"column":16,"offset":29088},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Webhook will only be triggered once in 5 seconds, nevertheless more detections occurred.","position":{"start":{"line":642,"column":1,"offset":29089},"end":{"line":642,"column":190,"offset":29278},"indent":[]}}],"position":{"start":{"line":642,"column":1,"offset":29089},"end":{"line":642,"column":190,"offset":29278},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Output","position":{"start":{"line":644,"column":7,"offset":29286},"end":{"line":644,"column":13,"offset":29292},"indent":[]}}],"position":{"start":{"line":644,"column":1,"offset":29280},"end":{"line":644,"column":13,"offset":29292},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A JSON object is POSTed to the url you've defined.","position":{"start":{"line":645,"column":1,"offset":29293},"end":{"line":645,"column":51,"offset":29343},"indent":[]}}],"position":{"start":{"line":645,"column":1,"offset":29293},"end":{"line":645,"column":51,"offset":29343},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"[\n 'regionCoordinates' : [618, 317, 703, 493],\n 'numberOfChanges' : 5446,\n 'timestamp' : '1465894497',\n 'microseconds' : '5-97451',\n 'token' : 695,\n 'pathToImage' : '1465894497_5-97451_frontdoor_618-317-703-493_5446_695.jpg',\n 'instanceName' : 'frontdoor',\n]","position":{"start":{"line":647,"column":1,"offset":29345},"end":{"line":657,"column":4,"offset":29622},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Script","position":{"start":{"line":659,"column":5,"offset":29628},"end":{"line":659,"column":11,"offset":29634},"indent":[]}}],"position":{"start":{"line":659,"column":1,"offset":29624},"end":{"line":659,"column":11,"offset":29634},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A bash script can be executed after a valid event was detected. A JSON object is send in the first parameter to the script you've defined.","position":{"start":{"line":660,"column":1,"offset":29635},"end":{"line":660,"column":139,"offset":29773},"indent":[]}}],"position":{"start":{"line":660,"column":1,"offset":29635},"end":{"line":660,"column":139,"offset":29773},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":662,"column":6,"offset":29780},"end":{"line":662,"column":16,"offset":29790},"indent":[]}}],"position":{"start":{"line":662,"column":1,"offset":29775},"end":{"line":662,"column":16,"offset":29790},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the Script output device can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":663,"column":1,"offset":29791},"end":{"line":663,"column":182,"offset":29972},"indent":[]}}],"position":{"start":{"line":663,"column":1,"offset":29791},"end":{"line":663,"column":182,"offset":29972},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n \n","position":{"start":{"line":665,"column":1,"offset":29974},"end":{"line":672,"column":4,"offset":30127},"indent":[1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Path","position":{"start":{"line":674,"column":7,"offset":30135},"end":{"line":674,"column":11,"offset":30139},"indent":[]}}],"position":{"start":{"line":674,"column":1,"offset":30129},"end":{"line":674,"column":11,"offset":30139},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The location of the script that will be executed on detection.","position":{"start":{"line":675,"column":1,"offset":30140},"end":{"line":675,"column":63,"offset":30202},"indent":[]}}],"position":{"start":{"line":675,"column":1,"offset":30140},"end":{"line":675,"column":63,"offset":30202},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Throttler","position":{"start":{"line":677,"column":7,"offset":30210},"end":{"line":677,"column":16,"offset":30219},"indent":[]}}],"position":{"start":{"line":677,"column":1,"offset":30204},"end":{"line":677,"column":16,"offset":30219},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Script will only be triggered once in 5 seconds, nevertheless more detections occurred.","position":{"start":{"line":678,"column":1,"offset":30220},"end":{"line":678,"column":189,"offset":30408},"indent":[]}}],"position":{"start":{"line":678,"column":1,"offset":30220},"end":{"line":678,"column":189,"offset":30408},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Example","position":{"start":{"line":680,"column":7,"offset":30416},"end":{"line":680,"column":14,"offset":30423},"indent":[]}}],"position":{"start":{"line":680,"column":1,"offset":30410},"end":{"line":680,"column":14,"offset":30423},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default the script will point to /etc/opt/kerberosio/scripts/run.sh, which contains a template how you should start your script. Note that when using KiOS, this script will be read-only, copy it to the /data folder and change the path parameter.","position":{"start":{"line":681,"column":1,"offset":30424},"end":{"line":681,"column":249,"offset":30672},"indent":[]}}],"position":{"start":{"line":681,"column":1,"offset":30424},"end":{"line":681,"column":249,"offset":30672},"indent":[]}},{"type":"code","lang":"python","meta":null,"value":"#!/bin/bash\n# -------------------------------------------\n# This is an example script which illustrates\n# how to use the Script IO device.\n#\n# --------------------------------------\n# The first parameter is the JSON object\n#\n# e.g. {\"regionCoordinates\":[308,250,346,329],\"numberOfChanges\":194,\"timestamp\":\"1486049622\",\"microseconds\":\"6-161868\",\"token\":344,\"pathToImage\":\"1486049622_6-161868_frontdoor_308-250-346-329_194_344.jpg\",\"instanceName\":\"frontdoor\"}\nJSON=$1\n# -------------------------------------------\n# You can use python to parse the JSON object\n# and get the required fields\nname=$(echo $JSON | python -c \"import sys, json; print json.load(sys.stdin)['instanceName']\")\ncoordinates=$(echo $JSON | python -c \"import sys, json; print json.load(sys.stdin)['regionCoordinates']\")\nchanges=$(echo $JSON | pythfon -c \"import sys, json; print json.load(sys.stdin)['numberOfChanges']\")\nimage=$(echo $JSON | python -c \"import sys, json; print json.load(sys.stdin)['pathToImage']\")\nThe idea is that you can use Python in your bash script, to parse the JSON object send as first parameter. Afterwards you can do with the output what you want.","position":{"start":{"line":683,"column":1,"offset":30674},"end":{"line":702,"column":4,"offset":31830},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"MQTT","position":{"start":{"line":704,"column":5,"offset":31836},"end":{"line":704,"column":9,"offset":31840},"indent":[]}}],"position":{"start":{"line":704,"column":1,"offset":31832},"end":{"line":704,"column":9,"offset":31840},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"MQTT protocol is a light-weight Machine to Machine (M2M) protocol widely used in Internet of things.\nDetailed information (a JSON object) is published to an MQTT topic. The JSON object contains the number of changes, the region, the URL of the image, etc.","position":{"start":{"line":705,"column":1,"offset":31841},"end":{"line":706,"column":155,"offset":32096},"indent":[1]}}],"position":{"start":{"line":705,"column":1,"offset":31841},"end":{"line":706,"column":155,"offset":32096},"indent":[1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":708,"column":6,"offset":32103},"end":{"line":708,"column":16,"offset":32113},"indent":[]}}],"position":{"start":{"line":708,"column":1,"offset":32098},"end":{"line":708,"column":16,"offset":32113},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters of the MQTT output can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.","position":{"start":{"line":709,"column":1,"offset":32114},"end":{"line":709,"column":173,"offset":32286},"indent":[]}}],"position":{"start":{"line":709,"column":1,"offset":32114},"end":{"line":709,"column":173,"offset":32286},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n false\n false\n 127.0.0.1\n 1883\n kios/mqtt\n \n \n 0\n \n","position":{"start":{"line":711,"column":1,"offset":32288},"end":{"line":724,"column":4,"offset":32652},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Secure","position":{"start":{"line":726,"column":7,"offset":32660},"end":{"line":726,"column":13,"offset":32666},"indent":[]}}],"position":{"start":{"line":726,"column":1,"offset":32654},"end":{"line":726,"column":13,"offset":32666},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If checked, enable SSL/TLS support. Please note that when SSL/TLS support is enabled, the server certificate issuer is verified against the CA (Certification Authority) files available in /etc/ssl/certs.","position":{"start":{"line":727,"column":1,"offset":32667},"end":{"line":727,"column":204,"offset":32870},"indent":[]}}],"position":{"start":{"line":727,"column":1,"offset":32667},"end":{"line":727,"column":204,"offset":32870},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Verifycn","position":{"start":{"line":729,"column":7,"offset":32878},"end":{"line":729,"column":15,"offset":32886},"indent":[]}}],"position":{"start":{"line":729,"column":1,"offset":32872},"end":{"line":729,"column":15,"offset":32886},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If checked, the MQTT server FQDN or ip address must match the CN (Common Name) of the server certificate.","position":{"start":{"line":730,"column":1,"offset":32887},"end":{"line":730,"column":106,"offset":32992},"indent":[]}}],"position":{"start":{"line":730,"column":1,"offset":32887},"end":{"line":730,"column":106,"offset":32992},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Server","position":{"start":{"line":732,"column":7,"offset":33000},"end":{"line":732,"column":13,"offset":33006},"indent":[]}}],"position":{"start":{"line":732,"column":1,"offset":32994},"end":{"line":732,"column":13,"offset":33006},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"IP address or FQDN of the MQTT broker.","position":{"start":{"line":733,"column":1,"offset":33007},"end":{"line":733,"column":39,"offset":33045},"indent":[]}}],"position":{"start":{"line":733,"column":1,"offset":33007},"end":{"line":733,"column":39,"offset":33045},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Port","position":{"start":{"line":735,"column":7,"offset":33053},"end":{"line":735,"column":11,"offset":33057},"indent":[]}}],"position":{"start":{"line":735,"column":1,"offset":33047},"end":{"line":735,"column":11,"offset":33057},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"TCP port of the MQTT broker.","position":{"start":{"line":736,"column":1,"offset":33058},"end":{"line":736,"column":29,"offset":33086},"indent":[]}}],"position":{"start":{"line":736,"column":1,"offset":33058},"end":{"line":736,"column":29,"offset":33086},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Topic","position":{"start":{"line":738,"column":7,"offset":33094},"end":{"line":738,"column":12,"offset":33099},"indent":[]}}],"position":{"start":{"line":738,"column":1,"offset":33088},"end":{"line":738,"column":12,"offset":33099},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The topic to publish to.","position":{"start":{"line":739,"column":1,"offset":33100},"end":{"line":739,"column":25,"offset":33124},"indent":[]}}],"position":{"start":{"line":739,"column":1,"offset":33100},"end":{"line":739,"column":25,"offset":33124},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Username","position":{"start":{"line":741,"column":7,"offset":33132},"end":{"line":741,"column":15,"offset":33140},"indent":[]}}],"position":{"start":{"line":741,"column":1,"offset":33126},"end":{"line":741,"column":15,"offset":33140},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The username for authenticating to the MQTT broker. This is only supported by brokers that implement the MQTT spec v3.1. If username is not set (empty), the password argument is ignored. This is only needed if the MQTT broker is configured for authentication.","position":{"start":{"line":742,"column":1,"offset":33141},"end":{"line":742,"column":260,"offset":33400},"indent":[]}}],"position":{"start":{"line":742,"column":1,"offset":33141},"end":{"line":742,"column":260,"offset":33400},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Password","position":{"start":{"line":744,"column":7,"offset":33408},"end":{"line":744,"column":15,"offset":33416},"indent":[]}}],"position":{"start":{"line":744,"column":1,"offset":33402},"end":{"line":744,"column":15,"offset":33416},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The password to use, together with the username, for authenticating to the MQTT broker. This is only supported by brokers that implement the MQTT spec v3.1. This is only needed if the MQTT broker is configured for authentication.","position":{"start":{"line":745,"column":1,"offset":33417},"end":{"line":745,"column":230,"offset":33646},"indent":[]}}],"position":{"start":{"line":745,"column":1,"offset":33417},"end":{"line":745,"column":230,"offset":33646},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Throttler","position":{"start":{"line":747,"column":7,"offset":33654},"end":{"line":747,"column":16,"offset":33663},"indent":[]}}],"position":{"start":{"line":747,"column":1,"offset":33648},"end":{"line":747,"column":16,"offset":33663},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the MQTT will only be triggered once in 5 seconds, nevertheless more detections occurred.","position":{"start":{"line":748,"column":1,"offset":33664},"end":{"line":748,"column":187,"offset":33850},"indent":[]}}],"position":{"start":{"line":748,"column":1,"offset":33664},"end":{"line":748,"column":187,"offset":33850},"indent":[]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Output","position":{"start":{"line":750,"column":7,"offset":33858},"end":{"line":750,"column":13,"offset":33864},"indent":[]}}],"position":{"start":{"line":750,"column":1,"offset":33852},"end":{"line":750,"column":13,"offset":33864},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A JSON object is published to the topic of the MQTT broker you have configured.","position":{"start":{"line":751,"column":1,"offset":33865},"end":{"line":751,"column":80,"offset":33944},"indent":[]}}],"position":{"start":{"line":751,"column":1,"offset":33865},"end":{"line":751,"column":80,"offset":33944},"indent":[]}},{"type":"code","lang":"json","meta":null,"value":"[\n 'regionCoordinates' : [618, 317, 703, 493],\n 'numberOfChanges' : 5446,\n 'timestamp' : '1465894497',\n 'microseconds' : '5-97451',\n 'token' : 695,\n 'pathToImage' : '1465894497_5-97451_frontdoor_618-317-703-493_5446_695.jpg',\n 'instanceName' : 'frontdoor',\n]","position":{"start":{"line":753,"column":1,"offset":33946},"end":{"line":763,"column":4,"offset":34223},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":5,"children":[{"type":"text","value":"Example","position":{"start":{"line":765,"column":7,"offset":34231},"end":{"line":765,"column":14,"offset":34238},"indent":[]}}],"position":{"start":{"line":765,"column":1,"offset":34225},"end":{"line":765,"column":14,"offset":34238},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It is possible to subscribe multiple distributed IoT devices to the same MQTT topic and perform specific actions upon the detection of a motion. Devices with more resources could fetch the image to perform further elaboration.","position":{"start":{"line":766,"column":1,"offset":34239},"end":{"line":766,"column":227,"offset":34465},"indent":[]}}],"position":{"start":{"line":766,"column":1,"offset":34239},"end":{"line":766,"column":227,"offset":34465},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Streaming","position":{"start":{"line":768,"column":4,"offset":34470},"end":{"line":768,"column":13,"offset":34479},"indent":[]}}],"position":{"start":{"line":768,"column":1,"offset":34467},"end":{"line":768,"column":13,"offset":34479},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The machinery has the ability to stream your capture device as a MJPG stream.","position":{"start":{"line":770,"column":1,"offset":34481},"end":{"line":770,"column":78,"offset":34558},"indent":[]}}],"position":{"start":{"line":770,"column":1,"offset":34481},"end":{"line":770,"column":78,"offset":34558},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Parameters","position":{"start":{"line":772,"column":5,"offset":34564},"end":{"line":772,"column":15,"offset":34574},"indent":[]}}],"position":{"start":{"line":772,"column":1,"offset":34560},"end":{"line":772,"column":15,"offset":34574},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The parameters for the supported streaming protocols can be found in the ","position":{"start":{"line":774,"column":1,"offset":34576},"end":{"line":774,"column":74,"offset":34649},"indent":[]}},{"type":"inlineCode","value":"config/stream.xml","position":{"start":{"line":774,"column":74,"offset":34649},"end":{"line":774,"column":93,"offset":34668},"indent":[]}},{"type":"text","value":" file, but you can also use the web to modify the parameters. Below you see a default configuration file; at the moment of writing only a MJPG stream is supported.","position":{"start":{"line":774,"column":93,"offset":34668},"end":{"line":774,"column":256,"offset":34831},"indent":[]}}],"position":{"start":{"line":774,"column":1,"offset":34576},"end":{"line":774,"column":256,"offset":34831},"indent":[]}},{"type":"code","lang":"xml","meta":null,"value":"\n\t\n \ttrue\n \t8889\n \t75\n \t\n \t75\n \n","position":{"start":{"line":776,"column":1,"offset":34833},"end":{"line":786,"column":4,"offset":35099},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Enabled","position":{"start":{"line":788,"column":6,"offset":35106},"end":{"line":788,"column":13,"offset":35113},"indent":[]}}],"position":{"start":{"line":788,"column":1,"offset":35101},"end":{"line":788,"column":13,"offset":35113},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A boolean which turns ON/OFF the stream. This is interesting when working with IP cameras, where you already have an RTSP/MJPG stream from the camera itself.","position":{"start":{"line":790,"column":1,"offset":35115},"end":{"line":790,"column":158,"offset":35272},"indent":[]}}],"position":{"start":{"line":790,"column":1,"offset":35115},"end":{"line":790,"column":158,"offset":35272},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Stream Port","position":{"start":{"line":792,"column":6,"offset":35279},"end":{"line":792,"column":17,"offset":35290},"indent":[]}}],"position":{"start":{"line":792,"column":1,"offset":35274},"end":{"line":792,"column":17,"offset":35290},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The port on which the stream is available.","position":{"start":{"line":794,"column":1,"offset":35292},"end":{"line":794,"column":43,"offset":35334},"indent":[]}}],"position":{"start":{"line":794,"column":1,"offset":35292},"end":{"line":794,"column":43,"offset":35334},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Quality","position":{"start":{"line":796,"column":6,"offset":35341},"end":{"line":796,"column":13,"offset":35348},"indent":[]}}],"position":{"start":{"line":796,"column":1,"offset":35336},"end":{"line":796,"column":13,"offset":35348},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"The quality is a value between ","position":{"start":{"line":798,"column":1,"offset":35350},"end":{"line":798,"column":32,"offset":35381},"indent":[]}},{"type":"linkReference","identifier":"0-100","label":"0-100","referenceType":"shortcut","children":[{"type":"text","value":"0-100","position":{"start":{"line":798,"column":33,"offset":35382},"end":{"line":798,"column":38,"offset":35387},"indent":[]}}],"position":{"start":{"line":798,"column":32,"offset":35381},"end":{"line":798,"column":39,"offset":35388},"indent":[]}},{"type":"text","value":". The lower the quality, the more the image will be compressed. If you're using the RaspberryPi Camera module, this option will be ignored.","position":{"start":{"line":798,"column":39,"offset":35388},"end":{"line":798,"column":178,"offset":35527},"indent":[]}}],"position":{"start":{"line":798,"column":1,"offset":35350},"end":{"line":798,"column":178,"offset":35527},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Username/password","position":{"start":{"line":800,"column":6,"offset":35534},"end":{"line":800,"column":23,"offset":35551},"indent":[]}}],"position":{"start":{"line":800,"column":1,"offset":35529},"end":{"line":800,"column":23,"offset":35551},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can secure the MJPEG streaming with a username and password. These credentials will be used to authorize your requests using Basic Authentication. Please note that once enabled, the live stream on the dashboard page can fail; however it will work if you open it directly in your browser or ip camera client. The format of the streaming url, after authentication enabled, will look as following:","position":{"start":{"line":802,"column":1,"offset":35553},"end":{"line":802,"column":399,"offset":35951},"indent":[]}}],"position":{"start":{"line":802,"column":1,"offset":35553},"end":{"line":802,"column":399,"offset":35951},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://username:password@ip-camera:8899","position":{"start":{"line":804,"column":1,"offset":35953},"end":{"line":806,"column":4,"offset":36002},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":809,"column":1,"offset":36005},"end":{"line":809,"column":31,"offset":36035},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":809,"column":31,"offset":36035}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport { Playground, Props } from 'docz'\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Machinery`}

\n

{`The machinery is the processing engine of Kerberos Open Source. It's an image processing framework, written in C++, who benefits from other third party libraries (OpenCV, etc). It takes images from the type of camera (USB-, IP- or RPi-camera) you've configured in the configuration files and executes one ore more algorithms and post-processes (e.g. save a snapshot). The configuration files allow you to define the type of camera, post-processes, conditions and much more; it's highly configurable. It's important to note that the machinery, out-of-the-box, can handle only one camera at a time.`}

\n

{`Project structure`}

\n

{`The machinery is an image processing framework which is devided into four steps:`}

\n
    \n
  • {`condition`}
  • \n
  • {`algorithm`}
  • \n
  • {`expositor`}
  • \n
  • {`heuristic`}
  • \n
\n

{`The steps belong to a four passway; illustrated on the image below. In each cycle a sequence of images is processed. Each step will process the sequence, and will return some result to the next step. For example: an algorithm will process the images and returns an array to the Expositor, which contains boolean values. The steps are loosly coupled, so they have simple conventions, just like the example before.`}

\n

{`Thanks to the loosly coupling, each step can be developed indepently. So algorithms, expositors, heuristics and conditions can be switched on the fly. This makes it easier for other developers who want to contribute to the machinery. They can create a new algorithm without knowing how a specific expositor or heuristic works. They just need to be aware of the convention an algorithm should meet.`}

\n

\"machinery

\n

{`These different steps can be configured by editing a couple of configurationn files located at `}{`config/`}{`. The main configuration file `}{`config/config.xml`}{` looks like this:`}

\n
{`{`xml`}{` version`}{`=`}{`\"1.0\"`}{`?>`}{`\n`}{`<`}{`kerberos`}{`>`}{`\n`}{`  `}{`<`}{`instance`}{`>`}{`\n`}{`    `}{`<`}{`name`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`frontdoor`}{`{`name`}{`>`}{`\n`}{`    `}{`<`}{`logging`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`false`}{`{`logging`}{`>`}{`\n`}{`    `}{`<`}{`timezone`}{` `}{`type`}{`=`}{`\"timezone\"`}{`>`}{`Europe-Brussels`}{`{`timezone`}{`>`}{`\n`}{`    `}{`<`}{`capture`}{` `}{`file`}{`=`}{`\"capture.xml\"`}{`>`}{`RaspiCamera`}{`{`capture`}{`>`}{`\n`}{`    `}{`<`}{`stream`}{` `}{`file`}{`=`}{`\"stream.xml\"`}{`>`}{`Mjpg`}{`{`stream`}{`>`}{`\n`}{`    `}{`<`}{`condition`}{` `}{`file`}{`=`}{`\"condition.xml\"`}{` `}{`type`}{`=`}{`\"multiple\"`}{`>`}{`Enabled`}{`{`condition`}{`>`}{`\n`}{`    `}{`<`}{`algorithm`}{` `}{`file`}{`=`}{`\"algorithm.xml\"`}{`>`}{`DifferentialCollins`}{`{`algorithm`}{`>`}{`\n`}{`    `}{`<`}{`expositor`}{` `}{`file`}{`=`}{`\"expositor.xml\"`}{`>`}{`Hull`}{`{`expositor`}{`>`}{`\n`}{`    `}{`<`}{`heuristic`}{` `}{`file`}{`=`}{`\"heuristic.xml\"`}{`>`}{`Sequence`}{`{`heuristic`}{`>`}{`\n`}{`    `}{`<`}{`io`}{` `}{`file`}{`=`}{`\"io.xml\"`}{` `}{`type`}{`=`}{`\"multiple\"`}{`>`}{`Video`}{`{`io`}{`>`}{`\n`}{`    `}{`<`}{`cloud`}{` `}{`file`}{`=`}{`\"cloud.xml\"`}{`>`}{`S3`}{`{`cloud`}{`>`}{`\n`}{`  `}{`{`instance`}{`>`}{`\n`}{`{`kerberos`}{`>`}
\n

{`Capture`}

\n

{`You can choose which capture device you will be using, you can use your old USB webcam, the popular Raspberry Pi camera or a state-of-the-art IP camera. The capture device will take pictures and deliver them to the algorithm if the conditions (the first step of the four passway) are valid.`}

\n

{`You can change the capture device by changing the `}{`config/config.xml`}{` file, and choose one of the following:`}

\n
    \n
  • {`USBCamera`}
  • \n
  • {`RaspiCamera`}
  • \n
  • {`IPCamera`}
  • \n
\n
{`{`xml`}{` version`}{`=`}{`\"1.0\"`}{`?>`}{`\n`}{`<`}{`kerberos`}{`>`}{`\n`}{`  `}{`<`}{`instance`}{`>`}{`\n`}{`    ...`}{`\n`}{`    `}{`<`}{`capture`}{` `}{`file`}{`=`}{`\"capture.xml\"`}{`>`}{`RaspiCamera`}{`{`capture`}{`>`}{`\n`}{`    ...`}{`\n`}{`  `}{`{`instance`}{`>`}{`\n`}{`{`kerberos`}{`>`}
\n

{`USB camera`}

\n

{`The machinery supports a whole range of USB cameras. You will find a complete list here. Make sure you have updated the web interface, to make the machinery aware you will be using an USB camera.`}

\n

{`Parameters`}

\n

{`The parameters of the USB camera can be found in the `}{`config/capture.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`captures`}{`>`}{`\n`}{`  `}{`<`}{`USBCamera`}{`>`}{`\n`}{`    `}{`<`}{`frameWidth`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`1280`}{`{`frameWidth`}{`>`}{`\n`}{`    `}{`<`}{`frameHeight`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`720`}{`{`frameHeight`}{`>`}{`\n`}{`    `}{`<`}{`deviceNumber`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`deviceNumber`}{`>`}{`\n`}{`    `}{`<`}{`delay`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`delay`}{`>`}{`\n`}{`    `}{`<`}{`angle`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`angle`}{`>`}{`\n`}{`  `}{`{`USBCamera`}{`>`}{`\n`}{`{`captures`}{`>`}
\n
{`Framewidth and -height`}
\n

{`You can set the resolution of the capture device, make sure the resolution you've defined is valid with your camera. Please check the specs of the USB camera you're using.`}

\n
{`Device number`}
\n

{`If more than one device is connected, you can specify the index of the USB-camera. The index is an integer (1-5).`}

\n
{`Delay`}
\n

{`You can provide a delay/interval (milliseconds) between two captures.`}

\n
{`Angle`}
\n

{`By defining an angle (degrees), you can rotate the images taken by the capture device. For example if you would mount the camera upside down, than you could enter the value 180 as the angle; this will flip the images.`}

\n

{`Raspberry Pi Camera Module`}

\n

{`You can use the Raspberry Pi Camera Module with the machinery. You just need to attach the camera module and you're ready to go. The Raspberry Pi Camera Module is enabled by default in the web.`}

\n

{`Parameters`}

\n

{`The parameters of the Raspberry Pi Camera Module can be found in the config/capture.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`captures`}{`>`}{`\n`}{`  `}{`<`}{`RaspiCamera`}{`>`}{`\n`}{`    `}{`<`}{`frameWidth`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`640`}{`{`frameWidth`}{`>`}{`\n`}{`    `}{`<`}{`frameHeight`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`480`}{`{`frameHeight`}{`>`}{`\n`}{`    `}{`<`}{`delay`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`1400`}{`{`delay`}{`>`}{`\n`}{`    `}{`<`}{`angle`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`angle`}{`>`}{`\n`}{`    `}{`<`}{`framerate`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`30`}{`{`framerate`}{`>`}{`\n`}{`    `}{`<`}{`sharpness`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`sharpness`}{`>`}{`\n`}{`    `}{`<`}{`saturation`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`saturation`}{`>`}{`\n`}{`    `}{`<`}{`contrast`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`contrast`}{`>`}{`\n`}{`    `}{`<`}{`brightness`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`50`}{`{`brightness`}{`>`}{`\n`}{`  `}{`{`RaspiCamera`}{`>`}{`\n`}{`{`captures`}{`>`}
\n
{`Framewidth and -height`}
\n

{`You can set the resolution of the camera module, make sure the resolution you've defined is valid.`}

\n
{`Delay`}
\n

{`You can provide a delay/interval (milliseconds) between two captures.`}

\n
{`Angle`}
\n

{`By defining an angle (degrees), you can rotate the images taken by the capture device. For example if you would mount the camera upside down, than you could enter the value 180 as the angle; this will flip the images.`}

\n
{`Framerate`}
\n

{`The number of frames captures per second. Please note that this parameter will also be used if you're recording video. E.g. if you set this parameter to 20, you're recorded videos will also be 20 FPS.`}

\n
{`Sharpness, saturation, contrast, brightness`}
\n

{`Camera properties which you can specify to tune the settings to your needs.`}

\n

{`IP camera`}

\n

{`The machinery can be used with any IP camera, that provides a RTSP (or MJPEG) stream. Make sure that you know the correct URL of your IP camera, you can `}{`find a list here`}{`.`}

\n

{`Parameters`}

\n

{`The parameters of the IP capture device can be found in the `}{`config/capture.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`captures`}{`>`}{`\n`}{`  `}{`<`}{`IPCamera`}{`>`}{`\n`}{`    `}{`<`}{`url`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`http://username:password@ipaddress/image.jpg`}{`{`url`}{`>`}{`\n`}{`    `}{`<`}{`frameWidth`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`800`}{`{`frameWidth`}{`>`}{`\n`}{`    `}{`<`}{`frameHeight`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`640`}{`{`frameHeight`}{`>`}{`\n`}{`    `}{`<`}{`delay`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`delay`}{`>`}{`\n`}{`    `}{`<`}{`angle`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`angle`}{`>`}{`\n`}{`  `}{`{`IPCamera`}{`>`}{`\n`}{`{`captures`}{`>`}
\n
{`URL`}
\n

{`To use your IP camera, you should provide a valid RTSP (or MJPEG) URL. The machinery will take snapshots from this stream.`}

\n
{`Framewidth and -height`}
\n

{`You can set the resolution of the capture device, make sure the resolution you've defined is equal to the resolution you've defined in your IP-camera software.`}

\n
{`Delay`}
\n

{`You can provide a delay/interval (milliseconds) between two captures.`}

\n
{`Angle`}
\n

{`By defining an angle (degrees), you can rotate the images taken by the capture device. For example if you would mount the camera upside down, than you could enter the value 180 as the angle; this will flip the images.`}

\n

{`Condition`}

\n

{`The condition is the first step of the four passway. In this step the machinery will determine if it's allowed to proceed to the next step. For example a condition can be a time constraint, a brightness threshold, etc; multiple conditions can be selected.`}

\n
{`{`xml`}{` version`}{`=`}{`\"1.0\"`}{`?>`}{`\n`}{`<`}{`kerberos`}{`>`}{`\n`}{`  `}{`<`}{`instance`}{`>`}{`\n`}{`    ...`}{`\n`}{`    `}{`<`}{`condition`}{` `}{`file`}{`=`}{`\"condition.xml\"`}{` `}{`type`}{`=`}{`\"multiple\"`}{`>`}{`Enabled`}{`{`condition`}{`>`}{`\n`}{`    ...`}{`\n`}{`  `}{`{`instance`}{`>`}{`\n`}{`{`kerberos`}{`>`}
\n

{`Enabled`}

\n

{`It can be helpful to enable or disable the machinery at specific times. Therefore the time condition makes it possible to select a time range for each day of the week. When the current time is within the time range, the machinery will be enabled.`}

\n

{`Parameters`}

\n

{`The parameters of the Enabled condition can be found in the `}{`config/condition.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`conditions`}{`>`}{`\n`}{`  `}{`<`}{`Enabled`}{`>`}{`\n`}{`    `}{`<`}{`active`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`true`}{`{`active`}{`>`}{`\n`}{`    `}{`<`}{`delay`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`5000`}{`{`delay`}{`>`}{`\n`}{`  `}{`{`Enabled`}{`>`}{`\n`}{`{`conditions`}{`>`}
\n
{`Active`}
\n

{`The active field is boolean value (true/false). When the active field is true, the machinery is enabled, if not it's disabled.`}

\n
{`Delay`}
\n

{`The delay value is used when the condition failed, so when the current time isn't in the selected time range for that day. In that case the machinery will idle for the specified delay time. The value of the delay is expressed in miliseconds.`}

\n

{`Time`}

\n

{`It can be helpful to enable or disable the machinery at specific times. Therefore the time condition makes it possible to select a time range for each day of the week. When the current time is within the time range, the machinery will be enabled.`}

\n

{`Parameters`}

\n

{`The parameters of the Time condition can be found in the `}{`config/condition.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`conditions`}{`>`}{`\n`}{`  `}{`<`}{`Time`}{`>`}{`\n`}{`    `}{`<`}{`times`}{` `}{`type`}{`=`}{`\"timeselection\"`}{`>`}{`13:00,15:00-0:01,20:58-0:01,20:59-0:01,19:20-0:01,21:59-0,0-0,0`}{`{`times`}{`>`}{`\n`}{`    `}{`<`}{`delay`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`10000`}{`{`delay`}{`>`}{`\n`}{`  `}{`{`Time`}{`>`}{`\n`}{`{`conditions`}{`>`}
\n
{`Times`}
\n

{`The times property contains a list of times, delimited by a \"-\". The first item in the list will specify the time range for the first day of the week (Monday), the last item for the last day of the week (Sunday). The begin- and end-time, for a specific day, are delimited by a \",\" where the first element will specify that start time and the second one specifies the end time.`}

\n
{`Delay`}
\n

{`The delay value is used when the condition failed, so when the current time isn't in the selected time range for that day. In that case the machinery will idle for the specified delay time. The value of the delay is expressed in miliseconds.`}

\n

{`Algorithm`}

\n

{`The algorithm is the second step of the four passway. An algorithm will execute some kind of function on a sequence of images, and end up with a black and white image; just like the image below. An example of an algorithm would be one that does motion detection or one that would detect cats or dogs (using TensorFlow, ar any other Deep Learning framework).`}

\n

\"machinery

\n

{`The white pixels on the image will indicate the object of interest. For example, when looking for motion, the pixels that have been changed; it depends on what the algorithm is looking for. The black pixels are background pixels.`}

\n

{`The only convention that an algorithm should meet is that it should return a black and white image to the next step; the expositor. And of course that it requires a sequence of images as a parameter. Besides those conventions, an algorithm can do everything it wants to do. So you could create your own cat detection algorithm, marker detection, etc.`}

\n

{`You can select the algortihm in the `}{`config/config.xml`}{`.`}

\n
{`{`xml`}{` version`}{`=`}{`\"1.0\"`}{`?>`}{`\n`}{`<`}{`kerberos`}{`>`}{`\n`}{`  `}{`<`}{`instance`}{`>`}{`\n`}{`    ...`}{`\n`}{`    `}{`<`}{`algorithm`}{` `}{`file`}{`=`}{`\"algorithm.xml\"`}{`>`}{`DifferentialCollins`}{`{`algorithm`}{`>`}{`\n`}{`    ...`}{`\n`}{`  `}{`{`instance`}{`>`}{`\n`}{`{`kerberos`}{`>`}
\n

{`Differential images`}

\n

{`This algorithm is a very simple method to detect motion; in terms of understanding but also processing. Just like the name says, it's the result of comparing images. When the images are compared, we know the pixels that have been changed and if the amount of pixels that changed is big enough, one can say that something happened and thus motion was detected.`}

\n

{`To get a more technical explanation: the algoritm will substract 2 or more images, and once that is done it will end up with a black and white image. The white pixels will mark the pixels that where different/changed and the black pixels are the pixels that have not changed; background pixels. Please note that there are several different combinations of substracting images. However for the machinery, we will use the method of Collins et al. as this method erases the phenomenon \"ghosting\".`}

\n

\"machinery

\n

{`In the image above the method of Collins et al. is illustrated. For this method we will process three images. The images are a sequence (from left to right), so the first (A) image was taken before the second (B) one, and the second (B) before the third (C) one. Next we will do a first comparision (C-B) of the third (C) image and the second (B) image, and after that we will do a second comparison (C-A) of the third (C) image and first (A) image.`}

\n

{`After the comparison we will end up with two difference images (C-B) and (C-A); both will mark the white pixels as changed pixels and black as non-changed pixels. To finish the algorithm we will do a logical AND-operation of the two difference images; this will give us the final black and white image ((C-B)&&(C-A)).`}

\n

{`The main idea of the Colins et al. method, is that it will erase \"ghosting\". In the last step we are doing a logical AND-operation, by doing this we will only keep the pixels, that changed in the first two images; therefore we can elimante false positives.`}

\n

{`Parameters`}

\n

{`The parameters of the Differential images algorithm can be found in the config/algorithm.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`algorithms`}{`>`}{`\n`}{`  `}{`<`}{`DifferentialCollins`}{`>`}{`\n`}{`    `}{`<`}{`erode`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`5`}{`{`erode`}{`>`}{`\n`}{`    `}{`<`}{`threshold`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`20`}{`{`threshold`}{`>`}{`\n`}{`  `}{`{`DifferentialCollins`}{`>`}{`\n`}{`{`algorithms`}{`>`}
\n
{`Erode`}
\n

{`The erode parameter represents a structural element (a morphological operation), which will be used to minimize the changed pixels; more information about eroding can be found here. The idea of the eroding is that pixels which are isolated will be removed; this means that when only one pixel changed, that pixel will reverted to the non-changed state. But for example when a large change happens and a lot of adjacent pixels are changed, the eroding will not be able to revert them.`}

\n

{`The higher the number of the erode parameter, the more aggressive the eroding will be. So high erode values, will make it possible that also large changes will be reverted to the non-changed state.`}

\n
{`Threshold`}
\n

{`When doing the comparison of two images, we won't end up with a clean black and white image. In most of the cases the values will be between 0 and 255; so gray values. This means that the value 0 will mean that both pixels where the same in both image, and values 255 mean that both pixels where totally different in both images. Of course we will also have values between 0-255, so pixels that are a little bit different in both images. So to make the resulting black and white image, we will need to apply a threshold value.`}

\n

{`The threshold will specify how much a pixel has to be different in the two images. So for example when the threshold is 30, it means that the difference between two pixels has to be equal or more then 30. The higher the threshold the more the pixel needs to be different, to be marked as changed.`}

\n

{`Expositor`}

\n

{`After the algorithm is executed, the expositor will determine, a region, where the changes were detected. An expositor can constrain a region in terms of selecting a hull or defining a rectangle.`}

\n

{`An expositor receives a black and white image as parameter and should modify a JSON object with all the information it processed. The JSON object must include: the bounding rectangle(s) of the positions where the pixels of interest are located and the number of pixels of interest. But can also include other optional parameters.`}

\n

{`You can change the expositor by changing the `}{`config/config.xml`}{` file, and choose one of the following:`}

\n
    \n
  • {`Hull`}
  • \n
  • {`Rectangle`}
  • \n
\n
{`{`xml`}{` version`}{`=`}{`\"1.0\"`}{`?>`}{`\n`}{`<`}{`kerberos`}{`>`}{`\n`}{`  `}{`<`}{`instance`}{`>`}{`\n`}{`    ...`}{`\n`}{`    `}{`<`}{`expositor`}{` `}{`file`}{`=`}{`\"expositor.xml\"`}{`>`}{`Hull`}{`{`expositor`}{`>`}{`\n`}{`    ...`}{`\n`}{`  `}{`{`instance`}{`>`}{`\n`}{`{`kerberos`}{`>`}
\n

{`Rectangle`}

\n

{`This is a trivial expositor. A rectangle region can be defined to constrain the locations of pixels of interest. The rectangle repositor will return the region of the pixels of interest.`}

\n

{`Parameters`}

\n

{`The parameters of the rectangle expositor can be found in the config/expositor.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`expositors`}{`>`}{`\n`}{`  `}{`<`}{`Rectangle`}{`>`}{`\n`}{`    `}{`<`}{`region`}{`>`}{`\n`}{`      `}{`<`}{`x1`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`x1`}{`>`}{`\n`}{`      `}{`<`}{`y1`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`y1`}{`>`}{`\n`}{`      `}{`<`}{`x2`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`1280`}{`{`x2`}{`>`}{`\n`}{`      `}{`<`}{`y2`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`720`}{`{`y2`}{`>`}{`\n`}{`    `}{`{`region`}{`>`}{`\n`}{`  `}{`{`Rectangle`}{`>`}{`\n`}{`{`expositors`}{`>`}
\n
{`Region`}
\n

{`The region parameter contains 4 values; x1, y1, x2 and y2 respectively. The values x1 and y1 indicate the x- and y-coordinate of the left upper starting point. The values x2 and y2 are the bottom right coordinates. A virtual rectangle will be drawn from (x1,y1) to (x2,y2). Pixels of interest that lie within this rectangle are valid pixels; if not they are invalid.`}

\n

{`Hull`}

\n

{`This hull is a more complex expositor than the rectangle. A hull can be selected with the web, you can select one or more coordinates to create a flexible region. The coordinates can be adjusted afterwards and be removed by double clicking on the coordinate. You can expand the hull by removing the start coordinate, which is marked by the white bullet.`}

\n

\"machinery

\n

{`Parameters`}

\n

{`The parameters of the hull expositor can be found in the config/expositor.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`expositors`}{`>`}{`\n`}{`  `}{`<`}{`Hull`}{`>`}{`\n`}{`    `}{`<`}{`region`}{` `}{`type`}{`=`}{`\"hullselection\"`}{`>`}{`347,361|627,266|975,328|1091,328|1148,413|1158,516|1121,534|962,567|699,648|531,700|243,613|423,550|665,453|850,470|666,361|467,385|325,460|165,372`}{`{`region`}{`>`}{`\n`}{`  `}{`{`Hull`}{`>`}{`\n`}{`{`expositors`}{`>`}
\n
{`Region`}
\n

{`The region parameter contains n values. Each value represents a coordinate (x,y) and are seperated by the \"|\" delimiter. These coordinates are used to calculate the concave hull. Pixels of interest that lie within the concave hull are valid pixels; if not they are invalid.`}

\n

{`Heuristic`}

\n

{`The heuristic is the last step in the four passway which will decide if the detection is valid or not. It will do this by using information from the previous steps (the expositor and the algorithm); e.g. number of changed pixels.`}

\n

{`You can change the heuristic by changing the `}{`config/config.xml`}{` file, and choose one of the following:`}

\n
    \n
  • {`Sequence`}
  • \n
\n
{`{`xml`}{` version`}{`=`}{`\"1.0\"`}{`?>`}{`\n`}{`<`}{`kerberos`}{`>`}{`\n`}{`  `}{`<`}{`instance`}{`>`}{`\n`}{`    ...`}{`\n`}{`    `}{`<`}{`heuristic`}{` `}{`file`}{`=`}{`\"heuristic.xml\"`}{`>`}{`Sequence`}{`{`heuristic`}{`>`}{`\n`}{`    ...`}{`\n`}{`  `}{`{`instance`}{`>`}{`\n`}{`{`kerberos`}{`>`}
\n

{`Sequence`}

\n

{`This is a trivial heuristic. The sequence heuristic will store a single integer in memory, that will count the numbers of valid detections. When the heuristic will detect a false detection, it will decrease the count. The sequence heuristic will return true, if a threshold is reached; for example when something was detected three times in a row.`}

\n

{`Parameters`}

\n

{`The parameters of the Sequence heuristic can be found in the config/heuristic.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`heuristics`}{`>`}{`\n`}{`<`}{`Sequence`}{`>`}{`\n`}{`    `}{`<`}{`minimumChanges`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`1`}{`{`minimumChanges`}{`>`}{`\n`}{`    `}{`<`}{`minimumDuration`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`1`}{`{`minimumDuration`}{`>`}{`\n`}{`    `}{`<`}{`noMotionDelayTime`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`2000`}{`{`noMotionDelayTime`}{`>`}{`\n`}{`  `}{`{`Sequence`}{`>`}{`\n`}{`{`heuristics`}{`>`}
\n
{`Minimum changes`}
\n

{`The heuristic will only return true if enough changes have been detected. The minimum of changes indicates the minimum number of pixels that have to been changed, to be a valid detection.`}

\n
{`Minimum durations`}
\n

{`The minimum number of detections in a row to be a valid detection.`}

\n
{`No motion delay time`}
\n

{`When the heuristic failed, due to not enough pixels changed or not x detections in a row, the heuristic will idle for some time.`}

\n

{`Output`}

\n

{`If the heuristic determined that the evaluation was valid, one or more output operations can be executed. You configure which ooutput operations that will be executed, by modifying the configuration file or using the web interface.`}

\n
{`{`xml`}{` version`}{`=`}{`\"1.0\"`}{`?>`}{`\n`}{`<`}{`kerberos`}{`>`}{`\n`}{`  `}{`<`}{`instance`}{`>`}{`\n`}{`    ...`}{`\n`}{`    `}{`<`}{`io`}{` `}{`file`}{`=`}{`\"io.xml\"`}{` `}{`type`}{`=`}{`\"multiple\"`}{`>`}{`Video`}{`{`io`}{`>`}{`\n`}{`    ...`}{`\n`}{`  `}{`{`instance`}{`>`}{`\n`}{`{`kerberos`}{`>`}
\n

{`You can choose which output devices you will be using. If you select multiple outputs, seperate them with an `}{`,`}{`. You can change the output device by changing the `}{`config/config.xml`}{` file, and choose one of the following:`}

\n
    \n
  • {`Disk`}
  • \n
  • {`Video`}
  • \n
  • {`GPIO`}
  • \n
  • {`TCPSocket`}
  • \n
  • {`Webhook`}
  • \n
  • {`MQTT`}
  • \n
  • {`Script`}
  • \n
\n

{`Disk`}

\n

{`An image can be saved to disk.`}

\n

{`Parameters`}

\n

{`The parameters of the Disk output device can be found in the `}{`config/io.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`ios`}{`>`}{`\n`}{`  `}{`<`}{`Disk`}{`>`}{`\n`}{`    `}{`<`}{`fileFormat`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`timestamp_microseconds_instanceName_regionCoordinates_numberOfChanges_token.jpg`}{`{`fileFormat`}{`>`}{`\n`}{`    `}{`<`}{`directory`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`/etc/opt/kerberosio/capture/`}{`{`directory`}{`>`}{`\n`}{`    `}{`<`}{`markWithTimestamp`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`false`}{`{`markWithTimestamp`}{`>`}{`\n`}{`    `}{`<`}{`timestampColor`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`white`}{`{`timestampColor`}{`>`}{`\n`}{`    `}{`<`}{`privacy`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`false`}{`{`privacy`}{`>`}{`\n`}{`    `}{`<`}{`throttler`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`throttler`}{`>`}{`\n`}{`  `}{`{`Disk`}{`>`}{`\n`}{`{`ios`}{`>`}
\n
{`File format`}
\n

{`The format that will be used for the name of the image. One or more variables can be defined and will be replaced by the machinery. Note that when you're using a variables name in the file format, that this name should be defined in the JSON object.`}

\n
{`Directory`}
\n

{`The directory where the image will be saved to. By default images are saved to the /etc/opt/kerberosio/capture directory.`}

\n
{`Mark with timestamp`}
\n

{`When this settings is set to true, the image is marked with a timestamp.`}

\n
{`Timestamp color`}
\n

{`A color can be defined for timestamp: white, black, red, green and blue.`}

\n
{`Privacy`}
\n

{`The privacy mode can be activated to remove some parts from the image. This especially helpful if you want to filter out public areas. When this option is enabled you will seee that after configuring the Hull expositor, you'll see that the pixels outside your region of interest (Hull) are made black.`}

\n
{`Throttler`}
\n

{`Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Disk will only be triggered once in 5 seconds, nevertheless more detections occurred.`}

\n

{`Video`}

\n

{`When a valid event is detected, a video will be recorded for x seconds. When more valid events are detected, while a video is recording, the video file will further record for x seconds; so no new video file be recorded, but the existing one will be expanded.`}

\n

{`Parameters`}

\n

{`The parameters of the Video output device can be found in the `}{`config/io.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`ios`}{`>`}{`\n`}{`  `}{`<`}{`Video`}{`>`}{`\n`}{`    `}{`<`}{`fps`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`3`}{`{`fps`}{`>`}{`\n`}{`    `}{`<`}{`recordAfter`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`5`}{`{`recordAfter`}{`>`}{`\n`}{`    `}{`<`}{`maxDuration`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`120`}{`{`maxDuration`}{`>`}{`\n`}{`    `}{`<`}{`extension`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`mp4`}{`{`extension`}{`>`}{`\n`}{`    `}{`<`}{`codec`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`h264`}{`{`codec`}{`>`}{`\n`}{`    `}{`<`}{`fileFormat`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`timestamp_microseconds_instanceName_regionCoordinates_numberOfChanges_token`}{`{`fileFormat`}{`>`}{`\n`}{`    `}{`<`}{`directory`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`/etc/opt/kerberosio/capture/`}{`{`directory`}{`>`}{`\n`}{`    `}{`<`}{`hardwareDirectory`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`/etc/opt/kerberosio/h264/`}{`{`hardwareDirectory`}{`>`}{`\n`}{`    `}{`<`}{`enableHardwareEncoding`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`true`}{`{`enableHardwareEncoding`}{`>`}{`\n`}{`    `}{`<`}{`markWithTimestamp`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`false`}{`{`markWithTimestamp`}{`>`}{`\n`}{`    `}{`<`}{`timestampColor`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`white`}{`{`timestampColor`}{`>`}{`\n`}{`    `}{`<`}{`privacy`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`false`}{`{`privacy`}{`>`}{`\n`}{`    `}{`<`}{`throttler`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`throttler`}{`>`}{`\n`}{`  `}{`{`Video`}{`>`}{`\n`}{`{`ios`}{`>`}
\n
{`FPS`}
\n

{`The frames per second of the video being recorded. Please note that this number is limited and depends heavily on your hardware setup. You'll be receiving following warning in the systems logs, if the machinery can't write the desired FPS.`}

\n
{`[trivial] IoVideo: framerate is too fast, can't record video at this speed (8/FPS)`}
\n
{`Record after`}
\n

{`The number of seconds recorded after the last valid event was detected. This means that when a video is already recording, and a valid event was detected, the video will be expanded with x more seconds.`}

\n
{`Extensions`}
\n

{`The extension or container of the video file. We highly recommend to use the MP4 container if you want cross-browser support. Leave this setting by default, if you don't know what you're doing.`}

\n
{`Codec`}
\n

{`The codec that is used to encode the video file.`}

\n
{`File format`}
\n

{`The format that will be used for the name of the image. One or more variables can be defined and will be replaced by the machinery. Note that when you're using a variables name in the file format, that this name should be defined in the JSON object.`}

\n
{`Directory`}
\n

{`The directory where the videos will be saved. By default videos are saved to the /etc/opt/kerberosio/capture directory.`}

\n
{`Hardware directory`}
\n

{`When using onboard hardware encoding (e.g. with Raspberry Pi camera), h264 video files are generated and stored in this directory. Afterwards these h264 files will be containerized to mp4 files, and stored in the Directory path.`}

\n
{`Enable Hardware encoding`}
\n

{`A boolean which can enable or disable hardware encoding. Please note that this option is enabled by default, but does not mean that it will work if you choose to use an USB camera.`}

\n
{`Mark with timestamp`}
\n

{`When this settings is set to true, the video is marked with a timestamp (similar to the Disk device).`}

\n
{`Timestamp color`}
\n

{`A color can be defined for timestamp: white, black, red, green and blue.`}

\n
{`Privacy`}
\n

{`The privacy mode can be activated to remove some parts from the video. This especially helpful if you want to filter out public areas.`}

\n
{`Video privacy`}
\n

{`After updating the configuration, you'll see that the pixels outside your region of interest (ROI) are made black; the image below illustrates this.`}

\n
{`Throttler`}
\n

{`Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Video will only be triggered once in 5 seconds, nevertheless more detections occurred.`}

\n

{`TCP/IP client`}

\n

{`The TCP/IP client will send a TCP packet to a server.`}

\n

{`Parameters`}

\n

{`The parameters of the TCP/IP client can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`ios`}{`>`}{`\n`}{`  `}{`<`}{`TCPSocket`}{`>`}{`\n`}{`    `}{`<`}{`server`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`127.0.0.1`}{`{`server`}{`>`}{`\n`}{`    `}{`<`}{`port`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`1337`}{`{`port`}{`>`}{`\n`}{`    `}{`<`}{`message`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`it's so fluffy`}{`{`message`}{`>`}{`\n`}{`    `}{`<`}{`throttler`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`throttler`}{`>`}{`\n`}{`  `}{`{`TCPSocket`}{`>`}{`\n`}{`{`ios`}{`>`}
\n
{`Server`}
\n

{`The IP of the TCP server.`}

\n
{`Port`}
\n

{`This is the port of the TCP server.`}

\n
{`Message`}
\n

{`You can send some data to a TCP server.`}

\n
{`Throttler`}
\n

{`Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the TCP will only be triggered once in 5 seconds, nevertheless more detections occurred.`}

\n

{`GPIO`}

\n

{`A GPIO pin can be set as output device.`}

\n

{`Parameters`}

\n

{`The parameters of the GPIO pin can be found in the `}{`config/io.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`ios`}{`>`}{`\n`}{`  `}{`<`}{`GPIO`}{`>`}{`\n`}{`    `}{`<`}{`pin`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`17`}{`{`pin`}{`>`}{`\n`}{`    `}{`<`}{`periods`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`5`}{`{`periods`}{`>`}{`\n`}{`    `}{`<`}{`periodTime`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`100000`}{`{`periodTime`}{`>`}{`\n`}{`    `}{`<`}{`throttler`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`throttler`}{`>`}{`\n`}{`  `}{`{`GPIO`}{`>`}{`\n`}{`{`ios`}{`>`}
\n
{`Pin`}
\n

{`The pin that will be triggered.`}

\n
{`Periods`}
\n

{`The number of times the pin will be triggered.`}

\n
{`Period time`}
\n

{`The time in microseconds that the pin will be set high.`}

\n
{`Throttler`}
\n

{`Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the GPIO will only be triggered once in 5 seconds, nevertheless more detections occurred.`}

\n

{`Webhook`}

\n

{`Detailed information (a JSON object) is send as a POST request to a webhook. The JSON object contains the number of changes, the region, the URL of the image, etc. This is useful if you want to integrate with your own application.`}

\n

{`Make sure that the Webhook comes after the Disk device, otherwise the URL of the image is not included.`}

\n

{`Parameters`}

\n

{`The parameters of the webhook can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`ios`}{`>`}{`\n`}{`  `}{`<`}{`Webhook`}{`>`}{`\n`}{`    `}{`<`}{`url`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`http://kerberos.web/api/v1/webhook`}{`{`url`}{`>`}{`\n`}{`    `}{`<`}{`throttler`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`throttler`}{`>`}{`\n`}{`  `}{`{`Webhook`}{`>`}{`\n`}{`{`ios`}{`>`}
\n
{`Url`}
\n

{`This is the URL, to which the machinery will send a JSON object (as a POST request).`}

\n
{`Throttler`}
\n

{`Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Webhook will only be triggered once in 5 seconds, nevertheless more detections occurred.`}

\n
{`Output`}
\n

{`A JSON object is POSTed to the url you've defined.`}

\n
{`[`}{`\n`}{`  `}{`'regionCoordinates'`}{` `}{`:`}{` [`}{`618`}{`, `}{`317`}{`, `}{`703`}{`, `}{`493`}{`],`}{`\n`}{`  `}{`'numberOfChanges'`}{` `}{`:`}{` `}{`5446`}{`,`}{`\n`}{`  `}{`'timestamp'`}{` `}{`:`}{` `}{`'`}{`1465894497`}{`'`}{`,`}{`\n`}{`  `}{`'microseconds'`}{` `}{`:`}{` `}{`'`}{`5-97451`}{`'`}{`,`}{`\n`}{`  `}{`'token'`}{` `}{`:`}{` `}{`695`}{`,`}{`\n`}{`  `}{`'pathToImage'`}{` `}{`:`}{` `}{`'`}{`1465894497`}{`_`}{`5-97451`}{`_frontdoor_`}{`618-317-703-493`}{`_`}{`5446`}{`_`}{`695`}{`.jpg'`}{`,`}{`\n`}{`  `}{`'instanceName'`}{` `}{`:`}{` `}{`'frontdoor'`}{`,`}{`\n`}{`]`}
\n

{`Script`}

\n

{`A bash script can be executed after a valid event was detected. A JSON object is send in the first parameter to the script you've defined.`}

\n

{`Parameters`}

\n

{`The parameters of the Script output device can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`ios`}{`>`}{`\n`}{`  `}{`<`}{`Script`}{`>`}{`\n`}{`    `}{`<`}{`path`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`/etc/opt/kerberosio/scripts/run.sh`}{`{`path`}{`>`}{`\n`}{`    `}{`<`}{`throttler`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`throttler`}{`>`}{`\n`}{`  `}{`{`Script`}{`>`}{`\n`}{`{`ios`}{`>`}
\n
{`Path`}
\n

{`The location of the script that will be executed on detection.`}

\n
{`Throttler`}
\n

{`Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the Script will only be triggered once in 5 seconds, nevertheless more detections occurred.`}

\n
{`Example`}
\n

{`By default the script will point to /etc/opt/kerberosio/scripts/run.sh, which contains a template how you should start your script. Note that when using KiOS, this script will be read-only, copy it to the /data folder and change the path parameter.`}

\n
{`#!/bin/bash`}{`\n`}{`# -------------------------------------------`}{`\n`}{`# This is an example script which illustrates`}{`\n`}{`# how to use the Script IO device.`}{`\n`}{`#`}{`\n`}{`# --------------------------------------`}{`\n`}{`# The first parameter is the JSON object`}{`\n`}{`#`}{`\n`}{`# e.g. {\"regionCoordinates\":[308,250,346,329],\"numberOfChanges\":194,\"timestamp\":\"1486049622\",\"microseconds\":\"6-161868\",\"token\":344,\"pathToImage\":\"1486049622_6-161868_frontdoor_308-250-346-329_194_344.jpg\",\"instanceName\":\"frontdoor\"}`}{`\n`}{`JSON=`}{`$`}{`1`}{`\n`}{`# -------------------------------------------`}{`\n`}{`# You can use python to parse the JSON object`}{`\n`}{`# and get the required fields`}{`\n`}{`name=`}{`$`}{`(echo `}{`$`}{`JSON | python -c `}{`\"import sys, json; print json.load(sys.stdin)['instanceName']\"`}{`)`}{`\n`}{`coordinates=`}{`$`}{`(echo `}{`$`}{`JSON | python -c `}{`\"import sys, json; print json.load(sys.stdin)['regionCoordinates']\"`}{`)`}{`\n`}{`changes=`}{`$`}{`(echo `}{`$`}{`JSON | pythfon -c `}{`\"import sys, json; print json.load(sys.stdin)['numberOfChanges']\"`}{`)`}{`\n`}{`image=`}{`$`}{`(echo `}{`$`}{`JSON | python -c `}{`\"import sys, json; print json.load(sys.stdin)['pathToImage']\"`}{`)`}{`\n`}{`The idea `}{`is`}{` that you can use Python `}{`in`}{` your bash script, to parse the JSON `}{`object`}{` send `}{`as`}{` first parameter. Afterwards you can do `}{`with`}{` the output what you want.`}
\n

{`MQTT`}

\n

{`MQTT protocol is a light-weight Machine to Machine (M2M) protocol widely used in Internet of things.\nDetailed information (a JSON object) is published to an MQTT topic. The JSON object contains the number of changes, the region, the URL of the image, etc.`}

\n

{`Parameters`}

\n

{`The parameters of the MQTT output can be found in the config/io.xml file, but you can also use the web to modify the parameters. Below you see a default configuration file.`}

\n
{`<`}{`ios`}{`\n`}{`  {`>`}{`\n`}{`    `}{`<`}{`secure`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`false`}{`{`secure`}{`>`}{`\n`}{`    `}{`<`}{`verifycn`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`false`}{`{`verifycn`}{`>`}{`\n`}{`    `}{`<`}{`server`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`127.0.0.1`}{`{`server`}{`>`}{`\n`}{`    `}{`<`}{`port`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`1883`}{`{`port`}{`>`}{`\n`}{`    `}{`<`}{`topic`}{` `}{`type`}{`=`}{`\"text\"`}{`>`}{`kios/mqtt`}{`{`topic`}{`>`}{`\n`}{`    `}{`<`}{`username`}{` `}{`type`}{`=`}{`\"text\"`}{`>{`username`}{`>`}{`\n`}{`    `}{`<`}{`password`}{` `}{`type`}{`=`}{`\"text\"`}{`>{`password`}{`>`}{`\n`}{`    `}{`<`}{`throttler`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`0`}{`{`throttler`}{`>`}{`\n`}{`  `}{`{`MQTT`}{`>`}{`\n`}{`{`ios`}{`>`}
\n
{`Secure`}
\n

{`If checked, enable SSL/TLS support. Please note that when SSL/TLS support is enabled, the server certificate issuer is verified against the CA (Certification Authority) files available in /etc/ssl/certs.`}

\n
{`Verifycn`}
\n

{`If checked, the MQTT server FQDN or ip address must match the CN (Common Name) of the server certificate.`}

\n
{`Server`}
\n

{`IP address or FQDN of the MQTT broker.`}

\n
{`Port`}
\n

{`TCP port of the MQTT broker.`}

\n
{`Topic`}
\n

{`The topic to publish to.`}

\n
{`Username`}
\n

{`The username for authenticating to the MQTT broker. This is only supported by brokers that implement the MQTT spec v3.1. If username is not set (empty), the password argument is ignored. This is only needed if the MQTT broker is configured for authentication.`}

\n
{`Password`}
\n

{`The password to use, together with the username, for authenticating to the MQTT broker. This is only supported by brokers that implement the MQTT spec v3.1. This is only needed if the MQTT broker is configured for authentication.`}

\n
{`Throttler`}
\n

{`Control the number of executions by setting a throttling value. E.g. if you set throttling to 5, the MQTT will only be triggered once in 5 seconds, nevertheless more detections occurred.`}

\n
{`Output`}
\n

{`A JSON object is published to the topic of the MQTT broker you have configured.`}

\n
{`[`}{`\n`}{`  `}{`'regionCoordinates'`}{` `}{`:`}{` [`}{`618`}{`, `}{`317`}{`, `}{`703`}{`, `}{`493`}{`],`}{`\n`}{`  `}{`'numberOfChanges'`}{` `}{`:`}{` `}{`5446`}{`,`}{`\n`}{`  `}{`'timestamp'`}{` `}{`:`}{` `}{`'`}{`1465894497`}{`'`}{`,`}{`\n`}{`  `}{`'microseconds'`}{` `}{`:`}{` `}{`'`}{`5-97451`}{`'`}{`,`}{`\n`}{`  `}{`'token'`}{` `}{`:`}{` `}{`695`}{`,`}{`\n`}{`  `}{`'pathToImage'`}{` `}{`:`}{` `}{`'`}{`1465894497`}{`_`}{`5-97451`}{`_frontdoor_`}{`618-317-703-493`}{`_`}{`5446`}{`_`}{`695`}{`.jpg'`}{`,`}{`\n`}{`  `}{`'instanceName'`}{` `}{`:`}{` `}{`'frontdoor'`}{`,`}{`\n`}{`]`}
\n
{`Example`}
\n

{`It is possible to subscribe multiple distributed IoT devices to the same MQTT topic and perform specific actions upon the detection of a motion. Devices with more resources could fetch the image to perform further elaboration.`}

\n

{`Streaming`}

\n

{`The machinery has the ability to stream your capture device as a MJPG stream.`}

\n

{`Parameters`}

\n

{`The parameters for the supported streaming protocols can be found in the `}{`config/stream.xml`}{` file, but you can also use the web to modify the parameters. Below you see a default configuration file; at the moment of writing only a MJPG stream is supported.`}

\n
{`<`}{`streams`}{`>`}{`\n`}{`\t`}{`<`}{`Mjpg`}{`>`}{`\n`}{`    \t`}{`<`}{`enabled`}{` `}{`type`}{`=`}{`\"bool\"`}{`>`}{`true`}{`{`enabled`}{`>`}{`\n`}{`    \t`}{`<`}{`streamPort`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`8889`}{`{`streamPort`}{`>`}{`\n`}{`    \t`}{`<`}{`quality`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`75`}{`{`quality`}{`>`}{`\n`}{`    \t`}{`<`}{`username`}{` `}{`type`}{`=`}{`\"number\"`}{`>{`username`}{`>`}{`\n`}{`    \t`}{`<`}{`password`}{` `}{`type`}{`=`}{`\"number\"`}{`>`}{`75`}{`{`password`}{`>`}{`\n`}{`    `}{`{`Mjpg`}{`>`}{`\n`}{`{`streams`}{`>`}
\n

{`Enabled`}

\n

{`A boolean which turns ON/OFF the stream. This is interesting when working with IP cameras, where you already have an RTSP/MJPG stream from the camera itself.`}

\n

{`Stream Port`}

\n

{`The port on which the stream is available.`}

\n

{`Quality`}

\n

{`The quality is a value between `}{`[0-100]`}{`. The lower the quality, the more the image will be compressed. If you're using the RaspberryPi Camera module, this option will be ignored.`}

\n

{`Username/password`}

\n

{`You can secure the MJPEG streaming with a username and password. These credentials will be used to authorize your requests using Basic Authentication. Please note that once enabled, the live stream on the dashboard page can fail; however it will work if you open it directly in your browser or ip camera client. The format of the streaming url, after authentication enabled, will look as following:`}

\n
{`http:`}{`//username:password@ip-camera:8899`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-eac50b06b920771ba28638c45c44daed.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-eac50b06b920771ba28638c45c44daed.json new file mode 100644 index 0000000..a6891de --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-eac50b06b920771ba28638c45c44daed.json @@ -0,0 +1 @@ +{"expireTime":9007200841982900000,"key":"gatsby-plugin-mdx-entire-payload-9b745e0ab5d03ec3880166054414529f-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Plug-and-Play","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":18,"offset":460},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":18,"offset":460},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":15,"column":5,"offset":465},"end":{"line":15,"column":9,"offset":469},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":41,"offset":501},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":15,"column":41,"offset":501},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":464},"end":{"line":15,"column":116,"offset":576},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":15,"column":116,"offset":576},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":581},"end":{"line":16,"column":11,"offset":587},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":45,"offset":621},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":621},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":580},"end":{"line":16,"column":121,"offset":697},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":577},"end":{"line":16,"column":121,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":702},"end":{"line":17,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":742},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":701},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":698},"end":{"line":17,"column":103,"offset":800},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":461},"end":{"line":17,"column":103,"offset":800},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Advanced","position":{"start":{"line":19,"column":5,"offset":806},"end":{"line":19,"column":13,"offset":814},"indent":[]}}],"position":{"start":{"line":19,"column":1,"offset":802},"end":{"line":19,"column":13,"offset":814},"indent":[]}},{"type":"list","ordered":true,"start":4,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":20,"column":5,"offset":819},"end":{"line":20,"column":13,"offset":827},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":49,"offset":863},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":20,"column":49,"offset":863},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":4,"offset":818},"end":{"line":20,"column":139,"offset":953},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":20,"column":139,"offset":953},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":21,"column":5,"offset":958},"end":{"line":21,"column":12,"offset":965},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":47,"offset":1000},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":21,"column":47,"offset":1000},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":4,"offset":957},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":21,"column":1,"offset":954},"end":{"line":21,"column":179,"offset":1132},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":815},"end":{"line":21,"column":179,"offset":1132},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":23,"column":4,"offset":1137},"end":{"line":23,"column":8,"offset":1141},"indent":[]}}],"position":{"start":{"line":23,"column":1,"offset":1134},"end":{"line":23,"column":8,"offset":1141},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":25,"column":1,"offset":1143},"end":{"line":25,"column":229,"offset":1371},"indent":[]}}],"position":{"start":{"line":25,"column":1,"offset":1143},"end":{"line":25,"column":229,"offset":1371},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":27,"column":1,"offset":1373},"end":{"line":27,"column":197,"offset":1569},"indent":[]}}],"position":{"start":{"line":27,"column":1,"offset":1373},"end":{"line":27,"column":197,"offset":1569},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":29,"column":5,"offset":1575},"end":{"line":29,"column":11,"offset":1581},"indent":[]}}],"position":{"start":{"line":29,"column":1,"offset":1571},"end":{"line":29,"column":11,"offset":1581},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":31,"column":1,"offset":1583},"end":{"line":31,"column":63,"offset":1645},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":31,"column":64,"offset":1646},"end":{"line":31,"column":85,"offset":1667},"indent":[]}}],"position":{"start":{"line":31,"column":63,"offset":1645},"end":{"line":31,"column":123,"offset":1705},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":31,"column":123,"offset":1705},"end":{"line":31,"column":124,"offset":1706},"indent":[]}}],"position":{"start":{"line":31,"column":1,"offset":1583},"end":{"line":31,"column":124,"offset":1706},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos installer","position":{"start":{"line":33,"column":5,"offset":1712},"end":{"line":33,"column":23,"offset":1730},"indent":[]}}],"position":{"start":{"line":33,"column":1,"offset":1708},"end":{"line":33,"column":23,"offset":1730},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":35,"column":1,"offset":1732},"end":{"line":35,"column":228,"offset":1959},"indent":[]}}],"position":{"start":{"line":35,"column":1,"offset":1732},"end":{"line":35,"column":228,"offset":1959},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":37,"column":1,"offset":1961},"end":{"line":37,"column":67,"offset":2027},"indent":[]}}],"position":{"start":{"line":37,"column":1,"offset":1961},"end":{"line":37,"column":67,"offset":2027},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":39,"column":1,"offset":2029},"end":{"line":39,"column":50,"offset":2078},"indent":[]}}],"position":{"start":{"line":39,"column":1,"offset":2029},"end":{"line":39,"column":50,"offset":2078},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":41,"column":3,"offset":2082},"end":{"line":41,"column":49,"offset":2128},"indent":[]}}],"position":{"start":{"line":41,"column":3,"offset":2082},"end":{"line":41,"column":49,"offset":2128},"indent":[]}}],"position":{"start":{"line":41,"column":3,"offset":2082},"end":{"line":41,"column":49,"offset":2128},"indent":[]}}],"position":{"start":{"line":41,"column":1,"offset":2080},"end":{"line":41,"column":49,"offset":2128},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":43,"column":5,"offset":2134},"end":{"line":43,"column":11,"offset":2140},"indent":[]}}],"position":{"start":{"line":43,"column":1,"offset":2130},"end":{"line":43,"column":11,"offset":2140},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":45,"column":1,"offset":2142},"end":{"line":45,"column":160,"offset":2301},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2142},"end":{"line":45,"column":160,"offset":2301},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":47,"column":4,"offset":2306},"end":{"line":47,"column":13,"offset":2315},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":47,"column":14,"offset":2316},"end":{"line":47,"column":28,"offset":2330},"indent":[]}}],"position":{"start":{"line":47,"column":13,"offset":2315},"end":{"line":47,"column":75,"offset":2377},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":47,"column":75,"offset":2377},"end":{"line":47,"column":76,"offset":2378},"indent":[]}}],"position":{"start":{"line":47,"column":4,"offset":2306},"end":{"line":47,"column":76,"offset":2378},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2303},"end":{"line":47,"column":76,"offset":2378},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":48,"column":4,"offset":2382},"end":{"line":48,"column":41,"offset":2419},"indent":[]}}],"position":{"start":{"line":48,"column":4,"offset":2382},"end":{"line":48,"column":41,"offset":2419},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2379},"end":{"line":48,"column":41,"offset":2419},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":49,"column":4,"offset":2423},"end":{"line":49,"column":60,"offset":2479},"indent":[]}}],"position":{"start":{"line":49,"column":4,"offset":2423},"end":{"line":49,"column":60,"offset":2479},"indent":[]}}],"position":{"start":{"line":49,"column":1,"offset":2420},"end":{"line":49,"column":60,"offset":2479},"indent":[]}}],"position":{"start":{"line":47,"column":1,"offset":2303},"end":{"line":49,"column":60,"offset":2479},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":51,"column":2,"offset":2482},"end":{"line":51,"column":64,"offset":2544},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2481},"end":{"line":51,"column":96,"offset":2576},"indent":[]}}],"position":{"start":{"line":51,"column":1,"offset":2481},"end":{"line":51,"column":96,"offset":2576},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":53,"column":1,"offset":2578},"end":{"line":53,"column":204,"offset":2781},"indent":[]}}],"position":{"start":{"line":53,"column":1,"offset":2578},"end":{"line":53,"column":204,"offset":2781},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":55,"column":6,"offset":2788},"end":{"line":55,"column":24,"offset":2806},"indent":[]}}],"position":{"start":{"line":55,"column":1,"offset":2783},"end":{"line":55,"column":24,"offset":2806},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":57,"column":1,"offset":2808},"end":{"line":57,"column":95,"offset":2902},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":57,"column":95,"offset":2902},"end":{"line":57,"column":110,"offset":2917},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":57,"column":110,"offset":2917},"end":{"line":57,"column":222,"offset":3029},"indent":[]}}],"position":{"start":{"line":57,"column":1,"offset":2808},"end":{"line":57,"column":222,"offset":3029},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":59,"column":1,"offset":3031},"end":{"line":67,"column":4,"offset":3140},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":69,"column":6,"offset":3147},"end":{"line":69,"column":31,"offset":3172},"indent":[]}}],"position":{"start":{"line":69,"column":1,"offset":3142},"end":{"line":69,"column":31,"offset":3172},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":71,"column":1,"offset":3174},"end":{"line":71,"column":79,"offset":3252},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":71,"column":79,"offset":3252},"end":{"line":71,"column":95,"offset":3268},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":71,"column":95,"offset":3268},"end":{"line":71,"column":137,"offset":3310},"indent":[]}}],"position":{"start":{"line":71,"column":1,"offset":3174},"end":{"line":71,"column":137,"offset":3310},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":73,"column":1,"offset":3312},"end":{"line":83,"column":4,"offset":3680},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":85,"column":5,"offset":3686},"end":{"line":85,"column":30,"offset":3711},"indent":[]}}],"position":{"start":{"line":85,"column":1,"offset":3682},"end":{"line":85,"column":30,"offset":3711},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":87,"column":1,"offset":3713},"end":{"line":87,"column":464,"offset":4176},"indent":[]}}],"position":{"start":{"line":87,"column":1,"offset":3713},"end":{"line":87,"column":464,"offset":4176},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":89,"column":1,"offset":4178},"end":{"line":89,"column":61,"offset":4238},"indent":[]}}],"position":{"start":{"line":89,"column":1,"offset":4178},"end":{"line":89,"column":61,"offset":4238},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":91,"column":5,"offset":4244},"end":{"line":91,"column":28,"offset":4267},"indent":[]}}],"position":{"start":{"line":91,"column":1,"offset":4240},"end":{"line":91,"column":28,"offset":4267},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":93,"column":1,"offset":4269},"end":{"line":93,"column":95,"offset":4363},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":93,"column":95,"offset":4363},"end":{"line":93,"column":100,"offset":4368},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":93,"column":100,"offset":4368},"end":{"line":93,"column":101,"offset":4369},"indent":[]}}],"position":{"start":{"line":93,"column":1,"offset":4269},"end":{"line":93,"column":101,"offset":4369},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":95,"column":1,"offset":4371},"end":{"line":99,"column":4,"offset":4488},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":101,"column":1,"offset":4490},"end":{"line":101,"column":80,"offset":4569},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":101,"column":80,"offset":4569},"end":{"line":101,"column":101,"offset":4590},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":101,"column":101,"offset":4590},"end":{"line":101,"column":162,"offset":4651},"indent":[]}}],"position":{"start":{"line":101,"column":1,"offset":4490},"end":{"line":101,"column":162,"offset":4651},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":103,"column":1,"offset":4653},"end":{"line":106,"column":4,"offset":4742},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":108,"column":4,"offset":4747},"end":{"line":108,"column":12,"offset":4755},"indent":[]}}],"position":{"start":{"line":108,"column":1,"offset":4744},"end":{"line":108,"column":12,"offset":4755},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":110,"column":1,"offset":4757},"end":{"line":110,"column":193,"offset":4949},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4757},"end":{"line":110,"column":193,"offset":4949},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":112,"column":4,"offset":4954},"end":{"line":112,"column":62,"offset":5012},"indent":[]}}],"position":{"start":{"line":112,"column":4,"offset":4954},"end":{"line":112,"column":62,"offset":5012},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":4951},"end":{"line":112,"column":62,"offset":5012},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":113,"column":4,"offset":5016},"end":{"line":113,"column":69,"offset":5081},"indent":[]}}],"position":{"start":{"line":113,"column":4,"offset":5016},"end":{"line":113,"column":69,"offset":5081},"indent":[]}}],"position":{"start":{"line":113,"column":1,"offset":5013},"end":{"line":113,"column":69,"offset":5081},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":4951},"end":{"line":113,"column":69,"offset":5081},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":115,"column":1,"offset":5083},"end":{"line":115,"column":99,"offset":5181},"indent":[]}}],"position":{"start":{"line":115,"column":1,"offset":5083},"end":{"line":115,"column":99,"offset":5181},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":117,"column":5,"offset":5187},"end":{"line":117,"column":14,"offset":5196},"indent":[]}}],"position":{"start":{"line":117,"column":1,"offset":5183},"end":{"line":117,"column":14,"offset":5196},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":119,"column":1,"offset":5198},"end":{"line":119,"column":71,"offset":5268},"indent":[]}}],"position":{"start":{"line":119,"column":1,"offset":5198},"end":{"line":119,"column":71,"offset":5268},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":121,"column":3,"offset":5272},"end":{"line":121,"column":47,"offset":5316},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":121,"column":47,"offset":5316},"end":{"line":121,"column":79,"offset":5348},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":121,"column":79,"offset":5348},"end":{"line":121,"column":198,"offset":5467},"indent":[]}}],"position":{"start":{"line":121,"column":3,"offset":5272},"end":{"line":121,"column":198,"offset":5467},"indent":[]}}],"position":{"start":{"line":121,"column":1,"offset":5270},"end":{"line":121,"column":198,"offset":5467},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":123,"column":1,"offset":5469},"end":{"line":125,"column":4,"offset":5532},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":127,"column":5,"offset":5538},"end":{"line":127,"column":14,"offset":5547},"indent":[]}}],"position":{"start":{"line":127,"column":1,"offset":5534},"end":{"line":127,"column":14,"offset":5547},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":129,"column":1,"offset":5549},"end":{"line":129,"column":56,"offset":5604},"indent":[]}}],"position":{"start":{"line":129,"column":1,"offset":5549},"end":{"line":129,"column":56,"offset":5604},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":130,"column":3,"offset":5607},"end":{"line":130,"column":52,"offset":5656},"indent":[]}}],"position":{"start":{"line":130,"column":3,"offset":5607},"end":{"line":130,"column":52,"offset":5656},"indent":[]}}],"position":{"start":{"line":130,"column":3,"offset":5607},"end":{"line":130,"column":52,"offset":5656},"indent":[]}}],"position":{"start":{"line":130,"column":1,"offset":5605},"end":{"line":130,"column":52,"offset":5656},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":132,"column":1,"offset":5658},"end":{"line":132,"column":3,"offset":5660},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":132,"column":3,"offset":5660},"end":{"line":132,"column":9,"offset":5666},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":132,"column":9,"offset":5666},"end":{"line":132,"column":223,"offset":5880},"indent":[]}}],"position":{"start":{"line":132,"column":1,"offset":5658},"end":{"line":132,"column":223,"offset":5880},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":134,"column":3,"offset":5884},"end":{"line":134,"column":159,"offset":6040},"indent":[]}}],"position":{"start":{"line":134,"column":3,"offset":5884},"end":{"line":134,"column":159,"offset":6040},"indent":[]}}],"position":{"start":{"line":134,"column":1,"offset":5882},"end":{"line":134,"column":159,"offset":6040},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":136,"column":1,"offset":6042},"end":{"line":139,"column":4,"offset":6219},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":141,"column":1,"offset":6221},"end":{"line":141,"column":160,"offset":6380},"indent":[]}}],"position":{"start":{"line":141,"column":1,"offset":6221},"end":{"line":141,"column":160,"offset":6380},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":143,"column":3,"offset":6384},"end":{"line":143,"column":31,"offset":6412},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":143,"column":31,"offset":6412},"end":{"line":143,"column":101,"offset":6482},"indent":[]}}],"position":{"start":{"line":143,"column":3,"offset":6384},"end":{"line":143,"column":101,"offset":6482},"indent":[]}}],"position":{"start":{"line":143,"column":1,"offset":6382},"end":{"line":143,"column":101,"offset":6482},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":145,"column":1,"offset":6484},"end":{"line":148,"column":4,"offset":6656},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":150,"column":1,"offset":6658},"end":{"line":150,"column":73,"offset":6730},"indent":[]}}],"position":{"start":{"line":150,"column":1,"offset":6658},"end":{"line":150,"column":73,"offset":6730},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":153,"column":3,"offset":6735},"end":{"line":153,"column":31,"offset":6763},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":153,"column":31,"offset":6763},"end":{"line":153,"column":101,"offset":6833},"indent":[]}}],"position":{"start":{"line":153,"column":3,"offset":6735},"end":{"line":153,"column":101,"offset":6833},"indent":[]}}],"position":{"start":{"line":153,"column":1,"offset":6733},"end":{"line":153,"column":101,"offset":6833},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":155,"column":1,"offset":6835},"end":{"line":158,"column":4,"offset":7007},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":160,"column":1,"offset":7009},"end":{"line":160,"column":62,"offset":7070},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":160,"column":63,"offset":7071},"end":{"line":160,"column":75,"offset":7083},"indent":[]}}],"position":{"start":{"line":160,"column":62,"offset":7070},"end":{"line":160,"column":143,"offset":7151},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":160,"column":143,"offset":7151},"end":{"line":160,"column":150,"offset":7158},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":160,"column":150,"offset":7158},"end":{"line":160,"column":169,"offset":7177},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":160,"column":169,"offset":7177},"end":{"line":160,"column":170,"offset":7178},"indent":[]}}],"position":{"start":{"line":160,"column":1,"offset":7009},"end":{"line":160,"column":170,"offset":7178},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":162,"column":1,"offset":7180},"end":{"line":164,"column":4,"offset":7207},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":166,"column":1,"offset":7209},"end":{"line":166,"column":58,"offset":7266},"indent":[]}}],"position":{"start":{"line":166,"column":1,"offset":7209},"end":{"line":166,"column":58,"offset":7266},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":168,"column":1,"offset":7268},"end":{"line":171,"column":4,"offset":7338},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":173,"column":5,"offset":7344},"end":{"line":173,"column":8,"offset":7347},"indent":[]}}],"position":{"start":{"line":173,"column":1,"offset":7340},"end":{"line":173,"column":8,"offset":7347},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":175,"column":1,"offset":7349},"end":{"line":175,"column":280,"offset":7628},"indent":[]}}],"position":{"start":{"line":175,"column":1,"offset":7349},"end":{"line":175,"column":280,"offset":7628},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":177,"column":1,"offset":7630},"end":{"line":177,"column":37,"offset":7666},"indent":[]}}],"position":{"start":{"line":177,"column":1,"offset":7630},"end":{"line":177,"column":37,"offset":7666},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":179,"column":1,"offset":7668},"end":{"line":181,"column":4,"offset":7841},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":183,"column":1,"offset":7843},"end":{"line":183,"column":25,"offset":7867},"indent":[]}}],"position":{"start":{"line":183,"column":1,"offset":7843},"end":{"line":183,"column":25,"offset":7867},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":185,"column":1,"offset":7869},"end":{"line":188,"column":4,"offset":7973},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":190,"column":1,"offset":7975},"end":{"line":190,"column":118,"offset":8092},"indent":[]}}],"position":{"start":{"line":190,"column":1,"offset":7975},"end":{"line":190,"column":118,"offset":8092},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":192,"column":1,"offset":8094},"end":{"line":212,"column":4,"offset":8601},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":214,"column":1,"offset":8603},"end":{"line":214,"column":14,"offset":8616},"indent":[]}}],"position":{"start":{"line":214,"column":1,"offset":8603},"end":{"line":214,"column":14,"offset":8616},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":216,"column":1,"offset":8618},"end":{"line":218,"column":4,"offset":8654},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":220,"column":1,"offset":8656},"end":{"line":220,"column":91,"offset":8746},"indent":[]}}],"position":{"start":{"line":220,"column":1,"offset":8656},"end":{"line":220,"column":91,"offset":8746},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":222,"column":1,"offset":8748},"end":{"line":230,"column":4,"offset":9121},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":232,"column":1,"offset":9123},"end":{"line":232,"column":145,"offset":9267},"indent":[]}}],"position":{"start":{"line":232,"column":1,"offset":9123},"end":{"line":232,"column":145,"offset":9267},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":234,"column":5,"offset":9273},"end":{"line":234,"column":17,"offset":9285},"indent":[]}}],"position":{"start":{"line":234,"column":1,"offset":9269},"end":{"line":234,"column":17,"offset":9285},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":236,"column":1,"offset":9287},"end":{"line":236,"column":300,"offset":9586},"indent":[]}}],"position":{"start":{"line":236,"column":1,"offset":9287},"end":{"line":236,"column":300,"offset":9586},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":238,"column":1,"offset":9588},"end":{"line":238,"column":178,"offset":9765},"indent":[]}}],"position":{"start":{"line":238,"column":1,"offset":9588},"end":{"line":238,"column":178,"offset":9765},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":240,"column":1,"offset":9767},"end":{"line":240,"column":48,"offset":9814},"indent":[]}}],"position":{"start":{"line":240,"column":1,"offset":9767},"end":{"line":240,"column":48,"offset":9814},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":242,"column":1,"offset":9816},"end":{"line":244,"column":4,"offset":9856},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":246,"column":1,"offset":9858},"end":{"line":246,"column":104,"offset":9961},"indent":[]}}],"position":{"start":{"line":246,"column":1,"offset":9858},"end":{"line":246,"column":104,"offset":9961},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":248,"column":1,"offset":9963},"end":{"line":256,"column":4,"offset":10233},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":258,"column":1,"offset":10235},"end":{"line":258,"column":28,"offset":10262},"indent":[]}}],"position":{"start":{"line":258,"column":1,"offset":10235},"end":{"line":258,"column":28,"offset":10262},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":260,"column":1,"offset":10264},"end":{"line":262,"column":4,"offset":10308},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":264,"column":1,"offset":10310},"end":{"line":264,"column":48,"offset":10357},"indent":[]}}],"position":{"start":{"line":264,"column":1,"offset":10310},"end":{"line":264,"column":48,"offset":10357},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":266,"column":1,"offset":10359},"end":{"line":268,"column":4,"offset":10381},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":270,"column":1,"offset":10383},"end":{"line":270,"column":72,"offset":10454},"indent":[]}}],"position":{"start":{"line":270,"column":1,"offset":10383},"end":{"line":270,"column":72,"offset":10454},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":272,"column":1,"offset":10456},"end":{"line":274,"column":4,"offset":10513},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":276,"column":4,"offset":10518},"end":{"line":276,"column":10,"offset":10524},"indent":[]}}],"position":{"start":{"line":276,"column":1,"offset":10515},"end":{"line":276,"column":10,"offset":10524},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":278,"column":1,"offset":10526},"end":{"line":278,"column":337,"offset":10862},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":278,"column":338,"offset":10863},"end":{"line":278,"column":352,"offset":10877},"indent":[]}}],"position":{"start":{"line":278,"column":337,"offset":10862},"end":{"line":278,"column":388,"offset":10913},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":278,"column":388,"offset":10913},"end":{"line":278,"column":389,"offset":10914},"indent":[]}}],"position":{"start":{"line":278,"column":1,"offset":10526},"end":{"line":278,"column":389,"offset":10914},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":280,"column":5,"offset":10920},"end":{"line":280,"column":18,"offset":10933},"indent":[]}}],"position":{"start":{"line":280,"column":1,"offset":10916},"end":{"line":280,"column":18,"offset":10933},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":282,"column":3,"offset":10937},"end":{"line":282,"column":50,"offset":10984},"indent":[]}}],"position":{"start":{"line":282,"column":3,"offset":10937},"end":{"line":282,"column":50,"offset":10984},"indent":[]}}],"position":{"start":{"line":282,"column":1,"offset":10935},"end":{"line":282,"column":50,"offset":10984},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":284,"column":5,"offset":10990},"end":{"line":284,"column":11,"offset":10996},"indent":[]}}],"position":{"start":{"line":284,"column":1,"offset":10986},"end":{"line":284,"column":11,"offset":10996},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":286,"column":1,"offset":10998},"end":{"line":286,"column":64,"offset":11061},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":286,"column":65,"offset":11062},"end":{"line":286,"column":86,"offset":11083},"indent":[]}}],"position":{"start":{"line":286,"column":64,"offset":11061},"end":{"line":286,"column":126,"offset":11123},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":286,"column":126,"offset":11123},"end":{"line":286,"column":127,"offset":11124},"indent":[]}}],"position":{"start":{"line":286,"column":1,"offset":10998},"end":{"line":286,"column":127,"offset":11124},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":288,"column":5,"offset":11130},"end":{"line":288,"column":26,"offset":11151},"indent":[]}}],"position":{"start":{"line":288,"column":1,"offset":11126},"end":{"line":288,"column":26,"offset":11151},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":290,"column":1,"offset":11153},"end":{"line":290,"column":126,"offset":11278},"indent":[]}}],"position":{"start":{"line":290,"column":1,"offset":11153},"end":{"line":290,"column":126,"offset":11278},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":292,"column":1,"offset":11280},"end":{"line":294,"column":4,"offset":11319},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":296,"column":1,"offset":11321},"end":{"line":296,"column":187,"offset":11507},"indent":[]}}],"position":{"start":{"line":296,"column":1,"offset":11321},"end":{"line":296,"column":187,"offset":11507},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":298,"column":1,"offset":11509},"end":{"line":300,"column":4,"offset":11587},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":302,"column":1,"offset":11589},"end":{"line":302,"column":153,"offset":11741},"indent":[]}}],"position":{"start":{"line":302,"column":1,"offset":11589},"end":{"line":302,"column":153,"offset":11741},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":304,"column":1,"offset":11743},"end":{"line":307,"column":4,"offset":11890},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":309,"column":1,"offset":11892},"end":{"line":309,"column":100,"offset":11991},"indent":[]}}],"position":{"start":{"line":309,"column":1,"offset":11892},"end":{"line":309,"column":100,"offset":11991},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":310,"column":1,"offset":11992},"end":{"line":314,"column":4,"offset":12061},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":316,"column":5,"offset":12067},"end":{"line":316,"column":12,"offset":12074},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12063},"end":{"line":316,"column":12,"offset":12074},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":318,"column":1,"offset":12076},"end":{"line":318,"column":64,"offset":12139},"indent":[]}}],"position":{"start":{"line":318,"column":1,"offset":12076},"end":{"line":318,"column":64,"offset":12139},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":319,"column":3,"offset":12142},"end":{"line":319,"column":25,"offset":12164},"indent":[]}}],"position":{"start":{"line":319,"column":3,"offset":12142},"end":{"line":319,"column":25,"offset":12164},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":12140},"end":{"line":319,"column":25,"offset":12164},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":320,"column":3,"offset":12167},"end":{"line":320,"column":59,"offset":12223},"indent":[]}}],"position":{"start":{"line":320,"column":3,"offset":12167},"end":{"line":320,"column":59,"offset":12223},"indent":[]}}],"position":{"start":{"line":320,"column":1,"offset":12165},"end":{"line":320,"column":59,"offset":12223},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":12140},"end":{"line":320,"column":59,"offset":12223},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Balena","position":{"start":{"line":322,"column":4,"offset":12228},"end":{"line":322,"column":10,"offset":12234},"indent":[]}}],"position":{"start":{"line":322,"column":1,"offset":12225},"end":{"line":322,"column":10,"offset":12234},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Running Kerberos as a Docker container is great, and makes it possible to run Kerberos everywhere, even on a Raspberry Pi or any other tiny PC. However some you might need more control and flexibility. This is where Balena comes into the picture.","position":{"start":{"line":324,"column":1,"offset":12236},"end":{"line":324,"column":247,"offset":12482},"indent":[]}}],"position":{"start":{"line":324,"column":1,"offset":12236},"end":{"line":324,"column":247,"offset":12482},"indent":[]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":327,"column":4,"offset":12488},"end":{"line":327,"column":11,"offset":12495},"indent":[]}}],"position":{"start":{"line":327,"column":1,"offset":12485},"end":{"line":327,"column":11,"offset":12495},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":329,"column":1,"offset":12497},"end":{"line":329,"column":283,"offset":12779},"indent":[]}}],"position":{"start":{"line":329,"column":1,"offset":12497},"end":{"line":329,"column":283,"offset":12779},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":331,"column":3,"offset":12783},"end":{"line":331,"column":54,"offset":12834},"indent":[]}}],"position":{"start":{"line":331,"column":3,"offset":12783},"end":{"line":331,"column":54,"offset":12834},"indent":[]}}],"position":{"start":{"line":331,"column":1,"offset":12781},"end":{"line":331,"column":54,"offset":12834},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":333,"column":5,"offset":12840},"end":{"line":333,"column":14,"offset":12849},"indent":[]}}],"position":{"start":{"line":333,"column":1,"offset":12836},"end":{"line":333,"column":14,"offset":12849},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":335,"column":1,"offset":12851},"end":{"line":335,"column":68,"offset":12918},"indent":[]}}],"position":{"start":{"line":335,"column":1,"offset":12851},"end":{"line":335,"column":68,"offset":12918},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":337,"column":1,"offset":12920},"end":{"line":340,"column":4,"offset":13071},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":342,"column":1,"offset":13073},"end":{"line":342,"column":46,"offset":13118},"indent":[]}}],"position":{"start":{"line":342,"column":1,"offset":13073},"end":{"line":342,"column":46,"offset":13118},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":344,"column":3,"offset":13122},"end":{"line":344,"column":103,"offset":13222},"indent":[]}}],"position":{"start":{"line":344,"column":3,"offset":13122},"end":{"line":344,"column":103,"offset":13222},"indent":[]}}],"position":{"start":{"line":344,"column":1,"offset":13120},"end":{"line":344,"column":103,"offset":13222},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":346,"column":1,"offset":13224},"end":{"line":351,"column":4,"offset":13434},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":353,"column":1,"offset":13436},"end":{"line":353,"column":151,"offset":13586},"indent":[]}}],"position":{"start":{"line":353,"column":1,"offset":13436},"end":{"line":353,"column":151,"offset":13586},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":355,"column":3,"offset":13590},"end":{"line":355,"column":22,"offset":13609},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":355,"column":22,"offset":13609},"end":{"line":355,"column":26,"offset":13613},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":355,"column":26,"offset":13613},"end":{"line":355,"column":40,"offset":13627},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":355,"column":40,"offset":13627},"end":{"line":355,"column":50,"offset":13637},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":355,"column":50,"offset":13637},"end":{"line":355,"column":98,"offset":13685},"indent":[]}}],"position":{"start":{"line":355,"column":3,"offset":13590},"end":{"line":355,"column":98,"offset":13685},"indent":[]}}],"position":{"start":{"line":355,"column":1,"offset":13588},"end":{"line":355,"column":98,"offset":13685},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":357,"column":1,"offset":13687},"end":{"line":361,"column":4,"offset":13849},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":363,"column":1,"offset":13851},"end":{"line":363,"column":72,"offset":13922},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":363,"column":72,"offset":13922},"end":{"line":363,"column":84,"offset":13934},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":363,"column":84,"offset":13934},"end":{"line":363,"column":102,"offset":13952},"indent":[]}}],"position":{"start":{"line":363,"column":1,"offset":13851},"end":{"line":363,"column":102,"offset":13952},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":365,"column":1,"offset":13954},"end":{"line":368,"column":4,"offset":14028},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":370,"column":5,"offset":14034},"end":{"line":370,"column":8,"offset":14037},"indent":[]}}],"position":{"start":{"line":370,"column":1,"offset":14030},"end":{"line":370,"column":8,"offset":14037},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":372,"column":1,"offset":14039},"end":{"line":372,"column":176,"offset":14214},"indent":[]}}],"position":{"start":{"line":372,"column":1,"offset":14039},"end":{"line":372,"column":176,"offset":14214},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":374,"column":1,"offset":14216},"end":{"line":381,"column":4,"offset":14513},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":383,"column":1,"offset":14515},"end":{"line":383,"column":60,"offset":14574},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14515},"end":{"line":383,"column":60,"offset":14574},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":385,"column":1,"offset":14576},"end":{"line":389,"column":4,"offset":14702},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":391,"column":1,"offset":14704},"end":{"line":391,"column":63,"offset":14766},"indent":[]}}],"position":{"start":{"line":391,"column":1,"offset":14704},"end":{"line":391,"column":63,"offset":14766},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":393,"column":1,"offset":14768},"end":{"line":413,"column":4,"offset":15275},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":415,"column":1,"offset":15277},"end":{"line":415,"column":99,"offset":15375},"indent":[]}}],"position":{"start":{"line":415,"column":1,"offset":15277},"end":{"line":415,"column":99,"offset":15375},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":417,"column":1,"offset":15377},"end":{"line":420,"column":4,"offset":15479},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":422,"column":1,"offset":15481},"end":{"line":422,"column":37,"offset":15517},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":422,"column":37,"offset":15517},"end":{"line":422,"column":47,"offset":15527},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":422,"column":47,"offset":15527},"end":{"line":422,"column":89,"offset":15569},"indent":[]}}],"position":{"start":{"line":422,"column":1,"offset":15481},"end":{"line":422,"column":89,"offset":15569},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":424,"column":1,"offset":15571},"end":{"line":428,"column":4,"offset":15696},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":430,"column":1,"offset":15698},"end":{"line":430,"column":78,"offset":15775},"indent":[]}}],"position":{"start":{"line":430,"column":1,"offset":15698},"end":{"line":430,"column":78,"offset":15775},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":432,"column":1,"offset":15777},"end":{"line":436,"column":4,"offset":15881},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":438,"column":1,"offset":15883},"end":{"line":438,"column":75,"offset":15957},"indent":[]}}],"position":{"start":{"line":438,"column":1,"offset":15883},"end":{"line":438,"column":75,"offset":15957},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":440,"column":1,"offset":15959},"end":{"line":444,"column":4,"offset":16032},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":446,"column":1,"offset":16034},"end":{"line":446,"column":145,"offset":16178},"indent":[]}}],"position":{"start":{"line":446,"column":1,"offset":16034},"end":{"line":446,"column":145,"offset":16178},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":448,"column":5,"offset":16184},"end":{"line":448,"column":17,"offset":16196},"indent":[]}}],"position":{"start":{"line":448,"column":1,"offset":16180},"end":{"line":448,"column":17,"offset":16196},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":450,"column":1,"offset":16198},"end":{"line":450,"column":300,"offset":16497},"indent":[]}}],"position":{"start":{"line":450,"column":1,"offset":16198},"end":{"line":450,"column":300,"offset":16497},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":452,"column":1,"offset":16499},"end":{"line":452,"column":178,"offset":16676},"indent":[]}}],"position":{"start":{"line":452,"column":1,"offset":16499},"end":{"line":452,"column":178,"offset":16676},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":454,"column":1,"offset":16678},"end":{"line":454,"column":48,"offset":16725},"indent":[]}}],"position":{"start":{"line":454,"column":1,"offset":16678},"end":{"line":454,"column":48,"offset":16725},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":456,"column":1,"offset":16727},"end":{"line":458,"column":4,"offset":16771},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":460,"column":1,"offset":16773},"end":{"line":460,"column":104,"offset":16876},"indent":[]}}],"position":{"start":{"line":460,"column":1,"offset":16773},"end":{"line":460,"column":104,"offset":16876},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":462,"column":1,"offset":16878},"end":{"line":470,"column":4,"offset":17148},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":472,"column":1,"offset":17150},"end":{"line":472,"column":28,"offset":17177},"indent":[]}}],"position":{"start":{"line":472,"column":1,"offset":17150},"end":{"line":472,"column":28,"offset":17177},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":474,"column":1,"offset":17179},"end":{"line":476,"column":4,"offset":17227},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":478,"column":1,"offset":17229},"end":{"line":478,"column":48,"offset":17276},"indent":[]}}],"position":{"start":{"line":478,"column":1,"offset":17229},"end":{"line":478,"column":48,"offset":17276},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":480,"column":1,"offset":17278},"end":{"line":482,"column":4,"offset":17300},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":484,"column":1,"offset":17302},"end":{"line":484,"column":72,"offset":17373},"indent":[]}}],"position":{"start":{"line":484,"column":1,"offset":17302},"end":{"line":484,"column":72,"offset":17373},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":486,"column":1,"offset":17375},"end":{"line":488,"column":4,"offset":17436},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":491,"column":1,"offset":17439},"end":{"line":491,"column":31,"offset":17469},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":491,"column":31,"offset":17469}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n

{`Plug-and-Play`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  4. \n
  5. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  6. \n
\n

{`Advanced`}

\n
    \n
  1. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  2. \n
  3. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  4. \n
\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Docker`}

\n

{`A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Balena`}

\n

{`Running Kerberos as a Docker container is great, and makes it possible to run Kerberos everywhere, even on a Raspberry Pi or any other tiny PC. However some you might need more control and flexibility. This is where Balena comes into the picture.`}

\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-edd4f3646d51b29f3e3eea1608fd9493.json b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-edd4f3646d51b29f3e3eea1608fd9493.json new file mode 100644 index 0000000..f950b6a --- /dev/null +++ b/.docz/.cache/caches/gatsby-plugin-mdx/diskstore-edd4f3646d51b29f3e3eea1608fd9493.json @@ -0,0 +1 @@ +{"expireTime":9007200841978652000,"key":"gatsby-plugin-mdx-entire-payload-2a9ab78b3d4e3adced62e3c5f9fda26a-","val":{"mdast":{"type":"root","children":[{"type":"import","value":"import DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"","position":{"start":{"line":3,"column":1,"offset":2},"end":{"line":3,"column":125,"offset":126},"indent":[]}},{"type":"export","default":true,"value":"export default DefaultLayout","position":{"start":{"line":5,"column":1,"offset":128},"end":{"line":5,"column":29,"offset":156},"indent":[]}},{"type":"import","value":"import ReplaceVersion from \"../components/ReplaceVersion\";","position":{"start":{"line":8,"column":1,"offset":159},"end":{"line":8,"column":59,"offset":217},"indent":[]}},{"type":"heading","depth":1,"children":[{"type":"text","value":"Installation","position":{"start":{"line":10,"column":3,"offset":221},"end":{"line":10,"column":15,"offset":233},"indent":[]}}],"position":{"start":{"line":10,"column":1,"offset":219},"end":{"line":10,"column":15,"offset":233},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:","position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}}],"position":{"start":{"line":12,"column":1,"offset":235},"end":{"line":12,"column":207,"offset":441},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#kios","children":[{"type":"text","value":"KiOS","position":{"start":{"line":14,"column":5,"offset":447},"end":{"line":14,"column":9,"offset":451},"indent":[]}}],"position":{"start":{"line":14,"column":4,"offset":446},"end":{"line":14,"column":41,"offset":483},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, and you only want to run a Kerberos agent on it.","position":{"start":{"line":14,"column":41,"offset":483},"end":{"line":14,"column":116,"offset":558},"indent":[]}}],"position":{"start":{"line":14,"column":4,"offset":446},"end":{"line":14,"column":116,"offset":558},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":14,"column":116,"offset":558},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#raspbian","children":[{"type":"text","value":"Raspbian","position":{"start":{"line":15,"column":5,"offset":563},"end":{"line":15,"column":13,"offset":571},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":562},"end":{"line":15,"column":49,"offset":607},"indent":[]}},{"type":"text","value":": You have a Raspberry Pi, but you want other services running next to the Kerberos agent.","position":{"start":{"line":15,"column":49,"offset":607},"end":{"line":15,"column":139,"offset":697},"indent":[]}}],"position":{"start":{"line":15,"column":4,"offset":562},"end":{"line":15,"column":139,"offset":697},"indent":[]}}],"position":{"start":{"line":15,"column":1,"offset":559},"end":{"line":15,"column":139,"offset":697},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#docker","children":[{"type":"text","value":"Docker","position":{"start":{"line":16,"column":5,"offset":702},"end":{"line":16,"column":11,"offset":708},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":701},"end":{"line":16,"column":45,"offset":742},"indent":[]}},{"type":"text","value":": You have a lot of IP cameras, and/or don't want to mess with dependencies.","position":{"start":{"line":16,"column":45,"offset":742},"end":{"line":16,"column":121,"offset":818},"indent":[]}}],"position":{"start":{"line":16,"column":4,"offset":701},"end":{"line":16,"column":121,"offset":818},"indent":[]}}],"position":{"start":{"line":16,"column":1,"offset":698},"end":{"line":16,"column":121,"offset":818},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#balena","children":[{"type":"text","value":"Balena","position":{"start":{"line":17,"column":5,"offset":823},"end":{"line":17,"column":11,"offset":829},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":822},"end":{"line":17,"column":45,"offset":863},"indent":[]}},{"type":"text","value":": Runnning the Kerberos Docker container on top of Balena.","position":{"start":{"line":17,"column":45,"offset":863},"end":{"line":17,"column":103,"offset":921},"indent":[]}}],"position":{"start":{"line":17,"column":4,"offset":822},"end":{"line":17,"column":103,"offset":921},"indent":[]}}],"position":{"start":{"line":17,"column":1,"offset":819},"end":{"line":17,"column":103,"offset":921},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"/opensource/installation#generic","children":[{"type":"text","value":"Generic","position":{"start":{"line":18,"column":5,"offset":926},"end":{"line":18,"column":12,"offset":933},"indent":[]}}],"position":{"start":{"line":18,"column":4,"offset":925},"end":{"line":18,"column":47,"offset":968},"indent":[]}},{"type":"text","value":": You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.","position":{"start":{"line":18,"column":47,"offset":968},"end":{"line":18,"column":179,"offset":1100},"indent":[]}}],"position":{"start":{"line":18,"column":4,"offset":925},"end":{"line":18,"column":179,"offset":1100},"indent":[]}}],"position":{"start":{"line":18,"column":1,"offset":922},"end":{"line":18,"column":179,"offset":1100},"indent":[]}}],"position":{"start":{"line":14,"column":1,"offset":443},"end":{"line":18,"column":179,"offset":1100},"indent":[1,1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"KiOS","position":{"start":{"line":20,"column":4,"offset":1105},"end":{"line":20,"column":8,"offset":1109},"indent":[]}}],"position":{"start":{"line":20,"column":1,"offset":1102},"end":{"line":20,"column":8,"offset":1109},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.","position":{"start":{"line":22,"column":1,"offset":1111},"end":{"line":22,"column":229,"offset":1339},"indent":[]}}],"position":{"start":{"line":22,"column":1,"offset":1111},"end":{"line":22,"column":229,"offset":1339},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.","position":{"start":{"line":24,"column":1,"offset":1341},"end":{"line":24,"column":197,"offset":1537},"indent":[]}}],"position":{"start":{"line":24,"column":1,"offset":1341},"end":{"line":24,"column":197,"offset":1537},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":26,"column":5,"offset":1543},"end":{"line":26,"column":11,"offset":1549},"indent":[]}}],"position":{"start":{"line":26,"column":1,"offset":1539},"end":{"line":26,"column":11,"offset":1549},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"KiOS is compiled using Buildroot, the project can be found on ","position":{"start":{"line":28,"column":1,"offset":1551},"end":{"line":28,"column":63,"offset":1613},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":28,"column":64,"offset":1614},"end":{"line":28,"column":85,"offset":1635},"indent":[]}}],"position":{"start":{"line":28,"column":63,"offset":1613},"end":{"line":28,"column":123,"offset":1673},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":28,"column":123,"offset":1673},"end":{"line":28,"column":124,"offset":1674},"indent":[]}}],"position":{"start":{"line":28,"column":1,"offset":1551},"end":{"line":28,"column":124,"offset":1674},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Kerberos installer","position":{"start":{"line":30,"column":5,"offset":1680},"end":{"line":30,"column":23,"offset":1698},"indent":[]}}],"position":{"start":{"line":30,"column":1,"offset":1676},"end":{"line":30,"column":23,"offset":1698},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!","position":{"start":{"line":32,"column":1,"offset":1700},"end":{"line":32,"column":228,"offset":1927},"indent":[]}}],"position":{"start":{"line":32,"column":1,"offset":1700},"end":{"line":32,"column":228,"offset":1927},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/kios-install.gif","alt":"access kerberos installer","position":{"start":{"line":34,"column":1,"offset":1929},"end":{"line":34,"column":67,"offset":1995},"indent":[]}}],"position":{"start":{"line":34,"column":1,"offset":1929},"end":{"line":34,"column":67,"offset":1995},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the correct installer for your OS below:","position":{"start":{"line":36,"column":1,"offset":1997},"end":{"line":36,"column":50,"offset":2046},"indent":[]}}],"position":{"start":{"line":36,"column":1,"offset":1997},"end":{"line":36,"column":50,"offset":2046},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/etcher/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/etcher/releases","position":{"start":{"line":38,"column":3,"offset":2050},"end":{"line":38,"column":49,"offset":2096},"indent":[]}}],"position":{"start":{"line":38,"column":3,"offset":2050},"end":{"line":38,"column":49,"offset":2096},"indent":[]}}],"position":{"start":{"line":38,"column":3,"offset":2050},"end":{"line":38,"column":49,"offset":2096},"indent":[]}}],"position":{"start":{"line":38,"column":1,"offset":2048},"end":{"line":38,"column":49,"offset":2096},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Etcher","position":{"start":{"line":40,"column":5,"offset":2102},"end":{"line":40,"column":11,"offset":2108},"indent":[]}}],"position":{"start":{"line":40,"column":1,"offset":2098},"end":{"line":40,"column":11,"offset":2108},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:","position":{"start":{"line":42,"column":1,"offset":2110},"end":{"line":42,"column":160,"offset":2269},"indent":[]}}],"position":{"start":{"line":42,"column":1,"offset":2110},"end":{"line":42,"column":160,"offset":2269},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Download ","position":{"start":{"line":44,"column":4,"offset":2274},"end":{"line":44,"column":13,"offset":2283},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/kios/releases","children":[{"type":"text","value":"the KiOS image","position":{"start":{"line":44,"column":14,"offset":2284},"end":{"line":44,"column":28,"offset":2298},"indent":[]}}],"position":{"start":{"line":44,"column":13,"offset":2283},"end":{"line":44,"column":75,"offset":2345},"indent":[]}},{"type":"text","value":",","position":{"start":{"line":44,"column":75,"offset":2345},"end":{"line":44,"column":76,"offset":2346},"indent":[]}}],"position":{"start":{"line":44,"column":4,"offset":2274},"end":{"line":44,"column":76,"offset":2346},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":2271},"end":{"line":44,"column":76,"offset":2346},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"flash it to your SD card with Etcher,","position":{"start":{"line":45,"column":4,"offset":2350},"end":{"line":45,"column":41,"offset":2387},"indent":[]}}],"position":{"start":{"line":45,"column":4,"offset":2350},"end":{"line":45,"column":41,"offset":2387},"indent":[]}}],"position":{"start":{"line":45,"column":1,"offset":2347},"end":{"line":45,"column":41,"offset":2387},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"and edit some configuration files at the boot directory.","position":{"start":{"line":46,"column":4,"offset":2391},"end":{"line":46,"column":60,"offset":2447},"indent":[]}}],"position":{"start":{"line":46,"column":4,"offset":2391},"end":{"line":46,"column":60,"offset":2447},"indent":[]}}],"position":{"start":{"line":46,"column":1,"offset":2388},"end":{"line":46,"column":60,"offset":2447},"indent":[]}}],"position":{"start":{"line":44,"column":1,"offset":2271},"end":{"line":46,"column":60,"offset":2447},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://www.balena.io/etcher/","children":[{"type":"image","title":null,"url":"../../public/images/etcher-install.png","alt":"use etcher for kios","position":{"start":{"line":48,"column":2,"offset":2450},"end":{"line":48,"column":64,"offset":2512},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2449},"end":{"line":48,"column":96,"offset":2544},"indent":[]}}],"position":{"start":{"line":48,"column":1,"offset":2449},"end":{"line":48,"column":96,"offset":2544},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.","position":{"start":{"line":50,"column":1,"offset":2546},"end":{"line":50,"column":204,"offset":2749},"indent":[]}}],"position":{"start":{"line":50,"column":1,"offset":2546},"end":{"line":50,"column":204,"offset":2749},"indent":[]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Connecting to WiFi","position":{"start":{"line":52,"column":6,"offset":2756},"end":{"line":52,"column":24,"offset":2774},"indent":[]}}],"position":{"start":{"line":52,"column":1,"offset":2751},"end":{"line":52,"column":24,"offset":2774},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file ","position":{"start":{"line":54,"column":1,"offset":2776},"end":{"line":54,"column":95,"offset":2870},"indent":[]}},{"type":"inlineCode","value":"wireless.conf","position":{"start":{"line":54,"column":95,"offset":2870},"end":{"line":54,"column":110,"offset":2885},"indent":[]}},{"type":"text","value":" on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.","position":{"start":{"line":54,"column":110,"offset":2885},"end":{"line":54,"column":222,"offset":2997},"indent":[]}}],"position":{"start":{"line":54,"column":1,"offset":2776},"end":{"line":54,"column":222,"offset":2997},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"update_config=1\nctrl_interface=/var/run/wpa_supplicant\nnetwork={\n scan_ssid=1\n ssid=\"\"\n psk=\"\"\n}","position":{"start":{"line":56,"column":1,"offset":2999},"end":{"line":64,"column":4,"offset":3108},"indent":[1,1,1,1,1,1,1,1]}},{"type":"heading","depth":4,"children":[{"type":"text","value":"Setup a static IP-address","position":{"start":{"line":66,"column":6,"offset":3115},"end":{"line":66,"column":31,"offset":3140},"indent":[]}}],"position":{"start":{"line":66,"column":1,"offset":3110},"end":{"line":66,"column":31,"offset":3140},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to assign a static ip-address to your Raspberry Pi, create a file ","position":{"start":{"line":68,"column":1,"offset":3142},"end":{"line":68,"column":79,"offset":3220},"indent":[]}},{"type":"inlineCode","value":"static_ip.conf","position":{"start":{"line":68,"column":79,"offset":3220},"end":{"line":68,"column":95,"offset":3236},"indent":[]}},{"type":"text","value":" on your SD card, with following contents:","position":{"start":{"line":68,"column":95,"offset":3236},"end":{"line":68,"column":137,"offset":3278},"indent":[]}}],"position":{"start":{"line":68,"column":1,"offset":3142},"end":{"line":68,"column":137,"offset":3278},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"#####################################################################\n# Enter the IP-address you want to have, followed by the subnet mask\n# e.g. 192.168.0.10/24\nstatic_ip=\"\"\n#####################################################################\n# Enter the Gateway and DNS, this will be your router in most cases\n# e.g. 192.168.0.1\nstatic_gw=\"\"\nstatic_dns=\"\"","position":{"start":{"line":70,"column":1,"offset":3280},"end":{"line":80,"column":4,"offset":3648},"indent":[1,1,1,1,1,1,1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Power on the Raspberry Pi","position":{"start":{"line":82,"column":5,"offset":3654},"end":{"line":82,"column":30,"offset":3679},"indent":[]}}],"position":{"start":{"line":82,"column":1,"offset":3650},"end":{"line":82,"column":30,"offset":3679},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.","position":{"start":{"line":84,"column":1,"offset":3681},"end":{"line":84,"column":464,"offset":4144},"indent":[]}}],"position":{"start":{"line":84,"column":1,"offset":3681},"end":{"line":84,"column":464,"offset":4144},"indent":[]}},{"type":"paragraph","children":[{"type":"image","title":null,"url":"../../public/images/access.png","alt":"access kerberos interface","position":{"start":{"line":86,"column":1,"offset":4146},"end":{"line":86,"column":61,"offset":4206},"indent":[]}}],"position":{"start":{"line":86,"column":1,"offset":4146},"end":{"line":86,"column":61,"offset":4206},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Access the Raspberry Pi","position":{"start":{"line":88,"column":5,"offset":4212},"end":{"line":88,"column":28,"offset":4235},"indent":[]}}],"position":{"start":{"line":88,"column":1,"offset":4208},"end":{"line":88,"column":28,"offset":4235},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using ","position":{"start":{"line":90,"column":1,"offset":4237},"end":{"line":90,"column":95,"offset":4331},"indent":[]}},{"type":"inlineCode","value":"ssh","position":{"start":{"line":90,"column":95,"offset":4331},"end":{"line":90,"column":100,"offset":4336},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":90,"column":100,"offset":4336},"end":{"line":90,"column":101,"offset":4337},"indent":[]}}],"position":{"start":{"line":90,"column":1,"offset":4237},"end":{"line":90,"column":101,"offset":4337},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12\nWelcome to kios-79e30bbb!\n[root@kios-79e30bbb ~]#","position":{"start":{"line":92,"column":1,"offset":4339},"end":{"line":96,"column":4,"offset":4456},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Note that by default no root password is set, you can define a password in the ","position":{"start":{"line":98,"column":1,"offset":4458},"end":{"line":98,"column":80,"offset":4537},"indent":[]}},{"type":"inlineCode","value":"/data/etc/kios.conf","position":{"start":{"line":98,"column":80,"offset":4537},"end":{"line":98,"column":101,"offset":4558},"indent":[]}},{"type":"text","value":" file. Once you added a password, make sure to reboot the OS.","position":{"start":{"line":98,"column":101,"offset":4558},"end":{"line":98,"column":162,"offset":4619},"indent":[]}}],"position":{"start":{"line":98,"column":1,"offset":4458},"end":{"line":98,"column":162,"offset":4619},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"[root@kios-79e30bbb ~]# nano /data/etc/kios.conf\n[root@kios-79e30bbb ~]# reboot","position":{"start":{"line":100,"column":1,"offset":4621},"end":{"line":103,"column":4,"offset":4710},"indent":[1,1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Raspbian","position":{"start":{"line":105,"column":4,"offset":4715},"end":{"line":105,"column":12,"offset":4723},"indent":[]}}],"position":{"start":{"line":105,"column":1,"offset":4712},"end":{"line":105,"column":12,"offset":4723},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:","position":{"start":{"line":107,"column":1,"offset":4725},"end":{"line":107,"column":193,"offset":4917},"indent":[]}}],"position":{"start":{"line":107,"column":1,"offset":4725},"end":{"line":107,"column":193,"offset":4917},"indent":[]}},{"type":"list","ordered":true,"start":1,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"Install the Kerberos agent using Docker (more info below),","position":{"start":{"line":109,"column":4,"offset":4922},"end":{"line":109,"column":62,"offset":4980},"indent":[]}}],"position":{"start":{"line":109,"column":4,"offset":4922},"end":{"line":109,"column":62,"offset":4980},"indent":[]}}],"position":{"start":{"line":109,"column":1,"offset":4919},"end":{"line":109,"column":62,"offset":4980},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or you can install the Kerberos agent manually (machinery + web).","position":{"start":{"line":110,"column":4,"offset":4984},"end":{"line":110,"column":69,"offset":5049},"indent":[]}}],"position":{"start":{"line":110,"column":4,"offset":4984},"end":{"line":110,"column":69,"offset":5049},"indent":[]}}],"position":{"start":{"line":110,"column":1,"offset":4981},"end":{"line":110,"column":69,"offset":5049},"indent":[]}}],"position":{"start":{"line":109,"column":1,"offset":4919},"end":{"line":110,"column":69,"offset":5049},"indent":[1]}},{"type":"paragraph","children":[{"type":"text","value":"This section will focus on option 2, and will show you how to install the Kerberos agent manually.","position":{"start":{"line":112,"column":1,"offset":5051},"end":{"line":112,"column":99,"offset":5149},"indent":[]}}],"position":{"start":{"line":112,"column":1,"offset":5051},"end":{"line":112,"column":99,"offset":5149},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Update OS","position":{"start":{"line":114,"column":5,"offset":5155},"end":{"line":114,"column":14,"offset":5164},"indent":[]}}],"position":{"start":{"line":114,"column":1,"offset":5151},"end":{"line":114,"column":14,"offset":5164},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Let's start with updating the OS, and installing a couple of packages.","position":{"start":{"line":116,"column":1,"offset":5166},"end":{"line":116,"column":71,"offset":5236},"indent":[]}}],"position":{"start":{"line":116,"column":1,"offset":5166},"end":{"line":116,"column":71,"offset":5236},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"We have tested the Raspbian installation on ","position":{"start":{"line":118,"column":3,"offset":5240},"end":{"line":118,"column":47,"offset":5284},"indent":[]}},{"type":"inlineCode","value":"Raspbian GNU/Linux 10 (buster)","position":{"start":{"line":118,"column":47,"offset":5284},"end":{"line":118,"column":79,"offset":5316},"indent":[]}},{"type":"text","value":". It might be that if you have a different version of Raspbian, you will need to install additional/different packages.","position":{"start":{"line":118,"column":79,"offset":5316},"end":{"line":118,"column":198,"offset":5435},"indent":[]}}],"position":{"start":{"line":118,"column":3,"offset":5240},"end":{"line":118,"column":198,"offset":5435},"indent":[]}}],"position":{"start":{"line":118,"column":1,"offset":5238},"end":{"line":118,"column":198,"offset":5435},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get update && sudo apt-get install -y ffmpeg","position":{"start":{"line":120,"column":1,"offset":5437},"end":{"line":122,"column":4,"offset":5500},"indent":[1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":124,"column":5,"offset":5506},"end":{"line":124,"column":14,"offset":5515},"indent":[]}}],"position":{"start":{"line":124,"column":1,"offset":5502},"end":{"line":124,"column":14,"offset":5515},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Download the debian file from the machinery repository.","position":{"start":{"line":126,"column":1,"offset":5517},"end":{"line":126,"column":56,"offset":5572},"indent":[]}}],"position":{"start":{"line":126,"column":1,"offset":5517},"end":{"line":126,"column":56,"offset":5572},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"link","title":null,"url":"https://github.com/kerberos-io/machinery/releases","children":[{"type":"text","value":"https://github.com/kerberos-io/machinery/releases","position":{"start":{"line":127,"column":3,"offset":5575},"end":{"line":127,"column":52,"offset":5624},"indent":[]}}],"position":{"start":{"line":127,"column":3,"offset":5575},"end":{"line":127,"column":52,"offset":5624},"indent":[]}}],"position":{"start":{"line":127,"column":3,"offset":5575},"end":{"line":127,"column":52,"offset":5624},"indent":[]}}],"position":{"start":{"line":127,"column":1,"offset":5573},"end":{"line":127,"column":52,"offset":5624},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A ","position":{"start":{"line":129,"column":1,"offset":5626},"end":{"line":129,"column":3,"offset":5628},"indent":[]}},{"type":"inlineCode","value":".deb","position":{"start":{"line":129,"column":3,"offset":5628},"end":{"line":129,"column":9,"offset":5634},"indent":[]}},{"type":"text","value":" file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.","position":{"start":{"line":129,"column":9,"offset":5634},"end":{"line":129,"column":223,"offset":5848},"indent":[]}}],"position":{"start":{"line":129,"column":1,"offset":5626},"end":{"line":129,"column":223,"offset":5848},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.","position":{"start":{"line":131,"column":3,"offset":5852},"end":{"line":131,"column":159,"offset":6008},"indent":[]}}],"position":{"start":{"line":131,"column":3,"offset":5852},"end":{"line":131,"column":159,"offset":6008},"indent":[]}}],"position":{"start":{"line":131,"column":1,"offset":5850},"end":{"line":131,"column":159,"offset":6008},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb\nsudo dpkg -i rpi4-machinery-kerberosio-armhf-2.8.0.deb","position":{"start":{"line":133,"column":1,"offset":6010},"end":{"line":136,"column":4,"offset":6187},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.","position":{"start":{"line":138,"column":1,"offset":6189},"end":{"line":138,"column":160,"offset":6348},"indent":[]}}],"position":{"start":{"line":138,"column":1,"offset":6189},"end":{"line":138,"column":160,"offset":6348},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx265.so.160","position":{"start":{"line":140,"column":3,"offset":6352},"end":{"line":140,"column":31,"offset":6380},"indent":[]}},{"type":"text","value":" this will download the libx265 shared library for the Raspberry Pi 4.","position":{"start":{"line":140,"column":31,"offset":6380},"end":{"line":140,"column":101,"offset":6450},"indent":[]}}],"position":{"start":{"line":140,"column":3,"offset":6352},"end":{"line":140,"column":101,"offset":6450},"indent":[]}}],"position":{"start":{"line":140,"column":1,"offset":6350},"end":{"line":140,"column":101,"offset":6450},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160\nsudo mv rpi4-libx265.so.160 /usr/lib/arm-linux-gnueabihf/libx265.so.160","position":{"start":{"line":142,"column":1,"offset":6452},"end":{"line":145,"column":4,"offset":6624},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Same applies for the libx264 library, download the right shared library.","position":{"start":{"line":147,"column":1,"offset":6626},"end":{"line":147,"column":73,"offset":6698},"indent":[]}}],"position":{"start":{"line":147,"column":1,"offset":6626},"end":{"line":147,"column":73,"offset":6698},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"inlineCode","value":"v2.8.0/rpi4-libx264.so.148","position":{"start":{"line":150,"column":3,"offset":6703},"end":{"line":150,"column":31,"offset":6731},"indent":[]}},{"type":"text","value":" this will download the libx264 shared library for the Raspberry Pi 4.","position":{"start":{"line":150,"column":31,"offset":6731},"end":{"line":150,"column":101,"offset":6801},"indent":[]}}],"position":{"start":{"line":150,"column":3,"offset":6703},"end":{"line":150,"column":101,"offset":6801},"indent":[]}}],"position":{"start":{"line":150,"column":1,"offset":6701},"end":{"line":150,"column":101,"offset":6801},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"wget https://github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148\nsudo mv rpi4-libx264.so.148 /usr/lib/arm-linux-gnueabihf/libx264.so.148","position":{"start":{"line":152,"column":1,"offset":6803},"end":{"line":155,"column":4,"offset":6975},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"If you wish to use the Raspberry Pi Camera Module, make sure ","position":{"start":{"line":157,"column":1,"offset":6977},"end":{"line":157,"column":62,"offset":7038},"indent":[]}},{"type":"link","title":null,"url":"https://www.raspberrypi.org/documentation/configuration/camera.md","children":[{"type":"text","value":"to enable it","position":{"start":{"line":157,"column":63,"offset":7039},"end":{"line":157,"column":75,"offset":7051},"indent":[]}}],"position":{"start":{"line":157,"column":62,"offset":7038},"end":{"line":157,"column":143,"offset":7119},"indent":[]}},{"type":"text","value":" using ","position":{"start":{"line":157,"column":143,"offset":7119},"end":{"line":157,"column":150,"offset":7126},"indent":[]}},{"type":"inlineCode","value":"sudo raspi-config","position":{"start":{"line":157,"column":150,"offset":7126},"end":{"line":157,"column":169,"offset":7145},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":157,"column":169,"offset":7145},"end":{"line":157,"column":170,"offset":7146},"indent":[]}}],"position":{"start":{"line":157,"column":1,"offset":6977},"end":{"line":157,"column":170,"offset":7146},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo raspi-config","position":{"start":{"line":159,"column":1,"offset":7148},"end":{"line":161,"column":4,"offset":7175},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Enable machinery to start on boot, and start the service.","position":{"start":{"line":163,"column":1,"offset":7177},"end":{"line":163,"column":58,"offset":7234},"indent":[]}}],"position":{"start":{"line":163,"column":1,"offset":7177},"end":{"line":163,"column":58,"offset":7234},"indent":[]}},{"type":"code","lang":null,"meta":null,"value":"sudo systemctl enable kerberosio\nsudo service kerberosio start","position":{"start":{"line":165,"column":1,"offset":7236},"end":{"line":168,"column":4,"offset":7306},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":170,"column":5,"offset":7312},"end":{"line":170,"column":8,"offset":7315},"indent":[]}}],"position":{"start":{"line":170,"column":1,"offset":7308},"end":{"line":170,"column":8,"offset":7315},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.","position":{"start":{"line":172,"column":1,"offset":7317},"end":{"line":172,"column":280,"offset":7596},"indent":[]}}],"position":{"start":{"line":172,"column":1,"offset":7317},"end":{"line":172,"column":280,"offset":7596},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Install Nginx and PHP (+extensions).","position":{"start":{"line":174,"column":1,"offset":7598},"end":{"line":174,"column":37,"offset":7634},"indent":[]}}],"position":{"start":{"line":174,"column":1,"offset":7598},"end":{"line":174,"column":37,"offset":7634},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get install -y nginx php7.1 php7.1-curl php7.1-gd php7.1-fpm php7.1-cli php7.1-opcache php7.1-mbstring php7.1-xml php7.1-zip php7.1-mcrypt php7.1-readline","position":{"start":{"line":176,"column":1,"offset":7636},"end":{"line":178,"column":4,"offset":7809},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Creating a Nginx config.","position":{"start":{"line":180,"column":1,"offset":7811},"end":{"line":180,"column":25,"offset":7835},"indent":[]}}],"position":{"start":{"line":180,"column":1,"offset":7811},"end":{"line":180,"column":25,"offset":7835},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/kerberosio.conf","position":{"start":{"line":182,"column":1,"offset":7837},"end":{"line":185,"column":4,"offset":7941},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.","position":{"start":{"line":187,"column":1,"offset":7943},"end":{"line":187,"column":118,"offset":8060},"indent":[]}}],"position":{"start":{"line":187,"column":1,"offset":7943},"end":{"line":187,"column":118,"offset":8060},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":189,"column":1,"offset":8062},"end":{"line":209,"column":4,"offset":8569},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Restart nginx","position":{"start":{"line":211,"column":1,"offset":8571},"end":{"line":211,"column":14,"offset":8584},"indent":[]}}],"position":{"start":{"line":211,"column":1,"offset":8571},"end":{"line":211,"column":14,"offset":8584},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo service nginx restart","position":{"start":{"line":213,"column":1,"offset":8586},"end":{"line":215,"column":4,"offset":8622},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have installed all the dependencies, we can download the web interface source code.","position":{"start":{"line":217,"column":1,"offset":8624},"end":{"line":217,"column":91,"offset":8714},"indent":[]}}],"position":{"start":{"line":217,"column":1,"offset":8624},"end":{"line":217,"column":91,"offset":8714},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo mkdir -p /var/www/web && sudo chown www-data:www-data /var/www/web\ncd /var/www/web\nsudo -u www-data wget https://github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz\nsudo -u www-data tar xvf web.tar.gz .\nsudo chown www-data -R storage bootstrap/cache config/kerberos.php\nsudo chmod -R 775 storage bootstrap/cache\nsudo chmod 0600 config/kerberos.php","position":{"start":{"line":219,"column":1,"offset":8716},"end":{"line":227,"column":4,"offset":9089},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":229,"column":1,"offset":9091},"end":{"line":229,"column":145,"offset":9235},"indent":[]}}],"position":{"start":{"line":229,"column":1,"offset":9091},"end":{"line":229,"column":145,"offset":9235},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":231,"column":5,"offset":9241},"end":{"line":231,"column":17,"offset":9253},"indent":[]}}],"position":{"start":{"line":231,"column":1,"offset":9237},"end":{"line":231,"column":17,"offset":9253},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":233,"column":1,"offset":9255},"end":{"line":233,"column":300,"offset":9554},"indent":[]}}],"position":{"start":{"line":233,"column":1,"offset":9255},"end":{"line":233,"column":300,"offset":9554},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":235,"column":1,"offset":9556},"end":{"line":235,"column":178,"offset":9733},"indent":[]}}],"position":{"start":{"line":235,"column":1,"offset":9556},"end":{"line":235,"column":178,"offset":9733},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":237,"column":1,"offset":9735},"end":{"line":237,"column":48,"offset":9782},"indent":[]}}],"position":{"start":{"line":237,"column":1,"offset":9735},"end":{"line":237,"column":48,"offset":9782},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/pi/autoremoval.sh","position":{"start":{"line":239,"column":1,"offset":9784},"end":{"line":241,"column":4,"offset":9824},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":243,"column":1,"offset":9826},"end":{"line":243,"column":104,"offset":9929},"indent":[]}}],"position":{"start":{"line":243,"column":1,"offset":9826},"end":{"line":243,"column":104,"offset":9929},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":245,"column":1,"offset":9931},"end":{"line":253,"column":4,"offset":10201},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":255,"column":1,"offset":10203},"end":{"line":255,"column":28,"offset":10230},"indent":[]}}],"position":{"start":{"line":255,"column":1,"offset":10203},"end":{"line":255,"column":28,"offset":10230},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/pi/autoremoval.sh","position":{"start":{"line":257,"column":1,"offset":10232},"end":{"line":259,"column":4,"offset":10276},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":261,"column":1,"offset":10278},"end":{"line":261,"column":48,"offset":10325},"indent":[]}}],"position":{"start":{"line":261,"column":1,"offset":10278},"end":{"line":261,"column":48,"offset":10325},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":263,"column":1,"offset":10327},"end":{"line":265,"column":4,"offset":10349},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":267,"column":1,"offset":10351},"end":{"line":267,"column":72,"offset":10422},"indent":[]}}],"position":{"start":{"line":267,"column":1,"offset":10351},"end":{"line":267,"column":72,"offset":10422},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/pi/autoremoval.sh","position":{"start":{"line":269,"column":1,"offset":10424},"end":{"line":271,"column":4,"offset":10481},"indent":[1,1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Docker","position":{"start":{"line":273,"column":4,"offset":10486},"end":{"line":273,"column":10,"offset":10492},"indent":[]}}],"position":{"start":{"line":273,"column":1,"offset":10483},"end":{"line":273,"column":10,"offset":10492},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on ","position":{"start":{"line":275,"column":1,"offset":10494},"end":{"line":275,"column":337,"offset":10830},"indent":[]}},{"type":"link","title":null,"url":"https://hub.docker.com/u/kerberos","children":[{"type":"text","value":"the Docker hub","position":{"start":{"line":275,"column":338,"offset":10831},"end":{"line":275,"column":352,"offset":10845},"indent":[]}}],"position":{"start":{"line":275,"column":337,"offset":10830},"end":{"line":275,"column":388,"offset":10881},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":275,"column":388,"offset":10881},"end":{"line":275,"column":389,"offset":10882},"indent":[]}}],"position":{"start":{"line":275,"column":1,"offset":10494},"end":{"line":275,"column":389,"offset":10882},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Prerequisites","position":{"start":{"line":277,"column":5,"offset":10888},"end":{"line":277,"column":18,"offset":10901},"indent":[]}}],"position":{"start":{"line":277,"column":1,"offset":10884},"end":{"line":277,"column":18,"offset":10901},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"Docker or Docker Desktop (Linux, OS or Windows)","position":{"start":{"line":279,"column":3,"offset":10905},"end":{"line":279,"column":50,"offset":10952},"indent":[]}}],"position":{"start":{"line":279,"column":3,"offset":10905},"end":{"line":279,"column":50,"offset":10952},"indent":[]}}],"position":{"start":{"line":279,"column":1,"offset":10903},"end":{"line":279,"column":50,"offset":10952},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Github","position":{"start":{"line":281,"column":5,"offset":10958},"end":{"line":281,"column":11,"offset":10964},"indent":[]}}],"position":{"start":{"line":281,"column":1,"offset":10954},"end":{"line":281,"column":11,"offset":10964},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"All technical information, such as Dockerfile, can be found on ","position":{"start":{"line":283,"column":1,"offset":10966},"end":{"line":283,"column":64,"offset":11029},"indent":[]}},{"type":"link","title":null,"url":"https://github.com/kerberos-io/docker","children":[{"type":"text","value":"following Github repo","position":{"start":{"line":283,"column":65,"offset":11030},"end":{"line":283,"column":86,"offset":11051},"indent":[]}}],"position":{"start":{"line":283,"column":64,"offset":11029},"end":{"line":283,"column":126,"offset":11091},"indent":[]}},{"type":"text","value":".","position":{"start":{"line":283,"column":126,"offset":11091},"end":{"line":283,"column":127,"offset":11092},"indent":[]}}],"position":{"start":{"line":283,"column":1,"offset":10966},"end":{"line":283,"column":127,"offset":11092},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Download docker image","position":{"start":{"line":285,"column":5,"offset":11098},"end":{"line":285,"column":26,"offset":11119},"indent":[]}}],"position":{"start":{"line":285,"column":1,"offset":11094},"end":{"line":285,"column":26,"offset":11119},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.","position":{"start":{"line":287,"column":1,"offset":11121},"end":{"line":287,"column":126,"offset":11246},"indent":[]}}],"position":{"start":{"line":287,"column":1,"offset":11121},"end":{"line":287,"column":126,"offset":11246},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker pull kerberos/kerberos","position":{"start":{"line":289,"column":1,"offset":11248},"end":{"line":291,"column":4,"offset":11287},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.","position":{"start":{"line":293,"column":1,"offset":11289},"end":{"line":293,"column":187,"offset":11475},"indent":[]}}],"position":{"start":{"line":293,"column":1,"offset":11289},"end":{"line":293,"column":187,"offset":11475},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos","position":{"start":{"line":295,"column":1,"offset":11477},"end":{"line":297,"column":4,"offset":11555},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).","position":{"start":{"line":299,"column":1,"offset":11557},"end":{"line":299,"column":153,"offset":11709},"indent":[]}}],"position":{"start":{"line":299,"column":1,"offset":11557},"end":{"line":299,"column":153,"offset":11709},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos\ndocker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos","position":{"start":{"line":301,"column":1,"offset":11711},"end":{"line":304,"column":4,"offset":11858},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"When the containers are created, you can open your browser and browse to your different containers.","position":{"start":{"line":306,"column":1,"offset":11860},"end":{"line":306,"column":100,"offset":11959},"indent":[]}}],"position":{"start":{"line":306,"column":1,"offset":11860},"end":{"line":306,"column":100,"offset":11959},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"http://localhost:80\nhttp://localhost:81\nhttp://localhost:82","position":{"start":{"line":307,"column":1,"offset":11960},"end":{"line":311,"column":4,"offset":12029},"indent":[1,1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Volumes","position":{"start":{"line":313,"column":5,"offset":12035},"end":{"line":313,"column":12,"offset":12042},"indent":[]}}],"position":{"start":{"line":313,"column":1,"offset":12031},"end":{"line":313,"column":12,"offset":12042},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"You can assign volumes to the Kerberos container to for example","position":{"start":{"line":315,"column":1,"offset":12044},"end":{"line":315,"column":64,"offset":12107},"indent":[]}}],"position":{"start":{"line":315,"column":1,"offset":12044},"end":{"line":315,"column":64,"offset":12107},"indent":[]}},{"type":"list","ordered":false,"start":null,"spread":false,"children":[{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"preload configuration,","position":{"start":{"line":316,"column":3,"offset":12110},"end":{"line":316,"column":25,"offset":12132},"indent":[]}}],"position":{"start":{"line":316,"column":3,"offset":12110},"end":{"line":316,"column":25,"offset":12132},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12108},"end":{"line":316,"column":25,"offset":12132},"indent":[]}},{"type":"listItem","spread":false,"checked":null,"children":[{"type":"paragraph","children":[{"type":"text","value":"or centralise the images/videos on your working station.","position":{"start":{"line":317,"column":3,"offset":12135},"end":{"line":317,"column":59,"offset":12191},"indent":[]}}],"position":{"start":{"line":317,"column":3,"offset":12135},"end":{"line":317,"column":59,"offset":12191},"indent":[]}}],"position":{"start":{"line":317,"column":1,"offset":12133},"end":{"line":317,"column":59,"offset":12191},"indent":[]}}],"position":{"start":{"line":316,"column":1,"offset":12108},"end":{"line":317,"column":59,"offset":12191},"indent":[1]}},{"type":"heading","depth":2,"children":[{"type":"text","value":"Generic","position":{"start":{"line":319,"column":4,"offset":12196},"end":{"line":319,"column":11,"offset":12203},"indent":[]}}],"position":{"start":{"line":319,"column":1,"offset":12193},"end":{"line":319,"column":11,"offset":12203},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.","position":{"start":{"line":321,"column":1,"offset":12205},"end":{"line":321,"column":283,"offset":12487},"indent":[]}}],"position":{"start":{"line":321,"column":1,"offset":12205},"end":{"line":321,"column":283,"offset":12487},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"This was tested on a Ubuntu VM (18.04.3 (LTS) x64).","position":{"start":{"line":323,"column":3,"offset":12491},"end":{"line":323,"column":54,"offset":12542},"indent":[]}}],"position":{"start":{"line":323,"column":3,"offset":12491},"end":{"line":323,"column":54,"offset":12542},"indent":[]}}],"position":{"start":{"line":323,"column":1,"offset":12489},"end":{"line":323,"column":54,"offset":12542},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Machinery","position":{"start":{"line":325,"column":5,"offset":12548},"end":{"line":325,"column":14,"offset":12557},"indent":[]}}],"position":{"start":{"line":325,"column":1,"offset":12544},"end":{"line":325,"column":14,"offset":12557},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Update the packages and kernel, and install some development tools.","position":{"start":{"line":327,"column":1,"offset":12559},"end":{"line":327,"column":68,"offset":12626},"indent":[]}}],"position":{"start":{"line":327,"column":1,"offset":12559},"end":{"line":327,"column":68,"offset":12626},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y update\nsudo apt-get install -y git cmake subversion dh-autoreconf libcurl4-openssl-dev yasm libx264-dev pkg-config libssl-dev","position":{"start":{"line":329,"column":1,"offset":12628},"end":{"line":332,"column":4,"offset":12779},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the FFmpeg library with x264 support.","position":{"start":{"line":334,"column":1,"offset":12781},"end":{"line":334,"column":46,"offset":12826},"indent":[]}}],"position":{"start":{"line":334,"column":1,"offset":12781},"end":{"line":334,"column":46,"offset":12826},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.","position":{"start":{"line":336,"column":3,"offset":12830},"end":{"line":336,"column":103,"offset":12930},"indent":[]}}],"position":{"start":{"line":336,"column":3,"offset":12830},"end":{"line":336,"column":103,"offset":12930},"indent":[]}}],"position":{"start":{"line":336,"column":1,"offset":12828},"end":{"line":336,"column":103,"offset":12930},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"git clone https://github.com/FFmpeg/FFmpeg ffmpeg\ncd ffmpeg && git checkout remotes/origin/release/3.1\n./configure --enable-gpl --enable-libx264 --enable-shared --prefix=/usr\nmake && sudo make install","position":{"start":{"line":338,"column":1,"offset":12932},"end":{"line":343,"column":4,"offset":13142},"indent":[1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.","position":{"start":{"line":345,"column":1,"offset":13144},"end":{"line":345,"column":151,"offset":13294},"indent":[]}}],"position":{"start":{"line":345,"column":1,"offset":13144},"end":{"line":345,"column":151,"offset":13294},"indent":[]}},{"type":"blockquote","children":[{"type":"paragraph","children":[{"type":"text","value":"You can change the ","position":{"start":{"line":347,"column":3,"offset":13298},"end":{"line":347,"column":22,"offset":13317},"indent":[]}},{"type":"inlineCode","value":"-j","position":{"start":{"line":347,"column":22,"offset":13317},"end":{"line":347,"column":26,"offset":13321},"indent":[]}},{"type":"text","value":" attribute of ","position":{"start":{"line":347,"column":26,"offset":13321},"end":{"line":347,"column":40,"offset":13335},"indent":[]}},{"type":"inlineCode","value":"make -j8","position":{"start":{"line":347,"column":40,"offset":13335},"end":{"line":347,"column":50,"offset":13345},"indent":[]}},{"type":"text","value":"to the number of cores of your compilation host.","position":{"start":{"line":347,"column":50,"offset":13345},"end":{"line":347,"column":98,"offset":13393},"indent":[]}}],"position":{"start":{"line":347,"column":3,"offset":13298},"end":{"line":347,"column":98,"offset":13393},"indent":[]}}],"position":{"start":{"line":347,"column":1,"offset":13296},"end":{"line":347,"column":98,"offset":13393},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd && git clone https://github.com/kerberos-io/machinery\ncd machinery && mkdir build && cd build\ncmake .. && make -j8 && make check && sudo make install","position":{"start":{"line":349,"column":1,"offset":13395},"end":{"line":353,"column":4,"offset":13557},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"After the machinery is build and installed succesfully, you can enable ","position":{"start":{"line":355,"column":1,"offset":13559},"end":{"line":355,"column":72,"offset":13630},"indent":[]}},{"type":"inlineCode","value":"kerberosio","position":{"start":{"line":355,"column":72,"offset":13630},"end":{"line":355,"column":84,"offset":13642},"indent":[]}},{"type":"text","value":" to start on boot.","position":{"start":{"line":355,"column":84,"offset":13642},"end":{"line":355,"column":102,"offset":13660},"indent":[]}}],"position":{"start":{"line":355,"column":1,"offset":13559},"end":{"line":355,"column":102,"offset":13660},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo systemctl enable kerberosio\nsudo systemctl start kerberosio","position":{"start":{"line":357,"column":1,"offset":13662},"end":{"line":360,"column":4,"offset":13736},"indent":[1,1,1]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Web","position":{"start":{"line":362,"column":5,"offset":13742},"end":{"line":362,"column":8,"offset":13745},"indent":[]}}],"position":{"start":{"line":362,"column":1,"offset":13738},"end":{"line":362,"column":8,"offset":13745},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.","position":{"start":{"line":364,"column":1,"offset":13747},"end":{"line":364,"column":176,"offset":13922},"indent":[]}}],"position":{"start":{"line":364,"column":1,"offset":13747},"end":{"line":364,"column":176,"offset":13922},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd ~\ncurl -sL https://deb.nodesource.com/setup_10.x | sudo bash -\nsudo apt-add-repository -y ppa:ondrej/php\nsudo apt-get -y update\nsudo apt-get install -y git php7.1-cli php7.1-gd php7.1-mcrypt php7.1-curl php7.1-mbstring php7.1-dom php7.1-zip php7.1-fpm nodejs\nsudo npm -g install bower","position":{"start":{"line":366,"column":1,"offset":13924},"end":{"line":373,"column":4,"offset":14221},"indent":[1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Next we'll need to install Nginx, and create a config file.","position":{"start":{"line":375,"column":1,"offset":14223},"end":{"line":375,"column":60,"offset":14282},"indent":[]}}],"position":{"start":{"line":375,"column":1,"offset":14223},"end":{"line":375,"column":60,"offset":14282},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo apt-get -y install nginx\nsudo rm -f /etc/nginx/sites-enabled/default\nsudo nano /etc/nginx/sites-enabled/default","position":{"start":{"line":377,"column":1,"offset":14284},"end":{"line":381,"column":4,"offset":14410},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Assign Nginx to our web interface (which we will soon create).","position":{"start":{"line":383,"column":1,"offset":14412},"end":{"line":383,"column":63,"offset":14474},"indent":[]}}],"position":{"start":{"line":383,"column":1,"offset":14412},"end":{"line":383,"column":63,"offset":14474},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"server\n{\n listen 80 default_server;\n listen [::]:80 default_server;\n root /var/www/web/public;\n server_name kerberos.rpi;\n index index.php index.html index.htm;\n location /\n {\n autoindex on;\n try_files $uri $uri/ /index.php?$query_string;\n }\n location ~ \\.php$\n {\n fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n include fastcgi_params;\n }\n}","position":{"start":{"line":385,"column":1,"offset":14476},"end":{"line":405,"column":4,"offset":14983},"indent":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Now we have all the dependencies installed we can clone the web repository to our working station.","position":{"start":{"line":407,"column":1,"offset":14985},"end":{"line":407,"column":99,"offset":15083},"indent":[]}}],"position":{"start":{"line":407,"column":1,"offset":14985},"end":{"line":407,"column":99,"offset":15083},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"mkdir -p /var/www\ncd /var/www && sudo git clone https://github.com/kerberos-io/web && cd web","position":{"start":{"line":409,"column":1,"offset":15085},"end":{"line":412,"column":4,"offset":15187},"indent":[1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Install the PHP dependency manager, ","position":{"start":{"line":414,"column":1,"offset":15189},"end":{"line":414,"column":37,"offset":15225},"indent":[]}},{"type":"inlineCode","value":"composer","position":{"start":{"line":414,"column":37,"offset":15225},"end":{"line":414,"column":47,"offset":15235},"indent":[]}},{"type":"text","value":", the install all the needed dependencies.","position":{"start":{"line":414,"column":47,"offset":15235},"end":{"line":414,"column":89,"offset":15277},"indent":[]}}],"position":{"start":{"line":414,"column":1,"offset":15189},"end":{"line":414,"column":89,"offset":15277},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"curl -sS https://getcomposer.org/installer | sudo php\nsudo mv composer.phar /usr/bin/composer\nsudo composer install","position":{"start":{"line":416,"column":1,"offset":15279},"end":{"line":420,"column":4,"offset":15404},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Change some permissions, to make sure we can write logging and caching files.","position":{"start":{"line":422,"column":1,"offset":15406},"end":{"line":422,"column":78,"offset":15483},"indent":[]}}],"position":{"start":{"line":422,"column":1,"offset":15406},"end":{"line":422,"column":78,"offset":15483},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"sudo chmod -R 777 storage\nsudo chmod -R 777 bootstrap/cache\nsudo chmod 777 config/kerberos.php","position":{"start":{"line":424,"column":1,"offset":15485},"end":{"line":428,"column":4,"offset":15589},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"We will need to install a couple of more JavaScript libraries using bower.","position":{"start":{"line":430,"column":1,"offset":15591},"end":{"line":430,"column":75,"offset":15665},"indent":[]}}],"position":{"start":{"line":430,"column":1,"offset":15591},"end":{"line":430,"column":75,"offset":15665},"indent":[]}},{"type":"code","lang":"ts","meta":null,"value":"cd public\nsudo bower --allow-root install\nservice nginx restart","position":{"start":{"line":432,"column":1,"offset":15667},"end":{"line":436,"column":4,"offset":15740},"indent":[1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.","position":{"start":{"line":438,"column":1,"offset":15742},"end":{"line":438,"column":145,"offset":15886},"indent":[]}}],"position":{"start":{"line":438,"column":1,"offset":15742},"end":{"line":438,"column":145,"offset":15886},"indent":[]}},{"type":"heading","depth":3,"children":[{"type":"text","value":"Auto removal","position":{"start":{"line":440,"column":5,"offset":15892},"end":{"line":440,"column":17,"offset":15904},"indent":[]}}],"position":{"start":{"line":440,"column":1,"offset":15888},"end":{"line":440,"column":17,"offset":15904},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.","position":{"start":{"line":442,"column":1,"offset":15906},"end":{"line":442,"column":300,"offset":16205},"indent":[]}}],"position":{"start":{"line":442,"column":1,"offset":15906},"end":{"line":442,"column":300,"offset":16205},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.","position":{"start":{"line":444,"column":1,"offset":16207},"end":{"line":444,"column":178,"offset":16384},"indent":[]}}],"position":{"start":{"line":444,"column":1,"offset":16207},"end":{"line":444,"column":178,"offset":16384},"indent":[]}},{"type":"paragraph","children":[{"type":"text","value":"Create a bash script and copy following script.","position":{"start":{"line":446,"column":1,"offset":16386},"end":{"line":446,"column":48,"offset":16433},"indent":[]}}],"position":{"start":{"line":446,"column":1,"offset":16386},"end":{"line":446,"column":48,"offset":16433},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"nano /home/[user]/autoremoval.sh","position":{"start":{"line":448,"column":1,"offset":16435},"end":{"line":450,"column":4,"offset":16479},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).","position":{"start":{"line":452,"column":1,"offset":16481},"end":{"line":452,"column":104,"offset":16584},"indent":[]}}],"position":{"start":{"line":452,"column":1,"offset":16481},"end":{"line":452,"column":104,"offset":16584},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"partition=/dev/root\nimagedir=/etc/opt/kerberosio/capture/\nif [[ $(df -h | grep $partition | head -1 | awk -F' ' '{ print $5/1 }' | tr ['%'] [\"0\"]) -gt 90 ]];\nthen\n echo \"Cleaning disk\"\n find $imagedir -type f | sort | head -n 100 | xargs -r rm -rf;\nfi;","position":{"start":{"line":454,"column":1,"offset":16586},"end":{"line":462,"column":4,"offset":16856},"indent":[1,1,1,1,1,1,1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Make the script executable.","position":{"start":{"line":464,"column":1,"offset":16858},"end":{"line":464,"column":28,"offset":16885},"indent":[]}}],"position":{"start":{"line":464,"column":1,"offset":16858},"end":{"line":464,"column":28,"offset":16885},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"chmod +x /home/[user]/autoremoval.sh","position":{"start":{"line":466,"column":1,"offset":16887},"end":{"line":468,"column":4,"offset":16935},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Initiate a cronjob, and select the nano editor.","position":{"start":{"line":470,"column":1,"offset":16937},"end":{"line":470,"column":48,"offset":16984},"indent":[]}}],"position":{"start":{"line":470,"column":1,"offset":16937},"end":{"line":470,"column":48,"offset":16984},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"crontab -e","position":{"start":{"line":472,"column":1,"offset":16986},"end":{"line":474,"column":4,"offset":17008},"indent":[1,1]}},{"type":"paragraph","children":[{"type":"text","value":"Append following line, to execute the autoremoval.sh script every 5min.","position":{"start":{"line":476,"column":1,"offset":17010},"end":{"line":476,"column":72,"offset":17081},"indent":[]}}],"position":{"start":{"line":476,"column":1,"offset":17010},"end":{"line":476,"column":72,"offset":17081},"indent":[]}},{"type":"code","lang":"bash","meta":null,"value":"*/5 * * * * /bin/bash /home/[user]/autoremoval.sh","position":{"start":{"line":478,"column":1,"offset":17083},"end":{"line":480,"column":4,"offset":17144},"indent":[1,1]}},{"type":"export","value":"export const _frontmatter = {}","position":{"start":{"line":483,"column":1,"offset":17147},"end":{"line":483,"column":31,"offset":17177},"indent":[]}}],"position":{"start":{"line":1,"column":1,"offset":0},"end":{"line":483,"column":31,"offset":17177}}},"scopeImports":[],"scopeIdentifiers":[],"rawMDXOutput":"/* @jsx mdx */\nimport { mdx } from '@mdx-js/react';\n/* @jsx mdx */\nimport DefaultLayout from \"/Users/i353408/Vagrant/www/repos/documentation/node_modules/gatsby-theme-docz/src/base/Layout.js\"\nimport ReplaceVersion from \"../components/ReplaceVersion\";\nexport const _frontmatter = {};\nconst makeShortcode = name => function MDXDefaultShortcode(props) {\n console.warn(\"Component \" + name + \" was not imported, exported, or provided by MDXProvider as global scope\")\n return
\n};\n\nconst layoutProps = {\n _frontmatter\n};\nconst MDXLayout = DefaultLayout\nexport default function MDXContent({\n components,\n ...props\n}) {\n return \n\n\n\n

{`Installation`}

\n

{`Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations:`}

\n
    \n
  1. {`KiOS`}{`: You have a Raspberry Pi, and you only want to run a Kerberos agent on it.`}
  2. \n
  3. {`Raspbian`}{`: You have a Raspberry Pi, but you want other services running next to the Kerberos agent.`}
  4. \n
  5. {`Docker`}{`: You have a lot of IP cameras, and/or don't want to mess with dependencies.`}
  6. \n
  7. {`Balena`}{`: Runnning the Kerberos Docker container on top of Balena.`}
  8. \n
  9. {`Generic`}{`: You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure.`}
  10. \n
\n

{`KiOS`}

\n

{`KiOS (Kerberos Operating System) is our custom linux OS, which runs the Kerberos agent out-of-the-box (read plug-and-play). It's an OS designed for the Raspberry Pi (all version are supported), which you can flash to an SD card.`}

\n

{`It can be installed using our own installer, which comes with a nice interface that handles the flashing and network configuration for you, or you can handle the flashing yourself by using Etcher.`}

\n

{`Github`}

\n

{`KiOS is compiled using Buildroot, the project can be found on `}{`following Github repo`}{`.`}

\n

{`Kerberos installer`}

\n

{`Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome!`}

\n

\"access

\n

{`Download the correct installer for your OS below:`}

\n
\n

{`https://github.com/kerberos-io/etcher/releases`}

\n
\n

{`Etcher`}

\n

{`If you love Etcher, or the Kerberos installer is not working as expected, you can also flash the Kerberos agent to your SD card manually. It goes as following:`}

\n
    \n
  1. {`Download `}{`the KiOS image`}{`,`}
  2. \n
  3. {`flash it to your SD card with Etcher,`}
  4. \n
  5. {`and edit some configuration files at the boot directory.`}
  6. \n
\n

\"use

\n

{`Once you have download the KiOS image (make sure you downloaded the right image) and flashed it to an SD card, put it back into your working station. Navigate to the SD card and creating following files.`}

\n

{`Connecting to WiFi`}

\n

{`If you want to connect your Raspberry Pi to a WiFi connection, you will need to create a file `}{`wireless.conf`}{` on your SD card, with following contents. Change the SSID and password properties to your own WiFi credentials.`}

\n
{`update_config`}{`=`}{`1`}{`\n`}{`ctrl_interface`}{`=/`}{`var`}{`/`}{`run`}{`/wpa_supplicant`}{`\n`}{`network`}{`={`}{`\n`}{`  `}{`scan_ssid`}{`=`}{`1`}{`\n`}{`  `}{`ssid`}{`=`}{`\"\"`}{`\n`}{`  `}{`psk`}{`=`}{`\"\"`}{`\n`}{`}`}
\n

{`Setup a static IP-address`}

\n

{`If you want to assign a static ip-address to your Raspberry Pi, create a file `}{`static_ip.conf`}{` on your SD card, with following contents:`}

\n
{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`IP`}{`-`}{`address`}{` `}{`you`}{` `}{`want`}{` `}{`to`}{` `}{`have`}{`, `}{`followed`}{` `}{`by`}{` `}{`the`}{` `}{`subnet`}{` `}{`mask`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.10`}{`/`}{`24`}{`\n`}{`static_ip`}{`=`}{`\"\"`}{`\n`}{`#####################################################################`}{`\n`}{`# `}{`Enter`}{` `}{`the`}{` `}{`Gateway`}{` `}{`and`}{` `}{`DNS`}{`, `}{`this`}{` `}{`will`}{` `}{`be`}{` `}{`your`}{` `}{`router`}{` `}{`in`}{` `}{`most`}{` `}{`cases`}{`\n`}{`# `}{`e`}{`.`}{`g`}{`. `}{`192.168`}{`.`}{`0.1`}{`\n`}{`static_gw`}{`=`}{`\"\"`}{`\n`}{`static_dns`}{`=`}{`\"\"`}
\n

{`Power on the Raspberry Pi`}

\n

{`Once you've finished the installation using either the KiOS installer or Etcher, you can put the SD card into your Raspberry Pi and turn it on. Please note that the first time you boot KiOS it can take about 2 mins before the system is operational. When KiOS is ready you can open your favorite browser and type in the IP address of your Raspberry Pi. This will open the Kerberos agent's front-end, which you can access with the username: root and password: root.`}

\n

\"access

\n

{`Access the Raspberry Pi`}

\n

{`You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `}{`ssh`}{`.`}

\n
{`Cedrics`}{`-`}{`Mac`}{`-mini:`}{`build`}{` `}{`cedricverst$`}{` `}{`ssh`}{` `}{`root`}{`@`}{`192.168`}{`.`}{`0.12`}{`\n`}{`Welcome`}{` `}{`to`}{` `}{`kios`}{`-79`}{`e30bbb`}{`!`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]#`}
\n

{`Note that by default no root password is set, you can define a password in the `}{`/data/etc/kios.conf`}{` file. Once you added a password, make sure to reboot the OS.`}

\n
{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`nano`}{` /`}{`data`}{`/`}{`etc`}{`/`}{`kios`}{`.`}{`conf`}{`\n`}{`[`}{`root`}{`@`}{`kios`}{`-79`}{`e30bbb`}{` ~]# `}{`reboot`}
\n

{`Raspbian`}

\n

{`If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this:`}

\n
    \n
  1. {`Install the Kerberos agent using Docker (more info below),`}
  2. \n
  3. {`or you can install the Kerberos agent manually (machinery + web).`}
  4. \n
\n

{`This section will focus on option 2, and will show you how to install the Kerberos agent manually.`}

\n

{`Update OS`}

\n

{`Let's start with updating the OS, and installing a couple of packages.`}

\n
\n

{`We have tested the Raspbian installation on `}{`Raspbian GNU/Linux 10 (buster)`}{`. It might be that if you have a different version of Raspbian, you will need to install additional/different packages.`}

\n
\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`update`}{` && `}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`ffmpeg`}
\n

{`Machinery`}

\n

{`Download the debian file from the machinery repository.`}

\n
\n

{`https://github.com/kerberos-io/machinery/releases`}

\n
\n

{`A `}{`.deb`}{` file is available for every version of the Raspberry Pi. For example if you are using a Raspberry Pi 4 for version 2.8.0, execute following command. You can change the version and Raspberry Pi board to your needs.`}

\n
\n

{`Please make sure you pick the right board (rpi, rpi2, rpi3 or rpi4), and choose the version you want (e.g. 2.8.0). Replace below url, with your preferences.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-machinery-kerberosio-armhf-2.8.0.deb`}{`\n`}{`sudo`}{` `}{`dpkg`}{` -`}{`i`}{` `}{`rpi4`}{`-`}{`machinery`}{`-`}{`kerberosio`}{`-`}{`armhf`}{`-`}{`2.8`}{`.0.`}{`deb`}
\n

{`Download the x265 library (version 160) from the machinery repository, as Raspbian Buster 10 only ships with version 165. Make sure you select the right board.`}

\n
\n

{`v2.8.0/rpi4-libx265.so.160`}{` this will download the libx265 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx265.so.160`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx265`}{`.`}{`so`}{`.`}{`160`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx265`}{`.`}{`so`}{`.`}{`160`}
\n

{`Same applies for the libx264 library, download the right shared library.`}

\n
\n

{`v2.8.0/rpi4-libx264.so.148`}{` this will download the libx264 shared library for the Raspberry Pi 4.`}

\n
\n
{`wget`}{` https:`}{`//github.com/kerberos-io/machinery/releases/download/v2.8.0/rpi4-libx264.so.148`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`rpi4`}{`-`}{`libx264`}{`.`}{`so`}{`.`}{`148`}{` /`}{`usr`}{`/`}{`lib`}{`/`}{`arm`}{`-`}{`linux`}{`-`}{`gnueabihf`}{`/`}{`libx264`}{`.`}{`so`}{`.`}{`148`}
\n

{`If you wish to use the Raspberry Pi Camera Module, make sure `}{`to enable it`}{` using `}{`sudo raspi-config`}{`.`}

\n
{`sudo`}{` `}{`raspi`}{`-`}{`config`}
\n

{`Enable machinery to start on boot, and start the service.`}

\n
{`sudo systemctl enable kerberosio`}{`\n`}{`sudo service kerberosio start`}
\n

{`Web`}

\n

{`Before you can run the web interface, you'll need to download and configure a webserver. We recommend to use Nginx, as it is a light-weight and fast webserver. The web interface is written in PHP, so we also need to download PHP and some packages. Update the packages and kernel.`}

\n

{`Install Nginx and PHP (+extensions).`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`nginx`}{` `}{`php7`}{`.`}{`1`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`opcache`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`xml`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`readline`}
\n

{`Creating a Nginx config.`}

\n
{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`kerberosio`}{`.`}{`conf`}
\n

{`Copy and paste following config file; this file tells nginx where the web will be installed and that it requires PHP.`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Restart nginx`}

\n
{`sudo`}{` `}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Now we have installed all the dependencies, we can download the web interface source code.`}

\n
{`sudo`}{` `}{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`/web && sudo chown www-data:`}{`www`}{`-`}{`data`}{` /`}{`var`}{`/`}{`www`}{`/`}{`web`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{`/web`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`wget`}{` https:`}{`//github.com/kerberos-io/web/releases/download/v2.8.0/web.tar.gz`}{`\n`}{`sudo`}{` -`}{`u`}{` `}{`www`}{`-`}{`data`}{` `}{`tar`}{` `}{`xvf`}{` `}{`web`}{`.`}{`tar`}{`.`}{`gz`}{` .`}{`\n`}{`sudo`}{` `}{`chown`}{` `}{`www`}{`-`}{`data`}{` -`}{`R`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`775`}{` `}{`storage`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`0600`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/pi/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/pi/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/pi/autoremoval.sh`}
\n

{`Docker`}

\n

{`A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on `}{`the Docker hub`}{`.`}

\n

{`Prerequisites`}

\n
\n

{`Docker or Docker Desktop (Linux, OS or Windows)`}

\n
\n

{`Github`}

\n

{`All technical information, such as Dockerfile, can be found on `}{`following Github repo`}{`.`}

\n

{`Download docker image`}

\n

{`Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub.`}

\n
{`docker`}{` `}{`pull`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889.`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera1`}{` -`}{`p`}{` `}{`80`}{`:`}{`80`}{` -`}{`p`}{` `}{`8889`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS).`}

\n
{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera2`}{` -`}{`p`}{` `}{`81`}{`:`}{`80`}{` -`}{`p`}{` `}{`8890`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}{`\n`}{`docker`}{` `}{`run`}{` --`}{`name`}{` `}{`camera3`}{` -`}{`p`}{` `}{`82`}{`:`}{`80`}{` -`}{`p`}{` `}{`8891`}{`:`}{`8889`}{` -`}{`d`}{` `}{`kerberos`}{`/`}{`kerberos`}
\n

{`When the containers are created, you can open your browser and browse to your different containers.`}

\n
{`http:`}{`//localhost:80`}{`\n`}{`http:`}{`//localhost:81`}{`\n`}{`http:`}{`//localhost:82`}
\n

{`Volumes`}

\n

{`You can assign volumes to the Kerberos container to for example`}

\n
    \n
  • {`preload configuration,`}
  • \n
  • {`or centralise the images/videos on your working station.`}
  • \n
\n

{`Generic`}

\n

{`If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.`}

\n
\n

{`This was tested on a Ubuntu VM (18.04.3 (LTS) x64).`}

\n
\n

{`Machinery`}

\n

{`Update the packages and kernel, and install some development tools.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`cmake`}{` `}{`subversion`}{` `}{`dh`}{`-`}{`autoreconf`}{` `}{`libcurl4`}{`-`}{`openssl`}{`-`}{`dev`}{` `}{`yasm`}{` `}{`libx264`}{`-`}{`dev`}{` `}{`pkg`}{`-`}{`config`}{` `}{`libssl`}{`-`}{`dev`}
\n

{`Install the FFmpeg library with x264 support.`}

\n
\n

{`It's recommended to install FFmpeg 3.1. Later versions might give issues at compilation or run time.`}

\n
\n
{`git`}{` `}{`clone`}{` https:`}{`//github.com/FFmpeg/FFmpeg ffmpeg`}{`\n`}{`cd`}{` `}{`ffmpeg`}{` && `}{`git`}{` `}{`checkout`}{` `}{`remotes`}{`/`}{`origin`}{`/`}{`release`}{`/`}{`3.1`}{`\n`}{`./`}{`configure`}{` --`}{`enable`}{`-`}{`gpl`}{` --`}{`enable`}{`-`}{`libx264`}{` --`}{`enable`}{`-`}{`shared`}{` --`}{`prefix`}{`=/`}{`usr`}{`\n`}{`make`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`Go to your home directory, or any place your prefer and pull the machinery from Github. Afterwards create a build directory and start the compilation.`}

\n
\n

{`You can change the `}{`-j`}{` attribute of `}{`make -j8`}{`to the number of cores of your compilation host.`}

\n
\n
{`cd`}{` && `}{`git`}{` `}{`clone`}{` https:`}{`//github.com/kerberos-io/machinery`}{`\n`}{`cd`}{` `}{`machinery`}{` && `}{`mkdir`}{` `}{`build`}{` && `}{`cd`}{` `}{`build`}{`\n`}{`cmake`}{` .. && `}{`make`}{` -`}{`j8`}{` && `}{`make`}{` `}{`check`}{` && `}{`sudo`}{` `}{`make`}{` `}{`install`}
\n

{`After the machinery is build and installed succesfully, you can enable `}{`kerberosio`}{` to start on boot.`}

\n
{`sudo`}{` `}{`systemctl`}{` `}{`enable`}{` `}{`kerberosio`}{`\n`}{`sudo`}{` `}{`systemctl`}{` `}{`start`}{` `}{`kerberosio`}
\n

{`Web`}

\n

{`If you want to install the web, you'll need to have a webserver (e.g. Nginx) and PHP running with some extensions. You'll also need NodeJS and npm installed, to install Bower.`}

\n
{`cd`}{` ~`}{`\n`}{`curl`}{` -`}{`sL`}{` https:`}{`//deb.nodesource.com/setup_10.x | sudo bash -`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`add`}{`-`}{`repository`}{` -`}{`y`}{` ppa:`}{`ondrej`}{`/`}{`php`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`update`}{`\n`}{`sudo`}{` `}{`apt`}{`-`}{`get`}{` `}{`install`}{` -`}{`y`}{` `}{`git`}{` `}{`php7`}{`.`}{`1`}{`-`}{`cli`}{` `}{`php7`}{`.`}{`1`}{`-`}{`gd`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mcrypt`}{` `}{`php7`}{`.`}{`1`}{`-`}{`curl`}{` `}{`php7`}{`.`}{`1`}{`-`}{`mbstring`}{` `}{`php7`}{`.`}{`1`}{`-`}{`dom`}{` `}{`php7`}{`.`}{`1`}{`-`}{`zip`}{` `}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{` `}{`nodejs`}{`\n`}{`sudo`}{` `}{`npm`}{` -`}{`g`}{` `}{`install`}{` `}{`bower`}
\n

{`Next we'll need to install Nginx, and create a config file.`}

\n
{`sudo`}{` `}{`apt`}{`-`}{`get`}{` -`}{`y`}{` `}{`install`}{` `}{`nginx`}{`\n`}{`sudo`}{` `}{`rm`}{` -`}{`f`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}{`\n`}{`sudo`}{` `}{`nano`}{` /`}{`etc`}{`/`}{`nginx`}{`/`}{`sites`}{`-`}{`enabled`}{`/`}{`default`}
\n

{`Assign Nginx to our web interface (which we will soon create).`}

\n
{`server`}{`\n`}{`{`}{`\n`}{`    `}{`listen`}{` `}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`listen`}{` [::]:`}{`80`}{` `}{`default_server`}{`;`}{`\n`}{`    `}{`root`}{` /`}{`var`}{`/`}{`www`}{`/web/public;`}{`\n`}{`    `}{`server_name`}{` `}{`kerberos`}{`.`}{`rpi`}{`;`}{`\n`}{`    `}{`index`}{` `}{`index`}{`.`}{`php`}{` `}{`index`}{`.`}{`html`}{` `}{`index`}{`.`}{`htm`}{`;`}{`\n`}{`    `}{`location`}{` /`}{`\n`}{`    {`}{`\n`}{`            `}{`autoindex`}{` `}{`on`}{`;`}{`\n`}{`            `}{`try_files`}{` `}{`$uri`}{` `}{`$uri`}{`/ /`}{`index`}{`.`}{`php`}{`?`}{`$query_string`}{`;`}{`\n`}{`    }`}{`\n`}{`    `}{`location`}{` ~ \\\\.`}{`php$`}{`\n`}{`    {`}{`\n`}{`            fastcgi_pass `}{`unix:`}{`/`}{`var`}{`/`}{`run`}{`/`}{`php`}{`/`}{`php7`}{`.`}{`1`}{`-`}{`fpm`}{`.`}{`sock`}{`;`}{`\n`}{`            `}{`fastcgi_param`}{` `}{`SCRIPT_FILENAME`}{` `}{`$document_root$fastcgi_script_name`}{`;`}{`\n`}{`            `}{`include`}{` `}{`fastcgi_params`}{`;`}{`\n`}{`    }`}{`\n`}{`}`}
\n

{`Now we have all the dependencies installed we can clone the web repository to our working station.`}

\n
{`mkdir`}{` -`}{`p`}{` /`}{`var`}{`/`}{`www`}{`\n`}{`cd`}{` /`}{`var`}{`/`}{`www`}{` && sudo git clone https:`}{`//github.com/kerberos-io/web && cd web`}
\n

{`Install the PHP dependency manager, `}{`composer`}{`, the install all the needed dependencies.`}

\n
{`curl`}{` -`}{`sS`}{` https:`}{`//getcomposer.org/installer | sudo php`}{`\n`}{`sudo`}{` `}{`mv`}{` `}{`composer`}{`.`}{`phar`}{` /`}{`usr`}{`/`}{`bin`}{`/`}{`composer`}{`\n`}{`sudo`}{` `}{`composer`}{` `}{`install`}
\n

{`Change some permissions, to make sure we can write logging and caching files.`}

\n
{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`storage`}{`\n`}{`sudo`}{` `}{`chmod`}{` -`}{`R`}{` `}{`777`}{` `}{`bootstrap`}{`/`}{`cache`}{`\n`}{`sudo`}{` `}{`chmod`}{` `}{`777`}{` `}{`config`}{`/`}{`kerberos`}{`.`}{`php`}
\n

{`We will need to install a couple of more JavaScript libraries using bower.`}

\n
{`cd`}{` `}{`public`}{`\n`}{`sudo`}{` `}{`bower`}{` --`}{`allow`}{`-`}{`root`}{` `}{`install`}{`\n`}{`service`}{` `}{`nginx`}{` `}{`restart`}
\n

{`Once everything is setup correctly, you should be able to browse towards the ip-address of your Raspberry Pi and see the Kerberos web interface.`}

\n

{`Auto removal`}

\n

{`By default images or videos aren't removed automatically. This means that the Kerberos agent will keep writing to disk, even if there is no more space available on your SD card. When your SD card is full you'll be experiencing strange errors: a corrupt web interface, blank images or corrupt videos.`}

\n

{`To resolve this your should install a simple bash script and initiate a cronjob which continuously poll your filesystem, and start removing media when your disk is getting full.`}

\n

{`Create a bash script and copy following script.`}

\n
{`nano /home/[user]/autoremoval.sh`}
\n

{`Copy following script (make sure the partition is correct, this is the default one for a Raspberry Pi).`}

\n
{`partition=/dev/root`}{`\n`}{`imagedir=/etc/opt/kerberosio/capture/`}{`\n`}{`if`}{` [[ `}{`$(df -h `}{`|`}{` grep `}{`$partition`}{` `}{`|`}{` head -1 `}{`|`}{` awk -F' ' '{ print $5/1 }' `}{`|`}{` tr ['%'] [\"0\"])`}{` -gt 90 ]];`}{`\n`}{`then`}{`\n`}{`    `}{`echo`}{` `}{`\"Cleaning disk\"`}{`\n`}{`    find `}{`$imagedir`}{` -type f | sort | head -n 100 | xargs -r rm -rf;`}{`\n`}{`fi`}{`;`}
\n

{`Make the script executable.`}

\n
{`chmod +x /home/[user]/autoremoval.sh`}
\n

{`Initiate a cronjob, and select the nano editor.`}

\n
{`crontab -e`}
\n

{`Append following line, to execute the autoremoval.sh script every 5min.`}

\n
{`*/5 * * * * /bin/bash /home/[user]/autoremoval.sh`}
\n\n \n
;\n}\n\n;\nMDXContent.isMDXComponent = true;"}} \ No newline at end of file diff --git a/.docz/.cache/dev-404-page.js b/.docz/.cache/dev-404-page.js new file mode 100755 index 0000000..bd20571 --- /dev/null +++ b/.docz/.cache/dev-404-page.js @@ -0,0 +1,145 @@ +import React from "react" +import PropTypes from "prop-types" +import { graphql, Link } from "gatsby" + +class Dev404Page extends React.Component { + static propTypes = { + data: PropTypes.object, + custom404: PropTypes.element, + location: PropTypes.object, + } + + constructor(props) { + super(props) + const { data } = this.props + const pagePaths = data.allSitePage.nodes.map(node => node.path) + this.state = { + showCustom404: false, + initPagePaths: pagePaths, + pagePaths: pagePaths, + pagePathSearchTerms: ``, + } + this.showCustom404 = this.showCustom404.bind(this) + this.handlePagePathSearch = this.handlePagePathSearch.bind(this) + this.handleSearchTermChange = this.handleSearchTermChange.bind(this) + } + + showCustom404() { + this.setState({ showCustom404: true }) + } + + handleSearchTermChange(event) { + this.setState({ + pagePathSearchTerms: event.target.value, + }) + } + + handlePagePathSearch(event) { + event.preventDefault() + const tempPagePaths = [...this.state.initPagePaths] + const searchTerm = new RegExp(`${this.state.pagePathSearchTerms}`) + this.setState({ + pagePaths: tempPagePaths.filter(pagePath => searchTerm.test(pagePath)), + }) + } + + render() { + const { pathname } = this.props.location + let newFilePath + if (pathname === `/`) { + newFilePath = `src/pages/index.js` + } else if (pathname.slice(-1) === `/`) { + newFilePath = `src/pages${pathname.slice(0, -1)}.js` + } else { + newFilePath = `src/pages${pathname}.js` + } + + return this.state.showCustom404 ? ( + this.props.custom404 + ) : ( +
+

Gatsby.js development 404 page

+

+ {`There's not a page yet at `} + {pathname} +

+ {this.props.custom404 ? ( +

+ +

+ ) : ( +

+ {`A custom 404 page wasn't detected - if you would like to add one, create a component in your site directory at `} + src/pages/404.js. +

+ )} +

+ Create a React.js component in your site directory at + {` `} + {newFilePath} + {` `} + and this page will automatically refresh to show the new page + component you created. +

+ {this.state.initPagePaths.length > 0 && ( +
+

+ If you were trying to reach another page, perhaps you can find it + below. +

+

+ Pages ( + {this.state.pagePaths.length != this.state.initPagePaths.length + ? `${this.state.pagePaths.length}/${this.state.initPagePaths.length}` + : this.state.initPagePaths.length} + ) +

+ +
+ + +
+
    + {this.state.pagePaths.map( + (pagePath, index) => + index < 100 && ( +
  • + {pagePath} +
  • + ) + )} + {this.state.pagePaths.length > 100 && ( +

    + ... and {this.state.pagePaths.length - 100} more. +

    + )} +
+
+ )} +
+ ) + } +} + +export default Dev404Page + +export const pagesQuery = graphql` + query PagesQuery { + allSitePage(filter: { path: { ne: "/dev-404-page/" } }) { + nodes { + path + } + } + } +` diff --git a/.docz/.cache/redux/redux.node.state_0 b/.docz/.cache/redux/redux.node.state_0 index 99ee1893271396dcf3c4ffb5eb406d645ef97e27..088afcd481c9bf33ad79558edfd51f2184c7912c 100644 GIT binary patch delta 71113 zcmeHw33OXmo%eluk|o=55=T}XXK7?5&2C%r64_}&>}*AC_M}T1(pby$lGv6b$#LA2 zib8>Y2MPqyUdljeCexM~plxbCM0W~PU})(w9T(Q1>l@VhN$)x1-*F#OvJ*RZ zMp&RSog7KUwXMm7mX0_Ab@7xI&1k#gecE7j{YW~K9PGa$3NS>Rfob$|rWZ*HNAB2`HqWwUP0J#VKzr__FIdsr zpJ@^goVh!Es~wTD+#SA9Ztl!VN5qqRa(gHj9ImQBgHD$#;2i$+-7WKvsun78Oh8NS z{+V;@I~|V6p=$uQs@AFaMHgkg(M&ov7I6fs=%?GT_XN4Qm1C zSafh8P=*#-DxfqRb#y8UkXMz``o@Me`I+DdFHLMGb(q_}qs)mRKYdQX5pm?M*s<8r z>BwDp&c|A!W;8UQ5JFLzUrT|EK(Lw2NOpko`47NO(aK$A{Bu$!bfBZegcR) z-R|5&*UTGt*Wc_m5d6I*gT+LEK!Z(GO)^n)B_Pi!$)TOvP(n+sOC~^J6PE691f~+X zZR#J;hNGFj!26nVw=a9SU2x50v>9;*Tq!LY&p@<@9~%0!fk7=3@q9X1BP`%dB;!{^9D#ED-w;ox zw1_ho`ia-usj5dE7V-Di=6w13YUPaRQ?>NUNLj!=s>Oz*@q?Yt@y~8}&YbcWHeEtM z`@{JcDBdDMFSk81YrP=cDUqQ}Dw!CG3rsiyRb8ogUw=l6XGT(5I^s+QoI}w;El{~_ zSR3+_U4+!b-rOJ8hSFN3BH+GgxHlC|Xpt#_iuK8%OsYRNlF=el1La$y@xJ~cEj1RI9#AjQ zVx8sXN1=G8T~O!5yv4xTw>NO7%XQQd@dRA!2a+QR=&bU=giVZB_C?bf+Y_lFg?Ooe zVo1kR@G7I+IWI{pych2|KMx23aX<}^94)4-ZhqV+5_bm}mpn^=J zk^X^1q#{tMOKI`z6q{+&>2}-2TrrC*_vri$xu347$lbYfY>^;ZQzT5$b!etf8-%tI z7r^Y$Gh<~w_9@B?3(cV@*s{>q_y$Q*ekdX-W|t8fbOn#n1{ zdvbNI>fA5lfww;RIf`<___1s56}|HvS9#`-@95iaA7WGtF~6cFx9q?>9YPqr*AML{ zc>N)H-8-DJu=pO$=$(+>Br3jjztWof)X1FN4?>l>*eBmH#xdhZa}q<>zyIBs@vAp>D{g(p zx$dg>=KLS@|8Z@yb_tQ1g zax=d)@7;jR(XZ4g{%A{2Pq?k4EgaJl;b3b=uqW2s91XTK_r%%~9X(o3*;ltvfY0W~ z*1*~(XAj17I^uvJixhVOPvbIr0^VM2NK3(^>`!PLdwR5ZCLO7OXb(rG6cg=JO*>xL z_0!GYg}*T!b=NA7TNVqP0i``&bV^>Dj@@f%$=VIYRzpc$%-^`6S+=G~!| zRc$L*wYKDH^4tBbJ>j612!>l)J647gJu5@;p7x&Rm0BX!99|g;cI2+f-y%jh{`lhY zUEc^glxuU-f9@N<@tz@CA)bfso2twx3selJv`l7fSN|1Sz||UBncH#y>}jF)-J$kX z!SJeSe3(RT` zHU}Gmh2ytg7I2APCTqaAmnpv7PwtF5u2tl!TULdFjje6XMONL`+Gbz1 z-j*NRsnqgMu2sr%-+$7b_d^tGkq${Eikev5MT#x6LL0>D%jcy2#!A{Ic;Yzq7%ljbDAY#i3j~e$Mwl zWIlW3k!_NWf{zg$jURvfQ`SBX{j=W3j@OoqKl4~J$YkPAKKcOnet^29IbO z26(=vPm^EoQf4jx>1ZKuu8 zP?bI7pLp|gikwHEqP)mIP^Rn=nt}g&nX<^ysqo|TltuZaZY3kZ$A4O`yvRK@vf=l? zOASMZl*Rn68s!N8U8S-ocmI!D`4!*r%*g+fPr1ezW#H4lTgm@Yr*Q8-e92+g6rm1&^(v*V zy0xLXd3SSgRcPg^)^KB}qfM8Z)~C(E7F}vupN2a4oukS;UO7*x;2Y*BcSumT%vEMB zKN$MRr`u;+wZz;zKCC~HJfT0~hvzDbcG)M=9Bi2=Jnf@Hx)x}Pf(9f!UGtO_A^l39 z0CWEMJmp6c75Thh*+3B??*FQZhWv#A*V z{Lpgc9-~oTqtWR0CQG9?nv{o)MoNpaQ3~!Q`9rPB4~$n=g%y+U^Dnh45SBtB9yn zGFs(D=HmIDiz6B+@urKFpL=XmX}U!Dk(|ZGOO;u!AFskJVwWlxx%Gw^zlKj6 zQC$4RiUU)4QI1HXM(j(qACry!fqA>~W_$8qH{zIlq$$~!Oj%;D!%D^vNW zQpzWxWNgz|n^yiqP9vI8X1Shd$26|WC_5|6w#H1R^S@-2t^9beb0OcoM`(8NX_;QpNvuukxgv!3*zGX1S`@UPE`o>}=%_AC8{P;5V_yvR3?m}HiJd_=iLj*|b{5tBfd&p&pRk~6+PezpF6{)G=J$))_U?<$vo;_^$rr%aoF!#&FCeENB1 z#e9CzS7-|PlV4G`Rq^oi%If^;dz52UJnM5@Dn9v%&vB%ZJEuBU=RZ;JxVMrAmMaVS zx62%D;`M)*Im+F9XT4)}zH_SMJ#HRpa0r!_zoo&kyqUkW)k(j;cboH`N`BxYj@9}1 z>~;QkC4cr7{mq(NozHmr1p#$6Uwx0_%@5q;oKnL(diB@W_d4t6DqrEsJ<56fRJE&y zul}y5f&Zx9QJ>#^jq|d(Vjd@NcJ6m@$6n{^{N@wR8yx(}{rUn{bUWU&h=2V<&ei!_ zKjOG@5&tMx_voRvvf*e-8_MveMarVQ_p|Dpy?pu!=jQwszf)6tdEl%1Qm*={a;Jcc1HjX?)wgu8sUe zwQF_$iF;j733DiaYoIK2F8|EEuGM+(d&{mr7Yq34mj}!8UmkQ{GaJ9bkj-Cqt@}y? zr87U~?ou4z`B;9>$K8u})(*1)Ho|&Y1BlT; zqJXCz{M2sGqI~~$PuS`2=!vh4#bYZ&p>Rh>b4!QT5^m|}Y1K3>w6Y@gSpIo@l^V72(<~jYF>!Y4cjB`S5_}TW0|_ftml(zxmoBPv~sd z^Bet}ogyRBfSAnG;ugO6xR{~S3(=k^hL@7uEWuR5iQ{9(%+bkr`ft~2+408@|!B; zZ;FiKJlM~t-t4L1Pmg)Jlyi8~E{~6|@R!e4&f(RMDZc!6e|e9>Zw!?Gd23lLI-m_j zW#3NOciB4e+?-8?oO+Ro7?bB;sV{$-->{(kE@f`+cxL%oQpu|XRsQrx%<(7XwnMLaT#h&Nr#Jr5bHeTTi~d_e zDSv;3@&P{ls%L4wa!UCprYj%BFN-n3Dg5@QJyraRPdY33^ACF#@E4x;Ov!uam4C=l z;;%yCVC64<{7uhC`4bDv@AXH6iFh;|i^W4LTUweEJ#EclE!G}tYi*CmLy3-dzW-s* z8s!=R^ZfKh#4|q|Wc{p{^@+J>SRd&(f?~>z{Df34*9vzz&L8r`b}r>iRC#r$qU&yVW^iK!mJX6Xsa#02>o9 z#yikWMqnkyMrdjL_~+d77fZMSv5l;PHS2TOz>+M^4ho3a=25+XB`ojsxlD^PKN}FR zLXSQC_zS8pn-T)hmMUmr$Ne1OKE_4_ zG$p_3Q0066#Z}K|KB`W2`vvJA;r0LQ@bdPX-E-$*f^GUF&KE?Bh4r(z9odlutk?FI zAh$>7>_Ys3FApnN(cZ zznylMOFV$~hIHCXvk^9I2uncQ4_@LA<=oy2A)z!KIZ^}zO{Zte3bu(Q*??FTB%q)b zUVXQ_j&HtAomvjb2;vyzJEp7NI#XByoZu_4A$a2POI>yR?>^_A0m(Wu0!euZNmS9p z02^dUmKM0ga{NqVJ*-C;H5f%=7(xx=sZU5=jbIDEk>9o0Ib#k{p5KrophaD#@F(wg z)uL&c2FijQB+}o-#>CJX8)QqFUzdv{)WHLgr=WKzmI3kA2s=WsHAFeqi=_~nFk!(^ z3kI=#&}aj|z#4Rc+Q4EgDLPrAOMM^(VT(oQ1Oo_4(g*;2FB{@r z5oayG`Sa@R>=NM=4=}%=N~@NPiV-2o3&~~agyj@MoirYlfRw2;lU;0s02TU9fXaqg zg_thjM@^t-0NWt}O}Ow-X;?PkD{&#AE*Yh;eQLrKh4$g0r&OOC(hT8==%Z?F2ecuu zOr!!4itz+ybUkSmcy`ntNFKm8-sQw3r*CT%ik!$e%7 zRm4US5);HdRg%gC*!U;!R_8Tg%78X739AM|7lIS?1q%d(O#%dM#`v1rvf8L5tGHMr z^sF8QV;Nn_fVn455Q7!+fFX$mf=2`)kMWahoxV0u^I_I6lmX@d7E6g40wFLKp~OKM zX;bF#davrulC3x-WCh3+5)z<+UICk6CZpn0unsK|n8Tb8>R7~TqfJMFqD@as#QRgeZy&a_eV9t8JnINF@y*aeyZz^Dt+0IjWnO?_qx4 zb%(mP61FTPF_!e~LXY=CgAkeDWGt4_Ne>Jt@r(XIO!jtwJBa|Ykod<>xo7a_j=HAv zYaUgncM%~%+YjrUBe5m>l_J8#n<*Bgnuyp4T`bftQb8V|o)KMgju{HU&w5!>muyj% z=8wPR@SR77HyPCvQLxuQf;6{5`xu~?X$B)#@aGnKre~oPq-|`SIJEnjXRW(U6M!lW zSdyAh_wZ)Wqa<40`sDrhslIbT2_)0N_9WINAwiQumic*Cwa1$!*|S%WyYz%CRAC`1 z=~KKFs<-wuk@APxkdyVYrGTL?JIe5<(Pn-(3O@$sp+TptN#~VqhIEjmqZ>K8>rkAJ zilC7B*%CI`$fAP7r5M6v*)cp3Yj+w;@cIWFzO021ge@fTV`83kwiWwm1IO2D0)TBG zJ%CYa3nv6#6^U7L$Y?si$*5qmgZvA(s^xoNZUM*S*FzF+71kbX96ZNLr~^p@_Q6e` z5b~ZZZJ}7e9JOwpl=$(#SG~%5Uj2;Qd%o-tM(HNjUqn0<8sv~)aG>D-VwGYoP*L-j z(%hgQWOq6-8_j8DEBNClUA2`Y;KdAh$W!LqC28Hyx&;Ga4P?APFVMg}tXoJXfZhb7 z9S)>30RBF#d>&tMpXymax@Em?vcSi|&=fk@#dfg>+rX#YtIo*+g9xZVup#_H&ZmTw zIjFSNtc%5zp}OEb!oP#cBF^jpouVJAntU`b`#Rk}Z{_M@F zH@k*4i7XU&hSYEq8)d^R%Jv)PENLsyWJW}pz-c;lu{G={s}LcVv@VwM9jwm;Ml{~Z zCjl1FpAEA#JLqR?^hfV!75YL<{emFU@1JqEG>}zeRV{_I1EnEN_BWq#`|A7Iu*lCP zgl#7EvxP~7?W3#^^l_1uK1^PTv;7SHykiQ<%D{~kRS4nymHw($YN!5$ za3v(jiF!@`^z*-Y*4@&E2Zfq;v2OT*vEW3)!6iMX3q}$0sIs}Le9MPjwOOn7wR^UJ z1R0KoKc{=IBsopbSn5er2wOF2aeb*r&-mZmt$OPvnkb$GaFfb~f&yH(^9Mhx`uOlo zu9?|>;e3L~A(-JENYnw5x+P^ZD$rKiu+Yo!8bBIoO$xqQk8}e7L=I%PTQ!UB@bDLZ ztd=WjUR_q^%R((+ewPSvW8PM9qA$|k2|KaTWTfAT)u!X52ppT3MhU(+WH(g%-nY-25 zS<|d~FWbPju!t^Kz_EB|a@@q2O1IFseXP5P6|zv6$Q0C)@avo?>$5`GH?s;ys0g1~ZKWAMthZKEP*EKy|Yw-E50y4PVBL2-pn} zX{>-@3gs@?5qw6n76xf?_-?V43fsUGsONxciG@?-PVT7K94 zt{GlpL!u`{kYx-*_>LeG;1M`8vx+1=@d-IE2|d8IPLLir7dR~>Oc`jy1c-=@AVo2{ z$l5xQ)}Fs$^-%C+HDGlhJP>9V>(LDsm_CSM0|JE;lHmj^JVBrYk#e|FLa`#1wqP-= z1wcn?99oXdxY4KsYyeoEBN8bjA`x$Wdl;-&{CwJfy60peci%H%qJ5aA0K=ZKE&Y-XR_dcMpkJi)CexOM6%a>k><=-=@~`%LiOD`SvSZPJVHh zI(?pX0#Y_$D0B5^6K$@qac<*_j;m7@KmXl-x|g4a*%T)yneTwb0*p(18RR9=MWjK| zTcTp3R%`x~T=sg4%dQ7HEWCnn4S)PuwT^E%<(RR?x?qH^;b=^hPS(US#303${XF`n zx*%zh4HjcblBaA;QWP>$26=mAc)AEN%jHuq(4D{rG7}k!*?;F{*VJ;d;bmNL-egvf z=nS9D_n8DwK~dQK8m~X0dii6O&KfTXC$prZodx-^afgpzbCX(=h0P2ZVtwDv+F8dL zK_=IO(n~F{e)U0V$)V2qcAALhS@6C#F|6`0z@+)YHXmSh(;^UsvV+NXXx*8 z(IG6@3BEDASVTld^g0wsQ<<1U{1kR1De(hB3qs8iO-OyFTLE=KY;;WK>SA$}yP}{X zf?!yvK)8L*Y8R7y@4aR-n-oL$QH z+rOvEog_Obm<6%JgG_4`I)aRj^K_;}hm>kWf=^?k#t^!lB`U*wg}qy}nn+4P6xKL* z?13suvKVX9V@(t-X|kzjsT~)v%`C*iEW{f0pTY*qHV7F37S}Uu0)X{M+29pvZe;ub z0ti7Y5dwMsQ)(@LGOY6VgrCZF?u0u@-m=lL*6GjanHa=oRz;bOPNJLzK=p z2)LhLeTC}d)1Oj3F2V9*z^tsn7-OS?20&Ek02x0Bc+zQ9l1YLF_6p>?>1>c8BF#%U zCBlpracB$;J}5?k8Rnm@Yo-WGvfX+V6EvP+X@2rHmrs?kk}B#1Qy5@lTyZ(QeD@F4 z01w`%&Wuw89COF4X`V840>6{=iUbTr^5}&RT0rDY;FxYSy|`%0Qc?i9jes2z(*R zKSDDJ3)z535p0S@N=WEf1jSH%fV4XiEwBhv7yb-rNfLMz&i1@=RE;8ekq}jj)9kJN ze8*?pb<@bOz^7tF@u5qEwaGg|$)S(vgW?@<*Z|80@%?fP339;tiXn$8kp?emMwaMF=V)#&<@Fhg(5>o@5vuBb&{#hq}L9? z59SeuTbXci^%@>gFY5oWYi2nCY5`lo>p!o0yRcBZ1~mtO?S$!Ls$`r3x)LiIB?-}u zuMUNFu%N*Eh|C$)6a2}lvRXv5XRQZO5Ten|L}3dFh)@;aMQbI&4#BMl8${s3aGC9R zHhmNr#$;tnY-7%*s3nv@`p{5_98>lbWwCN_5sVj>FV#p9)1}#}xq>>V)JVDv_8BH^ zd9wm-RGgm8`Yvnv5m~deGBYPt94tPHL0T)O{A>w7^pfhEw_F#NF~f{DGdXEq{fNW6 zlpqZ1r21c?S^R6=LD9@s@Q0pr`9icU0zQG99mo~GpAL2NC(hBJM^R2t|8uujloMHhKbcd#RX{N4i{b*0U+S83A>ajRV|R}bZbwm$EbF7;5j#YV z!>VvW%tX=&zT=0gk2ii^^~jAdB(}O`R??{HM__O(yNET}G(9rr2va}|n_Pm-3`!nh zOIo+hfE0*R$j(G>i zy;cXFcg=RrZ-Rwqt>+?u0dPpJ$SoEW;u~NZ?>go1@z&?m8T`)G&RH%IE=B?6E>ZKh z0AdikeSj0{0L4bq9~Ih^?|9uc-)owFMx8lV-gHp@kAJIQoqaA^TQMdD4R9|7lGx2N zuMK{;R0xG=#O53-xd359rXiUy!ZQ5i9~|?R4hm%plL}O1OF9ZsVTR!5|6Z+gOV&7c zw>mG13=A1xl3h*VDfJDKoq!5h1N)fBN(6wVfn2Q24u#lpc2JboMJT^62SVLHUSl=% zQ?un~#J5P=(K{q~Ooo2)b(fbf{JmPU%VY$z+GUB9HRxoVYR{_N#0?>xC|E1i!@x;6=BIe5lSfhg26afWg&thSXk@K=7}_VL$la!-e= zz7eMqAf?qOc1M_BNWw$)hvcgS8)gSZ5D2B05^fXv%$~VVGyXL>=Nw_pY$a>cH+>+| zhna#EmrS5e6a)ozRiEPLpK?qyxND}H5SJFF!G%`S02MC~g}N;(NC-L>#b(gJFba?k zFXRP`*2Wt7wyDlquT(g&6hN18mXW2LCSjYz+dUaxL}Vytth!M+2qMF2f;89@<EuO?W#e+%@Y2NKf0%cAa05&CB&&=oxq|obD{n4 ziN3D-+@MnBLy}@ zW?BgT23w@FSQXBhzpALQ$ZeE=idFEY=hWJ@Qgd64W3ozReTAVug)D*>MJBZH!T4AI z-BsHnwSqYnYk?BVyx~sT;KzUc1-EaGm2x15vF8VxUt`pu7UEA1Y2kDJ%KfT$LGiS; z8OIr6LzF+g>J4>92i8F{f3YrvrHvwCP#_NsKj7qAXYCdQD=4TeCyMF9Rv?QX0vetI z3@WS?pA+2x$uM}fiVZ$Ps1V@We(3UfDH@EbZN!Ee&^_PrEr+)r)p%IGEDlc#ryHIi^z}C zZFNB$W>cf3*&Xen!Zc9J2-#ie1e@?Ozmk($!j_|iNp2N}MGUG%dBsF+Xp&{2gHhaL zKtv30uvc}M^|4_V7UJ9fTSHdZ(XjmrUa($)ee0(UtcMMYy>j-aaUt9bzlXC7GNuh# zg>MI0Oi)J_@q3Ei**iVL28&GU3Sl5k>6zh z06AN6M&TqlKfR|#3anT-YjAeVe2|HRCV^h^qp1j#r0^bCL@=OHh8NZ2h*pVWEku(E zuQPXxEj=x|nt22FvI77B+HZl3rFsiG#qS!Ty_O>5agK_tK+ zx&gkVP_Yh+T{~hxTG3S^Co4NyC|@%FY1b!}T3kri{YJ$qtRPe=91$61na8Efc#{r% z`M;3ESwotVWsT^Pb+(0oDmE|-EJ&SQY(3j4O4oO@{cID9u+3~E+seAw7Pe7<5Jmyw zC8X6eY(I-gnp`-cYwV5!01?JADQ?oq@n?VQ@Mb5UU)uI5uwdUmg{TAx1Tx7CAu_=s zG*zHv3f;`Yc{rxFgVZoPw2C|wQzO_xc7z$+2T{=%R+&Ujt~3I`REWP3dzr_vz#fW-4YGqG{D?#?wx~muNLsSXi;00ms9Exi zF(3Rv0UM-gl&vzKK%L;xUT=iBdQgGE@L-1KY{`EX=~JO^k5i=|`BXo1loyK$jKHAZyM*x-`~3PiD}Tv^m&K z#B_yq3=0DRYwFhAp^to>>3dK-2ML7%u_lVr>ux1~@SoJWFh~(j7S&QqCMv$uky4Jr ztr1&jtED{vHV0!-;!YXmC(rlP@!^PbisI*8&$;W|FuB+1yCIZ*esxuucd2;>1J*=Q zCwcG^WCJjPpjv_}ryTRj;r)mV5U+1neSFhub*eZjs0Cy!ce%mP2mj+4WTR;?l6!=t zL7E-p*(vHA{tru?Gp3mtN%+7~9&$V9^paC*2AJ(TcF7MzxCGA6WUVB!WO=V_DILNX z)A&QLtG+dmYQU`|UHk@ULQz8cquLj{h9C?;M0g6^3ztoRx*8~lQ38aB&D#RP*}~RV zh?8wbRk9?Bk%tAmt@fk2I0Q0GO0r90nj8EgS%D$yN;>uEhgDIT-W9qa1VPeaSXv;K zJR}M-lJu&XUwO=O-;)YcK#{F=SGMl zBA*OPR1l7VRg#+~c}Xl2Sl0`XTGvHoHi!ikhXznJ%*Mpt_d#nDs|_tXp>z4m#IVUf3>4Rv%9A>~Pdv6N^f-7%3C zHry>eP6j@r8bjF5lm*+%_6l=s2}=k?)gTaer8va{P=$P1SY%3m(FTHnVyX?InjPOo z*{ER52DXVUW`6w5vc>GE@aD)020JfgZLCRr^nTF{pTbJ^v%PFFJC`kH`^3)y7Gwdo zPlWXl0l>E?-S)G6Y@e{>2v<1ZNm{7D2}lL!F0N+-h-iQ}BnLS-u%wQo?vNEm$nMk_O3M?u0Nes)nP^p7W`B5moOe@9D z+C)Wwy$;!6;4E9lnna#%8S~rzHi^v3koX^wNXW>yj|x$eQE*})jE|P8!lupk$aU|LF3HLJq$AxXZI2lSt@t%M1&X4Fzd~ zihQ_{lDp9{)R8noC>uc7o><|zf-A?>x>|5sT(6$GRDep%hE5jzJa>7jppa!qd4NCr znp&&-O~}BTyZ$0wwM5tKyI-=0B|&F$S;1$to^UW&p^Y!lVd@MC`x=dPJ~ zb~DKeAe&W^L<%50^8`jHYpmDIlMv|@XL@5$VUD+mFg%!RGtO}U)j|>5)BK=nYaJA# z8)QR+fiXd*??vbO^RZ>|QsSP|>kCYn^OU!PM(`{iszMw}C+Q2#$*_W{ zV2!0~!e&8@Td_Bi!id0%wSbPulB^?79WfZp7zV=;Ve(Pxzrw;Eg#}%vfotb6D|MbP z%q1cg)6)?4wiCiroMp!URHjzkFs01Xf)znxLadt2<lVrLC{>ccdmuB3 zjC@kzGBRc$#lVTF2CZ)SPh6?yvXTeS1Yq|rl>CNyM_rZ97D z#-b@wfU->)CeLQsmN7D@>hJ zjy`Lq(+V3P(E;PlKB?k4dRaOkv3EcSR}=J-v=DZnG^Or0A$3pHvqVJ}&SYD4q9#U@ z^jyeXg%oLWk71Jw)hFVbFkxY0P?Q43NCDZN1+EJRw5GJo70a-MQ8Iv9j3!It$!Z25 zc>gC#2F@?mtr;Zg5|$@m18HsoQTn>%#`+n>j>TC72zeq$2TlX_@UIN1gMCTPo9A@m z*wJF(hV&o<*_PZFHXX>MNNzu?*HRQu%OeT}gV6l=?Iicn3+yX#0Bu3S?7UIS2HsL~ zA4~;if>BmV?i;~V`f2jy`Ty_9{mC-!FgYOBrJV$QUM#yVG{F+73XFmwk|olxG<;Yp zl)P)Tv!>D_ltdgYOWH&x7A6WAtGQl0_by$5!o;{V$W6&Em9;T3CKBNr4c~yQf2;y0 z`I{nkvap4;>?VQ<^;I~4dU)KG=^kSdgH{E5Sw zSJBAnQ&_#bj+* zEiS6ym%g3ZCtAXvhisNb`!Pho5o{=IZtbw}oy{O&1ID5e0k)r|tee}sKJTbi)7T;S zY1LZ~(tyDzwV>jZ@j_!(`b9ESH-5Pbpz{y$vCk+tTgt@6r9idr(h){N&~eHTZH?R)Fx9C}Fw&aC{m zmmF24!VcsoN`)N#hvoBEDey2^UKlj|XD>NC|F`Qs4!rGp zkGG5=t_0NiE281no?uHyTeKw{?FfZi5w#D}i;NC_EM0b6y6jez zYm_d#EnRjiqAGG9HH0q(-4K2=3%WoqrOR%S#4cTSOLlbWvRg_U6jtoWGD6g($c-qa z%Wg$z7E#{PWw-iGR)utfAUG8i8E0Q2rY}ycEM0c1@4=wTe=5xq*^<&_w<4uu+dVBT zJDIdJuMRU$*A;upN|)Ut(*s)v_242KRJ!c8blGj`vRlCy@B-wGi`evFxemE>*)3{E zN|)W5ak|oFx7ByMOPAfE0!7|CiE}Mb+lu{5rOR&3Y8`BQr@~vZ>`Ry3f=XbCMOo>x zThv5%mM*(Bw?WaK5{gwLphBnZrH#9KQH^45)-o#wX~SFTvRiDIC|!0d=%RGlZRxUG z>`JD6u2vC4`40UgE~AcC#&JncFP7EJrOR$hm)(lnby2!3?-MLtc1xFYO@5Pb>9Skw zsGtO5>9Sk79X6>Ww+uuH3V?wsiFwcnY)SYrKNO_ZRxVxBr9EZyFeV2 zWxt#j8!GLZt1ey31|0W_j2j7 z+tOvXnbKvqsDAsOIJvfT*{wK8v~<}m&N!F%A5xhUPL{y4(q*>>U`m(WW{eAbt!Jr~ zF1wXGEhjsU1vSd0%WiFV>jEJ9N<GZjsO^ehh8tvRnPkBg>66rOR%`Y1GDzsG_dW zekCq+I8KU^r%%Z0IeFDX>9X51-Vj;3>^Ae3PDw3Yc569af$n6*mAIwLZsB5;F1ziv z95Y{d9JAPQ8M(S{qkVBvI^W#i-*9M{pWU$$-@=3ct&wshHT>9Si~@_07aY?Us% z?H1LDlieC)T;*E2?6!2-ZQ(_^rOR$TWu?n*>3W&cWw&fZ+)sxi@8u;-w7CSwz?eG) zu=~Dr*{vNi<|S^F`bLbHHbcrFP2sgprOR&Z*QAv$yCoj;v(ja^rOR$vy1-WXpD7tA zU3Sa%u~n>{1({#u`)~>A2peFT(_EQr-e_mP1haJ6t%wfdqQo(_-`LJxy6jfJ;MV$o z>9X6&vg@K?rF7YC>9SklXW$%coD$c^hHW>FmM*)Uyvm?-*=^~v+Y~EZb}PJygG?)3 zc3ZmaRwO0|OPAe>gH+9{eGziNcDFv;4cqI*sm7(tZk^dCaY)KA%jj3vmoB@-G5G=g zQUy3PIJ9g?gp3zXsF=ZtiWxR0&VEBnKf6-D@FgX7F5@>83eW{74Wb4v#Dc;Z$Gan0 zv7NP7xRAI>9@oMTif&V^hn>eN#PImPTl_&Je~WQsxvb+YtTQ-b)GEj$LW|!YeTKr0 zw|teVk)}i*u3y|zf?^3AgN#CmBpYG}Sdzs|DOI}cwvYW)FT1^Zt8*s5akuLt=R$Uk G@_zs^QxPlx delta 38777 zcmeHwdwd(!mA~)!Az4o1I1l3R%C&5gII*6VEZYQ#^CUD6H%W%Nb`QzR8mrBZ`Z zB$i6VA_Iv5c_1OBV)23gp`ldL?~$~;Y7t|bP!d~kY4nrc(ni!%YH9q&;*o})hK8fa z?^QLKjErtGM^LFNx2&tD0r}gKhE_0%!5%|9zsEG4PqS;AzJcg?-rGUfKkMn3y`<$Z z+H@Lf{so#kYLE?@W|@{D>VKHVIpI^Ky+s}X(u*=S^P@m1B-zP|JgsDtaRMM93EJ7Ot4z0?m3FO4oO8 zY#$M7WL^qAcwtvhgYeqon{8jd3|%-P_*>GVWhQ6*^ZCC4J)2J}YEOeu67ShQd&l{I z(^w^m?HBK~mG1YEX^W_)qN(PH;BO4(WPejICr`u3^9_;{jmc3)${ax>Nb@&YGdl4% z&4{_IzXjeB!;b<-g`Nfkwm07(nHilpU6@%f<}B^5AtsdC_V`PoJ*$MChLVooxpt(r zX8ILfg9TPTfl-0NR{NJ2%;dymmTY$C;9sa4L^m{vnC2KW;L?plON(=tiN9S_M>W%` zS~sn=f=2%Kf+6a=HO<^mcPl+G^?j!_B-*;>Q%gS@aoeK ze&f*6KkTJT4-LH%I`h~blGB)vY?Vwips0bvW>3THcZVmcIT*hzi5f>5dS;)v{9YuC zptJNw_pV=p)|`3hW-+UXrZfAVhS{HuJX!5xpV_FR&D>5rIZe)Ii8<2fZ<00XI)5wt z9gsAG_&aQGVr58<1mJm3L*r4QW5Jq41~MQO69VRpsV7pvLr z*|v`h>4vMWLdjDc)jU~~(nQ^;sVOC`9c}P8<%pUeY4*?Crdoz3=Ow0w`6GsuQ7j@^ zdGHpdsF*toyJKtV`1U15f7@1K;W0}zEFuFb(-N~;zUz5+lPnQUV){MX z6^W=O@q6~_X+xBW-?vdyEkjA>E#hz8AxarVCB}@uaUV(cG_)QSoPm9tA!^VK#dOAP z_AlC^7^a1-jG~sF-R}J(dFW|qJ}UT|H)gfG+|$tPZ_UXyp13U|npVvdXX|1f!w0_I zlnh0;w)h3h+~S{Acl=F@P;u5BJq^OqHC5{OKsW=7WwF1*+4nb*sWDn{ZFV?4qkj zy;V-;rfVnAd``59xn`|&;^GaZr?SgRla2FAdnf#`^v*6c({2gB_Le&<-t%x}iFeFC zCyz7hEsdn!`^O9uLFhfRci;L*h1SB^uE{wQDcBR)ac-15W-~`@F27*hdTz89&fZ;^ zKntqH{buCKJ2SKKT*?3H*aY%ACIb%yz%o7Q_ec z+fjNT=P7;jEti}t$5-Aw!A;;F-ud=(rFHB!o7VHUzwumY{lj~0S_}UA*tybr=1!Z| z;QMbnS6a;ArA~lu|zB$ zmq~v#G1Na;dgF@aF=n1Mso$wl*<2?#d-TEKs%;MskZ_ogfq_^`N=Cv%(L^|$j7R%p zLsE1o8B4`WCt5F@UGz^q+_Z-NdEy+WSNh&3KII+vH)S-_8ZZ6R!vhr$ie-sJqhdTV zkQx{mipIk!l1#>jDwyAL>u^ zC*>H4C&T^yi9||{lA&m6-X}i{kx%LN=U2^s`;%b--CR2Ut);VFpH|s~=-JM5=jG(m&H%x}s_z+LcD< zwZ(^{4lkv^tIJ)+N4D``-T8 z1?-8#Hh)sO`m?=r2cjnypiah$Cp>h(-z-^l{#(%bz}JZ+Io{2zZ<^?dV>e_%gn%ul{l z#mhH;`n=QUt1nmeN&n(I)qQUIRizJ(gp;XoJQkA&lKrwgm=ya52IawoJS0U229t@@ zY{zddM|55f^0tN(!_mRuU^qfY2GFw7ZU5!*4h~1-!NF*p>3U8h-9$@DkN(FU^KZWK z#)bZ-oFK9i$HQgQiw+~33cbjOPSQ^cmBu(8jm8rLgCrh_MoCm2 zl9S;?EEVY=8cd1((NwC`@taP1T_ajYf8s&=X?qj8n+eVvP7L=)gRw{nJ$@d=yOFmw z5+066g9Bl{k{s!>Mlnaa3uver-Qloc}1=lqLcKA#k@n;k}A5|67&_9?y+U)B;DQ4o88}DX-0q7 zj%Mh4mZSaUuP#JiaOr+?5jsh|7oq!B#G~P%Xe=rvNhC)4VdEPh;nYAP98M&}M3f%C z2+2sLAK!qkq3^yJ(Zz3ihv4_=2C=M}G37eqZ;mABZNq4JML@*p5 zV#}jF8U}CJ-#;8l1S1KyLKe<#N^jhOmeJ>KL@o5rF65)ntU&iWx_kno&b436-GB0; z|EgXiWMJK=^S_2C&Kj|wP)`?H*%1lM8JBjApv9qD2AMjQ9PxKX!_jacJeMuoZ+`5{ zjIAu__DEYrY2^cc^njy-@>Q3hO_1Qzhkw-Q>b3m*O7w`^H1lsI6>vG#r#X!o-*CD>l*``~5 z`(@}kx7$b7+wZ_%mzQopZH?&Wa@S^b6PwP&Xn1tdW$DCAU$B#(pdTJa%2Wb9!;Y#}O zJk(BqB%@nkV~zylgWNZ4CTKDJ5J8`DjOQaM)Y*LZr#|z_7=0pz_PVWMlRrYES-xW4 zovj+_*(|z=?jA=6=CQ=8FzKAugcT9zwh3bcB##G5z@= zw2*%H5c-Jg%J07xeGt8iiaE5u{J+N0kfT$2NfMo;a-PfOv3!+W+NV&FPUO%5`drwN z%Zk0;1(f!o1?3F|^j6oqcxTW_`tLd?vf^t^mF4iJBdF|-HDjTZ^o}%d_VaYrSeIqc zo9Mfy&;k0h<<3}_Z}4`|_bo*W=#+xq-4Yv)4Gf1%Z~PBTpHt9$I(Qg;)se~8Nz~c= zr18SXUQgvow7ZSB4F_X`3HsP1IzoRrQxSc6>N@mcho|zvW7UTH`5Vx`3+U$Z-EXuP z!|IzVT$ZP9LVx9Uyy~rJ6QbmE-uCj}y$wmd^pYjWPk;4u6z30zUPc?|Q{^eNj$VGd zu$aF4fOkH9YK`D2KleLycs~981LzvwGWBuPxB}fpZ_|ZK%O8FU^{t?byM_Jy<v%pZrmyJ#5d98y~f(aJ#UsjIV7% zdAcuRzoM_KK`YDOk2EenNWb-%u#V~{goWj+Zf!IU(iz#IdqNgI)<$C|gmvXF>cVf^ z=%Eigum1JJ!qN-T18lnVnnSHi%4;4M?!Ayt_r!OFF#$cuWuc!C-Yd}0UN3M#f$8*= zcOMfTSWI6$)U>XA`R&4rC3N2BymvMEAA2);?>)jrH1XeP1-pZ&k9$|~ehWO~S z?ZWv!Ny`xv7ZfW)zr0ZBET*#Jl$JNlARg23jF!haC7t15-DDpwWM;0wcu$64gNUZ4 zV#UO!lGC%K56eU+s;sDKtf|<_5S%v&mPC_aO(j^<0iJ~RNn%;Vz*a_7v8ZZRh8RIS zg3XL(SlFLcObcr%Y!FGy<%lXXEYckI`65Al@O8?rF*?#KT+lqJXl5_HwoABx;x1u1 zz3bo561uBP@OTgI7EL{=h;)6ga0#^7N{wrTCBFV3KDbGfCW*l)cx3i-FFmpMf5_{!M^AElBe7~@gZubjof&O{)HotK34qtaS20nZ~_#3Z&9Wj!`&`i8bCx&Q& z0LErai{yG?wp!l65-TR+tfJA##G;CKjbWLXN?N58^Mz$ayjsj=F;pc%zM?^}nb)BlK;&L$ zB+#QIsyLMu%?!3QATzcJOQInMeZFlLdzmCy;qWh!ao%K#%o|uMsP1#aAy~1RA{Mc# zNYK|JMoN?jXx73RQI)gAWQM?o1$v??W0hD1&6vaz1G4iVF-^rO%>XX@F#ne^#7Wdr zm;u`)*%VIBa2^li&6Wfvd>9%OGWn^GxmBcV+ z@Tk&L=^?Cq$P-u8E>c`sY#ii-PjPEqp~F@t!UDib32;R3;8*3=j#Kgkpb zwpJjfmLpw0U)MoVf@&k4bZp(7Fg-CPEZeGRQ2SwyC74!Hy*}S2t)ON#QD$iiXveO4H*T;TF6#Hug|wjl?W47Mw}uT3b(FaD^tX)bK)ep9)q`anh|aQ2HQm9 zOd7pxHca3|wkKclM}1h&Tktd~N|WGJH2QK=<9S8AQ=C%LqD4SfFmFdOAR2Z&0~G8k z1gDfNG5Ip>#v3(NB@%04X?UNqMR5(OAgWCK5^uuQP`y@}yTt9#$!Vl$D!u(Vw7AHR zg}@3_vII{Q6tG#-41#Z)07p`-)IP4&3X77aT12(XAl{e})in2XV`JMku{r6YX%;j? z1}CKx!&1PR+GYYid7rYSsKCr+qFRcWg~?7#OjxEbugjuE#<_#NEaH2z-Jc{C*$Cx;Y6y9D|X3zUFRl zxwP+t-sQzp1S*=aM`010mS`ywR`h@<%LaH6XByRF?&C_V2$OdkSM;-zW-;xGbJ&ps zaCgpseBGFpFqzG58+GRZ-ovq-j5t*!eYR$a40{t;sF_cy#KJkzob+{L5=;kiWGEVp z3=9Ut!ALk1jrrV3f>h6i*P`3GhT*NEMGE2!GpJ2F$6(h}All1jVY_G6X=r%}#}pOk zG!wQ$lbEMr*I_kX09I|jWz~dF6B83H+)LA=+!h?4v1*Fol%gsoEOn5Hy#w$~p9dL4 zfe?_r<^IGDLJWunxZAHdYj6(Ls~;T1+%?-is;~)Lc|!$HLf02smKLE`iWi=h9CuR8 zb@DNJ3}Ar|6O&rr!co{HAy`dm249&b3+h-*#{)f06|+ISFGEzDhzU`#Ji}}Q!YvJo z?o7xjap#m~C>Fu?fjG|Kj1CfE6WTV4o#mmiEv`0V2;x1i=72237K@ctCQcceY6XZ2 z?uA8_?zYBvY_^lY-18>vs-w3HLT8baWZMQ;_Xr;Y$XBmr zpKre%aN0~j114u%hKwoEve>zS^j!Uo+CKNnO*^*XoTe(4#%!VJ#C&+dG&2*fzuQP; zLy^qD4p9o^6jd2cLg^h#>@ft!Ru4AK44e1*sudXZ?IT%;WWgc9?i@%Ak^XQpne6f% z1R<@jd5DWQ9O~wdZ>I+P5QMqO87z~On9o{R)wpC`#|^m=u`0GJla!)@gR8XQx}ONi zq9wwX8-fvShX;E~5IZXgi*gZm(@O6?T-kCh4I6}+Gl+WEm@Avp&Etkc-B=Y>4WDM% zGj=dYvZ!empMQ5Z*S8|7uHR?TftckhfTt;|na^XEp@=HpkT)%2^txOBsVf&EV++=k z0&a7XfB;pK=|@pb`p_rPBKrG~(6SjaOig!J3Yk_+w!7~dgM~s2!V)2?py7fz!!{f+ zH8KTSQ|x4N8%5tlOBlUNxF_P-Azqz>C9kL{jfbW@R?`d`ETfBA`+ZI{2w{(X_64uS z1(Jl!fUQ&$;tfsZzBZ*vc@yFRI}48XvGvFNu$j>cY|&=40=@qeXgM39=!{@z8hhEE zjv?#ZP9Qip;m8hONNm4{=!ff`)3&`Ri+Zu7<@GE9alz3eG0h^Q%ke(KwPq31vi-B8 zEX^UnJ+-Fd3Fj5wx^r)6JIiGwVZ1uYwK~B9V-6N1?Zu(+Se;u2mX%bB7(}()WK~PK zoZy5M6N^)#l7(}d zECPp2Z^oH7efhtem(cOnmZe2V*SYP9ToiVKh-0jqlhsFqgTZhgCeuX9TR_ptP5~nk zRXK^5h&ur`gWe$CP4p~a1T5#nc_Z70yV-8Qwn^O}%tRz+ zpj^uZ&@N95PZfN~$umMzY=jUn6>!@HoP1T$0-}-2qynrJXo_2ptWTzKKw)$FgWZa( zAB%k5Ob@0!9UX|{tdcZDV+OBw#2y(4_rA78^+5{ht}5;wVM%Ffb_SanMd!GjE7D?Q zARfd!YVs_TWFfJhqpu(&(-YMq$tp=;GiYkT$Uu0aDh_lc$Y|Kju$d77M{p(u=!})Q zxOSJvF?W~wztB-FLtGoVDXxgxcQ}+cjZjuehD0M5U?5r`t>%fCR5B@eUNtdak*Q}) z%n>X?WK7)uIUo0I}fFbS0=6 z>5!~Rc{pXx_LNW!02q?Q95KXTPVTiG;skT=Ktc)drf$Sn&&X+L+l15!8%pF;1nyH%|4R!`8M#>!HLI> zyh_9W*}SAUqvcm+vsfjt?9bCVm(q2L?mW#&#*A*k zr(z-)2|x^+RaC+i$}alwIEu*}fQFQkcG$LUF^2;w%tClJgOI6M#0>C-A&2Z7fw$$c zH$?lVHl2_|6?qR# zTmc##)U;FrIm3=`fy%VriVjQMH_+BGdlbaHkZ0Ae-j3VnPOSjmgN6DIfFon5Oo83;(jZYKg_uxmC^C4YCh{ndWK{`?pPI*# zCfmN*ve#K|QdSHc(5tN}2~j^|P|5%@S|}6(kWddhKh!k#Niy!PvPC-*4CLK@*bQg= zMK{DhCDJUAWY7|gVEQ^PoN5A=XyECo6imu)gM++PEr&R;8=ID9h-r@Fv+Io^?!cIr zDW+X_0QTk3$Z0ZkO(f!H>R#P4JP;1sPOFw0+v6F)!15Egkdd}gi@eT?HqAt`vNQC~ zM}^KJN3O7?6+}bkg}o|F_jI5Y-!ceK4BYBWji&ANb|lXbjGQ(lW_`X56;Op$3`|Hj zx>-@ngv4H51zszsO@WE!EiDHCGZbg&k=d5>=&wUUdy(bVlZ5DOpM#0PUaOdseK1)S za#MgE3Cvg3FiZJO9a57@<~9ewx3RuzOdonf^$i}vrk*6Mz+@;zFm^SKL8Ace6T{F9 za~MM|ZWwu;?aLK|@59Ngs7_W**J;LQ4X6S@Jna4{ck_%5Go$6Rva{j^Af$M?vLmLnlu34xN?*kU$l zW~z3?xfI+oRM7@)bWk?$ZSGWy3@EsgdfK;J25x1ig#*<6yvXD%sLf~_K z%syqsxQy-Rnr_)Ej6QWm%lx8GN#TPBanEWwg##IUJx&`$$2~3~d_B%UsXq|G*JH6T zi33|!;Z=CmQLGz^YT=%ED1wiz!q;QVzz0`dvg!~%=nwl3_2NLrd*V5m%Q!LW9v`R+Hi~!1>8kF}Z zCb$~Fel0PH19p5iqQkk9DpP>atq+!a(E&_=V=;yFdF8evT+j@Q`#g_4RI zV%Gbb*4W)`qlW+m**Kzd0Th4n>gmCOK0LB}$5evdE&}^(!uRvA&O9P za5hbqK*=321yf5|1%Qemogr3U=O+sksIKKicA7>@0ph5svKhpuCLY{lF#T7jZjhR= z9ou2pIsOsEBPoj*+|fG;3?v==%nTE5S|AqVgXDGQVvM{Bb{E7W*{t2r@n=vBNy74S z&R2j!>_Id6WF>3NnYrxK-seRbYOBq08IDLo(`%Yy#r7d=Fx4EZ62JOQ{ z_IBpNL;NupLrq2q+JtpOBVED;ixkyVWagW>5fFpdmvz`$SOCS&Dseg$P^lt8ZoHQ1 zvm3IGP9ot7kuPFaumYt*BO=4xC1Ub3B#y4(T*-`9WE%n8)pR#+m%*Cj57pHv=;}5X z(}4Fvwn3(K2O_Kq0AQ1a(@J*q$(=v)g%vIhG4i3$oCX5vbu)Kle2N4Jj z2g8tuzz>6iL&NYF4#;Pc#vTpOX1@QslQVhIhQ9S_p}ok+>kuguD3rovoZ2=&y~giW#_ZjuqDLdI7Hel1WfP0IGaL%P#tdz1I7LkT zj7YRXBywgV#VV@--Bg6cjF=yRs5(wlDSB3yI^EzAOw6dN1ysldVIa%&!FiP7PzZ9X zY(_JS*6?6>?n7&MFmjq_QO+xzO1N6f=5xfXDn;`12vhtys0(J}TB^$jyn#4?Op9=? z(Kj3bSehMqanKp=G<*SYH4;%RL(D2R{LSOl5RcmE8`m~o09%7|xKLXyET@lr0?mgS zkH-h)2A=6a%g!RuK%A>WH1NR%l3)FQQl!}aGM8g>vVptfZT)QB8Fm>1KgqXRML1SOjSJ9g=!Zyd98Mzaa@ z2O~keT?Fr7qyMH|2}>(ekYSj4V&d~f%RY|C)xlMX;WPqW(AT)K$f<>FqILmGlI@=$ z$xXvKg$$7<;e-MN#1=6_nxUi>)k#!C{lSPY=z^;R2W${3kk+%64-P);khwi~3#)*#tjxxD z(3(KQJx#^y_wJcCpi`^@ZTXo_CPb#8)6~8u0*5EyfC2x80*H<#Sd}YqcyPjA`D#9w zgfk{7NDCmvv`<}BQO9scl}_}H?z|R;PP!V zsoi5M=K*Zge8SnM6>S1!Tmx9UJ01sM*bx*Po4yo^iav0)kYtA|8JrAXadXuelZ&de z!>mR4stMRSEVtT>H)sWRmX~h@l8kTgG4wZJZpY3+MVTan@Lf~fb+SN_MaAQhaBv!u z8mJ4ikUhYK0ySb$mIIYyE)L9KeZDRZYpQIJ!vMn3g(rnr(MIE{0ObncTtSHeu&V~8 z=c3HA=0ej|C^G=o!1rMr%K|Y3(vFqjq*fs74X&o0WEv2HYNa?n$HD!bV~=*&XoJA? zeI1SG7oD~o!ejFIQvuW!ESuTW2;WsXFm7q=*m9v*gXOK}=aLGpB-*4&c&Pm!f>->1M4o{{915xHFE5vzSVfKWB5b{ z6M{@q%4#a1U6%`so51AgzqB`=*UcTqDey435C`m~cb^oZ@cldNl*j|kjTi2B2bzHc z-eMYVI849}pqa#&V26>M@m=P?n-RH&N7qZ+zG@89pY=6%6&+{fLbtgow!Z-Npq>#8 zUXulg!5NgVR_Bv5IA3h`F=1YWBSua!*>{>T2Uqggvb1aecq1M zI$WM@;T!#HhD3!WnVcCr7K!G>S#AqD_%o?e`dtH2%F)b z0r5WbjO;JUY}_GF`{zq^{Tg8bj`Yik6nuX|fB!&yFg}=yOQMtziA zEpWv(S-+oJzn?ni&O-fuDqsf?%ka>%em}K-Kec{8wSGU<(jc{hE36z}tvNmn*ZJ%B zQ{f(B{eEiwero-GstF}nUZbqvPi5a)0cmly%d9F2R~ppsr`GSM*6*kCZ)vLEPi0@G zRKK5Ezn@yapUS>W&AGi_zn`ka>i1I{SDf`-Z2O>*ePNcD?rQJ(I`8WDQvvpaI&J-a zYW;p{r26Dg<>XQQekwoc@uxj7H21tv{eCL{hPe9uRQIb6YcDO-@2B#!KK1*laK)>B zKec{8wSGUfem}K-Kec{86~12{uJ+h>Gwb(L4Y=X!9yYGuPp#iibu~FTLn%O^4VoQl;o^uNDI$A8=yDc>^O{0>5k zL(QA1=gH=E4-GeeEyaJ~>I-)@Uvde0nE%4njZZee=Mwh(Z9hEOT>jz7mg)1IUm;w6 zM~ml}``d4~w0cI6@aDIb-{JGD+D+Hp=ke0@Pk64Pd#?3l={0KW0(#@q-X{8!Yd!1e zZQt@PDvyqPejw1BpYSBh*AdSxh~D)N9!#IQ*mEBJ%7dPs@@+}a=TNyN?a3>{M2sd9 z0|PNJ868XvM#)fIil-!bC?yRfqv0g6FXOgs(xmG)CH)>r%fs((+V&`-uYbm~vi$9* zJc%YO4G>9+h=cvH!~l_o;;~pf8IML{Ly0hv3F)W$v!08D$5Hw9&v@dEXW9G-Hbk)e z%WrrNo$U}$+I>FttmoOY9p`g)AI}S(Ey7vy_657o!!LS9&vu+Iu|A>l^p89rM`tj>6MTC){{o`Z&Tg?o&2!( zA^NJ{+fMsJ-bK{+A@6r+*FD|`(X!HGkE}gQ;eLZN^PYp=RrKR;@rLQoS9rbu{0Z+X zEoVvKTlQ?0dA*C5on@cz*nQ{<@743qvd?$zJ_iEcMQ1DN=j}e<40-?c>@<2YVqF4d zU(EZd7W&r5y}jj^hrR2Yg|`dz_-^ki`rJNmTUlQ3eW-=L@L6v!UH^V>8{N6pJD+~~ z`yL-9TfL$33){UvZ5D2^dq9iw&aK|_n}v4?<>R}(-)|Cbq8>}0=4 z8_0B*Q`bVDzp|TtRPz3N6a0p1V59uej5pOH{IyW-(7fMiL4QjpZuRz-mrZ%U(Ing{ zlwY~d`+1M>e%5$p`Gq%mkNMDD<%wIp<%PoE+a%V%-}|)iXR$we{3`F;=)sS8AHlKY zfD|PI1F>*CDi6lPkyIQUtr!&tQX~05b h_WrB46$$sX(~%)>XLSG9o0me{J14RoAJ`TR2A!H~}K+!=5b+`z?KDFy; z!bK;-2B<(mh#n{cw8b_>2oEeG2sAig7(s;z9VXOBDl9b+OfbPl^x(}dE^ox+s!Z7Ww&q0_FX9md~Vpz7WsMXHqjEVg8UT$kN(;GjqNqAKqP&n@8*s PmrH4lpR5p`TYY*3BaCg_ delta 117 zcmV-*0E++qL8LyAFd#BCGht&gGchzYFl1&lHaIb4Ha0jhIWuBpV`MUBWipXa+7mhe zdjcW~V{dJ6Z*FC7baOi*M3Vs;FO!=C6|-6ccLf4tCX>D#CX;{;6|)Zs^$7tavjr2O X3<`%9+0OS<{XZgUlK~o0lK~+8Rf{E? diff --git a/.docz/.cache/sync-requires.js b/.docz/.cache/sync-requires.js index d235bf6..d942a4e 100644 --- a/.docz/.cache/sync-requires.js +++ b/.docz/.cache/sync-requires.js @@ -5,11 +5,12 @@ const preferDefault = m => m && m.default || m exports.components = { + "component---cache-dev-404-page-js": hot(preferDefault(require("/Users/i353408/Vagrant/www/repos/documentation/.docz/.cache/dev-404-page.js"))), "component---src-architectures-mdx": hot(preferDefault(require("/Users/i353408/Vagrant/www/repos/documentation/src/architectures.mdx"))), "component---src-index-mdx": hot(preferDefault(require("/Users/i353408/Vagrant/www/repos/documentation/src/index.mdx"))), "component---src-enterprise-get-started-mdx": hot(preferDefault(require("/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/get-started.mdx"))), - "component---src-enterprise-installation-mdx": hot(preferDefault(require("/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/installation.mdx"))), "component---src-enterprise-index-mdx": hot(preferDefault(require("/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/index.mdx"))), + "component---src-enterprise-installation-mdx": hot(preferDefault(require("/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/installation.mdx"))), "component---src-enterprise-releases-mdx": hot(preferDefault(require("/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/releases.mdx"))), "component---src-open-source-get-started-mdx": hot(preferDefault(require("/Users/i353408/Vagrant/www/repos/documentation/src/open-source/get-started.mdx"))), "component---src-open-source-index-mdx": hot(preferDefault(require("/Users/i353408/Vagrant/www/repos/documentation/src/open-source/index.mdx"))), diff --git a/.docz/app/db.json b/.docz/app/db.json index 5456b20..0e5c903 100644 --- a/.docz/app/db.json +++ b/.docz/app/db.json @@ -702,6 +702,21 @@ "depth": 1, "value": "Installation" }, + { + "slug": "plug-and-play", + "depth": 3, + "value": "Plug and play" + }, + { + "slug": "advanced", + "depth": 3, + "value": "Advanced" + }, + { + "slug": "plug-and-play-1", + "depth": 1, + "value": "Plug and play" + }, { "slug": "kios", "depth": 2, @@ -713,9 +728,9 @@ "value": "Github" }, { - "slug": "kerberos-installer", + "slug": "kerberos-open-source-installer", "depth": 3, - "value": "Kerberos installer" + "value": "Kerberos Open Source installer" }, { "slug": "etcher", @@ -742,31 +757,6 @@ "depth": 3, "value": "Access the Raspberry Pi" }, - { - "slug": "raspbian", - "depth": 2, - "value": "Raspbian" - }, - { - "slug": "update-os", - "depth": 3, - "value": "Update OS" - }, - { - "slug": "machinery", - "depth": 3, - "value": "Machinery" - }, - { - "slug": "web", - "depth": 3, - "value": "Web" - }, - { - "slug": "auto-removal", - "depth": 3, - "value": "Auto removal" - }, { "slug": "docker", "depth": 2, @@ -792,6 +782,41 @@ "depth": 3, "value": "Volumes" }, + { + "slug": "balena", + "depth": 2, + "value": "Balena" + }, + { + "slug": "advanced-1", + "depth": 1, + "value": "Advanced" + }, + { + "slug": "raspbian", + "depth": 2, + "value": "Raspbian" + }, + { + "slug": "update-os", + "depth": 3, + "value": "Update OS" + }, + { + "slug": "machinery", + "depth": 3, + "value": "Machinery" + }, + { + "slug": "web", + "depth": 3, + "value": "Web" + }, + { + "slug": "auto-removal", + "depth": 3, + "value": "Auto removal" + }, { "slug": "generic", "depth": 2, diff --git a/.docz/gatsby-node.js b/.docz/gatsby-node.js new file mode 100644 index 0000000..3b6629d --- /dev/null +++ b/.docz/gatsby-node.js @@ -0,0 +1,144 @@ +const { get } = require('docz-utils') + +const NO_OP = () => {} + +const DEFAULT_RESOLVABLE_EXTENSIONS = () => [`.js`, `.jsx`] + +let gatsbyNodeCustom = {} +try { + gatsbyNodeCustom = require('./gatsby-node.custom') +} catch (err) {} + +// https://www.gatsbyjs.org/docs/node-apis/ + +exports.createPages = args => { + const createPages = get(gatsbyNodeCustom, 'createPages', NO_OP) + return createPages(args) +} + +exports.createPagesStatefully = args => { + const createPagesStatefully = get( + gatsbyNodeCustom, + 'createPagesStatefully', + NO_OP, + ) + return createPagesStatefully(args) +} + +exports.createResolvers = args => { + const createResolvers = get(gatsbyNodeCustom, 'createResolvers', NO_OP) + return createResolvers(args) +} + +exports.createSchemaCustomization = args => { + const createSchemaCustomization = get( + gatsbyNodeCustom, + 'createSchemaCustomization', + NO_OP, + ) + return createSchemaCustomization(args) +} + +exports.generateSideEffects = args => { + const generateSideEffects = get( + gatsbyNodeCustom, + 'generateSideEffects', + NO_OP, + ) + return generateSideEffects(args) +} + +exports.onCreateBabelConfig = args => { + const onCreateBabelConfig = get( + gatsbyNodeCustom, + 'onCreateBabelConfig', + NO_OP, + ) + return onCreateBabelConfig(args) +} + +exports.onCreateDevServer = args => { + const onCreateDevServer = get(gatsbyNodeCustom, 'onCreateDevServer', NO_OP) + return onCreateDevServer(args) +} + +exports.onCreateNode = args => { + const onCreateNode = get(gatsbyNodeCustom, 'onCreateNode', NO_OP) + return onCreateNode(args) +} + +exports.onCreatePage = args => { + const onCreatePage = get(gatsbyNodeCustom, 'onCreatePage', NO_OP) + return onCreatePage(args) +} + +exports.onCreateWebpackConfig = args => { + const onCreateWebpackConfig = get( + gatsbyNodeCustom, + 'onCreateWebpackConfig', + NO_OP, + ) + return onCreateWebpackConfig(args) +} + +exports.onPostBootstrap = args => { + const onPostBootstrap = get(gatsbyNodeCustom, 'onPostBootstrap', NO_OP) + return onPostBootstrap(args) +} + +exports.onPostBuild = args => { + const onPostBuild = get(gatsbyNodeCustom, 'onPostBuild', NO_OP) + return onPostBuild(args) +} + +exports.onPreBootstrap = args => { + const onPreBootstrap = get(gatsbyNodeCustom, 'onPreBootstrap', NO_OP) + return onPreBootstrap(args) +} + +exports.onPreBuild = args => { + const onPreBuild = get(gatsbyNodeCustom, 'onPreBuild', NO_OP) + return onPreBuild(args) +} + +exports.onPreExtractQueries = args => { + const onPreExtractQueries = get( + gatsbyNodeCustom, + 'onPreExtractQueries', + NO_OP, + ) + return onPreExtractQueries(args) +} + +exports.onPreInit = args => { + const onPreInit = get(gatsbyNodeCustom, 'onPreInit', NO_OP) + return onPreInit(args) +} + +exports.preprocessSource = args => { + const preprocessSource = get(gatsbyNodeCustom, 'preprocessSource', NO_OP) + return preprocessSource(args) +} + +exports.resolvableExtensions = args => { + const resolvableExtensions = get( + gatsbyNodeCustom, + 'resolvableExtensions', + DEFAULT_RESOLVABLE_EXTENSIONS, + ) + return resolvableExtensions(args) +} + +exports.setFieldsOnGraphQLNodeType = args => { + const setFieldsOnGraphQLNodeType = get( + gatsbyNodeCustom, + 'setFieldsOnGraphQLNodeType', + () => ({}), + ) + return setFieldsOnGraphQLNodeType(args) +} + +exports.sourceNodes = args => { + const sourceNodes = get(gatsbyNodeCustom, 'sourceNodes', NO_OP) + return sourceNodes(args) +} diff --git a/.docz/public/index.html b/.docz/public/index.html index 3d320f7..f8a2cb5 100644 --- a/.docz/public/index.html +++ b/.docz/public/index.html @@ -1,2 +1 @@ -Introduction | Kerberos.io
Kerberos.io
IntroductionThe name: Kerberos.ioWhy KerberosWhat is KerberosThe Kerberos agentHow does it workOpen Source vs EnterpriseCloudArchitectures
Open Source
Enterprise
Cloud

Kerberos.io

The Kerberos(dot)io project, is a video surveillance solution, which was initiated back in 2014. Over the years it has evolved into a trusted, stable and feature-rich video surveillance system. To set the expectations, watch the video below to understand what it can and can't do. If you want to install Kerberos(dot)io, it's recommended to have a look at the architectures page to find the best solution for your usecase.

The name: Kerberos.io

Many people are confused, and don't understand why this project is called Kerberos(dot)io. If you've been in the IT world for a while you will notice that Kerberos is already used for the authentication protocol Kerberos. -We believe that the name Kerberos(dot)io makes sense for this project as well, with a strong emphasize on the suffix .io, which stands for input and output devices (e.g. any type of camera). Kerberos(dot)io can be seen as a kind of security protocol driven by hardware devices such as surveillance cameras. To make writing easier we will from now on, refer to Kerberos instead of Kerberos(dot)io.

Why Kerberos

As burglary is very common, we believe that video surveillance is a trivial tool in our daily lifes which helps us to feel a little bit more secure. Responding to this need, a lot of companies have started developing their own video surveillance software in the past few years.

Nowadays we have a myriad of expensive cameras, recorders, and software solutions which are mainly outdated and difficult to install and use. Kerberos goal is to solve these problems and to provide every human being or enterprise in this world to have their own ecological, affordable, easy-to-use and innovative surveillance solution. Read more about our strategy here.

What is Kerberos

Kerberos is a video surveillance solution, that uses computer vision algorithms to detect changes, and that can trigger actions (notifications, api, etc). It comes in two flavors, Kerberos Open Source and Kerberos Enterprise. Kerberos can be deployed to any Linux OS, Docker, or cluster such as Kubernetes.

The Kerberos agent

When you install Kerberos Open Source or Kerberos Enterprise we will refer to it as a Kerberos agent. A Kerberos agent, is a software solution that processes the video stream of a single surveillance camera, makes and visualises recordings and takes actions (for example sending notifications).

How does it work

The Kerberos agent comes in two flavors, Open Source and Enterprise. Both versions have a web interface (front-end) and a video processing engine (back-end). The front-end allows a user to modify specific settings and watch recordings in a easy-to-use interface. The back-end is a solution that processes the camera feed with computer vision algorithms to detect motion, and makes recordings and/or execute specific actions. Kerberos supports any type of IP-camera (RTSP/ONVIF), USB (V4L2) and the popular Raspberry Pi camera.

Depending on the flavor you choose, you will have to install different components, but the idea as described above remains the same. If you would like to learn more dive deeper in the related sections: Open Source, Enterprise.

Open Source vs Enterprise

The Kerberos project started as an Open Source project, with a main focus on low-cost devices such as the Raspberry Pi. Later on the Open Source version was bundled inside the Docker technology so that it was easier to distribute. Anyone can use the Open Source version for personal usage.

Enterprises are more demanding, and have a lot of surveillance cameras, therefore they need a scalable surveillance system. The Enterprise edition of Kerberos is a licensed service which allows you to operate a video surveillance cluster (Kubernetes) on-premise or in the cloud (AWS/GCP/Azure).

The Open Source and Enterprise edition are significantly different from a source code point of view. The Enterprise edition is a complete rewrite of the Open Source version, and got all the best practices we discovered over the years implemented. Both version are and will remain updated in the future.

Cloud

When installing a Kerberos agent inside your local network, it's possible to review your activity by using the agent's web interface. By its nature, you will not be able to access the web interface from the cloud (outside your local network). On top of that, the Kerberos agent doesn't come with a consolidated overview. This means that you will need to open multiple web interfaces, one for each connected surveillance camera. To simplify and resolve all of these challenges, Kerberos Cloud was developed. Read more about the different features and functions of Kerberos Cloud here.

\ No newline at end of file +
\ No newline at end of file diff --git a/.docz/public/page-data/opensource/installation/page-data.json b/.docz/public/page-data/opensource/installation/page-data.json index aca2a34..7a950e6 100644 --- a/.docz/public/page-data/opensource/installation/page-data.json +++ b/.docz/public/page-data/opensource/installation/page-data.json @@ -1 +1 @@ -{"componentChunkName":"component---src-open-source-installation-mdx","path":"/opensource/installation","result":{"pageContext":{"frontmatter":{"name":"Installation","menu":"Open Source","route":"/opensource/installation"},"entry":{"id":"9e9908538be367cca76a80425244646f","filepath":"src/open-source/installation.mdx","fullpath":"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/installation.mdx","route":"/opensource/installation","slug":"src-open-source-installation","name":"Installation","menu":"Open Source","headings":[{"slug":"installation","depth":1,"value":"Installation"},{"slug":"kios","depth":2,"value":"KiOS"},{"slug":"github","depth":3,"value":"Github"},{"slug":"kerberos-installer","depth":3,"value":"Kerberos installer"},{"slug":"etcher","depth":3,"value":"Etcher"},{"slug":"connecting-to-wifi","depth":4,"value":"Connecting to WiFi"},{"slug":"setup-a-static-ip-address","depth":4,"value":"Setup a static IP-address"},{"slug":"power-on-the-raspberry-pi","depth":3,"value":"Power on the Raspberry Pi"},{"slug":"access-the-raspberry-pi","depth":3,"value":"Access the Raspberry Pi"},{"slug":"raspbian","depth":2,"value":"Raspbian"},{"slug":"update-os","depth":3,"value":"Update OS"},{"slug":"machinery","depth":3,"value":"Machinery"},{"slug":"web","depth":3,"value":"Web"},{"slug":"auto-removal","depth":3,"value":"Auto removal"},{"slug":"docker","depth":2,"value":"Docker"},{"slug":"prerequisites","depth":3,"value":"Prerequisites"},{"slug":"github-1","depth":3,"value":"Github"},{"slug":"download-docker-image","depth":3,"value":"Download docker image"},{"slug":"volumes","depth":3,"value":"Volumes"},{"slug":"generic","depth":2,"value":"Generic"},{"slug":"machinery-1","depth":3,"value":"Machinery"},{"slug":"web-1","depth":3,"value":"Web"},{"slug":"auto-removal-1","depth":3,"value":"Auto removal"}]}}}} \ No newline at end of file +{"componentChunkName":"component---src-open-source-installation-mdx","path":"/opensource/installation","result":{"pageContext":{"frontmatter":{"name":"Installation","menu":"Open Source","route":"/opensource/installation"},"entry":{"id":"9e9908538be367cca76a80425244646f","filepath":"src/open-source/installation.mdx","fullpath":"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/installation.mdx","route":"/opensource/installation","slug":"src-open-source-installation","name":"Installation","menu":"Open Source","headings":[{"slug":"installation","depth":1,"value":"Installation"},{"slug":"plug-and-play","depth":3,"value":"Plug and play"},{"slug":"advanced","depth":3,"value":"Advanced"},{"slug":"plug-and-play-1","depth":1,"value":"Plug and play"},{"slug":"kios","depth":2,"value":"KiOS"},{"slug":"github","depth":3,"value":"Github"},{"slug":"kerberos-open-source-installer","depth":3,"value":"Kerberos Open Source installer"},{"slug":"etcher","depth":3,"value":"Etcher"},{"slug":"connecting-to-wifi","depth":4,"value":"Connecting to WiFi"},{"slug":"setup-a-static-ip-address","depth":4,"value":"Setup a static IP-address"},{"slug":"power-on-the-raspberry-pi","depth":3,"value":"Power on the Raspberry Pi"},{"slug":"access-the-raspberry-pi","depth":3,"value":"Access the Raspberry Pi"},{"slug":"docker","depth":2,"value":"Docker"},{"slug":"prerequisites","depth":3,"value":"Prerequisites"},{"slug":"github-1","depth":3,"value":"Github"},{"slug":"download-docker-image","depth":3,"value":"Download docker image"},{"slug":"volumes","depth":3,"value":"Volumes"},{"slug":"balena","depth":2,"value":"Balena"},{"slug":"advanced-1","depth":1,"value":"Advanced"},{"slug":"raspbian","depth":2,"value":"Raspbian"},{"slug":"update-os","depth":3,"value":"Update OS"},{"slug":"machinery","depth":3,"value":"Machinery"},{"slug":"web","depth":3,"value":"Web"},{"slug":"auto-removal","depth":3,"value":"Auto removal"},{"slug":"generic","depth":2,"value":"Generic"},{"slug":"machinery-1","depth":3,"value":"Machinery"},{"slug":"web-1","depth":3,"value":"Web"},{"slug":"auto-removal-1","depth":3,"value":"Auto removal"}]}}}} \ No newline at end of file diff --git a/.docz/public/static/d/1803957048.json b/.docz/public/static/d/1803957048.json index 1088245..e36c8bb 100644 --- a/.docz/public/static/d/1803957048.json +++ b/.docz/public/static/d/1803957048.json @@ -1 +1 @@ -{"data":{"doczDb":{"id":"ace00e2b-9c46-5e24-a19a-5ed242ca9c64","db":"{\"config\":{\"title\":\"Kerberos.io\",\"description\":\"My awesome app using docz\",\"menu\":[\"Introduction\",\"Architectures\",{\"name\":\"Open Source\",\"menu\":[\"First things first\",\"Get Started\",\"Installation\",\"Releases\",\"License\",\"Upgrade\",\"Contribute\",\"Machinery\",\"Web\"]},{\"name\":\"Enterprise\",\"menu\":[\"First things first\",\"Get Started\",\"Installation\",\"Releases\",\"License\"]},\"Cloud\"],\"version\":\"2.0.0-rc.41\",\"repository\":\"https://github.com/kerberos-io\",\"native\":false,\"themeConfig\":{\"colors\":{\"primary\":\"#943733\",\"secondary\":\"#9e9e9e\",\"h5\":{\"color\":\"#943733\"},\"header\":{\"bg\":\"#943733\"},\"sidebar\":{\"bg\":\"#f9f9f9\",\"navLinkActive\":\"#943733\"},\"modes\":{\"dark\":{\"primary\":\"#9e9e9e\",\"secondary\":\"#943733\",\"header\":{\"bg\":\"#943733\"},\"sidebar\":{\"navLinkActive\":\"#fff\"}}}}},\"separator\":\"-\",\"gatsbyRemarkPlugins\":[{\"resolve\":\"gatsby-remark-vscode\"},{\"resolve\":\"gatsby-remark-grid-tables\"}]},\"entries\":[{\"key\":\"src/architectures.mdx\",\"value\":{\"name\":\"Architectures\",\"route\":\"/architectures\",\"id\":\"bb781d264051ead449d715317c32b263\",\"filepath\":\"src/architectures.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/architectures.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-architectures\",\"menu\":\"\",\"headings\":[{\"slug\":\"architectures\",\"depth\":1,\"value\":\"Architectures\"},{\"slug\":\"agents-on-premise\",\"depth\":2,\"value\":\"Agents on-premise\"},{\"slug\":\"kerberos-open-source--5-kerberos-agents\",\"depth\":3,\"value\":\"Kerberos Open Source (< 5 Kerberos agents)\"},{\"slug\":\"kerberos-enterprise--5-kerberos-agents\",\"depth\":3,\"value\":\"Kerberos Enterprise (> 5 Kerberos agents)\"},{\"slug\":\"agents-in-the-cloud\",\"depth\":2,\"value\":\"Agents in the cloud\"},{\"slug\":\"kerberos-open-source--5-kerberos-agents-1\",\"depth\":3,\"value\":\"Kerberos Open Source (< 5 Kerberos agents)\"},{\"slug\":\"kerberos-enterprise--5-kerberos-agents-1\",\"depth\":3,\"value\":\"Kerberos Enterprise (> 5 Kerberos agents)\"},{\"slug\":\"kerberos-cloud\",\"depth\":2,\"value\":\"Kerberos Cloud\"},{\"slug\":\"architecture\",\"depth\":3,\"value\":\"Architecture\"}]}},{\"key\":\"src/index.mdx\",\"value\":{\"name\":\"Introduction\",\"route\":\"/\",\"id\":\"6576455a124f9aaefd860597f03a8fe4\",\"filepath\":\"src/index.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/index.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-index\",\"menu\":\"\",\"headings\":[{\"slug\":\"kerberosio\",\"depth\":1,\"value\":\"Kerberos.io\"},{\"slug\":\"the-name-kerberosio\",\"depth\":2,\"value\":\"The name: Kerberos.io\"},{\"slug\":\"why-kerberos\",\"depth\":2,\"value\":\"Why Kerberos\"},{\"slug\":\"what-is-kerberos\",\"depth\":2,\"value\":\"What is Kerberos\"},{\"slug\":\"the-kerberos-agent\",\"depth\":2,\"value\":\"The Kerberos agent\"},{\"slug\":\"how-does-it-work\",\"depth\":2,\"value\":\"How does it work\"},{\"slug\":\"open-source-vs-enterprise\",\"depth\":2,\"value\":\"Open Source vs Enterprise\"},{\"slug\":\"cloud\",\"depth\":2,\"value\":\"Cloud\"}]}},{\"key\":\"src/cloud/index.mdx\",\"value\":{\"name\":\"Cloud\",\"route\":\"/cloud\",\"id\":\"082761d36d79f69c41234676c7b77e13\",\"filepath\":\"src/cloud/index.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/cloud/index.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-cloud-index\",\"menu\":\"\",\"headings\":[{\"slug\":\"cloud\",\"depth\":1,\"value\":\"Cloud\"},{\"slug\":\"architecture\",\"depth\":2,\"value\":\"Architecture\"},{\"slug\":\"public-or-private-edition\",\"depth\":3,\"value\":\"Public or Private edition\"},{\"slug\":\"features\",\"depth\":2,\"value\":\"Features\"},{\"slug\":\"secured-storage\",\"depth\":2,\"value\":\"Secured storage\"},{\"slug\":\"consolidated-overview\",\"depth\":2,\"value\":\"Consolidated overview\"},{\"slug\":\"security\",\"depth\":3,\"value\":\"Security\"},{\"slug\":\"advanced-searching\",\"depth\":2,\"value\":\"Advanced searching\"},{\"slug\":\"machine-learning\",\"depth\":2,\"value\":\"Machine learning\"},{\"slug\":\"alerts\",\"depth\":2,\"value\":\"Alerts\"},{\"slug\":\"notifications\",\"depth\":3,\"value\":\"Notifications\"},{\"slug\":\"channels\",\"depth\":3,\"value\":\"Channels\"},{\"slug\":\"live-streaming\",\"depth\":2,\"value\":\"Live streaming\"},{\"slug\":\"accounts\",\"depth\":2,\"value\":\"Accounts\"},{\"slug\":\"logging\",\"depth\":2,\"value\":\"Logging\"}]}},{\"key\":\"src/enterprise/get-started.mdx\",\"value\":{\"name\":\"Get Started\",\"menu\":\"Enterprise\",\"route\":\"/enterprise/get-started\",\"id\":\"190cf47f9b2f25ec9b7155086f299a78\",\"filepath\":\"src/enterprise/get-started.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/get-started.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-enterprise-get-started\",\"headings\":[{\"slug\":\"get-started\",\"depth\":1,\"value\":\"Get Started\"},{\"slug\":\"login-page\",\"depth\":2,\"value\":\"Login page\"},{\"slug\":\"license-key\",\"depth\":2,\"value\":\"License key\"},{\"slug\":\"overview\",\"depth\":2,\"value\":\"Overview\"},{\"slug\":\"kubernetes\",\"depth\":2,\"value\":\"Kubernetes\"},{\"slug\":\"nodes\",\"depth\":2,\"value\":\"Nodes\"},{\"slug\":\"deployments\",\"depth\":2,\"value\":\"Deployments\"},{\"slug\":\"adding-a-new-deployment\",\"depth\":3,\"value\":\"Adding a new deployment\"},{\"slug\":\"configuring-a-deployment\",\"depth\":3,\"value\":\"Configuring a deployment\"},{\"slug\":\"pods\",\"depth\":2,\"value\":\"Pods\"},{\"slug\":\"storage-and-video-management\",\"depth\":2,\"value\":\"Storage and video management\"}]}},{\"key\":\"src/enterprise/index.mdx\",\"value\":{\"name\":\"First things first\",\"menu\":\"Enterprise\",\"route\":\"/enterprise/introduction\",\"id\":\"8f8fd9e742255635cf471c3030fa24ac\",\"filepath\":\"src/enterprise/index.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/index.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-enterprise-index\",\"headings\":[{\"slug\":\"enterprise\",\"depth\":1,\"value\":\"Enterprise\"},{\"slug\":\"kubernetes\",\"depth\":2,\"value\":\"Kubernetes\"},{\"slug\":\"cloud-or-on-premise\",\"depth\":2,\"value\":\"Cloud or on premise\"},{\"slug\":\"licensing\",\"depth\":2,\"value\":\"Licensing\"}]}},{\"key\":\"src/enterprise/installation.mdx\",\"value\":{\"name\":\"Installation\",\"menu\":\"Enterprise\",\"route\":\"/enterprise/installation\",\"id\":\"5cf033b11c0e22a8dad307af4f84a83b\",\"filepath\":\"src/enterprise/installation.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/installation.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-enterprise-installation\",\"headings\":[{\"slug\":\"introduction\",\"depth\":1,\"value\":\"Introduction\"},{\"slug\":\"installation\",\"depth\":1,\"value\":\"Installation\"},{\"slug\":\"helm\",\"depth\":2,\"value\":\"Helm\"},{\"slug\":\"initiate-helm\",\"depth\":3,\"value\":\"Initiate helm\"},{\"slug\":\"traefik\",\"depth\":2,\"value\":\"Traefik\"},{\"slug\":\"mongodb\",\"depth\":2,\"value\":\"MongoDB\"},{\"slug\":\"factory\",\"depth\":2,\"value\":\"Factory\"},{\"slug\":\"test-out-configuration\",\"depth\":1,\"value\":\"Test out configuration\"},{\"slug\":\"access-the-system\",\"depth\":2,\"value\":\"Access the system\"}]}},{\"key\":\"src/enterprise/license.mdx\",\"value\":{\"name\":\"License\",\"menu\":\"Enterprise\",\"route\":\"/enterprise/license\",\"id\":\"692a3e0f1bc0489a5d98bfb87a5efa3e\",\"filepath\":\"src/enterprise/license.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/license.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-enterprise-license\",\"headings\":[{\"slug\":\"eula\",\"depth\":1,\"value\":\"EULA\"}]}},{\"key\":\"src/enterprise/releases.mdx\",\"value\":{\"name\":\"Releases\",\"menu\":\"Enterprise\",\"route\":\"/enterprise/releases\",\"id\":\"d55649896dc1baed370ad4ea221aefb5\",\"filepath\":\"src/enterprise/releases.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/releases.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-enterprise-releases\",\"headings\":[{\"slug\":\"release-notes\",\"depth\":1,\"value\":\"Release notes\"},{\"slug\":\"100\",\"depth\":3,\"value\":\"1.0.0\"},{\"slug\":\"factory\",\"depth\":4,\"value\":\"Factory\"}]}},{\"key\":\"src/open-source/contribute.mdx\",\"value\":{\"name\":\"Contribute\",\"menu\":\"Open Source\",\"route\":\"/opensource/contribute\",\"id\":\"111290db815f0c1a551a7742fd821f6f\",\"filepath\":\"src/open-source/contribute.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/contribute.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-contribute\",\"headings\":[{\"slug\":\"contribute\",\"depth\":1,\"value\":\"Contribute\"},{\"slug\":\"machinery\",\"depth\":2,\"value\":\"Machinery\"},{\"slug\":\"prerequisites\",\"depth\":3,\"value\":\"Prerequisites\"},{\"slug\":\"installation\",\"depth\":3,\"value\":\"Installation\"},{\"slug\":\"testing\",\"depth\":3,\"value\":\"Testing\"},{\"slug\":\"adding-a-new-class\",\"depth\":3,\"value\":\"Adding a new class\"},{\"slug\":\"create-the-header-file\",\"depth\":4,\"value\":\"Create the header file\"},{\"slug\":\"create-the-source-file\",\"depth\":4,\"value\":\"Create the source file\"},{\"slug\":\"modify-the-cmakeliststxt-file\",\"depth\":4,\"value\":\"Modify the CMakeLists.txt file\"},{\"slug\":\"create-a-new-entry-in-the-config-file\",\"depth\":4,\"value\":\"Create a new entry in the config file\"},{\"slug\":\"compile\",\"depth\":3,\"value\":\"Compile\"},{\"slug\":\"web\",\"depth\":2,\"value\":\"Web\"},{\"slug\":\"prerequisites-1\",\"depth\":3,\"value\":\"Prerequisites\"},{\"slug\":\"installation-1\",\"depth\":3,\"value\":\"Installation\"}]}},{\"key\":\"src/open-source/get-started.mdx\",\"value\":{\"name\":\"Get Started\",\"menu\":\"Open Source\",\"route\":\"/opensource/get-started\",\"id\":\"059e06c8b1653a3b0c3473f90d782c13\",\"filepath\":\"src/open-source/get-started.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/get-started.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-get-started\",\"headings\":[{\"slug\":\"get-started\",\"depth\":1,\"value\":\"Get Started\"},{\"slug\":\"welcome-page\",\"depth\":2,\"value\":\"Welcome page\"},{\"slug\":\"login-page\",\"depth\":2,\"value\":\"Login page\"},{\"slug\":\"dashboard\",\"depth\":2,\"value\":\"Dashboard\"},{\"slug\":\"media\",\"depth\":2,\"value\":\"Media\"},{\"slug\":\"settings\",\"depth\":2,\"value\":\"Settings\"},{\"slug\":\"region-of-interest\",\"depth\":3,\"value\":\"Region of interest\"},{\"slug\":\"storage\",\"depth\":3,\"value\":\"Storage\"},{\"slug\":\"system\",\"depth\":2,\"value\":\"System\"}]}},{\"key\":\"src/open-source/index.mdx\",\"value\":{\"name\":\"First things first\",\"menu\":\"Open Source\",\"route\":\"/opensource/introduction\",\"id\":\"e182a675cff01d9e46eba94b9b98f68a\",\"filepath\":\"src/open-source/index.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/index.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-index\",\"headings\":[{\"slug\":\"first-things-first\",\"depth\":1,\"value\":\"First things first\"},{\"slug\":\"license\",\"depth\":2,\"value\":\"License\"},{\"slug\":\"when-using-the-open-source-version\",\"depth\":2,\"value\":\"When using the Open Source version\"},{\"slug\":\"how-to-install\",\"depth\":2,\"value\":\"How to install\"}]}},{\"key\":\"src/open-source/installation.mdx\",\"value\":{\"name\":\"Installation\",\"menu\":\"Open Source\",\"route\":\"/opensource/installation\",\"id\":\"9e9908538be367cca76a80425244646f\",\"filepath\":\"src/open-source/installation.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/installation.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-installation\",\"headings\":[{\"slug\":\"installation\",\"depth\":1,\"value\":\"Installation\"},{\"slug\":\"kios\",\"depth\":2,\"value\":\"KiOS\"},{\"slug\":\"github\",\"depth\":3,\"value\":\"Github\"},{\"slug\":\"kerberos-installer\",\"depth\":3,\"value\":\"Kerberos installer\"},{\"slug\":\"etcher\",\"depth\":3,\"value\":\"Etcher\"},{\"slug\":\"connecting-to-wifi\",\"depth\":4,\"value\":\"Connecting to WiFi\"},{\"slug\":\"setup-a-static-ip-address\",\"depth\":4,\"value\":\"Setup a static IP-address\"},{\"slug\":\"power-on-the-raspberry-pi\",\"depth\":3,\"value\":\"Power on the Raspberry Pi\"},{\"slug\":\"access-the-raspberry-pi\",\"depth\":3,\"value\":\"Access the Raspberry Pi\"},{\"slug\":\"raspbian\",\"depth\":2,\"value\":\"Raspbian\"},{\"slug\":\"update-os\",\"depth\":3,\"value\":\"Update OS\"},{\"slug\":\"machinery\",\"depth\":3,\"value\":\"Machinery\"},{\"slug\":\"web\",\"depth\":3,\"value\":\"Web\"},{\"slug\":\"auto-removal\",\"depth\":3,\"value\":\"Auto removal\"},{\"slug\":\"docker\",\"depth\":2,\"value\":\"Docker\"},{\"slug\":\"prerequisites\",\"depth\":3,\"value\":\"Prerequisites\"},{\"slug\":\"github-1\",\"depth\":3,\"value\":\"Github\"},{\"slug\":\"download-docker-image\",\"depth\":3,\"value\":\"Download docker image\"},{\"slug\":\"volumes\",\"depth\":3,\"value\":\"Volumes\"},{\"slug\":\"generic\",\"depth\":2,\"value\":\"Generic\"},{\"slug\":\"machinery-1\",\"depth\":3,\"value\":\"Machinery\"},{\"slug\":\"web-1\",\"depth\":3,\"value\":\"Web\"},{\"slug\":\"auto-removal-1\",\"depth\":3,\"value\":\"Auto removal\"}]}},{\"key\":\"src/open-source/license.mdx\",\"value\":{\"name\":\"License\",\"menu\":\"Open Source\",\"route\":\"/opensource/license\",\"id\":\"b41faa434ffd47abb4b845cb083fff55\",\"filepath\":\"src/open-source/license.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/license.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-license\",\"headings\":[{\"slug\":\"cc-by-nc-sa-40\",\"depth\":1,\"value\":\"CC BY-NC-SA 4.0\"},{\"slug\":\"summary\",\"depth\":2,\"value\":\"Summary\"},{\"slug\":\"the-license\",\"depth\":2,\"value\":\"The license\"},{\"slug\":\"section-1--definitions\",\"depth\":3,\"value\":\"Section 1 – Definitions.\"},{\"slug\":\"section-2--scope\",\"depth\":3,\"value\":\"Section 2 – Scope.\"},{\"slug\":\"section-3--license-conditions\",\"depth\":3,\"value\":\"Section 3 – License Conditions.\"},{\"slug\":\"section-4--sui-generis-database-rights\",\"depth\":3,\"value\":\"Section 4 – Sui Generis Database Rights.\"},{\"slug\":\"section-5--disclaimer-of-warranties-and-limitation-of-liability\",\"depth\":3,\"value\":\"Section 5 – Disclaimer of Warranties and Limitation of Liability.\"},{\"slug\":\"section-6--term-and-termination\",\"depth\":3,\"value\":\"Section 6 – Term and Termination.\"},{\"slug\":\"section-7--other-terms-and-conditions\",\"depth\":3,\"value\":\"Section 7 – Other Terms and Conditions.\"},{\"slug\":\"section-8--interpretation\",\"depth\":3,\"value\":\"Section 8 – Interpretation.\"}]}},{\"key\":\"src/open-source/machinery.mdx\",\"value\":{\"name\":\"Machinery\",\"menu\":\"Open Source\",\"route\":\"/opensource/machinery\",\"id\":\"8b5e104d90b9ec673d88bf43d6bf99f2\",\"filepath\":\"src/open-source/machinery.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/machinery.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-machinery\",\"headings\":[{\"slug\":\"machinery\",\"depth\":1,\"value\":\"Machinery\"},{\"slug\":\"project-structure\",\"depth\":2,\"value\":\"Project structure\"},{\"slug\":\"capture\",\"depth\":2,\"value\":\"Capture\"},{\"slug\":\"usb-camera\",\"depth\":3,\"value\":\"USB camera\"},{\"slug\":\"parameters\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"framewidth-and--height\",\"depth\":5,\"value\":\"Framewidth and -height\"},{\"slug\":\"device-number\",\"depth\":5,\"value\":\"Device number\"},{\"slug\":\"delay\",\"depth\":5,\"value\":\"Delay\"},{\"slug\":\"angle\",\"depth\":5,\"value\":\"Angle\"},{\"slug\":\"raspberry-pi-camera-module\",\"depth\":3,\"value\":\"Raspberry Pi Camera Module\"},{\"slug\":\"parameters-1\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"framewidth-and--height-1\",\"depth\":5,\"value\":\"Framewidth and -height\"},{\"slug\":\"delay-1\",\"depth\":5,\"value\":\"Delay\"},{\"slug\":\"angle-1\",\"depth\":5,\"value\":\"Angle\"},{\"slug\":\"framerate\",\"depth\":5,\"value\":\"Framerate\"},{\"slug\":\"sharpness-saturation-contrast-brightness\",\"depth\":5,\"value\":\"Sharpness, saturation, contrast, brightness\"},{\"slug\":\"ip-camera\",\"depth\":3,\"value\":\"IP camera\"},{\"slug\":\"parameters-2\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"url\",\"depth\":5,\"value\":\"URL\"},{\"slug\":\"framewidth-and--height-2\",\"depth\":5,\"value\":\"Framewidth and -height\"},{\"slug\":\"delay-2\",\"depth\":5,\"value\":\"Delay\"},{\"slug\":\"angle-2\",\"depth\":5,\"value\":\"Angle\"},{\"slug\":\"condition\",\"depth\":2,\"value\":\"Condition\"},{\"slug\":\"enabled\",\"depth\":3,\"value\":\"Enabled\"},{\"slug\":\"parameters-3\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"active\",\"depth\":5,\"value\":\"Active\"},{\"slug\":\"delay-3\",\"depth\":5,\"value\":\"Delay\"},{\"slug\":\"time\",\"depth\":3,\"value\":\"Time\"},{\"slug\":\"parameters-4\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"times\",\"depth\":5,\"value\":\"Times\"},{\"slug\":\"delay-4\",\"depth\":5,\"value\":\"Delay\"},{\"slug\":\"algorithm\",\"depth\":2,\"value\":\"Algorithm\"},{\"slug\":\"differential-images\",\"depth\":3,\"value\":\"Differential images\"},{\"slug\":\"parameters-5\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"erode\",\"depth\":5,\"value\":\"Erode\"},{\"slug\":\"threshold\",\"depth\":5,\"value\":\"Threshold\"},{\"slug\":\"expositor\",\"depth\":2,\"value\":\"Expositor\"},{\"slug\":\"rectangle\",\"depth\":3,\"value\":\"Rectangle\"},{\"slug\":\"parameters-6\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"region\",\"depth\":5,\"value\":\"Region\"},{\"slug\":\"hull\",\"depth\":3,\"value\":\"Hull\"},{\"slug\":\"parameters-7\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"region-1\",\"depth\":5,\"value\":\"Region\"},{\"slug\":\"heuristic\",\"depth\":2,\"value\":\"Heuristic\"},{\"slug\":\"sequence\",\"depth\":3,\"value\":\"Sequence\"},{\"slug\":\"parameters-8\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"minimum-changes\",\"depth\":5,\"value\":\"Minimum changes\"},{\"slug\":\"minimum-durations\",\"depth\":5,\"value\":\"Minimum durations\"},{\"slug\":\"no-motion-delay-time\",\"depth\":5,\"value\":\"No motion delay time\"},{\"slug\":\"output\",\"depth\":2,\"value\":\"Output\"},{\"slug\":\"disk\",\"depth\":3,\"value\":\"Disk\"},{\"slug\":\"parameters-9\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"file-format\",\"depth\":5,\"value\":\"File format\"},{\"slug\":\"directory\",\"depth\":5,\"value\":\"Directory\"},{\"slug\":\"mark-with-timestamp\",\"depth\":5,\"value\":\"Mark with timestamp\"},{\"slug\":\"timestamp-color\",\"depth\":5,\"value\":\"Timestamp color\"},{\"slug\":\"privacy\",\"depth\":5,\"value\":\"Privacy\"},{\"slug\":\"throttler\",\"depth\":5,\"value\":\"Throttler\"},{\"slug\":\"video\",\"depth\":3,\"value\":\"Video\"},{\"slug\":\"parameters-10\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"fps\",\"depth\":5,\"value\":\"FPS\"},{\"slug\":\"record-after\",\"depth\":5,\"value\":\"Record after\"},{\"slug\":\"extensions\",\"depth\":5,\"value\":\"Extensions\"},{\"slug\":\"codec\",\"depth\":5,\"value\":\"Codec\"},{\"slug\":\"file-format-1\",\"depth\":5,\"value\":\"File format\"},{\"slug\":\"directory-1\",\"depth\":5,\"value\":\"Directory\"},{\"slug\":\"hardware-directory\",\"depth\":5,\"value\":\"Hardware directory\"},{\"slug\":\"enable-hardware-encoding\",\"depth\":5,\"value\":\"Enable Hardware encoding\"},{\"slug\":\"mark-with-timestamp-1\",\"depth\":5,\"value\":\"Mark with timestamp\"},{\"slug\":\"timestamp-color-1\",\"depth\":5,\"value\":\"Timestamp color\"},{\"slug\":\"privacy-1\",\"depth\":5,\"value\":\"Privacy\"},{\"slug\":\"video-privacy\",\"depth\":5,\"value\":\"Video privacy\"},{\"slug\":\"throttler-1\",\"depth\":5,\"value\":\"Throttler\"},{\"slug\":\"tcpip-client\",\"depth\":3,\"value\":\"TCP/IP client\"},{\"slug\":\"parameters-11\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"server\",\"depth\":5,\"value\":\"Server\"},{\"slug\":\"port\",\"depth\":5,\"value\":\"Port\"},{\"slug\":\"message\",\"depth\":5,\"value\":\"Message\"},{\"slug\":\"throttler-2\",\"depth\":5,\"value\":\"Throttler\"},{\"slug\":\"gpio\",\"depth\":3,\"value\":\"GPIO\"},{\"slug\":\"parameters-12\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"pin\",\"depth\":5,\"value\":\"Pin\"},{\"slug\":\"periods\",\"depth\":5,\"value\":\"Periods\"},{\"slug\":\"period-time\",\"depth\":5,\"value\":\"Period time\"},{\"slug\":\"throttler-3\",\"depth\":5,\"value\":\"Throttler\"},{\"slug\":\"webhook\",\"depth\":3,\"value\":\"Webhook\"},{\"slug\":\"parameters-13\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"url-1\",\"depth\":5,\"value\":\"Url\"},{\"slug\":\"throttler-4\",\"depth\":5,\"value\":\"Throttler\"},{\"slug\":\"output-1\",\"depth\":5,\"value\":\"Output\"},{\"slug\":\"script\",\"depth\":3,\"value\":\"Script\"},{\"slug\":\"parameters-14\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"path\",\"depth\":5,\"value\":\"Path\"},{\"slug\":\"throttler-5\",\"depth\":5,\"value\":\"Throttler\"},{\"slug\":\"example\",\"depth\":5,\"value\":\"Example\"},{\"slug\":\"mqtt\",\"depth\":3,\"value\":\"MQTT\"},{\"slug\":\"parameters-15\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"secure\",\"depth\":5,\"value\":\"Secure\"},{\"slug\":\"verifycn\",\"depth\":5,\"value\":\"Verifycn\"},{\"slug\":\"server-1\",\"depth\":5,\"value\":\"Server\"},{\"slug\":\"port-1\",\"depth\":5,\"value\":\"Port\"},{\"slug\":\"topic\",\"depth\":5,\"value\":\"Topic\"},{\"slug\":\"username\",\"depth\":5,\"value\":\"Username\"},{\"slug\":\"password\",\"depth\":5,\"value\":\"Password\"},{\"slug\":\"throttler-6\",\"depth\":5,\"value\":\"Throttler\"},{\"slug\":\"output-2\",\"depth\":5,\"value\":\"Output\"},{\"slug\":\"example-1\",\"depth\":5,\"value\":\"Example\"},{\"slug\":\"streaming\",\"depth\":2,\"value\":\"Streaming\"},{\"slug\":\"parameters-16\",\"depth\":3,\"value\":\"Parameters\"},{\"slug\":\"enabled-1\",\"depth\":4,\"value\":\"Enabled\"},{\"slug\":\"stream-port\",\"depth\":4,\"value\":\"Stream Port\"},{\"slug\":\"quality\",\"depth\":4,\"value\":\"Quality\"},{\"slug\":\"usernamepassword\",\"depth\":4,\"value\":\"Username/password\"}]}},{\"key\":\"src/open-source/releases.mdx\",\"value\":{\"name\":\"Releases\",\"menu\":\"Open Source\",\"route\":\"/opensource/releases\",\"id\":\"0513012dd89890d93de77c3aa4597e7f\",\"filepath\":\"src/open-source/releases.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/releases.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-releases\",\"headings\":[{\"slug\":\"release-notes\",\"depth\":1,\"value\":\"Release notes\"},{\"slug\":\"280\",\"depth\":3,\"value\":\"2.8.0\"},{\"slug\":\"web\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"kios\",\"depth\":4,\"value\":\"KiOS\"},{\"slug\":\"272\",\"depth\":3,\"value\":\"2.7.2\"},{\"slug\":\"machinery\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"271\",\"depth\":3,\"value\":\"2.7.1\"},{\"slug\":\"machinery-1\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"kios-1\",\"depth\":4,\"value\":\"KiOS\"},{\"slug\":\"270\",\"depth\":3,\"value\":\"2.7.0\"},{\"slug\":\"web-1\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-2\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"docker\",\"depth\":4,\"value\":\"Docker\"},{\"slug\":\"kios-2\",\"depth\":4,\"value\":\"KiOS\"},{\"slug\":\"261\",\"depth\":3,\"value\":\"2.6.1\"},{\"slug\":\"web-2\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-3\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"260\",\"depth\":3,\"value\":\"2.6.0\"},{\"slug\":\"web-3\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-4\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"docker-1\",\"depth\":4,\"value\":\"Docker\"},{\"slug\":\"250\",\"depth\":3,\"value\":\"2.5.0\"},{\"slug\":\"web-4\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-5\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"242\",\"depth\":3,\"value\":\"2.4.2\"},{\"slug\":\"web-5\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-6\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"241\",\"depth\":3,\"value\":\"2.4.1\"},{\"slug\":\"web-6\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"240\",\"depth\":3,\"value\":\"2.4.0\"},{\"slug\":\"ecosystem\",\"depth\":4,\"value\":\"Ecosystem\"},{\"slug\":\"web-7\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"docker-2\",\"depth\":4,\"value\":\"Docker\"},{\"slug\":\"machinery-7\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"231\",\"depth\":3,\"value\":\"2.3.1\"},{\"slug\":\"machinery-8\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"230\",\"depth\":3,\"value\":\"2.3.0\"},{\"slug\":\"ecosystem-1\",\"depth\":4,\"value\":\"Ecosystem\"},{\"slug\":\"221\",\"depth\":3,\"value\":\"2.2.1\"},{\"slug\":\"ecosystem-2\",\"depth\":4,\"value\":\"Ecosystem\"},{\"slug\":\"web-8\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-9\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"220\",\"depth\":3,\"value\":\"2.2.0\"},{\"slug\":\"ecosystem-3\",\"depth\":4,\"value\":\"Ecosystem\"},{\"slug\":\"web-9\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-10\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"210\",\"depth\":3,\"value\":\"2.1.0\"},{\"slug\":\"web-10\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-11\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"ecosystem-4\",\"depth\":4,\"value\":\"Ecosystem\"},{\"slug\":\"200\",\"depth\":3,\"value\":\"2.0.0\"},{\"slug\":\"web-11\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-12\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"docker-3\",\"depth\":4,\"value\":\"Docker\"},{\"slug\":\"ecosystem-5\",\"depth\":4,\"value\":\"Ecosystem\"},{\"slug\":\"110\",\"depth\":3,\"value\":\"1.1.0\"},{\"slug\":\"web-12\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-13\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"cloud\",\"depth\":4,\"value\":\"Cloud\"},{\"slug\":\"103\",\"depth\":3,\"value\":\"1.0.3\"},{\"slug\":\"web-13\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-14\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"cloud-1\",\"depth\":4,\"value\":\"Cloud\"},{\"slug\":\"102\",\"depth\":3,\"value\":\"1.0.2\"},{\"slug\":\"web-14\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-15\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"101\",\"depth\":3,\"value\":\"1.0.1\"},{\"slug\":\"web-15\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-16\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"100\",\"depth\":3,\"value\":\"1.0.0\"},{\"slug\":\"first-commit-of-kerberosio\",\"depth\":4,\"value\":\"First commit of Kerberos.io\"}]}},{\"key\":\"src/open-source/upgrade.mdx\",\"value\":{\"name\":\"Upgrade\",\"menu\":\"Open Source\",\"route\":\"/opensource/upgrade\",\"id\":\"bdff501afe4f3c7e6fc0f2ef0f365d5d\",\"filepath\":\"src/open-source/upgrade.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/upgrade.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-upgrade\",\"headings\":[{\"slug\":\"upgrade\",\"depth\":1,\"value\":\"Upgrade\"},{\"slug\":\"kios\",\"depth\":2,\"value\":\"KiOS\"},{\"slug\":\"raspbian\",\"depth\":2,\"value\":\"Raspbian\"},{\"slug\":\"docker\",\"depth\":2,\"value\":\"Docker\"}]}},{\"key\":\"src/open-source/web.mdx\",\"value\":{\"name\":\"Web\",\"menu\":\"Open Source\",\"route\":\"/opensource/web\",\"id\":\"302e6588cf7f47fc4110356883b1761b\",\"filepath\":\"src/open-source/web.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/web.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-web\",\"headings\":[{\"slug\":\"web-interface\",\"depth\":1,\"value\":\"Web interface\"},{\"slug\":\"overview\",\"depth\":2,\"value\":\"Overview\"},{\"slug\":\"dashboard\",\"depth\":3,\"value\":\"Dashboard\"},{\"slug\":\"overview-1\",\"depth\":3,\"value\":\"Overview\"},{\"slug\":\"settings\",\"depth\":3,\"value\":\"Settings\"},{\"slug\":\"system\",\"depth\":3,\"value\":\"System\"},{\"slug\":\"project-structure\",\"depth\":2,\"value\":\"Project structure\"},{\"slug\":\"back-end\",\"depth\":3,\"value\":\"Back-end\"},{\"slug\":\"front-end\",\"depth\":3,\"value\":\"Front-end\"},{\"slug\":\"api\",\"depth\":2,\"value\":\"API\"},{\"slug\":\"authentication\",\"depth\":3,\"value\":\"Authentication\"},{\"slug\":\"endpoints\",\"depth\":3,\"value\":\"Endpoints\"},{\"slug\":\"version-1\",\"depth\":3,\"value\":\"Version 1\"}]}}],\"props\":[{\"key\":\"src/components/Link.jsx\",\"value\":[{\"description\":\"\",\"displayName\":\"Link\",\"methods\":[],\"actualName\":\"Link\"}]},{\"key\":\"src/gatsby-theme-docz/components/Header/index.js\",\"value\":[{\"description\":\"\",\"displayName\":\"Header\",\"methods\":[],\"actualName\":\"Header\"}]},{\"key\":\"src/gatsby-theme-docz/components/Logo/index.js\",\"value\":[{\"description\":\"\",\"displayName\":\"Logo\",\"methods\":[],\"actualName\":\"Logo\"}]}]}"}}} \ No newline at end of file +{"data":{"doczDb":{"id":"ace00e2b-9c46-5e24-a19a-5ed242ca9c64","db":"{\"config\":{\"title\":\"Kerberos.io\",\"description\":\"My awesome app using docz\",\"menu\":[\"Introduction\",\"Architectures\",{\"name\":\"Open Source\",\"menu\":[\"First things first\",\"Get Started\",\"Installation\",\"Releases\",\"License\",\"Upgrade\",\"Contribute\",\"Machinery\",\"Web\"]},{\"name\":\"Enterprise\",\"menu\":[\"First things first\",\"Get Started\",\"Installation\",\"Releases\",\"License\"]},\"Cloud\"],\"version\":\"2.0.0-rc.41\",\"repository\":\"https://github.com/kerberos-io\",\"native\":false,\"themeConfig\":{\"colors\":{\"primary\":\"#943733\",\"secondary\":\"#9e9e9e\",\"h5\":{\"color\":\"#943733\"},\"header\":{\"bg\":\"#943733\"},\"sidebar\":{\"bg\":\"#f9f9f9\",\"navLinkActive\":\"#943733\"},\"modes\":{\"dark\":{\"primary\":\"#9e9e9e\",\"secondary\":\"#943733\",\"header\":{\"bg\":\"#943733\"},\"sidebar\":{\"navLinkActive\":\"#fff\"}}}}},\"separator\":\"-\",\"gatsbyRemarkPlugins\":[{\"resolve\":\"gatsby-remark-vscode\"},{\"resolve\":\"gatsby-remark-grid-tables\"}]},\"entries\":[{\"key\":\"src/architectures.mdx\",\"value\":{\"name\":\"Architectures\",\"route\":\"/architectures\",\"id\":\"bb781d264051ead449d715317c32b263\",\"filepath\":\"src/architectures.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/architectures.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-architectures\",\"menu\":\"\",\"headings\":[{\"slug\":\"architectures\",\"depth\":1,\"value\":\"Architectures\"},{\"slug\":\"agents-on-premise\",\"depth\":2,\"value\":\"Agents on-premise\"},{\"slug\":\"kerberos-open-source--5-kerberos-agents\",\"depth\":3,\"value\":\"Kerberos Open Source (< 5 Kerberos agents)\"},{\"slug\":\"kerberos-enterprise--5-kerberos-agents\",\"depth\":3,\"value\":\"Kerberos Enterprise (> 5 Kerberos agents)\"},{\"slug\":\"agents-in-the-cloud\",\"depth\":2,\"value\":\"Agents in the cloud\"},{\"slug\":\"kerberos-open-source--5-kerberos-agents-1\",\"depth\":3,\"value\":\"Kerberos Open Source (< 5 Kerberos agents)\"},{\"slug\":\"kerberos-enterprise--5-kerberos-agents-1\",\"depth\":3,\"value\":\"Kerberos Enterprise (> 5 Kerberos agents)\"},{\"slug\":\"kerberos-cloud\",\"depth\":2,\"value\":\"Kerberos Cloud\"},{\"slug\":\"architecture\",\"depth\":3,\"value\":\"Architecture\"}]}},{\"key\":\"src/index.mdx\",\"value\":{\"name\":\"Introduction\",\"route\":\"/\",\"id\":\"6576455a124f9aaefd860597f03a8fe4\",\"filepath\":\"src/index.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/index.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-index\",\"menu\":\"\",\"headings\":[{\"slug\":\"kerberosio\",\"depth\":1,\"value\":\"Kerberos.io\"},{\"slug\":\"the-name-kerberosio\",\"depth\":2,\"value\":\"The name: Kerberos.io\"},{\"slug\":\"why-kerberos\",\"depth\":2,\"value\":\"Why Kerberos\"},{\"slug\":\"what-is-kerberos\",\"depth\":2,\"value\":\"What is Kerberos\"},{\"slug\":\"the-kerberos-agent\",\"depth\":2,\"value\":\"The Kerberos agent\"},{\"slug\":\"how-does-it-work\",\"depth\":2,\"value\":\"How does it work\"},{\"slug\":\"open-source-vs-enterprise\",\"depth\":2,\"value\":\"Open Source vs Enterprise\"},{\"slug\":\"cloud\",\"depth\":2,\"value\":\"Cloud\"}]}},{\"key\":\"src/cloud/index.mdx\",\"value\":{\"name\":\"Cloud\",\"route\":\"/cloud\",\"id\":\"082761d36d79f69c41234676c7b77e13\",\"filepath\":\"src/cloud/index.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/cloud/index.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-cloud-index\",\"menu\":\"\",\"headings\":[{\"slug\":\"cloud\",\"depth\":1,\"value\":\"Cloud\"},{\"slug\":\"architecture\",\"depth\":2,\"value\":\"Architecture\"},{\"slug\":\"public-or-private-edition\",\"depth\":3,\"value\":\"Public or Private edition\"},{\"slug\":\"features\",\"depth\":2,\"value\":\"Features\"},{\"slug\":\"secured-storage\",\"depth\":2,\"value\":\"Secured storage\"},{\"slug\":\"consolidated-overview\",\"depth\":2,\"value\":\"Consolidated overview\"},{\"slug\":\"security\",\"depth\":3,\"value\":\"Security\"},{\"slug\":\"advanced-searching\",\"depth\":2,\"value\":\"Advanced searching\"},{\"slug\":\"machine-learning\",\"depth\":2,\"value\":\"Machine learning\"},{\"slug\":\"alerts\",\"depth\":2,\"value\":\"Alerts\"},{\"slug\":\"notifications\",\"depth\":3,\"value\":\"Notifications\"},{\"slug\":\"channels\",\"depth\":3,\"value\":\"Channels\"},{\"slug\":\"live-streaming\",\"depth\":2,\"value\":\"Live streaming\"},{\"slug\":\"accounts\",\"depth\":2,\"value\":\"Accounts\"},{\"slug\":\"logging\",\"depth\":2,\"value\":\"Logging\"}]}},{\"key\":\"src/enterprise/get-started.mdx\",\"value\":{\"name\":\"Get Started\",\"menu\":\"Enterprise\",\"route\":\"/enterprise/get-started\",\"id\":\"190cf47f9b2f25ec9b7155086f299a78\",\"filepath\":\"src/enterprise/get-started.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/get-started.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-enterprise-get-started\",\"headings\":[{\"slug\":\"get-started\",\"depth\":1,\"value\":\"Get Started\"},{\"slug\":\"login-page\",\"depth\":2,\"value\":\"Login page\"},{\"slug\":\"license-key\",\"depth\":2,\"value\":\"License key\"},{\"slug\":\"overview\",\"depth\":2,\"value\":\"Overview\"},{\"slug\":\"kubernetes\",\"depth\":2,\"value\":\"Kubernetes\"},{\"slug\":\"nodes\",\"depth\":2,\"value\":\"Nodes\"},{\"slug\":\"deployments\",\"depth\":2,\"value\":\"Deployments\"},{\"slug\":\"adding-a-new-deployment\",\"depth\":3,\"value\":\"Adding a new deployment\"},{\"slug\":\"configuring-a-deployment\",\"depth\":3,\"value\":\"Configuring a deployment\"},{\"slug\":\"pods\",\"depth\":2,\"value\":\"Pods\"},{\"slug\":\"storage-and-video-management\",\"depth\":2,\"value\":\"Storage and video management\"}]}},{\"key\":\"src/enterprise/index.mdx\",\"value\":{\"name\":\"First things first\",\"menu\":\"Enterprise\",\"route\":\"/enterprise/introduction\",\"id\":\"8f8fd9e742255635cf471c3030fa24ac\",\"filepath\":\"src/enterprise/index.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/index.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-enterprise-index\",\"headings\":[{\"slug\":\"enterprise\",\"depth\":1,\"value\":\"Enterprise\"},{\"slug\":\"kubernetes\",\"depth\":2,\"value\":\"Kubernetes\"},{\"slug\":\"cloud-or-on-premise\",\"depth\":2,\"value\":\"Cloud or on premise\"},{\"slug\":\"licensing\",\"depth\":2,\"value\":\"Licensing\"}]}},{\"key\":\"src/enterprise/installation.mdx\",\"value\":{\"name\":\"Installation\",\"menu\":\"Enterprise\",\"route\":\"/enterprise/installation\",\"id\":\"5cf033b11c0e22a8dad307af4f84a83b\",\"filepath\":\"src/enterprise/installation.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/installation.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-enterprise-installation\",\"headings\":[{\"slug\":\"introduction\",\"depth\":1,\"value\":\"Introduction\"},{\"slug\":\"installation\",\"depth\":1,\"value\":\"Installation\"},{\"slug\":\"helm\",\"depth\":2,\"value\":\"Helm\"},{\"slug\":\"initiate-helm\",\"depth\":3,\"value\":\"Initiate helm\"},{\"slug\":\"traefik\",\"depth\":2,\"value\":\"Traefik\"},{\"slug\":\"mongodb\",\"depth\":2,\"value\":\"MongoDB\"},{\"slug\":\"factory\",\"depth\":2,\"value\":\"Factory\"},{\"slug\":\"test-out-configuration\",\"depth\":1,\"value\":\"Test out configuration\"},{\"slug\":\"access-the-system\",\"depth\":2,\"value\":\"Access the system\"}]}},{\"key\":\"src/enterprise/license.mdx\",\"value\":{\"name\":\"License\",\"menu\":\"Enterprise\",\"route\":\"/enterprise/license\",\"id\":\"692a3e0f1bc0489a5d98bfb87a5efa3e\",\"filepath\":\"src/enterprise/license.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/license.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-enterprise-license\",\"headings\":[{\"slug\":\"eula\",\"depth\":1,\"value\":\"EULA\"}]}},{\"key\":\"src/enterprise/releases.mdx\",\"value\":{\"name\":\"Releases\",\"menu\":\"Enterprise\",\"route\":\"/enterprise/releases\",\"id\":\"d55649896dc1baed370ad4ea221aefb5\",\"filepath\":\"src/enterprise/releases.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/enterprise/releases.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-enterprise-releases\",\"headings\":[{\"slug\":\"release-notes\",\"depth\":1,\"value\":\"Release notes\"},{\"slug\":\"100\",\"depth\":3,\"value\":\"1.0.0\"},{\"slug\":\"factory\",\"depth\":4,\"value\":\"Factory\"}]}},{\"key\":\"src/open-source/contribute.mdx\",\"value\":{\"name\":\"Contribute\",\"menu\":\"Open Source\",\"route\":\"/opensource/contribute\",\"id\":\"111290db815f0c1a551a7742fd821f6f\",\"filepath\":\"src/open-source/contribute.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/contribute.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-contribute\",\"headings\":[{\"slug\":\"contribute\",\"depth\":1,\"value\":\"Contribute\"},{\"slug\":\"machinery\",\"depth\":2,\"value\":\"Machinery\"},{\"slug\":\"prerequisites\",\"depth\":3,\"value\":\"Prerequisites\"},{\"slug\":\"installation\",\"depth\":3,\"value\":\"Installation\"},{\"slug\":\"testing\",\"depth\":3,\"value\":\"Testing\"},{\"slug\":\"adding-a-new-class\",\"depth\":3,\"value\":\"Adding a new class\"},{\"slug\":\"create-the-header-file\",\"depth\":4,\"value\":\"Create the header file\"},{\"slug\":\"create-the-source-file\",\"depth\":4,\"value\":\"Create the source file\"},{\"slug\":\"modify-the-cmakeliststxt-file\",\"depth\":4,\"value\":\"Modify the CMakeLists.txt file\"},{\"slug\":\"create-a-new-entry-in-the-config-file\",\"depth\":4,\"value\":\"Create a new entry in the config file\"},{\"slug\":\"compile\",\"depth\":3,\"value\":\"Compile\"},{\"slug\":\"web\",\"depth\":2,\"value\":\"Web\"},{\"slug\":\"prerequisites-1\",\"depth\":3,\"value\":\"Prerequisites\"},{\"slug\":\"installation-1\",\"depth\":3,\"value\":\"Installation\"}]}},{\"key\":\"src/open-source/get-started.mdx\",\"value\":{\"name\":\"Get Started\",\"menu\":\"Open Source\",\"route\":\"/opensource/get-started\",\"id\":\"059e06c8b1653a3b0c3473f90d782c13\",\"filepath\":\"src/open-source/get-started.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/get-started.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-get-started\",\"headings\":[{\"slug\":\"get-started\",\"depth\":1,\"value\":\"Get Started\"},{\"slug\":\"welcome-page\",\"depth\":2,\"value\":\"Welcome page\"},{\"slug\":\"login-page\",\"depth\":2,\"value\":\"Login page\"},{\"slug\":\"dashboard\",\"depth\":2,\"value\":\"Dashboard\"},{\"slug\":\"media\",\"depth\":2,\"value\":\"Media\"},{\"slug\":\"settings\",\"depth\":2,\"value\":\"Settings\"},{\"slug\":\"region-of-interest\",\"depth\":3,\"value\":\"Region of interest\"},{\"slug\":\"storage\",\"depth\":3,\"value\":\"Storage\"},{\"slug\":\"system\",\"depth\":2,\"value\":\"System\"}]}},{\"key\":\"src/open-source/index.mdx\",\"value\":{\"name\":\"First things first\",\"menu\":\"Open Source\",\"route\":\"/opensource/introduction\",\"id\":\"e182a675cff01d9e46eba94b9b98f68a\",\"filepath\":\"src/open-source/index.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/index.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-index\",\"headings\":[{\"slug\":\"first-things-first\",\"depth\":1,\"value\":\"First things first\"},{\"slug\":\"license\",\"depth\":2,\"value\":\"License\"},{\"slug\":\"when-using-the-open-source-version\",\"depth\":2,\"value\":\"When using the Open Source version\"},{\"slug\":\"how-to-install\",\"depth\":2,\"value\":\"How to install\"}]}},{\"key\":\"src/open-source/installation.mdx\",\"value\":{\"name\":\"Installation\",\"menu\":\"Open Source\",\"route\":\"/opensource/installation\",\"id\":\"9e9908538be367cca76a80425244646f\",\"filepath\":\"src/open-source/installation.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/installation.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-installation\",\"headings\":[{\"slug\":\"installation\",\"depth\":1,\"value\":\"Installation\"},{\"slug\":\"plug-and-play\",\"depth\":3,\"value\":\"Plug and play\"},{\"slug\":\"advanced\",\"depth\":3,\"value\":\"Advanced\"},{\"slug\":\"plug-and-play-1\",\"depth\":1,\"value\":\"Plug and play\"},{\"slug\":\"kios\",\"depth\":2,\"value\":\"KiOS\"},{\"slug\":\"github\",\"depth\":3,\"value\":\"Github\"},{\"slug\":\"kerberos-open-source-installer\",\"depth\":3,\"value\":\"Kerberos Open Source installer\"},{\"slug\":\"etcher\",\"depth\":3,\"value\":\"Etcher\"},{\"slug\":\"connecting-to-wifi\",\"depth\":4,\"value\":\"Connecting to WiFi\"},{\"slug\":\"setup-a-static-ip-address\",\"depth\":4,\"value\":\"Setup a static IP-address\"},{\"slug\":\"power-on-the-raspberry-pi\",\"depth\":3,\"value\":\"Power on the Raspberry Pi\"},{\"slug\":\"access-the-raspberry-pi\",\"depth\":3,\"value\":\"Access the Raspberry Pi\"},{\"slug\":\"docker\",\"depth\":2,\"value\":\"Docker\"},{\"slug\":\"prerequisites\",\"depth\":3,\"value\":\"Prerequisites\"},{\"slug\":\"github-1\",\"depth\":3,\"value\":\"Github\"},{\"slug\":\"download-docker-image\",\"depth\":3,\"value\":\"Download docker image\"},{\"slug\":\"volumes\",\"depth\":3,\"value\":\"Volumes\"},{\"slug\":\"balena\",\"depth\":2,\"value\":\"Balena\"},{\"slug\":\"advanced-1\",\"depth\":1,\"value\":\"Advanced\"},{\"slug\":\"raspbian\",\"depth\":2,\"value\":\"Raspbian\"},{\"slug\":\"update-os\",\"depth\":3,\"value\":\"Update OS\"},{\"slug\":\"machinery\",\"depth\":3,\"value\":\"Machinery\"},{\"slug\":\"web\",\"depth\":3,\"value\":\"Web\"},{\"slug\":\"auto-removal\",\"depth\":3,\"value\":\"Auto removal\"},{\"slug\":\"generic\",\"depth\":2,\"value\":\"Generic\"},{\"slug\":\"machinery-1\",\"depth\":3,\"value\":\"Machinery\"},{\"slug\":\"web-1\",\"depth\":3,\"value\":\"Web\"},{\"slug\":\"auto-removal-1\",\"depth\":3,\"value\":\"Auto removal\"}]}},{\"key\":\"src/open-source/license.mdx\",\"value\":{\"name\":\"License\",\"menu\":\"Open Source\",\"route\":\"/opensource/license\",\"id\":\"b41faa434ffd47abb4b845cb083fff55\",\"filepath\":\"src/open-source/license.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/license.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-license\",\"headings\":[{\"slug\":\"cc-by-nc-sa-40\",\"depth\":1,\"value\":\"CC BY-NC-SA 4.0\"},{\"slug\":\"summary\",\"depth\":2,\"value\":\"Summary\"},{\"slug\":\"the-license\",\"depth\":2,\"value\":\"The license\"},{\"slug\":\"section-1--definitions\",\"depth\":3,\"value\":\"Section 1 – Definitions.\"},{\"slug\":\"section-2--scope\",\"depth\":3,\"value\":\"Section 2 – Scope.\"},{\"slug\":\"section-3--license-conditions\",\"depth\":3,\"value\":\"Section 3 – License Conditions.\"},{\"slug\":\"section-4--sui-generis-database-rights\",\"depth\":3,\"value\":\"Section 4 – Sui Generis Database Rights.\"},{\"slug\":\"section-5--disclaimer-of-warranties-and-limitation-of-liability\",\"depth\":3,\"value\":\"Section 5 – Disclaimer of Warranties and Limitation of Liability.\"},{\"slug\":\"section-6--term-and-termination\",\"depth\":3,\"value\":\"Section 6 – Term and Termination.\"},{\"slug\":\"section-7--other-terms-and-conditions\",\"depth\":3,\"value\":\"Section 7 – Other Terms and Conditions.\"},{\"slug\":\"section-8--interpretation\",\"depth\":3,\"value\":\"Section 8 – Interpretation.\"}]}},{\"key\":\"src/open-source/machinery.mdx\",\"value\":{\"name\":\"Machinery\",\"menu\":\"Open Source\",\"route\":\"/opensource/machinery\",\"id\":\"8b5e104d90b9ec673d88bf43d6bf99f2\",\"filepath\":\"src/open-source/machinery.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/machinery.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-machinery\",\"headings\":[{\"slug\":\"machinery\",\"depth\":1,\"value\":\"Machinery\"},{\"slug\":\"project-structure\",\"depth\":2,\"value\":\"Project structure\"},{\"slug\":\"capture\",\"depth\":2,\"value\":\"Capture\"},{\"slug\":\"usb-camera\",\"depth\":3,\"value\":\"USB camera\"},{\"slug\":\"parameters\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"framewidth-and--height\",\"depth\":5,\"value\":\"Framewidth and -height\"},{\"slug\":\"device-number\",\"depth\":5,\"value\":\"Device number\"},{\"slug\":\"delay\",\"depth\":5,\"value\":\"Delay\"},{\"slug\":\"angle\",\"depth\":5,\"value\":\"Angle\"},{\"slug\":\"raspberry-pi-camera-module\",\"depth\":3,\"value\":\"Raspberry Pi Camera Module\"},{\"slug\":\"parameters-1\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"framewidth-and--height-1\",\"depth\":5,\"value\":\"Framewidth and -height\"},{\"slug\":\"delay-1\",\"depth\":5,\"value\":\"Delay\"},{\"slug\":\"angle-1\",\"depth\":5,\"value\":\"Angle\"},{\"slug\":\"framerate\",\"depth\":5,\"value\":\"Framerate\"},{\"slug\":\"sharpness-saturation-contrast-brightness\",\"depth\":5,\"value\":\"Sharpness, saturation, contrast, brightness\"},{\"slug\":\"ip-camera\",\"depth\":3,\"value\":\"IP camera\"},{\"slug\":\"parameters-2\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"url\",\"depth\":5,\"value\":\"URL\"},{\"slug\":\"framewidth-and--height-2\",\"depth\":5,\"value\":\"Framewidth and -height\"},{\"slug\":\"delay-2\",\"depth\":5,\"value\":\"Delay\"},{\"slug\":\"angle-2\",\"depth\":5,\"value\":\"Angle\"},{\"slug\":\"condition\",\"depth\":2,\"value\":\"Condition\"},{\"slug\":\"enabled\",\"depth\":3,\"value\":\"Enabled\"},{\"slug\":\"parameters-3\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"active\",\"depth\":5,\"value\":\"Active\"},{\"slug\":\"delay-3\",\"depth\":5,\"value\":\"Delay\"},{\"slug\":\"time\",\"depth\":3,\"value\":\"Time\"},{\"slug\":\"parameters-4\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"times\",\"depth\":5,\"value\":\"Times\"},{\"slug\":\"delay-4\",\"depth\":5,\"value\":\"Delay\"},{\"slug\":\"algorithm\",\"depth\":2,\"value\":\"Algorithm\"},{\"slug\":\"differential-images\",\"depth\":3,\"value\":\"Differential images\"},{\"slug\":\"parameters-5\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"erode\",\"depth\":5,\"value\":\"Erode\"},{\"slug\":\"threshold\",\"depth\":5,\"value\":\"Threshold\"},{\"slug\":\"expositor\",\"depth\":2,\"value\":\"Expositor\"},{\"slug\":\"rectangle\",\"depth\":3,\"value\":\"Rectangle\"},{\"slug\":\"parameters-6\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"region\",\"depth\":5,\"value\":\"Region\"},{\"slug\":\"hull\",\"depth\":3,\"value\":\"Hull\"},{\"slug\":\"parameters-7\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"region-1\",\"depth\":5,\"value\":\"Region\"},{\"slug\":\"heuristic\",\"depth\":2,\"value\":\"Heuristic\"},{\"slug\":\"sequence\",\"depth\":3,\"value\":\"Sequence\"},{\"slug\":\"parameters-8\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"minimum-changes\",\"depth\":5,\"value\":\"Minimum changes\"},{\"slug\":\"minimum-durations\",\"depth\":5,\"value\":\"Minimum durations\"},{\"slug\":\"no-motion-delay-time\",\"depth\":5,\"value\":\"No motion delay time\"},{\"slug\":\"output\",\"depth\":2,\"value\":\"Output\"},{\"slug\":\"disk\",\"depth\":3,\"value\":\"Disk\"},{\"slug\":\"parameters-9\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"file-format\",\"depth\":5,\"value\":\"File format\"},{\"slug\":\"directory\",\"depth\":5,\"value\":\"Directory\"},{\"slug\":\"mark-with-timestamp\",\"depth\":5,\"value\":\"Mark with timestamp\"},{\"slug\":\"timestamp-color\",\"depth\":5,\"value\":\"Timestamp color\"},{\"slug\":\"privacy\",\"depth\":5,\"value\":\"Privacy\"},{\"slug\":\"throttler\",\"depth\":5,\"value\":\"Throttler\"},{\"slug\":\"video\",\"depth\":3,\"value\":\"Video\"},{\"slug\":\"parameters-10\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"fps\",\"depth\":5,\"value\":\"FPS\"},{\"slug\":\"record-after\",\"depth\":5,\"value\":\"Record after\"},{\"slug\":\"extensions\",\"depth\":5,\"value\":\"Extensions\"},{\"slug\":\"codec\",\"depth\":5,\"value\":\"Codec\"},{\"slug\":\"file-format-1\",\"depth\":5,\"value\":\"File format\"},{\"slug\":\"directory-1\",\"depth\":5,\"value\":\"Directory\"},{\"slug\":\"hardware-directory\",\"depth\":5,\"value\":\"Hardware directory\"},{\"slug\":\"enable-hardware-encoding\",\"depth\":5,\"value\":\"Enable Hardware encoding\"},{\"slug\":\"mark-with-timestamp-1\",\"depth\":5,\"value\":\"Mark with timestamp\"},{\"slug\":\"timestamp-color-1\",\"depth\":5,\"value\":\"Timestamp color\"},{\"slug\":\"privacy-1\",\"depth\":5,\"value\":\"Privacy\"},{\"slug\":\"video-privacy\",\"depth\":5,\"value\":\"Video privacy\"},{\"slug\":\"throttler-1\",\"depth\":5,\"value\":\"Throttler\"},{\"slug\":\"tcpip-client\",\"depth\":3,\"value\":\"TCP/IP client\"},{\"slug\":\"parameters-11\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"server\",\"depth\":5,\"value\":\"Server\"},{\"slug\":\"port\",\"depth\":5,\"value\":\"Port\"},{\"slug\":\"message\",\"depth\":5,\"value\":\"Message\"},{\"slug\":\"throttler-2\",\"depth\":5,\"value\":\"Throttler\"},{\"slug\":\"gpio\",\"depth\":3,\"value\":\"GPIO\"},{\"slug\":\"parameters-12\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"pin\",\"depth\":5,\"value\":\"Pin\"},{\"slug\":\"periods\",\"depth\":5,\"value\":\"Periods\"},{\"slug\":\"period-time\",\"depth\":5,\"value\":\"Period time\"},{\"slug\":\"throttler-3\",\"depth\":5,\"value\":\"Throttler\"},{\"slug\":\"webhook\",\"depth\":3,\"value\":\"Webhook\"},{\"slug\":\"parameters-13\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"url-1\",\"depth\":5,\"value\":\"Url\"},{\"slug\":\"throttler-4\",\"depth\":5,\"value\":\"Throttler\"},{\"slug\":\"output-1\",\"depth\":5,\"value\":\"Output\"},{\"slug\":\"script\",\"depth\":3,\"value\":\"Script\"},{\"slug\":\"parameters-14\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"path\",\"depth\":5,\"value\":\"Path\"},{\"slug\":\"throttler-5\",\"depth\":5,\"value\":\"Throttler\"},{\"slug\":\"example\",\"depth\":5,\"value\":\"Example\"},{\"slug\":\"mqtt\",\"depth\":3,\"value\":\"MQTT\"},{\"slug\":\"parameters-15\",\"depth\":4,\"value\":\"Parameters\"},{\"slug\":\"secure\",\"depth\":5,\"value\":\"Secure\"},{\"slug\":\"verifycn\",\"depth\":5,\"value\":\"Verifycn\"},{\"slug\":\"server-1\",\"depth\":5,\"value\":\"Server\"},{\"slug\":\"port-1\",\"depth\":5,\"value\":\"Port\"},{\"slug\":\"topic\",\"depth\":5,\"value\":\"Topic\"},{\"slug\":\"username\",\"depth\":5,\"value\":\"Username\"},{\"slug\":\"password\",\"depth\":5,\"value\":\"Password\"},{\"slug\":\"throttler-6\",\"depth\":5,\"value\":\"Throttler\"},{\"slug\":\"output-2\",\"depth\":5,\"value\":\"Output\"},{\"slug\":\"example-1\",\"depth\":5,\"value\":\"Example\"},{\"slug\":\"streaming\",\"depth\":2,\"value\":\"Streaming\"},{\"slug\":\"parameters-16\",\"depth\":3,\"value\":\"Parameters\"},{\"slug\":\"enabled-1\",\"depth\":4,\"value\":\"Enabled\"},{\"slug\":\"stream-port\",\"depth\":4,\"value\":\"Stream Port\"},{\"slug\":\"quality\",\"depth\":4,\"value\":\"Quality\"},{\"slug\":\"usernamepassword\",\"depth\":4,\"value\":\"Username/password\"}]}},{\"key\":\"src/open-source/releases.mdx\",\"value\":{\"name\":\"Releases\",\"menu\":\"Open Source\",\"route\":\"/opensource/releases\",\"id\":\"0513012dd89890d93de77c3aa4597e7f\",\"filepath\":\"src/open-source/releases.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/releases.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-releases\",\"headings\":[{\"slug\":\"release-notes\",\"depth\":1,\"value\":\"Release notes\"},{\"slug\":\"280\",\"depth\":3,\"value\":\"2.8.0\"},{\"slug\":\"web\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"kios\",\"depth\":4,\"value\":\"KiOS\"},{\"slug\":\"272\",\"depth\":3,\"value\":\"2.7.2\"},{\"slug\":\"machinery\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"271\",\"depth\":3,\"value\":\"2.7.1\"},{\"slug\":\"machinery-1\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"kios-1\",\"depth\":4,\"value\":\"KiOS\"},{\"slug\":\"270\",\"depth\":3,\"value\":\"2.7.0\"},{\"slug\":\"web-1\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-2\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"docker\",\"depth\":4,\"value\":\"Docker\"},{\"slug\":\"kios-2\",\"depth\":4,\"value\":\"KiOS\"},{\"slug\":\"261\",\"depth\":3,\"value\":\"2.6.1\"},{\"slug\":\"web-2\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-3\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"260\",\"depth\":3,\"value\":\"2.6.0\"},{\"slug\":\"web-3\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-4\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"docker-1\",\"depth\":4,\"value\":\"Docker\"},{\"slug\":\"250\",\"depth\":3,\"value\":\"2.5.0\"},{\"slug\":\"web-4\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-5\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"242\",\"depth\":3,\"value\":\"2.4.2\"},{\"slug\":\"web-5\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-6\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"241\",\"depth\":3,\"value\":\"2.4.1\"},{\"slug\":\"web-6\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"240\",\"depth\":3,\"value\":\"2.4.0\"},{\"slug\":\"ecosystem\",\"depth\":4,\"value\":\"Ecosystem\"},{\"slug\":\"web-7\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"docker-2\",\"depth\":4,\"value\":\"Docker\"},{\"slug\":\"machinery-7\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"231\",\"depth\":3,\"value\":\"2.3.1\"},{\"slug\":\"machinery-8\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"230\",\"depth\":3,\"value\":\"2.3.0\"},{\"slug\":\"ecosystem-1\",\"depth\":4,\"value\":\"Ecosystem\"},{\"slug\":\"221\",\"depth\":3,\"value\":\"2.2.1\"},{\"slug\":\"ecosystem-2\",\"depth\":4,\"value\":\"Ecosystem\"},{\"slug\":\"web-8\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-9\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"220\",\"depth\":3,\"value\":\"2.2.0\"},{\"slug\":\"ecosystem-3\",\"depth\":4,\"value\":\"Ecosystem\"},{\"slug\":\"web-9\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-10\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"210\",\"depth\":3,\"value\":\"2.1.0\"},{\"slug\":\"web-10\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-11\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"ecosystem-4\",\"depth\":4,\"value\":\"Ecosystem\"},{\"slug\":\"200\",\"depth\":3,\"value\":\"2.0.0\"},{\"slug\":\"web-11\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-12\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"docker-3\",\"depth\":4,\"value\":\"Docker\"},{\"slug\":\"ecosystem-5\",\"depth\":4,\"value\":\"Ecosystem\"},{\"slug\":\"110\",\"depth\":3,\"value\":\"1.1.0\"},{\"slug\":\"web-12\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-13\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"cloud\",\"depth\":4,\"value\":\"Cloud\"},{\"slug\":\"103\",\"depth\":3,\"value\":\"1.0.3\"},{\"slug\":\"web-13\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-14\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"cloud-1\",\"depth\":4,\"value\":\"Cloud\"},{\"slug\":\"102\",\"depth\":3,\"value\":\"1.0.2\"},{\"slug\":\"web-14\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-15\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"101\",\"depth\":3,\"value\":\"1.0.1\"},{\"slug\":\"web-15\",\"depth\":4,\"value\":\"Web\"},{\"slug\":\"machinery-16\",\"depth\":4,\"value\":\"Machinery\"},{\"slug\":\"100\",\"depth\":3,\"value\":\"1.0.0\"},{\"slug\":\"first-commit-of-kerberosio\",\"depth\":4,\"value\":\"First commit of Kerberos.io\"}]}},{\"key\":\"src/open-source/upgrade.mdx\",\"value\":{\"name\":\"Upgrade\",\"menu\":\"Open Source\",\"route\":\"/opensource/upgrade\",\"id\":\"bdff501afe4f3c7e6fc0f2ef0f365d5d\",\"filepath\":\"src/open-source/upgrade.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/upgrade.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-upgrade\",\"headings\":[{\"slug\":\"upgrade\",\"depth\":1,\"value\":\"Upgrade\"},{\"slug\":\"kios\",\"depth\":2,\"value\":\"KiOS\"},{\"slug\":\"raspbian\",\"depth\":2,\"value\":\"Raspbian\"},{\"slug\":\"docker\",\"depth\":2,\"value\":\"Docker\"}]}},{\"key\":\"src/open-source/web.mdx\",\"value\":{\"name\":\"Web\",\"menu\":\"Open Source\",\"route\":\"/opensource/web\",\"id\":\"302e6588cf7f47fc4110356883b1761b\",\"filepath\":\"src/open-source/web.mdx\",\"fullpath\":\"/Users/i353408/Vagrant/www/repos/documentation/src/open-source/web.mdx\",\"link\":\"\",\"hidden\":false,\"slug\":\"src-open-source-web\",\"headings\":[{\"slug\":\"web-interface\",\"depth\":1,\"value\":\"Web interface\"},{\"slug\":\"overview\",\"depth\":2,\"value\":\"Overview\"},{\"slug\":\"dashboard\",\"depth\":3,\"value\":\"Dashboard\"},{\"slug\":\"overview-1\",\"depth\":3,\"value\":\"Overview\"},{\"slug\":\"settings\",\"depth\":3,\"value\":\"Settings\"},{\"slug\":\"system\",\"depth\":3,\"value\":\"System\"},{\"slug\":\"project-structure\",\"depth\":2,\"value\":\"Project structure\"},{\"slug\":\"back-end\",\"depth\":3,\"value\":\"Back-end\"},{\"slug\":\"front-end\",\"depth\":3,\"value\":\"Front-end\"},{\"slug\":\"api\",\"depth\":2,\"value\":\"API\"},{\"slug\":\"authentication\",\"depth\":3,\"value\":\"Authentication\"},{\"slug\":\"endpoints\",\"depth\":3,\"value\":\"Endpoints\"},{\"slug\":\"version-1\",\"depth\":3,\"value\":\"Version 1\"}]}}],\"props\":[{\"key\":\"src/components/Link.jsx\",\"value\":[{\"description\":\"\",\"displayName\":\"Link\",\"methods\":[],\"actualName\":\"Link\"}]},{\"key\":\"src/gatsby-theme-docz/components/Header/index.js\",\"value\":[{\"description\":\"\",\"displayName\":\"Header\",\"methods\":[],\"actualName\":\"Header\"}]},{\"key\":\"src/gatsby-theme-docz/components/Logo/index.js\",\"value\":[{\"description\":\"\",\"displayName\":\"Logo\",\"methods\":[],\"actualName\":\"Logo\"}]}]}"}}} \ No newline at end of file diff --git a/src/open-source/installation.mdx b/src/open-source/installation.mdx index c1096d9..1d5d187 100644 --- a/src/open-source/installation.mdx +++ b/src/open-source/installation.mdx @@ -10,10 +10,20 @@ import ReplaceVersion from "../components/ReplaceVersion"; Kerberos Open Source comes with different installation flavours. So you might think, why? The reason is simple, depending on the use case one option is better than another. A short list of recommendations: +### Plug and play 1. [KiOS](/opensource/installation#kios): You have a Raspberry Pi, and you only want to run a Kerberos agent on it. -2. [Raspbian](/opensource/installation#raspbian): You have a Raspberry Pi, but you want other services running next to the Kerberos agent. -3. [Docker](/opensource/installation#docker): You have a lot of IP cameras, and/or don't want to mess with dependencies. -4. [Generic](/opensource/installation#generic): You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure. +2. [Docker](/opensource/installation#docker): You have a lot of IP cameras, and/or don't want to mess with dependencies. +3. [Balena](/opensource/installation#balena): Runnning the Kerberos Docker container on top of Balena. + +### Advanced +4. [Raspbian](/opensource/installation#raspbian): You have a Raspberry Pi, but you want other services running next to the Kerberos agent. +5. [Generic](/opensource/installation#generic): You want to develop/extend Kerberos with your own features, or you want to run a Kerberos agent on a not supported OS/architecure. + +--- + +# Plug and play + +Following installation methods aim for the simplicity of installing Kerberos Open Source. With almost no efforts you can have Kerberos Open Source running. ## KiOS @@ -25,7 +35,7 @@ It can be installed using our own installer, which comes with a nice interface t KiOS is compiled using Buildroot, the project can be found on [following Github repo](https://github.com/kerberos-io/kios). -### Kerberos installer +### Kerberos Open Source installer Installing the Kerberos agent to your Raspberry Pi, has never been so easy. By using our cross-platform installer, you can run a fully configured video surveillance system within 3 minutes. Indeed, we also think that's awesome! @@ -88,7 +98,7 @@ Once you've finished the installation using either the KiOS installer or Etcher, You can access the KiOS system with attaching your Raspberry Pi to a HDMI monitor or by using `ssh`. ```ts -Cedrics-Mac-mini:build cedricverst$ ssh root@192.168.0.12 +$ ssh root@192.168.0.12 Welcome to kios-79e30bbb! [root@kios-79e30bbb ~]# ``` @@ -100,6 +110,82 @@ Note that by default no root password is set, you can define a password in the ` [root@kios-79e30bbb ~]# reboot ``` +## Docker + +A Docker image (amd64, armv7, arm64) is available on [the Docker hub](https://hub.docker.com/u/kerberos), which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use Docker, to get the Kerberos agent up and running. All Docker images can be found on [the Docker hub](https://hub.docker.com/u/kerberos). + +### Prerequisites + +> Docker or Docker Desktop (Linux, OS or Windows) + +### Github + +All technical information, such as Dockerfile, can be found on [following Github repo](https://github.com/kerberos-io/docker). + +### Download docker image + +Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub. + +```ts +docker pull kerberos/kerberos +``` + +When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889. + +```ts +docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos +``` + +To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS). + +```ts +docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos +docker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos +``` + +When the containers are created, you can open your browser and browse to your different containers. +```ts +http://localhost:80 +http://localhost:81 +http://localhost:82 +``` + +### Volumes + +Instead of just running the Kerberos container, you can also persist your configuration by assigning volumes. An example of mounting volumes looks like this; an overview of [the different volumes can be found here](https://github.com/kerberos-io/docker/blob/master/Dockerfile#L171-L177). + +- preload configuration, +- or centralise the images/videos on your working station. + +```ts +docker run --name kerberos-camera1 \ +-p 80:80 -p 8889:8889 \ +-v ~/config:/etc/opt/kerberosio/config \ +-v ~/capture:/etc/opt/kerberosio/capture \ +-v ~/logs:/etc/opt/kerberosio/logs \ +-v ~/webconfig:/var/www/web/config \ +-d kerberos/kerberos +``` + +If you want to learn more about Kerberos.io on Docker, have a look at these tutorials. +- [Kerberos.io — the road to Docker](https://medium.com/@cedricverst/kerberos-io-the-road-to-docker-8e048a480241) +- [Kerberos.io on Docker](https://medium.com/@cedricverst/kerberos-io-on-docker-19b25fa7efd1) + + +## Balena + +Running Kerberos inside a Docker container is great, it makes it possible to run Kerberos everywhere, basically on any Linux OS. These days we have a lot of IoT boards, however by default we only support the Raspberry Pi versions. The reason is simple, it's not our major concern to support any kind of board. + +To fill the gap, regarding the latter, we can rely on another solution called [Balena.io](https://balena.io). Balena supports a huge range of IoT boards, the only thing it requires is a Docker image build for the require architecture. As the Docker image for Kerberos Open Source is a multi-architecture image, we can run our Kerberos Docker image on the Balena OS (more info follows). + +On top of supporting a lot of boars, + +--- + +# Advanced + +Following installation methods are only for advanced users, who need to have more control over the Kerberos Open Source environment. + ## Raspbian If you have already an OS (e.g. Raspbian Buster) flashed to your Raspberry Pi, then it makes sense to install the Kerberos agent on top of your existing OS. There are two ways to achieve this: @@ -268,52 +354,6 @@ Append following line, to execute the autoremoval.sh script every 5min. */5 * * * * /bin/bash /home/pi/autoremoval.sh ``` -## Docker - -A Docker image (x86, ARMv7, ARMv8) is available on the Docker Hub, which contains all the necessary software to setup the Kerberos agent in a matter of seconds. Before you can run this image, make sure you have Docker installed. Afterwards you can use docker, to get the Kerberos agent up and running. All docker images can be found on [the Docker hub](https://hub.docker.com/u/kerberos). - -### Prerequisites - -> Docker or Docker Desktop (Linux, OS or Windows) - -### Github - -All technical information, such as Dockerfile, can be found on [following Github repo](https://github.com/kerberos-io/docker). - -### Download docker image - -Before you are able to run the Kerberos agent inside a container, you will need to pull the docker image from the Docker hub. - -```ts -docker pull kerberos/kerberos -``` - -When you pulled succesfully you can run your first Kerberos container as following. This will run Kerberos agent and expose the web interface on port 80, and the livestream on port 8889. - -```ts -docker run --name camera1 -p 80:80 -p 8889:8889 -d kerberos/kerberos -``` - -To add more containers, you can change the name parameter and assign another port to expose the web interface and livestream (ports are unique on a OS). - -```ts -docker run --name camera2 -p 81:80 -p 8890:8889 -d kerberos/kerberos -docker run --name camera3 -p 82:80 -p 8891:8889 -d kerberos/kerberos -``` - -When the containers are created, you can open your browser and browse to your different containers. -```ts -http://localhost:80 -http://localhost:81 -http://localhost:82 -``` - -### Volumes - -You can assign volumes to the Kerberos container to for example -- preload configuration, -- or centralise the images/videos on your working station. - ## Generic If you want to install the Kerberos agent from source on your working station or server, either for development or running the software, this is the preferred installation procedure. We are assuming that you use a Linux OS, when using Mac OSX the installation is slightly different.