This commit is contained in:
2024-08-06 17:33:59 +02:00
parent 6e1f478ce5
commit da14091106
81 changed files with 549 additions and 185 deletions

View File

@@ -79,7 +79,7 @@ dl := gridtypes.Deployment{
network(), // network workload definition
zmount(), // zmount workload definition
publicip(), // public ip definition
zmachine(), // zmachine definition
zero_vm(), // zero_vm definition
},
SignatureRequirement: gridtypes.SignatureRequirement{
WeightRequired: 1,
@@ -168,7 +168,7 @@ type Workload struct {
- [`network`](./workload_types.md#network-type)
- [`ip`](./workload_types.md#ip-type)
- [`zmount`](./workload_types.md#zmount-type)
- [`zmachine`](./workload_types.md#zmachine-type)
- [`zero_vm`](./workload_types.md#zero_vm-type)
- [`zlogs`](./workload_types.md#zlogs-type)
- Storage related
- [`zdb`](./workload_types.md#zdb-type)

View File

@@ -7,7 +7,7 @@
- [`network` type](#network-type)
- [`ip` type](#ip-type)
- [`zmount` type](#zmount-type)
- [`zmachine` type](#zmachine-type)
- [`zero_vm` type](#zero_vm-type)
- [Building your `flist`](#building-your-flist)
- [`zlogs` type](#zlogs-type)
- [Storage](#storage)
@@ -51,30 +51,30 @@ In minimal form, `IP` workload does not require any data. But in reality it has
Full `IP` workload definition can be found [here](https://github.com/threefoldtech/zos/blob/main/pkg/gridtypes/zos/ipv4.go)
### `zmount` type
A `zmount` is a local disk that can be attached directly to a container or a virtual machine. `zmount` only require `size` as input as defined [here](https://github.com/threefoldtech/zos/blob/main/pkg/gridtypes/zos/zmount.go) this workload type is only utilized via the `zmachine` workload.
A `zmount` is a local disk that can be attached directly to a container or a virtual machine. `zmount` only require `size` as input as defined [here](https://github.com/threefoldtech/zos/blob/main/pkg/gridtypes/zos/zmount.go) this workload type is only utilized via the `zero_vm` workload.
### `zmachine` type
### `zero_vm` type
`zmachine` is a unified container/virtual machine type. This can be used to start a virtual machine on a `zos` node give the following:
`zero_vm` is a unified container/virtual machine type. This can be used to start a virtual machine on a `zos` node give the following:
- `flist`, this what provide the base `vm` image or container image.
- the `flist` content is what changes the `zmachine` mode. An `flist` built from a docker image or has files, or executable binaries will run in a container mode. `ZOS` will inject it's own `kernel+initramfs` to run the workload and kick start the defined `flist` `entrypoint`
- the `flist` content is what changes the `zero_vm` mode. An `flist` built from a docker image or has files, or executable binaries will run in a container mode. `ZOS` will inject it's own `kernel+initramfs` to run the workload and kick start the defined `flist` `entrypoint`
- private network to join (with assigned IP)
- optional public `ipv4` or `ipv6`
- optional disks. But at least one disk is required in case running `zmachine` in `vm` mode, which is used to hold the `vm` root image.
- optional disks. But at least one disk is required in case running `zero_vm` in `vm` mode, which is used to hold the `vm` root image.
For more details on all parameters needed to run a `zmachine` please refer to [`zmachine` data](https://github.com/threefoldtech/zos/blob/main/pkg/gridtypes/zos/zmachine.go)
For more details on all parameters needed to run a `zero_vm` please refer to [`zero_vm` data](https://github.com/threefoldtech/zos/blob/main/pkg/gridtypes/zos/zero_vm.go)
#### Building your `flist`
Please refer to [this document](manual.md) here about how to build an compatible `zmachine flist`
Please refer to [this document](manual.md) here about how to build an compatible `zero_vm flist`
### `zlogs` type
Zlogs is a utility workload that allows you to stream `zmachine` logs to a remote location.
Zlogs is a utility workload that allows you to stream `zero_vm` logs to a remote location.
The `zlogs` workload needs to know what `zmachine` to stream logs of and also the `target` location to stream the logs to. `zlogs` uses internally the [`tailstream`](https://github.com/threefoldtech/tailstream) so it supports any streaming url that is supported by this utility.
The `zlogs` workload needs to know what `zero_vm` to stream logs of and also the `target` location to stream the logs to. `zlogs` uses internally the [`tailstream`](https://github.com/threefoldtech/tailstream) so it supports any streaming url that is supported by this utility.
`zlogs` workload runs inside the same private network as the `zmachine` instance. Which means zlogs can stream logs to other `zmachines` that is running inside the same private network (possibly on different nodes).
`zlogs` workload runs inside the same private network as the `zero_vm` instance. Which means zlogs can stream logs to other `zero_vms` that is running inside the same private network (possibly on different nodes).
For example, you can run [`logagg`](https://github.com/threefoldtech/logagg) which is a web-socket server that can work with `tailstream` web-socket protocol.

View File

@@ -1,10 +1,10 @@
# `zlogs` type
Zlogs is a utility workload that allows you to stream `zmachine` logs to a remote location.
Zlogs is a utility workload that allows you to stream `zero_vm` logs to a remote location.
The `zlogs` workload needs to know what `zmachine` to stream logs of and also the `target` location to stream the logs to. `zlogs` uses internally the [`tailstream`](https://github.com/threefoldtech/tailstream) so it supports any streaming url that is supported by this utility.
The `zlogs` workload needs to know what `zero_vm` to stream logs of and also the `target` location to stream the logs to. `zlogs` uses internally the [`tailstream`](https://github.com/threefoldtech/tailstream) so it supports any streaming url that is supported by this utility.
`zlogs` workload runs inside the same private network as the `zmachine` instance. Which means zlogs can stream logs to other `zmachines` that is running inside the same private network (possibly on different nodes).
`zlogs` workload runs inside the same private network as the `zero_vm` instance. Which means zlogs can stream logs to other `zero_vms` that is running inside the same private network (possibly on different nodes).
For example, you can run [`logagg`](https://github.com/threefoldtech/logagg) which is a web-socket server that can work with `tailstream` web-socket protocol.

View File

@@ -1,13 +1,13 @@
# `zmachine` type
# `zero_vm` type
`zmachine` is a unified container/virtual machine type. This can be used to start a virtual machine on a `zos` node give the following:
`zero_vm` is a unified container/virtual machine type. This can be used to start a virtual machine on a `zos` node give the following:
- `flist`, this what provide the base `vm` image or container image.
- the `flist` content is what changes the `zmachine` mode. An `flist` built from a docker image or has files, or executable binaries will run in a container mode. `ZOS` will inject it's own `kernel+initramfs` to run the workload and kick start the defined `flist` `entrypoint`
- the `flist` content is what changes the `zero_vm` mode. An `flist` built from a docker image or has files, or executable binaries will run in a container mode. `ZOS` will inject it's own `kernel+initramfs` to run the workload and kick start the defined `flist` `entrypoint`
- private network to join (with assigned IP)
- optional public `ipv4` or `ipv6`
- optional disks. But at least one disk is required in case running `zmachine` in `vm` mode, which is used to hold the `vm` root image.
- optional disks. But at least one disk is required in case running `zero_vm` in `vm` mode, which is used to hold the `vm` root image.
For more details on all parameters needed to run a `zmachine` please refer to [`zmachine` data](https://github.com/threefoldtech/zos/blob/main/pkg/gridtypes/zos/zmachine.go)
For more details on all parameters needed to run a `zero_vm` please refer to [`zero_vm` data](https://github.com/threefoldtech/zos/blob/main/pkg/gridtypes/zos/zero_vm.go)
# Building your `flist`.
Please refer to [this document](manual.md) here about how to build an compatible `zmachine flist`
Please refer to [this document](manual.md) here about how to build an compatible `zero_vm flist`

View File

@@ -1,2 +1,2 @@
# `zmount` type
A `zmount` is a local disk that can be attached directly to a container or a virtual machine. `zmount` only require `size` as input as defined [here](https://github.com/threefoldtech/zos/blob/main/pkg/gridtypes/zos/zmount.go) this workload type is only utilized via the `zmachine` workload.
A `zmount` is a local disk that can be attached directly to a container or a virtual machine. `zmount` only require `size` as input as defined [here](https://github.com/threefoldtech/zos/blob/main/pkg/gridtypes/zos/zmount.go) this workload type is only utilized via the `zero_vm` workload.