tilt icon indicating copy to clipboard operation
tilt copied to clipboard

exec user process caused: exec format error

Open tekumara opened this issue 3 years ago • 4 comments

Expected Behavior

Automatically detect my cluster's arch and build the correct image for it.

Current Behavior

          api │ Attaching to existing pod (api-76dfc675cd-7zlcm). Only new logs will be streamed.
          api │ WARNING: Detected container restart. Pod: api-76dfc675cd-7zlcm. Container: deployer.
          api │ standard_init_linux.go:228: exec user process caused: exec format error

Steps to Reproduce

  1. Run tilt up on a mac m1 arm64 against an amd64 cluster

Context

tilt doctor Output

$ tilt doctor
Tilt: v0.30.7, built 2022-08-12
System: darwin-arm64
---
Docker
- Host: unix:///var/run/docker.sock
- Server Version: 20.10.17
- API Version: 1.41
- Builder: 2
- Compose Version: v2.6.1
---
Kubernetes
- Env: unknown
- Context: myorg
- Cluster Name: myorg.com
- Namespace: prefect-tools
- Container Runtime: read-failure
- Version: v1.20.15-eks-84b4fe6
- Cluster Local Registry: none
---

About Your Use Case

For some reason tilt is building the arm64 image rather than detecting my cluster arch and building an amd64 image.

tekumara avatar Aug 16 '22 12:08 tekumara

For now I'm using docker_build( ..., platform='linux/amd64') and it works!

tekumara avatar Aug 16 '22 12:08 tekumara

The Container Runtime: read-failure is suspicious. That usually means that your cluster admin is denying you permission to read info about the cluster nodes (which includes both container runtime and processor arch).

Can you run tilt get clusters -o yaml against a running tilt session and post the output?

nicks avatar Aug 16 '22 19:08 nicks

But yeah, setting the platform manually is the best workaround if your admin is denying permission to read the arch off the cluster.

nicks avatar Aug 16 '22 19:08 nicks

Sure!

$ tilt get clusters -o yaml
apiVersion: v1
items:
- apiVersion: tilt.dev/v1alpha1
  kind: Cluster
  metadata:
    annotations:
      tilt.dev/resource: (Tiltfile)
    creationTimestamp: "2022-08-17T02:51:49Z"
    name: default
    ownerReferences:
    - apiVersion: tilt.dev/v1alpha1
      blockOwnerDeletion: true
      controller: true
      kind: Tiltfile
      name: (Tiltfile)
      uid: 9fbb43bb-1b12-4e40-a877-8af3bec009cf
    resourceVersion: "40"
    uid: 29ed1463-54a8-46e6-836a-6712e9e25933
  spec:
    connection:
      kubernetes: {}
  status:
    arch: unknown
    connectedAt: "2022-08-17T02:51:49.360319Z"
    connection:
      kubernetes:
        cluster: cluster.myorg.com
        configPath: /Users/tekumara/Library/Application Support/tilt-dev/tilt-default/cluster/default.yml
        context: myorg
        namespace: prefect-tools
        product: unknown
    version: v1.20.15-eks-84b4fe6
kind: List
metadata:
  resourceVersion: ""
  selfLink: ""

tekumara avatar Aug 17 '22 02:08 tekumara