Azure-Samples / azure-search-openai-demo-java

This repo is the Java version of Microsoft's sample app for ChatGPT + Enterprise data.
MIT License
64 stars 66 forks source link

Local dev container fails on Mac M1 #87

Open dfberry opened 1 month ago

dfberry commented 1 month ago

Please provide us with the following information:

This issue is for a: (mark with an x)

- [ x] bug report -> please search issues before submitting
- [ ] feature request
- [ ] documentation issue or request
- [ ] regression (a behavior that used to work and stopped in a new release)

Minimal steps to reproduce

  1. azd is installed, docker is running
  2. create new folder
  3. code . in new folder
  4. azd init -t azure-search-openai-demo-java
  5. last bit of log is
#0 2.495 Preparing to unpack .../bash-completion_1%3a2.11-2_all.deb ...

#0 2.732 Unpacking bash-completion (1:2.11-2) ...

#0 2.783 Setting up bash-completion (1:2.11-2) ...

#0 3.045 Processing triggers for man-db (2.9.4-2) ...

#0 3.108 Downloading kubectl...
#0 3.795 KUBECTL_VERSION=1.1.8
#0 4.765 sha256sum: 'standard input': no properly formatted SHA256 checksum lines found
#0 4.767 ERROR: Feature "Kubectl, Helm, and Minikube" (ghcr.io/devcontainers/features/kubectl-helm-minikube) failed to install! Look at the documentation at https://github.com/devcontainers/features/tree/main/src/kubectl-helm-minikube for help troubleshooting this error.
------
Dockerfile.extended:71
--------------------
  70 |     
  71 | >>> RUN --mount=type=bind,from=dev_containers_feature_content_source,source=kubectl-helm-minikube_5,target=/tmp/build-features-src/kubectl-helm-minikube_5 \
  72 | >>>     cp -ar /tmp/build-features-src/kubectl-helm-minikube_5 /tmp/dev-container-features \
  73 | >>>  && chmod -R 0755 /tmp/dev-container-features/kubectl-helm-minikube_5 \
  74 | >>>  && cd /tmp/dev-container-features/kubectl-helm-minikube_5 \
  75 | >>>  && chmod +x ./devcontainer-features-install.sh \
  76 | >>>  && ./devcontainer-features-install.sh \
  77 | >>>  && rm -rf /tmp/dev-container-features/kubectl-helm-minikube_5
  78 |     
--------------------
error: failed to solve: process "/bin/sh -c cp -ar /tmp/build-features-src/kubectl-helm-minikube_5 /tmp/dev-container-features  && chmod -R 0755 /tmp/dev-container-features/kubectl-helm-minikube_5  && cd /tmp/dev-container-features/kubectl-helm-minikube_5  && chmod +x ./devcontainer-features
[2024-05-17T16:28:56.006Z] -install.sh  && ./devcontainer-features-install.sh  && rm -rf /tmp/dev-container-features/kubectl-helm-minikube_5" did not complete successfully: exit code: 1
[2024-05-17T16:28:56.009Z] Stop (158544 ms): Run: docker buildx build --load --build-context dev_containers_feature_content_source=/tmp/devcontainercli-root/container-features/0.59.1-1715963170619 --build-arg _DEV_CONTAINERS_BASE_IMAGE=mcr.microsoft.com/devcontainers/java:1-17-bullseye --build-arg _DEV_CONTAINERS_IMAGE_USER=root --build-arg _DEV_CONTAINERS_FEATURE_CONTENT_SOURCE=dev_container_feature_content_temp --target dev_containers_target_stage -t vsc-azure-search-openai-demo-java-fc686df8037b654333f52149569bf756dec3d9a7b0aac3b0d9a42ca8a1119f21-features -f /tmp/devcontainercli-root/container-features/0.59.1-1715963170619/Dockerfile.extended /tmp/devcontainercli-root/empty-folder
[2024-05-17T16:28:56.014Z] Error: Command failed: docker buildx build --load --build-context dev_containers_feature_content_source=/tmp/devcontainercli-root/container-features/0.59.1-1715963170619 --build-arg _DEV_CONTAINERS_BASE_IMAGE=mcr.microsoft.com/devcontainers/java:1-17-bullseye --build-arg _DEV_CONTAINERS_IMAGE_USER=root --build-arg _DEV_CONTAINERS_FEATURE_CONTENT_SOURCE=dev_container_feature_content_temp --target dev_containers_target_stage -t vsc-azure-search-openai-demo-java-fc686df8037b654333f52149569bf756dec3d9a7b0aac3b0d9a42ca8a1119f21-features -f /tmp/devcontainercli-root/container-features/0.59.1-1715963170619/Dockerfile.extended /tmp/devcontainercli-root/empty-folder
[2024-05-17T16:28:56.014Z]     at ptA (/root/.vscode-remote-containers/dist/dev-containers-cli-0.362.0/dist/spec-node/devContainersSpecCLI.js:464:1260)
[2024-05-17T16:28:56.014Z]     at NH (/root/.vscode-remote-containers/dist/dev-containers-cli-0.362.0/dist/spec-node/devContainersSpecCLI.js:464:1002)
[2024-05-17T16:28:56.014Z]     at runMicrotasks (<anonymous>)
[2024-05-17T16:28:56.014Z]     at processTicksAndRejections (node:internal/process/task_queues:96:5)
[2024-05-17T16:28:56.014Z]     at async KtA (/root/.vscode-remote-containers/dist/dev-containers-cli-0.362.0/dist/spec-node/devContainersSpecCLI.js:481:3692)
[2024-05-17T16:28:56.015Z]     at async $C (/root/.vscode-remote-containers/dist/dev-containers-cli-0.362.0/dist/spec-node/devContainersSpecCLI.js:481:4807)
[2024-05-17T16:28:56.015Z]     at async hrA (/root/.vscode-remote-containers/dist/dev-containers-cli-0.362.0/dist/spec-node/devContainersSpecCLI.js:661:13255)
[2024-05-17T16:28:56.015Z]     at async lrA (/root/.vscode-remote-containers/dist/dev-containers-cli-0.362.0/dist/spec-node/devContainersSpecCLI.js:661:12996)
[2024-05-17T16:28:56.028Z] Stop (166875 ms): Run in container: node /root/.vscode-remote-containers/dist/dev-containers-cli-0.362.0/dist/spec-node/devContainersSpecCLI.js up --container-session-data-folder /tmp/devcontainers-fd601280-1ae0-49c1-b319-1c95d6ae01031715963144850 --workspace-folder /workspaces/azure-search-openai-demo-java --workspace-mount-consistency cached --id-label vsch.local.repository=https://github.com/Azure-Samples/azure-search-openai-demo-java --id-label vsch.local.repository.volume=azure-search-openai-demo-java-f61ebbeac61bf367e08de080c1d9f47f99314616fe18efbfcfbc3fdd62b521e5 --id-label vsch.local.repository.folder=azure-search-openai-demo-java --id-label devcontainer.config_file=/workspaces/azure-search-openai-demo-java/.devcontainer/devcontainer.json --log-level debug --log-format json --config /workspaces/azure-search-openai-demo-java/.devcontainer/devcontainer.json --override-config /tmp/devcontainer-1e1bf359-1435-4fe0-8d37-11a49c306667.json --default-user-env-probe loginInteractiveShell --mount type=volume,source=azure-search-openai-demo-java-f61ebbeac61bf367e08de080c1d9f47f99314616fe18efbfcfbc3fdd62b521e5,target=/workspaces,external=true --mount type=volume,source=vscode,target=/vscode,external=true --skip-post-create --update-remote-user-uid-default off --mount-workspace-git-root --terminal-columns 171 --terminal-rows 19
[2024-05-17T16:28:56.028Z] Exit code 1
[2024-05-17T16:28:56.029Z] Start: Run: docker rm -f 65e728c0d4c35d6d9371de698a56e5eef93c536cb97c4b85a600df2ca76a6fa6
[2024-05-17T16:28:56.032Z] Command failed: node /root/.vscode-remote-containers/dist/dev-containers-cli-0.362.0/dist/spec-node/devContainersSpecCLI.js up --container-session-data-folder /tmp/devcontainers-fd601280-1ae0-49c1-b319-1c95d6ae01031715963144850 --workspace-folder /workspaces/azure-search-openai-demo-java --workspace-mount-consistency cached --id-label vsch.local.repository=https://github.com/Azure-Samples/azure-search-openai-demo-java --id-label vsch.local.repository.volume=azure-search-openai-demo-java-f61ebbeac61bf367e08de080c1d9f47f99314616fe18efbfcfbc3fdd62b521e5 --id-label vsch.local.repository.folder=azure-search-openai-demo-java --id-label devcontainer.config_file=/workspaces/azure-search-openai-demo-java/.devcontainer/devcontainer.json --log-level debug --log-format json --config /workspaces/azure-search-openai-demo-java/.devcontainer/devcontainer.json --override-config /tmp/devcontainer-1e1bf359-1435-4fe0-8d37-11a49c306667.json --default-user-env-probe loginInteractiveShell --mount type=volume,source=azure-search-openai-demo-java-f61ebbeac61bf367e08de080c1d9f47f99314616fe18efbfcfbc3fdd62b521e5,target=/workspaces,external=true --mount type=volume,source=vscode,target=/vscode,external=true --skip-post-create --update-remote-user-uid-default off --mount-workspace-git-root --terminal-columns 171 --terminal-rows 19
[2024-05-17T16:28:56.032Z] Exit code 1
[2024-05-17T16:28:56.090Z] Stop (169596 ms): Run in container: /bin/sh
[2024-05-17T16:28:56.091Z] Stop (169531 ms): Run in container: /bin/sh
[2024-05-17T16:28:56.091Z] Container server terminated (code: 137, signal: null).
[2024-05-17T16:28:56.173Z] Stop (144 ms): Run: docker rm -f 65e728c0d4c35d6d9371de698a56e5eef93c536cb97c4b85a600df2ca76a6fa6
[2024-05-17T16:29:46.586Z] Start: Run: docker volume ls -q
[2024-05-17T16:29:46.641Z] Stop (55 ms): Run: docker volume ls -q
[2024-05-17T16:29:46.642Z] Getting Docker parameters for own remote.
[2024-05-17T16:29:46.680Z] Start: Run: docker version --format {{json .}}
[2024-05-17T16:29:46.734Z] {"Client":{"CloudIntegration":"v1.0.35+desktop.11","Version":"25.0.3","ApiVersion":"1.44","DefaultAPIVersion":"1.44","GitCommit":"4debf41","GoVersion":"go1.21.6","Os":"darwin","Arch":"arm64","BuildTime":"Tue Feb  6 21:13:26 2024","Context":"desktop-linux"},"Server":{"Platform":{"Name":"Docker Desktop 4.28.0 (139021)"},"Components":[{"Name":"Engine","Version":"25.0.3","Details":{"ApiVersion":"1.44","Arch":"arm64","BuildTime":"Tue Feb  6 21:14:22 2024","Experimental":"false","GitCommit":"f417435","GoVersion":"go1.21.6","KernelVersion":"6.6.16-linuxkit","MinAPIVersion":"1.24","Os":"linux"}},{"Name":"containerd","Version":"1.6.28","Details":{"GitCommit":"ae07eda36dd25f8a1b98dfbf587313b99c0190bb"}},{"Name":"runc","Version":"1.1.12","Details":{"GitCommit":"v1.1.12-0-g51d5e94"}},{"Name":"docker-init","Version":"0.19.0","Details":{"GitCommit":"de40ad0"}}],"Version":"25.0.3","ApiVersion":"1.44","MinAPIVersion":"1.24","GitCommit":"f417435","GoVersion":"go1.21.6","Os":"linux","Arch":"arm64","KernelVersion":"6.6.16-linuxkit","BuildTime":"2024-02-06T21:14:22.000000000+00:00"}}
[2024-05-17T16:29:46.735Z] Stop (55 ms): Run: docker version --format {{json .}}

Any log messages given by the failure

Expected/desired behavior

OS and Version?

Windows 7, 8 or 10. Linux (which distribution). macOS (Yosemite? El Capitan? Sierra?)

azd version?

run azd version and copy paste here.

Versions

Mention any other details that might be useful


Thanks! We'll be in touch soon.

diberry commented 1 month ago

@achandmsft Not sure if this is a critical path for Java customers.

torumakabe commented 1 week ago

@dfberry The same thing happened in my environment. It seems the settings for the kubectl-helm-minikube features of the devcontainer are not appropriate.

The version specified in this feature refers to the kubectl version.

https://github.com/devcontainers/features/tree/main/src/kubectl-helm-minikube

However, the value specified in this sample is not appropriate. When I tried specifying 'latest', the devcontainer build was successful.