summaryrefslogtreecommitdiffstats
path: root/meta-agl-flutter/tools/configs/agl-qemu-master.json
blob: eba953f7d244ddb923d631ab183b31d9fee1c3c1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24

@media only all and (prefers-color-scheme: dark) {
.highlight .hll { background-color: #49483e }
.highlight .c { color: #75715e } /* Comment */
.highlight .err { color: #960050; background-color: #1e0010 } /* Error */
.highlight .k { color: #66d9ef } /* Keyword */
.highlight .l { color: #ae81ff } /* Literal */
.highlight .n { color: #f8f8f2 } /* Name */
.highlight .o { color: #f92672 } /* Operator */
.highlight .p { color: #f8f8f2 } /* Punctuation */
.highlight .ch { color: #75715e } /* Comment.Hashbang */
.highlight .cm { color: #75715e } /* Comment.Multiline */
.highlight .cp { color: #75715e } /* Comment.Preproc */
.highlight .cpf { color: #75715e } /* Comment.PreprocFile */
.highlight .c1 { color: #75715e } /* Comment.Single */
.highlight .cs { color: #75715e } /* Comment.Special */
.highlight .gd { color: #f92672 } /* Generic.Deleted */
.highlight .ge { font-style: italic } /* Generic.Emph */
.highlight .gi { color: #a6e22e } /* Generic.Inserted */
.highlight .gs { font-weight: bold } /* Generic.Strong */
.highlight .gu { color: #75715e } /* Generic.Subheading */
.highlight .kc { color: #66d9ef } /* Keyword.Constant */
.highlight .kd { color: #66d9ef } /* Keyword.Declaration */
.highlight .kn { color: #f92672 } /* Keyword.Namespace */
.highlight .kp { color: #66d9ef } /* Keyword.Pseudo */
.highlight .kr { color: #66d9ef } /* Keyword.Reserved */
.highlight .kt { color: #66d9ef } /* Keyword.Type */
.highlight .ld { color: #e6db74 } /* Literal.Date */
.highlight .m { color: #ae81ff } /* Literal.Number */
.highlight .s { color: #e6db74 } /* Literal.String */
.highlight .na { color: #a6e22e } /* Name.Attribute */
.highlight .nb { color: #f8f8f2 } /* Name.Builtin */
.highlight .nc { color: #a6e22e } /* Name.Class */
.highlight .no { color: #66d9ef } /* Name.Constant */
.highlight .nd { color: #a6e22e } /* Name.Decorator */
.highlight .ni { color: #f8f8f2 } /* Name.Entity */
.highlight .ne { color: #a6e22e } /* Name.Exception */
.highlight .nf { color: #a6e22e } /* Name.Function */
.highlight .nl { color: #f8f8f2 } /* Name.Label */
.highlight .nn { color: #f8f8f2 } /* Name.Namespace */
.highlight .nx { color: #a6e22e } /* Name.Other */
.highlight .py { color: #f8f8f2 } /* Name.Property */
.highlight .nt { color: #f92672 } /* Name.Tag */
.highlight .nv { color: #f8f8f2 } /* Name.Variable */
.highlight .ow { color: #f92672 } /* Operator.Word */
.highlight .w { color: #f8f8f2 } /* Text.Whitespace */
.highlight .mb { color: #ae81ff } /* Literal.Number.Bin */
.highlight .mf { color: #ae81ff } /* Literal.Number.Float */
.highlight .mh { color: #ae81ff } /* Literal.Number.Hex */
.highlight .mi { color: #ae81ff } /* Literal.Number.Integer */
.highlight .mo { color: #ae81ff } /* Literal.Number.Oct */
.highlight .sa { color: #e6db74 } /* Literal.String.Affix */
.highlight .sb { color: #e6db74 } /* Literal.String.Backtick */
{
    "id": "agl-qemu-master",
    "load": true,
    "supported_archs": [
        "x86_64",
        "arm64"
    ],
    "supported_host_types": [
        "darwin",
        "ubuntu",
        "fedora"
    ],
    "flutter_runtime": "debug",
    "type": "qemu",
    "env": {
        "RELEASE_NAME": "master",
        "RELEASE_VERSION": "latest",
        "FLUTTER_DEBUG_PORT": "1234",
        "FLUTTER_OBSERVATORY_HOST": "0.0.0.0",
        "CONTAINER_SSH_PORT": "2222",
        "DEVICE_HOSTNAME": "localhost",
        "FLUTTER_AUTO_EXE": "flutter-auto --j=/tmp/${appName}/default_config.json --b=/tmp/${appName}",
        "PING_CMD": "(echo >/dev/tcp/localhost/${CONTAINER_SSH_PORT}) &>/dev/null && echo open || echo closed",
        "DELETE_USER_PWD": "ssh -p ${CONTAINER_SSH_PORT} -t -oBatchMode=yes root@${DEVICE_HOSTNAME} passwd -d agl-driver",
        "CREATE_BUNDLE_FOLDER": "ssh -p ${CONTAINER_SSH_PORT} -o BatchMode=yes agl-driver@${DEVICE_HOSTNAME} mkdir -p /tmp/${appName}/data",
        "COPY_PLATFORM_ID_TO_DEVICE": "scp -P ${CONTAINER_SSH_PORT} -r ${PLATFORM_ID_DIR}/default_config.json agl-driver@${DEVICE_HOSTNAME}:/tmp/${appName}/",
        "COPY_ASSETS_TO_DEVICE": "scp -P ${CONTAINER_SSH_PORT} -r ${localPath}/* agl-driver@${DEVICE_HOSTNAME}:/tmp/${appName}/data/flutter_assets",
        "DELETE_APP_FOLDER": "ssh -p ${CONTAINER_SSH_PORT} -o BatchMode=yes agl-driver@${DEVICE_HOSTNAME} rm -rf /tmp/${appName}"
    },
    "runtime": {
        "config": {
            "view": [
                {
                    "window_type": "BG",
                    "width": 1920,
                    "height": 1080
                }
            ]
        },
        "pre-requisites": {
            "arm64": {
                "darwin": {
                    "cmds": [
                        "bash -c \"arch -arm64 brew install xz\"",
                        "bash -c \"arch -arm64 brew install qemu\""
                    ]
                }
            }
        },
        "artifacts": {
            "http": {
                "url": "https://download.automotivelinux.org/AGL/snapshots/${RELEASE_NAME}/${RELEASE_VERSION}",
                "artifacts": {
                    "x86_64": [
                        {
                            "endpoint": "/qemux86-64/deploy/images/qemux86-64/agl-ivi-demo-platform-flutter-qemux86-64.wic.vmdk.xz"
                        }
                    ],
                    "arm64": [
                        {
                            "endpoint": "/qemuarm64/deploy/images/qemuarm64/agl-demo-platform-crosssdk-qemuarm64.ext4.xz"
                        },
                        {
                            "endpoint": "/qemuarm64/deploy/images/qemuarm64/Image-qemuarm64.bin"
                        }
                    ]
                }
            }
        },
        "qemu": {
            "cmd": "qemu-system-${FORMAL_MACHINE_ARCH}",
            "x86_64": {
                "image": "agl-ivi-demo-platform-flutter-qemux86-64.wic.vmdk",
                "args": "-m 2048 ${QEMU_EXTRA} -hda ${QEMU_IMAGE} -cpu kvm64 -cpu qemu64,+ssse3,+sse4.1,+sse4.2,+popcnt -vga virtio -device virtio-rng-pci -serial mon:stdio -serial null -device intel-hda -device hda-duplex -device virtio-net-pci,netdev=net0,mac=${RANDOM_MAC} -netdev user,id=net0,hostfwd=tcp::${CONTAINER_SSH_PORT}-:22,hostfwd=tcp::${FLUTTER_DEBUG_PORT}-:${FLUTTER_DEBUG_PORT}"
            },
            "arm64": {
                "kernel": "Image-qemuarm64.bin",
                "image": "agl-demo-platform-crosssdk-qemuarm64.ext4",
                "args": "-accel hvf -cpu host -M virt ${QEMU_EXTRA} -m 4096 -device virtio-gpu-pci -nographic -display cocoa,show-cursor=on -object rng-random,filename=/dev/urandom,id=rng0 -device virtio-rng-pci,rng=rng0 -device qemu-xhci -device usb-tablet -device usb-mouse -device usb-kbd -device virtio-net-pci,netdev=vnet -netdev user,id=vnet,hostfwd=tcp::${CONTAINER_SSH_PORT}-:22,hostfwd=tcp::${FLUTTER_DEBUG_PORT}-:${FLUTTER_DEBUG_PORT} -kernel ${QEMU_KERNEL} -drive file=${QEMU_IMAGE},format=raw,if=virtio -append root=/dev/vda"
            },
            "extra": {
                "darwin": "-smp cpus=8,sockets=1,cores=8,threads=1",
                "ubuntu": "-bios OVMF.fd",
                "fedora": "-bios /usr/share/edk2/ovmf/OVMF_CODE.fd"
            }
        },
        "post_cmds": [
            {
                "cwd": "${PLATFORM_ID_DIR}",
                "cmds": [
                    "bash -c \"rm ${QEMU_IMAGE}|true\"",
                    "unxz --keep ${QEMU_IMAGE}.xz"
                ]
            }
        ]
    },
    "overwrite-existing": true,
    "custom-device": {
        "id": "agl-qemu-${RELEASE_NAME}",
        "label": "AGL ${RELEASE_NAME}-${RELEASE_VERSION} QEMU Image",
        "sdkNameAndVersion": "qemu-${RELEASE_NAME} ${RELEASE_VERSION}",
        "platform": "linux-x64",
        "enabled": true,
        "ping": "bash -c \"${PING_CMD}\"",
        "pingSuccessRegex": "open",
        "postBuild": "bash -c \"${DELETE_USER_PWD}\"",
        "install": "bash -c \"${CREATE_BUNDLE_FOLDER} && ${COPY_PLATFORM_ID_TO_DEVICE} && ${COPY_ASSETS_TO_DEVICE}\"",
        "uninstall": "bash -c \"${DELETE_APP_FOLDER}\"",
        "runDebug": "bash -c \"ssh -t -t -o BatchMode=yes agl-driver@${DEVICE_HOSTNAME} ${FLUTTER_AUTO_EXE}\"",
        "forwardPort": null,
        "forwardPortSuccessRegex": null,
        "screenshot": null
    }
}