Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setup NixOS Hypervisor #629

Merged
merged 15 commits into from
Dec 22, 2023
5 changes: 5 additions & 0 deletions .changeset/bunq2ynab-nervous-oranges-fetch.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"bunq2ynab": patch
---

fix: Loading Python base image
5 changes: 5 additions & 0 deletions .changeset/provisioner-healthy-parents-drop.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"provisioner": patch
---

fix: Loading Python base image
10 changes: 8 additions & 2 deletions WORKSPACE.bzlmod
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,10 @@ nixpkgs_package(
name = "python_base_image_amd64",
build_file_content = """
package(default_visibility = [ "//visibility:public" ])
exports_files(["image.tar.gz"])
filegroup(
name = "image",
srcs = ["image.tar.gz"],
)
""",
nix_file = "//tools/python:python_base_image.nix",
nixopts = [
Expand All @@ -233,7 +236,10 @@ nixpkgs_package(
name = "python_base_image_arm64",
build_file_content = """
package(default_visibility = [ "//visibility:public" ])
exports_files(["image.tar.gz"])
filegroup(
name = "image",
srcs = ["image.tar.gz"],
)
""",
nix_file = "//tools/python:python_base_image.nix",
nixopts = [
Expand Down
3 changes: 2 additions & 1 deletion devbox.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
"[email protected]",
"libarchive@latest",
"[email protected]",
"[email protected]"
"[email protected]",
"nixos-rebuild@latest"
],
"shell": {
"init_hook": ["alias bazel='bazelisk'", "export PATH=$HOME/bin:$PATH"]
Expand Down
13 changes: 13 additions & 0 deletions devbox.lock
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,19 @@
}
}
},
"nixos-rebuild@latest": {
"last_modified": "2023-12-13T22:54:10Z",
"resolved": "github:NixOS/nixpkgs/fd04bea4cbf76f86f244b9e2549fca066db8ddff#nixos-rebuild",
"source": "devbox-search",
"systems": {
"aarch64-linux": {
"store_path": "/nix/store/lvdvlm6j41mkykldg84kkx7xd1bwsghw-nixos-rebuild"
},
"x86_64-linux": {
"store_path": "/nix/store/34kyi1rwzqpfyb6vm4y3jxfwj4iy8vz7-nixos-rebuild"
}
}
},
"[email protected]": {
"last_modified": "2023-09-17T10:54:49Z",
"resolved": "github:NixOS/nixpkgs/5148520bfab61f99fd25fb9ff7bfbb50dad3c9db#nixpkgs-fmt",
Expand Down
3 changes: 1 addition & 2 deletions esphome_nimble/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -100,8 +100,7 @@ switch:
id: shelly_relay
name: "${entity_id}"
output: "relay_output"
# after reboot, keep the relay off. this prevents light turning on after a power outage
restore_mode: ALWAYS_OFF
restore_mode: RESTORE_DEFAULT_OFF

# From https://community.home-assistant.io/t/shelly-plus-1-esphome-bletracker/363549/38
# Setup a button in home assistant to reboot the shelly into safe mode
Expand Down
2 changes: 1 addition & 1 deletion home-assistant/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ services:
- ./zigbee2mqtt-data:/app/data
- /run/udev:/run/udev:ro
ports:
- "127.0.0.1:8080:8080"
- "0.0.0.0:8080:8080"
environment:
- TZ=Europe/Amsterdam
devices:
Expand Down
3 changes: 1 addition & 2 deletions home-assistant/esphome-data/.shelly-1l.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,4 @@ switch:
id: shelly_relay
name: "${entity_id}"
output: "relay_output"
# after reboot, keep the relay off. this prevents light turning on after a power outage
restore_mode: ALWAYS_OFF
restore_mode: RESTORE_DEFAULT_OFF
3 changes: 1 addition & 2 deletions home-assistant/esphome-data/.shelly-1pm-plus.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@ switch:
id: shelly_relay
name: "${entity_id}"
output: "relay_output"
# after reboot, keep the relay off. this prevents light turning on after a power outage
restore_mode: ALWAYS_OFF
restore_mode: RESTORE_DEFAULT_OFF

status_led:
pin:
Expand Down
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/baby-room-bed-light-moko.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ substitutions:
packages:
device_base: !include .moko-mk115.yaml
base: !include .base.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/baby-room-moon-light-moko.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ substitutions:
packages:
device_base: !include .moko-mk115.yaml
base: !include .base.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/baby-room-shelly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ substitutions:

packages:
device_base: !include .shelly-1pm-plus.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
base: !include .base.yaml
smart_light_restore: !include .smart_light_restore.yaml

Expand Down
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/bathroom-human-moko.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ substitutions:
packages:
device_base: !include .moko-mk115.yaml
base: !include .base.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/bedroom-charger-moko.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ substitutions:
packages:
device_base: !include .moko-mk115.yaml
base: !include .base.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/bedroom-shelly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ substitutions:

packages:
device_base: !include .shelly-1pm-plus.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
base: !include .base.yaml

binary_sensor:
Expand Down
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/bedroom-tv-moko.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ substitutions:
packages:
device_base: !include .moko-mk115.yaml
base: !include .base.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/driveway-shelly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ substitutions:

packages:
device_base: !include .shelly-1pm-plus.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
base: !include .base.yaml

binary_sensor:
Expand Down
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/garden-shelly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ substitutions:

packages:
device_base: !include .shelly-1pm-plus.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
base: !include .base.yaml

binary_sensor:
Expand Down
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/hallway-shelly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ substitutions:

packages:
device_base: !include .shelly-1pm-plus.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
base: !include .base.yaml
smart_light_restore: !include .smart_light_restore.yaml

Expand Down
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/hallway-vacuum-moko.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ substitutions:
packages:
device_base: !include .moko-mk115.yaml
base: !include .base.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/kitchen-oven-moko.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ substitutions:
packages:
device_base: !include .moko-mk115.yaml
base: !include .base.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/kitchen-shelly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ substitutions:

packages:
device_base: !include .shelly-1pm-plus.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
base: !include .base.yaml
smart_light_restore: !include .smart_light_restore.yaml

Expand Down
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/landing-shelly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ substitutions:

packages:
device_base: !include .shelly-1pm-plus.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
base: !include .base.yaml
smart_light_restore: !include .smart_light_restore.yaml

Expand Down
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/laundry-room-shelly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ substitutions:

packages:
device_base: !include .shelly-1pm-plus.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
base: !include .base.yaml

binary_sensor:
Expand Down
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/living-room-monkey-moko.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ substitutions:
packages:
device_base: !include .moko-mk115.yaml
base: !include .base.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/living-room-shelly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ substitutions:

packages:
device_base: !include .shelly-1pm-plus.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
base: !include .base.yaml
smart_light_restore: !include .smart_light_restore.yaml

Expand Down
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/living-room-tv-moko.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ substitutions:
packages:
device_base: !include .moko-mk115.yaml
base: !include .base.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/office-human-moko.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ substitutions:
packages:
device_base: !include .moko-mk115.yaml
base: !include .base.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/office-server-moko.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ substitutions:
packages:
device_base: !include .moko-mk115.yaml
base: !include .base.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/office-shelly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ substitutions:

packages:
device_base: !include .shelly-1pm-plus.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
base: !include .base.yaml

binary_sensor:
Expand Down
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/supply-closet-shelly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ substitutions:

packages:
device_base: !include .shelly-1pm-plus.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
base: !include .base.yaml

binary_sensor:
Expand Down
2 changes: 1 addition & 1 deletion home-assistant/esphome-data/test-shelly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ substitutions:

packages:
device_base: !include .shelly-1pm-plus.yaml
bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
# bluetooth_object_tracking: !include .bluetooth_object_tracking.yaml
base: !include .base.yaml

binary_sensor:
Expand Down
Loading
Loading