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

Add pre-reqs and section in troubleshooting guide for dapr init #4051

Merged
merged 1 commit into from
Feb 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions daprdocs/content/en/getting-started/install-dapr-cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ You'll use the Dapr CLI as the main tool for various Dapr-related tasks. You can

The Dapr CLI works with both [self-hosted]({{< ref self-hosted >}}) and [Kubernetes]({{< ref Kubernetes >}}) environments.

{{% alert title="Before you begin" color="primary" %}}
In Docker Desktop's advanced options, verify you've allowed the default Docker socket to be used.
<img src="/images/docker-desktop-setting.png" width=800 style="padding-bottom:15px;">
{{% /alert %}}

### Step 1: Install the Dapr CLI

{{< tabs Linux Windows MacOS Binaries>}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ To initialize Dapr in your local or remote **Kubernetes** cluster for developmen
{{% /alert %}}

{{% alert title="Docker" color="primary" %}}
The recommended development environment requires [Docker](https://docs.docker.com/install/). While you can [initialize Dapr without a dependency on Docker]({{< ref self-hosted-no-docker.md >}})), the next steps in this guide assume the recommended Docker development environment.
The recommended development environment requires [Docker](https://docs.docker.com/install/). While you can [initialize Dapr without a dependency on Docker]({{< ref self-hosted-no-docker.md >}}), the next steps in this guide assume the recommended Docker development environment.

You can also install [Podman](https://podman.io/) in place of Docker. Read more about [initializing Dapr using Podman]({{< ref dapr-init.md >}}).
{{% /alert %}}
Expand Down Expand Up @@ -70,7 +70,7 @@ dapr init

**If you are installing on Mac OS Silicon with Docker,** you may need to perform the following workaround to enable `dapr init` to talk to Docker without using Kubernetes.
1. Navigate to **Docker Desktop** > **Settings** > **Advanced**.
1. Select the **Enable default Docker socket** checkbox.
1. Select the **Allow the default Docker socket to be used (requires password)** checkbox.

{{% /codetab %}}

Expand All @@ -86,6 +86,7 @@ dapr init

{{< /tabs >}}

[See the troubleshooting guide if you encounter any error messages regarding Docker not being installed or running.]({{< ref "common_issues.md#dapr-cant-connect-to-docker-when-installing-the-dapr-cli" >}})

### Step 3: Verify Dapr version

Expand Down
18 changes: 18 additions & 0 deletions daprdocs/content/en/operations/troubleshooting/common_issues.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,24 @@ weight: 1000
description: "Common issues and problems faced when running Dapr applications"
---

This guide covers common issues you may encounter while installing and running Dapr.

## Dapr can't connect to Docker when installing the Dapr CLI

When installing and initializing the Dapr CLI, if you see the following error message after running `dapr init`:

```bash
⌛ Making the jump to hyperspace...
❌ could not connect to docker. docker may not be installed or running
```

Troubleshoot the error by ensuring:

1. [The correct containers are running.]({{< ref "install-dapr-selfhost.md#step-4-verify-containers-are-running" >}})
1. In Docker Desktop, verify the **Allow the default Docker socket to be used (requires password)** option is selected.

<img src="/images/docker-desktop-setting.png" width=800 style="padding-bottom:15px;">

## I don't see the Dapr sidecar injected to my pod

There could be several reasons to why a sidecar will not be injected into a pod.
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading