文章摘要
GPT 4

采用homebrew安装Redis,前提是Mac已经安装Redis

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
~ brew install redis # 执行这个命令来安装Redis
Running `brew update --auto-update`...
==> Downloading https://formulae.brew.sh/api/formula.jws.json

######################################################################## 100.0%
==> Fetching redis
==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/redis-7.0.1
######################################################################## 100.0%
==> Pouring redis-7.0.10.arm64_monterey.bottle.tar.gz
==> Caveats
To start redis now and restart at login:
brew services start redis
==> Summary
🍺 /opt/homebrew/Cellar/redis/7.0.10: 14 files, 2.7MB
==> Running `brew cleanup redis`...
Disable this behaviour by setting HOMEBREW_NO_INSTALL_CLEANUP.
Hide these hints with HOMEBREW_NO_ENV_HINTS (see `man brew`).
➜ ~ brew services start redis
==> Downloading https://formulae.brew.sh/api/formula.jws.json
##O=# #
Warning: Calling formula.plist_path is deprecated! Use formula.launchd_service_path instead.
Please report this issue to the homebrew/services tap (not Homebrew/brew or Homebrew/homebrew-core), or even better, submit a PR to fix it:
/opt/homebrew/Library/Taps/homebrew/homebrew-services/lib/service/formula_wrapper.rb:58
1
2
3
4
5
6
7
➜  ~ redis-cli # 启动redis
127.0.0.1:6379> set name couture
OK
127.0.0.1:6379> get name
"couture"
127.0.0.1:6379> shutdown # 关闭
not connected> quit # 退出

homebrew安装的时候也出现一个问题

1
2
3
Warning: Calling formula.plist_path is deprecated! Use formula.launchd_service_path instead.
Please report this issue to the homebrew/services tap (not Homebrew/brew or Homebrew/homebrew-core), or even better, submit a PR to fix it:
/opt/homebrew/Library/Taps/homebrew/homebrew-services/lib/service/formula_wrapper.rb:58

需要修复什么东西

然后只需要执行命令

1
➜  ~ unset HOMEBREW_BOTTLE_DOMAIN

问题解决~