-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
25 changed files
with
520 additions
and
286 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
VM_NAME = dogebox-$(shell date +%s) | ||
|
||
pve: | ||
@echo "Generating Proxmox LXC..." | ||
@nixos-generate -c nix/default-builder.nix -f proxmox-lxc | ||
|
||
virtualbox: | ||
@echo "Generating VirtualBox OVA..." | ||
@nixos-generate -c nix/vbox-builder.nix -f virtualbox | ||
|
||
virtualbox-launch: virtualbox | ||
@echo "Importing and launching the VirtualBox VM..." | ||
# Capture the generated OVA path from the nixos-generate output | ||
OVA_FILE=$$(nixos-generate -c nix/vbox-builder.nix -f virtualbox | grep -o '.*\.ova$$'); \ | ||
BRIDGE_ADAPTER=$$(VBoxManage list bridgedifs | grep '^Name:' | head -n1 | awk '{print $$2}'); \ | ||
VBoxManage import $$OVA_FILE --vsys 0 --vmname "$(VM_NAME)" && \ | ||
VBoxManage modifyvm "$(VM_NAME)" --nic1 bridged --bridgeadapter1 $$BRIDGE_ADAPTER && \ | ||
VBoxManage startvm "$(VM_NAME)" | ||
|
||
.PHONY: pve qcow virtualbox virtualbox-launch |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,45 +1,110 @@ | ||
# dogebox | ||
Dogebox is a NixOS distribution that runs the Dogebox Runtime Environment | ||
<div align="center"> | ||
<img src="docs/img/dogebox-logo.png" alt="Dogebox Logo"/> | ||
<p>DOGEBOX is a NixOS distribution that runs the Dogebox Runtime Environment</p> | ||
</div> | ||
|
||
## SD and SD installer images | ||
> [!CAUTION] | ||
> Dogebox is currently in a pre-alpha developer preview. Do not use it for any production workloads, and definitely don't send any money to addresses generated by it. | ||
These are built with FriendlyElec's sd-fuse_rk3588. Documentation TBA. | ||
|
||
## Container/VM images | ||
Quick notes on building a container or VM image from a configuration.nix file: | ||
## What is Dogebox | ||
Dogebox is a Linux OS with a web-based management interface and permission-based routing and container system designed to | ||
provide a platform and DRE (Dogecoin Runtime Environment) for building services and apps on top of the Dogecoin blockchain. | ||
|
||
- make sure the configuration.nix doesn't mention a bootloader, an appropriate one is included automatically and one defined here can conflict. | ||
Services & applications packaged for Dogebox are called 'pups', these are standard linux services that are executed in | ||
isolated containers, with access to other 'pups' and the Dogecoin blockchain via ACL/Permission controlled internal routing. | ||
|
||
- install 'nixos-generators', if you have the nix package manager or are running NixOS you can just run 'nix-shell -p nixos-generators' | ||
## Current Status | ||
|
||
- build the desired image with 'nixos-generate -c configuration.nix -f <format>' | ||
**As a pre-alpha preview, these images are provided for people to get an idea of how the system works, while we push to | ||
complete all the 'glue' that brings the whole system together. We expect rapid acceleration of functionality over the | ||
next two weeks (now - 20th Sept 2024).** | ||
|
||
Tested image formats include: | ||
- docker | ||
- install-iso | ||
- iso | ||
- lxc / lxc-metadata | ||
- proxmox-lxc | ||
- qcow | ||
- vmware | ||
Expect that these images will be rapidly replaced as we get closer to a complete working system! | ||
|
||
- The build output should tell you the name and location of the built image. | ||
### Functionality in current nightly: | ||
|
||
### 'docker' for docker/podman | ||
Use 'docker import' or 'podman import' to generate a container image. You will need to manually specify a run CMD. | ||
- **Builtin: dogeboxd / DKM (doge key manager) running** | ||
- *Setup Dogebox & configure password / master keys* | ||
- *Install a 'test-pup' and stop/start it* | ||
|
||
### 'install-iso / iso' for optical media images | ||
Generates a bootable iso, 'install-iso' will give you an installer, 'iso' will be a live CD. | ||
|
||
### 'lxc / lxc-metadata, proxmox-lxc' for linux containers | ||
Use 'lxc' and 'lxc-metadata' for a manual container, or load the file generated by 'proxmox-lxc' as a CT template to generate a container in proxmox. | ||
### Functionality end of week: | ||
|
||
### 'qcow' for qemu qcow2 | ||
Can be used as a disk image for qemu. | ||
- **Builtin: Dogenet running** (Dogebox meta-gossip-protocol service for node communication) | ||
- **Builtin: Internal Pup API Router** (Pups talking to eachother) | ||
- *SPV node pup available* | ||
- *Core node pup available* | ||
- *GigaWallet pup avaialble* | ||
|
||
### 'vmware' for VMWare and VirtualBox | ||
Generates a VMDK file that can be used by VMware or VirtualBox VMs directly | ||
### Functionality remaining (end Sept): | ||
|
||
If you'd prefer a VDI, you can convert with 'VBoxManage clonehd --format VDI <from>.vmdk <to>.vdi' | ||
- *Network Map pup available* | ||
- *Identity pup available* | ||
- *dPanel: pup realtime logging* | ||
- *dPanel: resolve API deps when installing pups* | ||
- **ARM builds available** | ||
|
||
Generating a VDI out of the box with '-f virtualbox' doesn't appear to be working currently with the default config. | ||
</div> | ||
|
||
## Getting It | ||
|
||
Builds are available on our [Github Releases](https://github.com/dogeorg/dogebox/releases) page. | ||
|
||
> [!NOTE] | ||
> All releases currently have hardcoded credentials until we work on SSH management. These are `shibe:suchpass` | ||
## Running It | ||
|
||
Currently, only "virtual machine" images are being released. We plan to release ARM (`aarch64`) and `x86_64` compatible hardware images over the next couple of weeks. | ||
|
||
See details below for specific setups: | ||
|
||
<details> | ||
<summary>Running in QEMU</summary> | ||
|
||
1. First, grab the latest QEMU release. | ||
|
||
2. Launch the image with the following command: | ||
|
||
```bash | ||
qemu-system-x86_64 \ | ||
-drive file=dogebox.qcow2,format=qcow2 \ | ||
-m 4G \ | ||
-smp 2 \ | ||
-nographic \ | ||
-netdev user,id=net0,hostfwd=tcp::2222-:22 \ | ||
-device virtio-net,netdev=net0 | ||
``` | ||
|
||
</details> | ||
|
||
<details> | ||
<summary>Running in VMWare</summary> | ||
|
||
TODO :) | ||
|
||
</details> | ||
|
||
<details> | ||
<summary>Running in Virtualbox</summary> | ||
|
||
1. Install Virtualbox :) | ||
2. Run `make virtualbox-launch` | ||
|
||
</details> | ||
|
||
<details> | ||
<summary>Running on Proxmox</summary> | ||
|
||
TODO :) | ||
|
||
</details> | ||
|
||
## Issues | ||
|
||
If you're struggling to get something working, please open a github issue with a description of the problem. | ||
|
||
## Contributing | ||
|
||
If you want to contribute, please check the current [roadmap](https://docs.google.com/spreadsheets/d/1FfJ_c-PjJdzkTAB3QFmDd2PRadrtNgvOhuDJTBEeOWU/view?gid=759122314#gid=759122314), and join our [discord server](https://discord.gg/VEUMWpThg9) to start chatting with other developers. |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# Building Dogebox | ||
|
||
## SD and SD installer images | ||
|
||
These are built with FriendlyElec's sd-fuse_rk3588. Documentation TBA. | ||
|
||
## Container/VM images | ||
|
||
Quick notes on building a container or VM image from a configuration.nix file: | ||
|
||
- Make sure the configuration.nix doesn't mention a bootloader, an appropriate one is included automatically and one defined here can conflict. | ||
|
||
- Install `nixos-generators`, if you have the nix package manager or are running NixOS you can just run 'nix-shell -p nixos-generators' | ||
|
||
- Build the desired image with `nixos-generate -c configuration.nix -f $format` | ||
|
||
Tested image formats include: `docker`, `install-iso`, `iso`, `lxc`, `lxc-metadata`, `proxmox-lxc`, `qcow`, `vmware` | ||
|
||
- The build output should tell you the name and location of the built image. | ||
|
||
### 'docker' for docker/podman | ||
|
||
Use `docker import` or 'podman import' to generate a container image. You will need to manually specify a run CMD. | ||
|
||
### 'install-iso / iso' for optical media images | ||
|
||
Generates a bootable iso, `install-iso` will give you an installer, `iso` will be a live CD. | ||
|
||
### 'lxc / lxc-metadata, proxmox-lxc' for linux containers | ||
|
||
Use `lxc` and `lxc-metadata` for a manual container, or load the file generated by `proxmox-lxc` as a CT template to generate a container in proxmox. | ||
|
||
### 'qcow' for qemu qcow2 | ||
|
||
Can be used as a disk image for qemu. | ||
|
||
### 'vmware' for VMWare and VirtualBox | ||
|
||
Generates a VMDK file that can be used by VMware or VirtualBox VMs directly | ||
|
||
If you'd prefer a VDI, you can convert with `VBoxManage clonehd --format VDI <from>.vmdk <to>.vdi` | ||
|
||
Generating a VDI out of the box with `-f virtualbox` doesn't appear to be working currently with the default config. |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# Edit this configuration file to define what should be installed on | ||
# your system. Help is available in the configuration.nix(5) man page, on | ||
# https://search.nixos.org/options and in the NixOS manual (`nixos-help`). | ||
|
||
{ lib, pkgs, ... }: | ||
|
||
{ | ||
imports = [ ./dogebox.nix ]; | ||
|
||
nix.settings = { | ||
#allowed-users = [ "*" ]; | ||
auto-optimise-store = false; | ||
# builders = | ||
#cores = 0; | ||
experimental-features = [ "nix-command" "flakes" ]; | ||
#extra-sandbox-paths = | ||
##max-jobs = auto; | ||
require-sigs = true; | ||
sandbox = true; | ||
sandbox-fallback = false; | ||
substituters = [ "https://cache.nixos.org/" ]; | ||
system-features = [ "nixos-test" "benchmark" "big-parallel" "kvm" ]; | ||
trusted-public-keys = [ "cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=" ]; | ||
#trusted-substituters = | ||
trusted-users = [ "root" "nixos" ]; | ||
}; | ||
|
||
# Set your time zone. | ||
time.timeZone = "Australia/Brisbane"; | ||
|
||
environment.systemPackages = with pkgs; [ | ||
# Install a few utility packages | ||
git | ||
vim | ||
wget | ||
]; | ||
|
||
# DO NOT CHANGE THIS. EVER. EVEN WHEN UPDATING YOUR SYSTEM PAST 24.05. | ||
system.stateVersion = "24.05"; | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
Oops, something went wrong.