feat: readme
This commit is contained in:
@@ -2,9 +2,11 @@
|
||||
|
||||
**背景**
|
||||
博主使用的架构是
|
||||
|
||||
用户-->中转服务器nginx反代-->wireguard-->rke2集群网关nginx
|
||||
|
||||
因为有中转,tls握手需要在nginx实现一次;
|
||||
|
||||
因为有wireguard(自己会加密),所以tls可以终止与中转服务器nginx;
|
||||
|
||||
通过搜索资料得知,这样也可以实现自动化,利用scp和ssh,创建一个pod监听tls证书生成
|
||||
@@ -12,6 +14,7 @@
|
||||
然后分成nginx需要的pem和key,连同server配置块一同上传到中转服务器
|
||||
|
||||
scp需要登录用户对文件夹有写入权限,这一点有时候比较难注意到
|
||||
|
||||
因此推荐使用sudo tee的方式,这样可以在服务器配置该用户sudo某些指令不需要使用密码,ssh连接使用bash,更加方便
|
||||
|
||||
|
||||
@@ -19,6 +22,7 @@ scp需要登录用户对文件夹有写入权限,这一点有时候比较难
|
||||
使用预先创建的ssh密钥或者让pod自己生成ssh密钥
|
||||
|
||||
自己创建的密钥,打包进入容器后记得设置权限(私钥600,公钥644),否则ssh-server不会使用
|
||||
|
||||
上传例如这样:
|
||||
```
|
||||
ssh_command = [
|
||||
|
||||
Reference in New Issue
Block a user