DDEV mkcert installation issue

User
admin1@PC-274:~/ddev-projects/all4cloud-wordpress-website$ ddev start
Starting all4cloud…
Building project images…
.Project images built in 2s.
Container ddev-all4cloud-web Created
Container ddev-all4cloud-db Created
Container ddev-all4cloud-db Started
Container ddev-all4cloud-web Started
Failed to create certificates for project, check mkcert operation: ; err=exec: "mkcert": executable file not found in $PATH
Assistant
The error message you're seeing indicates that DDEV is trying to use `mkcert` to create local SSL certificates, but it cannot find the `mkcert` executable in your system's PATH. Here’s how to resolve this issue:

1. **Install mkcert**: If you haven't already installed `mkcert`, you can do so by following these steps:

– For **Ubuntu**, you can install `mkcert` using the following commands:

sudo apt install libnss3-tools
     wget https://github.com/FiloSottile/mkcert/releases/latest/download/mkcert-linux-amd64
     sudo mv mkcert-linux-amd64 /usr/local/bin/mkcert
     sudo chmod +x /usr/local/bin/mkcert
     mkcert -install

– For **MacOS**, use Homebrew:

brew install mkcert
     mkcert -install

– For **Windows**, download the `mkcert.exe` from the [mkcert releases page](https://github.com/FiloSottile/mkcert/releases) and add it to your PATH.

2. **Verify mkcert Installation**: After installation, ensure that `mkcert` is accessible from your terminal by running:

mkcert -version

You should see the version number if it is installed correctly.

3. **Restart DDEV**: Once `mkcert` is installed, you can restart your DDEV project:

ddev restart

This should resolve the issue with SSL certificates. Let me know if you encounter any further problems!

User
Location: https://github.com/FiloSottile/mkcert/releases/download/v1.4.4/mkcert-linux-amd64 [following]
–2025-01-21 12:44:41– https://github.com/FiloSottile/mkcert/releases/download/v1.4.4/mkcert-linux-amd64
Reusing existing connection to github.com:443.
HTTP request sent, awaiting response… 404 Not Found
2025-01-21 12:44:41 ERROR 404: Not Found.
Assistant
It seems that the link to the `mkcert` binary you were trying to access is outdated or incorrect. Here's how to install `mkcert` with the correct steps:

1. **Install Dependencies**: First, ensure that you have the necessary dependencies:

sudo apt install libnss3-tools

2. **Download mkcert**: You can use the following commands to download and install the latest version of `mkcert`:

# Download the latest mkcert release
   wget -O mkcert https://dl.filippo.io/mkcert/latest?for=linux/amd64

   # Move it to /usr/local/bin and make it executable
   sudo mv mkcert /usr/local/bin/
   sudo chmod +x /usr/local/bin/mkcert

3. **Install the Local CA**: Once `mkcert` is installed, run the following command to set up the local Certificate Authority:

mkcert -install

4. **Verify Installation**: Ensure `mkcert` is working by checking its version:

mkcert -version

5. **Restart DDEV**: After successfully installing `mkcert`, restart your DDEV project:

ddev restart

This should resolve the issue. Let me know if you need any more assistance!

Leave a Comment

Your email address will not be published. Required fields are marked *