openvpn router unikernel using caravan

This commit is contained in:
Hannes Mehnert 2021-05-04 23:05:34 +02:00
parent 15db88325b
commit dc1390c3b9
6 changed files with 135 additions and 12 deletions

View file

@ -0,0 +1,34 @@
opam-version: "2.0"
name: "provision"
maintainer: [ "Romain Calascibetta <romain.calascibetta@gmail.com>" ]
authors: [ "Romain Calascibetta <romain.calascibetta@gmail.com>" ]
homepage: "https://github.com/dinosaure/caravan"
bug-reports: "https://github.com/dinosaure/caravan/issues"
dev-repo: "git+https://github.com/dinosaure/caravan.git"
doc: "https://dinosaure.github.io/caravan/"
license: "MIT"
synopsis: "Section injection into ELF binary file"
description: """
Tool to inject new <.provision> section into given ELF binary file.
"""
build: [ ["dune" "subst"] {dev}
["dune" "build" "-p" name "-j" jobs ]
["dune" "runtest" "-p" name "-j" jobs] {with-test} ]
depends: [
"ocaml" {>= "4.07.0"}
"dune" {>= "1.9.2"}
"base-bytes"
"base-unix"
"bigstringaf"
"fmt"
"bos"
"logs"
"rresult"
"mmap"
"cmdliner"
]
url {
src: "git+https://github.com/hannesm/caravan.git#next"
}

View file

@ -1,8 +1,7 @@
# Generated by ./config.exe configure -t hvt --allocation-policy=best-fit (2021-01-18 16:29:37-00:00).
# Generated by ./config.exe configure -t hvt --allocation-policy=best-fit (2021-05-04 21:03:08-00:00).
opam-version: "2.0"
name: "mirage-unikernel-ovpn_router-hvt"
depends: [ "arp" { >= "2.3.0" & < "3.0.0"}
"crunch" {build & >= "3.1.0" & < "4.0.0"}
"ethernet" { >= "2.2.0" & < "3.0.0"}
"functoria-runtime"
"logs"
@ -12,9 +11,8 @@ depends: [ "arp" { >= "2.3.0" & < "3.0.0"}
"mirage-bootvar-solo5" { >= "0.6.0" & < "0.7.0"}
"mirage-clock-freestanding" { >= "3.0.0" & < "4.0.0"}
"mirage-console-solo5" { >= "0.6.1" & < "0.7.0"}
"mirage-crypto-rng-mirage" { >= "0.8.0" & < "0.9.0"}
"mirage-crypto-rng-mirage" { >= "0.8.0" & < "0.11.0"}
"mirage-kv"
"mirage-kv-mem" { >= "3.0.0" & < "4.0.0"}
"mirage-logs" { >= "1.2.0" & < "2.0.0"}
"mirage-net-solo5" { >= "0.6.1" & < "0.7.0"}
"mirage-runtime" { >= "3.10.0" & >= "3.8.0" & < "3.11.0"}
@ -26,8 +24,9 @@ depends: [ "arp" { >= "2.3.0" & < "3.0.0"}
"ocamlbuild" {build}
"ocamlfind" {build}
"openvpn"
"solo5-bindings-hvt" { >= "0.6.0" & < "0.7.0"}
"tcpip" { >= "6.0.0" & < "7.0.0"}
"provision"
"solo5-bindings-hvt" { = "0.6.8~caravan"}
"tcpip" { >= "6.1.0" & < "7.0.0"}
]
pin-depends: [ ["openvpn.dev" "git+https://github.com/roburio/openvpn.git"]
]
@ -36,7 +35,7 @@ authors: "dummy"
homepage: "dummy"
bug-reports: "dummy"
dev-repo: "git+https://example.com/nonexistent"
build: [ "sh" "-exc" "cd mirage-router && cp /root/openvpn.config configuration/ && mirage configure -t hvt --allocation-policy=best-fit && mirage build" ]
build: [ "sh" "-exc" "cd mirage-router && mirage configure -t hvt --allocation-policy=best-fit && mirage build" ]
synopsis: "This is a dummy"
install: [
[ "cp" "mirage-router/ovpn_router.hvt" "%{bin}%/ovpn_router.hvt" ]

View file

@ -9,7 +9,7 @@ maintainer: ["robur"]
license: "AGPL"
build: [
["dune" "subst" ] {pinned}
["dune" "subst" ] {dev}
["dune" "build" "-p" name "-j" jobs]
["dune" "runtest" "-p" name "-j" jobs] {with-test}
]
@ -38,9 +38,9 @@ depends: [
"mirage-crypto-rng" {>= "0.8.0"}
"ptime"
"rresult"
"tls" {>= "0.11.0"}
"dns-client" {>= "4.5.0"}
"x509" {>= "0.10.0"}
"tls" {>= "0.13.0"}
"dns-client" {>= "5.0.0"}
"x509" {>= "0.13.0"}
"duration"
"tuntap" {>= "1.8.1"}
@ -49,7 +49,7 @@ depends: [
"mtime"
"randomconv"
# mirage:
"mirage-stack" {>= "2.0.0"}
"mirage-stack" {>= "2.2.0"}
"mirage-protocols" {>= "5.0.0"}
"tcpip" {>= "4.1.0"}
"mirage-random" {>= "2.0.0"}

View file

@ -0,0 +1,36 @@
opam-version: "2.0"
name: "provision"
maintainer: [ "Romain Calascibetta <romain.calascibetta@gmail.com>" ]
authors: [ "Romain Calascibetta <romain.calascibetta@gmail.com>" ]
homepage: "https://github.com/dinosaure/caravan"
bug-reports: "https://github.com/dinosaure/caravan/issues"
dev-repo: "git+https://github.com/dinosaure/caravan.git"
doc: "https://dinosaure.github.io/caravan/"
license: "MIT"
synopsis: "Section injection into ELF binary file"
description: """
Tool to inject new <.provision> section into given ELF binary file.
"""
build: [ ["dune" "subst"] {dev}
["dune" "build" "-p" name "-j" jobs ]
["dune" "runtest" "-p" name "-j" jobs] {with-test} ]
depends: [
"ocaml" {>= "4.07.0"}
"dune" {>= "1.9.2"}
"base-bytes"
"bigstringaf"
"fmt"
]
depopts: [
"ocaml-freestanding"
]
conflicts: [
"ocaml-freestanding" {< "0.6.0"}
]
url {
src: "git+https://github.com/hannesm/caravan.git#next"
}

View file

@ -0,0 +1,54 @@
opam-version: "2.0"
maintainer: "martin@lucina.net"
authors: [
"Dan Williams <djwillia@us.ibm.com>"
"Martin Lucina <martin@lucina.net>"
"Ricardo Koller <kollerr@us.ibm.com>"
]
homepage: "https://github.com/solo5/solo5"
bug-reports: "https://github.com/solo5/solo5/issues"
license: "ISC"
dev-repo: "git+https://github.com/solo5/solo5.git"
build: [
["./configure.sh"]
[make "V=1" "CONFIG_SPT=" "CONFIG_VIRTIO=" "CONFIG_MUEN=" "CONFIG_GENODE=" "CONFIG_XEN="]
]
install: [make "V=1" "CONFIG_SPT=" "CONFIG_VIRTIO=" "CONFIG_MUEN=" "CONFIG_GENODE=" "CONFIG_XEN=" "install-opam-hvt" "PREFIX=%{prefix}%"]
depends: [
"conf-pkg-config"
"conf-libseccomp" {build & os = "linux"}
]
depexts: [
["linux-headers"] {os-distribution = "alpine"}
["kernel-headers"] {os-distribution = "fedora"}
["kernel-headers"] {os-distribution = "rhel"}
["linux-libc-dev"] {os-family = "debian"}
]
conflicts: [
"ocaml-freestanding" {< "0.6.0"}
"solo5-bindings-spt"
"solo5-bindings-virtio"
"solo5-bindings-muen"
"solo5-bindings-genode"
"solo5-bindings-xen"
]
available: [
(arch = "x86_64" | arch = "arm64") &
(os = "linux" | os = "freebsd" | os = "openbsd")
]
synopsis: "Solo5 sandboxed execution environment (hvt target)"
description: """
Solo5 is a sandboxed execution environment primarily intended
for, but not limited to, running applications built using various
unikernels (a.k.a. library operating systems).
This package provides the Solo5 components needed to build and
run MirageOS unikernels on the "hvt" target, including the
"solo5-hvt" tender source code, and "solo5-hvt-configure" script
used to specialize the tender at MirageOS unikernel build time.
The "hvt" target is supported on 64-bit Linux, FreeBSD and
OpenBSD systems with hardware virtualization."""
url {
src: "git+https://github.com/hannesm/solo5.git#0.6.8-caravan"
}