Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error for running on k8s windows node #1651

Open
kennyd3d opened this issue Feb 18, 2025 · 0 comments
Open

Error for running on k8s windows node #1651

kennyd3d opened this issue Feb 18, 2025 · 0 comments
Labels

Comments

@kennyd3d
Copy link

What happened?
Ran devpods on a windows k8s AKS cluster with devpods up <source> --ide vscode --debug. There appears to be a error pulling a python container dependency. I am running this on apple silicon.

r: code = NotFound desc = failed to pull and unpack image "mcr.microsoft.com/devcontainers/python:3": no match for platform in manifest: not found (ErrImagePull)

What did you expect to happen instead?
Devpods opens up with project in k8s windows pod.

How can we reproduce the bug? (as minimally and precisely as possible)
Set up a windows cluster, specify config in provider, spin up project.

My devcontainer.json:

{
  "name": "aks",
  "version": "v0.1.19",
  "icon": "https://devpod.sh/assets/kubernetes.svg",
  "home": "https://github.com/loft-sh/devpod",
  "source": {
    "github": "loft-sh/devpod-provider-kubernetes",
    "raw": "kubernetes"
  },
  "description": "DevPod on Kubernetes",
  "optionGroups": [
    {
      "name": "Options",
      "options": [
        "KUBERNETES_NAMESPACE",
        "DISK_SIZE"
      ],
      "defaultVisible": true
    },
    {
      "name": "Kubernetes Config",
      "options": [
        "KUBERNETES_CONTEXT",
        "KUBERNETES_CONFIG"
      ]
    },
    {
      "name": "Advanced Options",
      "options": [
        "CLUSTER_ROLE",
        "SERVICE_ACCOUNT",
        "CREATE_NAMESPACE",
        "KUBECTL_PATH",
        "INACTIVITY_TIMEOUT",
        "STORAGE_CLASS",
        "PVC_ACCESS_MODE",
        "PVC_ANNOTATIONS",
        "RESOURCES",
        "POD_MANIFEST_TEMPLATE",
        "ARCH_DETECTION_POD_MANIFEST_TEMPLATE",
        "NODE_SELECTOR",
        "HELPER_RESOURCES",
        "HELPER_IMAGE",
        "LABELS",
        "DOCKERLESS_DISABLED",
        "DOCKERLESS_IMAGE"
      ]
    }
  ],
  "options": {
    "ARCH_DETECTION_POD_MANIFEST_TEMPLATE": {
      "description": "Pod manifest template file path used as template to build the architecture detenction pod. E.g. /path/pod_manifest.yaml. Alternatively can be an inline yaml string.",
      "type": "multiline",
      "global": true
    },
    "CLUSTER_ROLE": {
      "description": "If defined, DevPod will create a role binding for the given cluster role.",
      "global": true
    },
    "CREATE_NAMESPACE": {
      "description": "If true, DevPod will try to create the namespace.",
      "type": "boolean",
      "global": true,
      "default": "true"
    },
    "DANGEROUSLY_OVERRIDE_IMAGE": {
      "description": "Only set this if you know what you're doing! Overrides the pod base image and could break your workspace.",
      "global": true
    },
    "DISK_SIZE": {
      "description": "The default size for the persistent volume to use.",
      "global": true,
      "default": "10Gi"
    },
    "DOCKERLESS_DISABLED": {
      "description": "If dockerless should be disabled. Dockerless is the way DevPod uses to build images directly within Kubernetes. If dockerless is disabled and no image is specified, DevPod will fail instead.",
      "global": true,
      "default": "false"
    },
    "DOCKERLESS_IMAGE": {
      "description": "The dockerless image to use.",
      "global": true
    },
    "HELPER_IMAGE": {
      "description": "The image DevPod will use to find out the cluster architecture. Defaults to alpine.",
      "global": true
    },
    "HELPER_RESOURCES": {
      "description": "The resources to use for the workspace init container. E.g. requests.cpu=100m,limits.memory=1Gi",
      "global": true
    },
    "INACTIVITY_TIMEOUT": {
      "description": "If defined, will automatically stop the pod after the inactivity period. Examples: 10m, 1h"
    },
    "KUBECTL_PATH": {
      "description": "The path where to find the kubectl binary.",
      "global": true,
      "default": "kubectl"
    },
    "KUBERNETES_CONFIG": {
      "description": "The kubernetes config to use. E.g. /path/to/my/kube/config.yaml"
    },
    "KUBERNETES_CONTEXT": {
      "description": "The kubernetes context to use. E.g. my-kube-context"
    },
    "KUBERNETES_NAMESPACE": {
      "description": "The kubernetes namespace to use",
      "command": "NAMESPACE=$(${KUBECTL_PATH} config view --kubeconfig=${KUBERNETES_CONFIG} --context=${KUBERNETES_CONTEXT} --minify -o jsonpath='{..namespace}' 2>/dev/null || true)\nif [ -z \"${NAMESPACE}\" ]; then\n  NAMESPACE=devpod\nfi\necho $NAMESPACE"
    },
    "KUBERNETES_PULL_SECRETS_ENABLED": {
      "description": "If true, DevPod will try to use the pull secrets from the current context.",
      "type": "boolean",
      "global": true,
      "default": "true"
    },
    "LABELS": {
      "description": "The labels to use for the workspace pod. E.g. devpod.sh/example=value,devpod.sh/example2=value2",
      "global": true
    },
    "NODE_SELECTOR": {
      "description": "The node selector to use for the workspace pod. E.g. my-label=value,my-label-2=value-2",
      "global": true
    },
    "POD_MANIFEST_TEMPLATE": {
      "description": "Pod manifest template file path used as template to build the devpod pod. E.g. /path/pod_manifest.yaml. Alternatively can be an inline yaml string.",
      "type": "multiline",
      "global": true
    },
    "POD_TIMEOUT": {
      "description": "Determines how long the provider waits for the workspace pod to come up. Examples: 10m, 1h",
      "default": "10m"
    },
    "PVC_ACCESS_MODE": {
      "description": "If defined, DevPod will use the given access mode to create the persistent volume claim. You will need to ensure the storage class support the given access mode!. E.g. RWO or ROX or RWX or RWOP",
      "global": true
    },
    "PVC_ANNOTATIONS": {
      "description": "If defined, DevPod will use add the given annotations to the main workspace pvc",
      "global": true
    },
    "RESOURCES": {
      "description": "The resources to use for the workspace container. E.g. requests.cpu=500m,limits.memory=5Gi,limits.gpu-vendor.example/example-gpu=1",
      "global": true
    },
    "SERVICE_ACCOUNT": {
      "description": "If defined, DevPod will use the given service account for the dev container.",
      "global": true
    },
    "STORAGE_CLASS": {
      "description": "If defined, DevPod will use the given storage class to create the persistent volume claim. You will need to ensure the storage class exists in your cluster!",
      "global": true
    },
    "STRICT_SECURITY": {
      "description": "EXPERIMENTAL! Use at your own risk. Removes the default security context and merges the one from POD_MANIFEST_TEMPLATE if specified.",
      "type": "boolean",
      "default": "false"
    },
    "WORKSPACE_VOLUME_MOUNT": {
      "description": "Sets the path of the workspace volume mount. By default it is the root of your workspace source code, usually /workspaces/$WORKSPACE_ID. If you intend to create multi-repo workspaces or need additional files throughout the lifecycle of the workspace, set this option to a parent directory of the workspace mount.",
      "type": "string"
    }
  },
  "agent": {
    "local": "true",
    "containerInactivityTimeout": "${INACTIVITY_TIMEOUT}",
    "exec": {},
    "binaries": {
      "KUBERNETES_PROVIDER": [
        {
          "os": "linux",
          "arch": "amd64",
          "checksum": "99cb3516bd77e0b0b1e360432556917edc374a89585f8aad3ccaa2a10f582ae4",
          "path": "https://github.com/loft-sh/devpod-provider-kubernetes/releases/download/v0.1.19/devpod-provider-kubernetes-linux-amd64"
        },
        {
          "os": "linux",
          "arch": "arm64",
          "checksum": "805f98946692f649fb9ecd18a0d26df157c712acb9f9a79d5c376c496029d032",
          "path": "https://github.com/loft-sh/devpod-provider-kubernetes/releases/download/v0.1.19/devpod-provider-kubernetes-linux-arm64"
        },
        {
          "os": "darwin",
          "arch": "amd64",
          "checksum": "1a85515db7aedf84f61f1f38a7ec16d3527f3db65e2d663bfa49b5dd1ce8fb6a",
          "path": "https://github.com/loft-sh/devpod-provider-kubernetes/releases/download/v0.1.19/devpod-provider-kubernetes-darwin-amd64"
        },
        {
          "os": "darwin",
          "arch": "arm64",
          "checksum": "21dfea983c88da858e0ce2b4dc681f6dc3b1cee427fee35df24bb95542516bb3",
          "path": "https://github.com/loft-sh/devpod-provider-kubernetes/releases/download/v0.1.19/devpod-provider-kubernetes-darwin-arm64"
        },
        {
          "os": "windows",
          "arch": "amd64",
          "checksum": "042a528d64f8ce449ae9b3cf6f85ae4bb8e603627857c7d479574a3e4cbc1ae0",
          "path": "https://github.com/loft-sh/devpod-provider-kubernetes/releases/download/v0.1.19/devpod-provider-kubernetes-windows-amd64.exe"
        }
      ]
    },
    "dockerless": {
      "disabled": "${DOCKERLESS_DISABLED}",
      "image": "${DOCKERLESS_IMAGE}"
    },
    "driver": "custom",
    "docker": {},
    "custom": {
      "findDevContainer": [
        "\"${KUBERNETES_PROVIDER}\" find"
      ],
      "commandDevContainer": [
        "\"${KUBERNETES_PROVIDER}\" command"
      ],
      "targetArchitecture": [
        "\"${KUBERNETES_PROVIDER}\" target-architecture"
      ],
      "runDevContainer": [
        "\"${KUBERNETES_PROVIDER}\" run"
      ],
      "startDevContainer": [
        "\"${KUBERNETES_PROVIDER}\" start"
      ],
      "stopDevContainer": [
        "\"${KUBERNETES_PROVIDER}\" stop"
      ],
      "deleteDevContainer": [
        "\"${KUBERNETES_PROVIDER}\" delete"
      ],
      "canReprovision": "true"
    }
  },
  "exec": {
    "command": [
      "\"${DEVPOD}\" helper sh -c \"${COMMAND}\""
    ]
  }
}

Local Environment:

  • DevPod Version: v0.6.12%
  • Operating System: mac
  • ARCH of the OS: ARM64

DevPod Provider:

  • Cloud Provider: azure via local kube config
  • Kubernetes Provider: 1.31.1
  • Local/remote provider: ssh
  • Custom provider: provide imported provider.yaml config file

Anything else we need to know?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant