Skip to content

Commit

Permalink
docs(readme): standardize and format README files across languages
Browse files Browse the repository at this point in the history
- Remove an empty line in `README.md`
- Replace underscores with bold formatting for default key types in `README.zh-cn.md` and `README.zh-tw.md`
- Standardize list formatting in `README.md`, `README.zh-cn.md`, and `README.zh-tw.md`

Signed-off-by: appleboy <[email protected]>
  • Loading branch information
appleboy committed Dec 1, 2024
1 parent 6137f73 commit b76e617
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 41 deletions.
25 changes: 12 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,19 +60,18 @@ Executing remote SSH commands.
name: remote ssh command
on: [push]
jobs:

build:
name: Build
runs-on: ubuntu-latest
steps:
- name: executing remote ssh commands using password
uses: appleboy/[email protected]
with:
host: ${{ secrets.HOST }}
username: linuxserver.io
password: ${{ secrets.PASSWORD }}
port: ${{ secrets.PORT }}
script: whoami
- name: executing remote ssh commands using password
uses: appleboy/[email protected]
with:
host: ${{ secrets.HOST }}
username: linuxserver.io
password: ${{ secrets.PASSWORD }}
port: ${{ secrets.PORT }}
script: whoami
```
output:
Expand Down Expand Up @@ -152,9 +151,9 @@ See the detail information about [SSH login without password](http://www.linuxpr

**A note** from one of our readers: Depending on your version of SSH you might also have to do the following changes:

* Put the public key in `.ssh/authorized_keys2`
* Change the permissions of `.ssh` to 700
* Change the permissions of `.ssh/authorized_keys2` to 640
- Put the public key in `.ssh/authorized_keys2`
- Change the permissions of `.ssh` to 700
- Change the permissions of `.ssh/authorized_keys2` to 640

### If you are using OpenSSH

Expand Down Expand Up @@ -231,7 +230,7 @@ ssh-keygen -t ed25519 -a 200 -C "[email protected]"
username: ${{ secrets.USERNAME }}
key: ${{ secrets.KEY }}
port: ${{ secrets.PORT }}
script_path: scripts/script.sh
script_path: scripts/script.sh
```
#### Multiple Hosts
Expand Down
27 changes: 13 additions & 14 deletions README.zh-cn.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,19 +57,18 @@
name: remote ssh command
on: [push]
jobs:

build:
name: Build
runs-on: ubuntu-latest
steps:
- name: executing remote ssh commands using password
uses: appleboy/[email protected]
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
port: ${{ secrets.PORT }}
script: whoami
- name: executing remote ssh commands using password
uses: appleboy/[email protected]
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
port: ${{ secrets.PORT }}
script: whoami
```
画面输出
Expand Down Expand Up @@ -132,9 +131,9 @@ clip < ~/.ssh/id_ed25519

**来自读者的注意事项**: 根据您的 SSH 版本,您可能还需要进行以下更改:

* 将公钥放在 `.ssh/authorized_keys2`
*`.ssh` 的权限更改为700
*`.ssh/authorized_keys2` 的权限更改为640
- 将公钥放在 `.ssh/authorized_keys2`
-`.ssh` 的权限更改为 700
-`.ssh/authorized_keys2` 的权限更改为 640

### 如果你使用的是 OpenSSH

Expand Down Expand Up @@ -227,7 +226,7 @@ ssh-keygen -t ed25519 -a 200 -C ”[email protected]
username: ${{ secrets.USERNAME }}
key: ${{ secrets.KEY }}
port: ${{ secrets.PORT }}
script_path: scripts/script.sh
script_path: scripts/script.sh
```
#### 多个不同端口的主机
Expand Down Expand Up @@ -380,7 +379,7 @@ Host FooServer

设置 SSH 主机指纹验证可以帮助防止中间人攻击。在设置之前,运行以下命令以获取 SSH 主机指纹。请记得将 `ed25519` 替换为您适当的密钥类型(`rsa`、 `dsa`等),而 `example.com` 则替换为您的主机。

现代 OpenSSH 版本中,需要提取的_默认密钥_类型是 `rsa`(从版本 5.1 开始)、`ecdsa`(从版本 6.0 开始)和 `ed25519`(从版本 6.7 开始)。
现代 OpenSSH 版本中,需要提取的**默认密钥**类型是 `rsa`(从版本 5.1 开始)、`ecdsa`(从版本 6.0 开始)和 `ed25519`(从版本 6.7 开始)。

```sh
ssh example.com ssh-keygen -l -f /etc/ssh/ssh_host_ed25519_key.pub | cut -d ’ ‘ -f2
Expand Down
27 changes: 13 additions & 14 deletions README.zh-tw.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,19 +60,18 @@
name: remote ssh command
on: [push]
jobs:

build:
name: Build
runs-on: ubuntu-latest
steps:
- name: executing remote ssh commands using password
uses: appleboy/[email protected]
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
port: ${{ secrets.PORT }}
script: whoami
- name: executing remote ssh commands using password
uses: appleboy/[email protected]
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
port: ${{ secrets.PORT }}
script: whoami
```
畫面輸出
Expand Down Expand Up @@ -135,9 +134,9 @@ clip < ~/.ssh/id_ed25519

**來自讀者的注意事項**: 根據您的 SSH 版本,您可能還需要進行以下更改:

* 將公鑰放在 `.ssh/authorized_keys2`
*`.ssh` 的權限更改為700
*`.ssh/authorized_keys2` 的權限更改為640
- 將公鑰放在 `.ssh/authorized_keys2`
-`.ssh` 的權限更改為 700
-`.ssh/authorized_keys2` 的權限更改為 640

### 如果你使用的是 OpenSSH

Expand Down Expand Up @@ -214,7 +213,7 @@ ssh-keygen -t ed25519 -a 200 -C "[email protected]"
username: ${{ secrets.USERNAME }}
key: ${{ secrets.KEY }}
port: ${{ secrets.PORT }}
script_path: scripts/script.sh
script_path: scripts/script.sh
```
#### 多台主機
Expand Down Expand Up @@ -383,7 +382,7 @@ Host FooServer

設置 SSH 主機指紋驗證可以幫助防止中間人攻擊。在設置之前,運行以下命令以獲取 SSH 主機指紋。請記得將 `ed25519` 替換為您的適當金鑰類型(`rsa`、 `dsa`等),而 `example.com` 則替換為您的主機。

現代 OpenSSH 版本中,需要提取的_默認金鑰_類型是 `rsa`(從版本 5.1 開始)、`ecdsa`(從版本 6.0 開始)和 `ed25519`(從版本 6.7 開始)。
現代 OpenSSH 版本中,需要提取的**默認金鑰**類型是 `rsa`(從版本 5.1 開始)、`ecdsa`(從版本 6.0 開始)和 `ed25519`(從版本 6.7 開始)。

```sh
ssh example.com ssh-keygen -l -f /etc/ssh/ssh_host_ed25519_key.pub | cut -d ' ' -f2
Expand Down

0 comments on commit b76e617

Please sign in to comment.