mirror of
https://github.com/linuxkit/linuxkit.git
synced 2025-07-21 10:09:07 +00:00
sdk: add a yml example on how to use fdd to create container channels
Lots of boilerplate for now on, will work on upstreaming that in the tool properly if needed later. Signed-off-by: Thomas Gazagnaire <thomas@gazagnaire.org>
This commit is contained in:
parent
736713dc8f
commit
b4feb71f78
37
projects/miragesdk/examples/fdd.yml
Normal file
37
projects/miragesdk/examples/fdd.yml
Normal file
@ -0,0 +1,37 @@
|
||||
kernel:
|
||||
image: "linuxkit/kernel:4.9.34"
|
||||
cmdline: "console=ttyS0 page_poison=1"
|
||||
init:
|
||||
- linuxkit/init:36c56f0664d49c5a6adc1120d1bf5ba6ac30b389
|
||||
- linuxkit/runc:291131ec026430371e7c36165c3f43734fbc2541
|
||||
- linuxkit/containerd:1e3e8f207421de8deac8cedc26a138d6b1661a0d
|
||||
- linuxkit/ca-certificates:46b59484919bfa9af700e54e042048cb06261de4
|
||||
- samoht/fdd
|
||||
onboot:
|
||||
- name: sysctl
|
||||
image: "linuxkit/sysctl:3aa6bc663c2849ef239be7d941d3eaf3e6fcc018"
|
||||
services:
|
||||
- name: getty
|
||||
image: "linuxkit/getty:6cbeee0392b0670053ce2bf05a5a0d67ec2bce05"
|
||||
env:
|
||||
- INSECURE=true
|
||||
- name: rngd
|
||||
image: "linuxkit/rngd:b50b22dd574c5377708977af769f053009fff6d5"
|
||||
- name: dhcpcd
|
||||
image: "linuxkit/dhcpcd:6c1ca76dbf808d5c27d10cbf22a8d4399be5c8ae"
|
||||
files:
|
||||
- path: etc/init.d/020-fdd-init
|
||||
mode: "0700"
|
||||
contents: |
|
||||
#!/bin/sh
|
||||
/bin/fdd init -vv -s /run/fdd.sock
|
||||
- path: etc/init.d/030-fdd-share
|
||||
mode: "0700"
|
||||
contents: |
|
||||
#!/bin/sh
|
||||
/bin/fdd share -vv -s /run/fdd.sock /tmp/channel-net-eng &&
|
||||
/bin/fdd share -vv -s /run/fdd.sock /tmp/channel-conf-net &&
|
||||
/bin/fdd share -vv -s /run/fdd.sock /tmp/channel-conf-act
|
||||
trust:
|
||||
org:
|
||||
- linuxkit
|
@ -3,10 +3,10 @@ RUN sudo apk add m4
|
||||
RUN opam install jbuilder lwt fd-send-recv logs fmt cmdliner
|
||||
ADD . /src
|
||||
RUN opam pin add fdd /src
|
||||
RUN sudo mkdir /out
|
||||
RUN sudo cp /home/opam/.opam/4.04.2/bin/fdd /out
|
||||
RUN sudo mkdir -p /out/bin
|
||||
RUN sudo cp /home/opam/.opam/4.04.2/bin/fdd /out/bin
|
||||
|
||||
FROM scratch
|
||||
COPY --from=base /out/fdd .
|
||||
COPY --from=base /out .
|
||||
USER 0
|
||||
ENTRYPOINT ["/fdd"]
|
||||
|
@ -5,3 +5,10 @@ all:
|
||||
|
||||
clean:
|
||||
jbuilder clean
|
||||
|
||||
### FIXME: use Makefile template
|
||||
|
||||
IMAGE=samoht/fdd
|
||||
|
||||
tag:
|
||||
docker build -t $(IMAGE) . && docker push $(IMAGE)
|
||||
|
Loading…
Reference in New Issue
Block a user