mkcert

2023年 10月 13日 54.5k 0

Ubuntu 18 mkcert https

mkcert is a simple tool for making locally-trusted development certificates. It requires no configuration

install Linuxbrew

sh -c "$(curl -fsSL https://raw.githubusercontent.com/Linuxbrew/install/master/install.sh)"

test -d ~/.linuxbrew && eval $(~/.linuxbrew/bin/brew shellenv)
test -d /home/linuxbrew/.linuxbrew && eval $(/home/linuxbrew/.linuxbrew/bin/brew shellenv)
test -r ~/.bash_profile && echo "eval \$($(brew --prefix)/bin/brew shellenv)" >>~/.bash_profile
echo "eval \$($(brew --prefix)/bin/brew shellenv)" >>~/.profile

$ brew --version
Homebrew 2.1.11
Homebrew/linuxbrew-core (git revision 0c03; last commit 2019-09-16)

docs.brew.sh/Homebrew-on…

install mkcert

brew install mkcert

$ brew --version
Homebrew 2.1.11
Homebrew/linuxbrew-core (git revision 0c03; last commit 2019-09-16)

$ brew install mkcert
==> Downloading https://linuxbrew.bintray.com/bottles/mkcert-1.4.0.x86_64_linux.
==> Downloading from https://akamai.bintray.com/a4/a40257c8cc9547ab98595a907e3f2
######################################################################## 100.0%
==> Pouring mkcert-1.4.0.x86_64_linux.bottle.tar.gz
🍺  /home/linuxbrew/.linuxbrew/Cellar/mkcert/1.4.0: 7 files, 4.7MB


$ mkcert -install
Created a new local CA at "/home/w/.local/share/mkcert" 💥
[sudo] password for w: 
The local CA is now installed in the system trust store! ⚡️
Warning: "certutil" is not available, so the CA can't be automatically installed in Firefox and/or Chrome/Chromium! ⚠️
Install "certutil" with "apt install libnss3-tools" and re-run "mkcert -install" 👈



$ mkcert example.com "*.example.com" example.test localhost 127.0.0.1 ::1
Using the local CA at "/home/w/.local/share/mkcert" ✨
Warning: the local CA is not installed in the Firefox and/or Chrome/Chromium trust store! ⚠️
Run "mkcert -install" to avoid verification errors ‼️

Created a new certificate valid for the following names 📜
 - "example.com"
 - "*.example.com"
 - "example.test"
 - "localhost"
 - "127.0.0.1"
 - "::1"

Reminder: X.509 wildcards only go one level deep, so this won't match a.b.example.com ℹ️

The certificate is at "./example.com+5.pem" and the key at "./example.com+5-key.pem" ✅


相关文章

服务器端口转发,带你了解服务器端口转发
服务器开放端口,服务器开放端口的步骤
产品推荐:7月受欢迎AI容器镜像来了,有Qwen系列大模型镜像
如何使用 WinGet 下载 Microsoft Store 应用
百度搜索:蓝易云 – 熟悉ubuntu apt-get命令详解
百度搜索:蓝易云 – 域名解析成功但ping不通解决方案

发布评论