diff --git a/README.md b/README.md index 66f2be9..c7d5803 100644 --- a/README.md +++ b/README.md @@ -11,16 +11,15 @@ [![Go Report Card](https://goreportcard.com/badge/github.com/appleboy/drone-ssh)](https://goreportcard.com/report/github.com/appleboy/drone-ssh) [![Docker Pulls](https://img.shields.io/docker/pulls/appleboy/drone-ssh.svg)](https://hub.docker.com/r/appleboy/drone-ssh/) -Drone plugin to execute commands on a remote host through SSH. For the usage -information and a listing of the available options please take a look at [the docs](http://plugins.drone.io/appleboy/drone-ssh/). +A Drone plugin for executing commands on remote hosts via SSH. For usage instructions and a list of available options, please refer to [the documentation](http://plugins.drone.io/appleboy/drone-ssh/). -**Note: Please update your image config path to `appleboy/drone-ssh` for drone. `plugins/ssh` is no longer maintained.** +**Note: Please update your Drone image config path to `appleboy/drone-ssh`. The `plugins/ssh` image is no longer maintained.** ![demo](./images/demo2017.05.10.gif) -## Breaking changes +## Breaking Changes -`v1.5.0`: change command timeout flag to `Duration`. See the following setting: +As of `v1.5.0`, the command timeout flag has changed to use the `Duration` format. See the following example: ```diff pipeline: @@ -40,21 +39,21 @@ pipeline: - echo "Hello World" ``` -## Build or Download a binary +## Build or Download a Binary -The pre-compiled binaries can be downloaded from [release page](https://github.com/appleboy/drone-ssh/releases). Support the following OS type. +Pre-compiled binaries are available on the [releases page](https://github.com/appleboy/drone-ssh/releases), supporting the following operating systems: - Windows amd64/386 - Linux arm/amd64/386 -- Darwin amd64/386 +- macOS (Darwin) amd64/386 -With `Go` installed +If you have `Go` installed: ```sh go install github.com/appleboy/drone-ssh@latest ``` -or build the binary with the following command: +Or build the binary manually with the following commands: ```sh export GOOS=linux @@ -69,7 +68,7 @@ go build -v -a -tags netgo -o release/linux/amd64/drone-ssh . ## Docker -Build the docker image with the following commands: +Build the Docker image with the following command: ```sh make docker @@ -77,7 +76,7 @@ make docker ## Usage -Execute from the working directory: +Run from your working directory: ```sh docker run --rm \ @@ -90,13 +89,13 @@ docker run --rm \ ghcr.io/appleboy/drone-ssh ``` -## Mount key from file path +## Mount Key from File Path -Please make sure that enable the `trusted` mode in project setting for [drone 0.8 version](https://0-8-0.docs.drone.io/). +Make sure to enable `trusted` mode in your project settings (for [Drone 0.8 version](https://0-8-0.docs.drone.io/)). ![trusted mode](./images/trust.png) -Mount private key in `volumes` setting of `.drone.yml` config +Mount the private key in the `volumes` section of your `.drone.yml` config: ```diff pipeline: @@ -111,11 +110,11 @@ pipeline: - echo "test ssh" ``` -See the detail of [issue comment](https://github.com/appleboy/drone-ssh/issues/51#issuecomment-336732928). +See details in [this issue comment](https://github.com/appleboy/drone-ssh/issues/51#issuecomment-336732928). ## Configuration -See [DOCS.md](./DOCS.md) for examples and full configuration options +See [DOCS.md](./DOCS.md) for examples and full configuration options. Configuration options are loaded from multiple sources: @@ -123,4 +122,4 @@ Configuration options are loaded from multiple sources: 1. From a dotenv file at a path specified by the `PLUGIN_ENV_FILE` environment variable. 2. From your `.drone.yml` Drone configuration. -Later sources override previous sources, i.e. if `PORT` is set in an `.env` file committed in the repository or created by previous test steps, it will override the default set `main.go`. +Later sources override earlier ones. For example, if `PORT` is set in an `.env` file committed in the repository or created by previous test steps, it will override the default set in `main.go`. diff --git a/README.zh-cn.md b/README.zh-cn.md index c80543d..9a8066f 100644 --- a/README.zh-cn.md +++ b/README.zh-cn.md @@ -57,7 +57,7 @@ pipeline: go install github.com/appleboy/drone-ssh@latest ``` -或使用以下命令自行构建二进制文件: +或使用以下命令手动构建二进制文件: ```sh export GOOS=linux @@ -95,12 +95,10 @@ docker run --rm \ ## 通过文件路径挂载密钥 -请确保已在项目设置中启用 `trusted` 模式(适用于 [drone 0.8 版本](https://0-8-0.docs.drone.io/))。 +请确保已在项目设置中启用 `trusted` 模式(适用于 [Drone 0.8 版本](https://0-8-0.docs.drone.io/))。 ![trusted mode](./images/trust.png) - - 在 `.drone.yml` 配置文件的 `volumes` 部分挂载私钥: ```diff @@ -116,11 +114,11 @@ pipeline: - echo "test ssh" ``` -详情请参考 [issue comment](https://github.com/appleboy/drone-ssh/issues/51#issuecomment-336732928)。 +详情请参考 [此 issue comment](https://github.com/appleboy/drone-ssh/issues/51#issuecomment-336732928)。 ## 配置说明 -更多示例和完整配置选项请参考 [DOCS.md](./DOCS.md) +更多示例和完整配置选项请参考 [DOCS.md](./DOCS.md)。 配置选项来源如下: @@ -128,4 +126,4 @@ pipeline: 1. 由 `PLUGIN_ENV_FILE` 环境变量指定的 dotenv 文件。 2. `.drone.yml` Drone 配置文件。 -后面的来源会覆盖前面的设置,例如 `.env` 文件中的 `PORT` 会覆盖 main.go 的默认值。 +后面的来源会覆盖前面的设置。例如,`.env` 文件中的 `PORT` 会覆盖 main.go 的默认值。 diff --git a/README.zh-tw.md b/README.zh-tw.md index 507ec11..97e626c 100644 --- a/README.zh-tw.md +++ b/README.zh-tw.md @@ -57,7 +57,7 @@ pipeline: go install github.com/appleboy/drone-ssh@latest ``` -或使用下列指令自行建置執行檔: +或使用下列指令手動建置執行檔: ```sh export GOOS=linux @@ -95,12 +95,10 @@ docker run --rm \ ## 以檔案路徑掛載金鑰 -請確認已於專案設定中啟用 `trusted` 模式(適用於 [drone 0.8 版本](https://0-8-0.docs.drone.io/))。 +請確認已於專案設定中啟用 `trusted` 模式(適用於 [Drone 0.8 版本](https://0-8-0.docs.drone.io/))。 ![trusted mode](./images/trust.png) - - 於 `.drone.yml` 設定檔的 `volumes` 區段掛載私鑰: ```diff @@ -116,11 +114,11 @@ pipeline: - echo "test ssh" ``` -詳情請參考 [issue comment](https://github.com/appleboy/drone-ssh/issues/51#issuecomment-336732928)。 +詳情請參考 [此 issue comment](https://github.com/appleboy/drone-ssh/issues/51#issuecomment-336732928)。 ## 設定說明 -更多範例與完整設定選項請參考 [DOCS.md](./DOCS.md) +更多範例與完整設定選項請參考 [DOCS.md](./DOCS.md)。 設定選項來源如下: @@ -128,4 +126,4 @@ pipeline: 1. 由 `PLUGIN_ENV_FILE` 環境變數指定的 dotenv 檔案。 2. `.drone.yml` Drone 設定檔。 -後面的來源會覆蓋前面的設定,例如 `.env` 檔案中的 `PORT` 會覆蓋 main.go 的預設值。 +後面的來源會覆蓋前面的設定。例如,`.env` 檔案中的 `PORT` 會覆蓋 main.go 的預設值。