Skip to content

Commit

Permalink
Merge branch 'main' into drop-label-printer
Browse files Browse the repository at this point in the history
  • Loading branch information
guyonvarch authored Sep 6, 2024
2 parents 71b5880 + 2befad4 commit d92b460
Show file tree
Hide file tree
Showing 7 changed files with 1,012 additions and 26 deletions.
39 changes: 23 additions & 16 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,18 +21,28 @@ This repository contains the application layer for running the Dividat Play web

See the [documentation](docs/arch) and [user manual](docs/user-manual) for more information.

## Quick start
## Building the system

Running `nix build` will create following (in `result/`):
### Quick start

The quickest way to see the system in action is to [use the QEMU VM](#qemu-vm).

You can perform all common build variants using the `build` script. Run `./build` without parameters for a list of build variants.

### Full build

Running `./build all` (equivalently `nix-build`) creates all of the following (in `result/`):

- `bin/`: Tools
- `playos-VERSION-UNSIGNED.raucb`: RAUC bundle that can be used to update systems. Note that it is signed with a dummy development key. Real deployments would resign the bundle with `rauc resign`.
- `playos-installer-VERSION.iso`: Bootable ISO image that can install the system.
- `disk.img`: Preinstalled disk with bootloader, system partitions A/B and data partitions for testing (but without test instrumentation).

Note that a full build takes a long time.

### Choose what to build

For quicker development cycles you may pass following arguments to the build:
The following arguments may be used to control the build outputs:

- `buildInstaller`: Should the installer ISO image be built.
- `buildBundle`: Should the RAUC bundle be built.
Expand All @@ -41,19 +51,6 @@ For quicker development cycles you may pass following arguments to the build:

For example: `nix build --arg buildInstaller false --arg buildBundle false` will only build the system toplevels and the preinstalled disk image.

A virtual machine (with test instrumentation) can be started without any of the above builds.

## Components

### Controller

The [controller](controller/) service orchestrates the system's self-update and acts as a configuration interface for the options exposed to the user. It may be run directly on a Linux host for development purposes.

### Kiosk

The [kiosk](kiosk/) browser is used in the default configuration of PlayOS to run any web application in a full screen kiosk. It can be run directly on most hosts for development purposes.


## System Testing

To test integrated portions of the PlayOS system, there are several options/levels available:
Expand Down Expand Up @@ -139,6 +136,16 @@ To release an update to the `develop` channel:

When switching key pairs on a channel, the new certficiate must be built into the bundle, which must then be signed with the old key. For this purpose, the `--override-cert` option of the deploy script is needed to provide RAUC with a certificate matching the new key.

## Components

### Controller

The [controller](controller/) service orchestrates the system's self-update and acts as a configuration interface for the options exposed to the user. It may be run directly on a Linux host for development purposes.

### Kiosk

The [kiosk](kiosk/) browser is used in the default configuration of PlayOS to run any web application in a full screen kiosk. It can be run directly on most hosts for development purposes.

## Change Log

Update the change log for every release. See http://keepachangelog.com/ for formatting and conventions.
Expand Down
14 changes: 11 additions & 3 deletions build
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
#!/usr/bin/env bash
set -euo pipefail

TARGET="${1:-default}"
usage() {
echo "Usage: $0 {vm|develop|validation|master|stuck|lab-key|shed-key|all}"
exit 1
}

if [ $# -eq 0 ]; then
usage
fi
TARGET="$1"

# Allow unfree packages, required for zerotier using a BSL 1.1 licence
# See https://nixos.wiki/wiki/FAQ/How_can_I_install_a_proprietary_or_unfree_package%3F
Expand Down Expand Up @@ -106,7 +114,7 @@ elif [ "$TARGET" == "shed-key" ]; then
--arg buildBundle false \
--arg buildDisk false)

elif [ "$TARGET" == "default" ]; then
elif [ "$TARGET" == "all" ]; then

(set -x; nix-build)

Expand All @@ -115,6 +123,6 @@ else
echo
echo "I do not know how to build '$TARGET'."
echo "Aborting."
exit 1
usage

fi
4 changes: 4 additions & 0 deletions controller/Changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# [UNRELEASED]

## Added

- controller: Enable spatial navigation using the arrow keys

## Removed

- controller: Remove unused label printing functionality
Expand Down
1 change: 1 addition & 0 deletions controller/dune
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
(Changelog.html as Changelog.html)
(gui/reset.css as static/reset.css)
(gui/style.css as static/style.css)
(gui/vendor/focus-shift.js as static/vendor/focus-shift.js)
(gui/client.js as static/client.js)))

; Disable missing-record-field-pattern warnings (partial matching),
Expand Down
Loading

0 comments on commit d92b460

Please sign in to comment.