6
6
[ ![ Workflow Lint] ( https://img.shields.io/github/actions/workflow/status/cssnr/stack-deploy-action/lint.yaml?logo=github&label=lint )] ( https://github.com/cssnr/stack-deploy-action/actions/workflows/lint.yaml )
7
7
[ ![ GitHub Last Commit] ( https://img.shields.io/github/last-commit/cssnr/stack-deploy-action?logo=github&label=updated )] ( https://github.com/cssnr/stack-deploy-action/pulse )
8
8
[ ![ Codeberg Last Commit] ( https://img.shields.io/gitea/last-commit/cssnr/stack-deploy-action/master?gitea_url=https%3A%2F%2Fcodeberg.org%2F&logo=codeberg&logoColor=white&label=updated )] ( https://codeberg.org/cssnr/stack-deploy-action )
9
- [ ![ GitHub Contributors] ( https://img.shields.io/github/contributors/cssnr/stack-deploy-action )] ( https://github.com/cssnr/stack-deploy-action/graphs/contributors )
9
+ [ ![ GitHub Contributors] ( https://img.shields.io/github/contributors/cssnr/stack-deploy-action?logo=github )] ( https://github.com/cssnr/stack-deploy-action/graphs/contributors )
10
10
[ ![ GitHub Repo Size] ( https://img.shields.io/github/repo-size/cssnr/stack-deploy-action?logo=bookstack&logoColor=white&label=size )] ( https://github.com/cssnr/stack-deploy-action )
11
11
[ ![ GitHub Top Language] ( https://img.shields.io/github/languages/top/cssnr/stack-deploy-action?logo=sharp&logoColor=white )] ( https://github.com/cssnr/stack-deploy-action )
12
12
[ ![ GitHub Discussions] ( https://img.shields.io/github/discussions/cssnr/stack-deploy-action?logo=github )] ( https://github.com/cssnr/stack-deploy-action/discussions )
@@ -44,27 +44,27 @@ For more details see [action.yaml](action.yaml) and [src/main.sh](src/main.sh).
44
44
45
45
## Inputs
46
46
47
- | Input  ; Name | Is & nbsp ; Required | Default  ; Value | Input   ; Description |
48
- | :------------------- | :-------------- : | :---------------------------------- | :---------------------------------------- |
49
- | ` name ` | ** Yes** | - | Docker Stack/Project Name \* |
50
- | ` file ` | - | ` docker-compose.yaml ` | Docker Stack/Compose File |
51
- | ` mode ` ** ¹** | - | ` swarm ` | Deploy Mode: [ ` swarm ` , ` compose ` ] \* |
52
- | ` args ` ** ¹** | - | ` --remove-orphans --force-recreate ` | Additional Arguments for ** Compose** \* |
53
- | ` host ` | ** Yes** | - | Remote Docker Hostname or IP \* |
54
- | ` port ` | - | ` 22 ` | Remote Docker Port |
55
- | ` user ` | ** Yes** | - | Remote Docker Username |
56
- | ` pass ` | or ` ssh_key ` | - | Remote Docker Password \* |
57
- | ` ssh_key ` | or ` pass ` | - | Remote SSH Key File \* |
58
- | ` disable_keyscan ` | - | ` false ` | Disable SSH Key Scan: ` ssh-keyscan ` \* |
59
- | ` env_file ` | - | - | Docker Environment File \* |
60
- | ` detach ` ** ²** | - | ` true ` | Detach Flag, ` false ` , to disable \* |
61
- | ` prune ` ** ²** | - | ` false ` | Prune Flag, ` true ` , to enable |
62
- | ` resolve_image ` ** ²** | - | ` always ` | Resolve [ ` always ` , ` changed ` , ` never ` ] \* |
63
- | ` registry_auth ` ** ²** | - | - | Enable Registry Authentication \* |
64
- | ` registry_host ` | - | - | Registry Authentication Host \* |
65
- | ` registry_user ` | - | - | Registry Authentication Username \* |
66
- | ` registry_pass ` | - | - | Registry Authentication Password \* |
67
- | ` summary ` | - | ` true ` | Add Job Summary \* |
47
+ | Input  ; Name | Required | Default  ; Value | Short   ; Description& nbsp ; of & nbsp ; Input |
48
+ | :------------------- | :----------: | :---------------------------------- | :---------------------------------------- |
49
+ | ` name ` | ** Yes** | - | Docker Stack/Project Name \* |
50
+ | ` file ` | - | ` docker-compose.yaml ` | Docker Stack/Compose File(s) \* |
51
+ | ` mode ` ** ¹** | - | ` swarm ` | Deploy Mode [ ` swarm ` , ` compose ` ] \* |
52
+ | ` args ` ** ¹** | - | ` --remove-orphans --force-recreate ` | Additional ** Compose** Arguments \* |
53
+ | ` host ` | ** Yes** | - | Remote Docker Hostname or IP \* |
54
+ | ` port ` | - | ` 22 ` | Remote Docker Port |
55
+ | ` user ` | ** Yes** | - | Remote Docker Username |
56
+ | ` pass ` | or ` ssh_key ` | - | Remote Docker Password \* |
57
+ | ` ssh_key ` | or ` pass ` | - | Remote SSH Key File \* |
58
+ | ` disable_keyscan ` | - | ` false ` | Disable SSH Keyscan ` ssh-keyscan ` \* |
59
+ | ` env_file ` | - | - | Docker Environment File \* |
60
+ | ` detach ` ** ²** | - | ` true ` | Detach Flag, ` false ` , to disable \* |
61
+ | ` prune ` ** ²** | - | ` false ` | Prune Flag, ` true ` , to enable |
62
+ | ` resolve_image ` ** ²** | - | ` always ` | Resolve [ ` always ` , ` changed ` , ` never ` ] \* |
63
+ | ` registry_auth ` ** ²** | - | - | Enable Registry Authentication \* |
64
+ | ` registry_host ` | - | - | Registry Authentication Host \* |
65
+ | ` registry_user ` | - | - | Registry Authentication Username \* |
66
+ | ` registry_pass ` | - | - | Registry Authentication Password \* |
67
+ | ` summary ` | - | ` true ` | Add Job Summary \* |
68
68
69
69
> ** ¹** Compose Only, view the [ Docs] ( https://docs.docker.com/reference/cli/docker/compose/up/ ) .
70
70
> ** ²** Swarm Only, view the [ Docs] ( https://docs.docker.com/reference/cli/docker/stack/deploy/ ) .
@@ -78,14 +78,19 @@ if [[ "${INPUT_MODE}" == "swarm" ]];then
78
78
COMMAND=(" docker" " stack" " deploy" " -c" " ${INPUT_FILE} " " ${EXTRA_ARGS[@]} " " ${INPUT_NAME} " )
79
79
else
80
80
DEPLOY_TYPE=" Compose"
81
- COMMAND=(" docker" " compose" " -f " " ${INPUT_FILE }" " -p" " ${INPUT_NAME} " " up" " -d" " -y" " ${EXTRA_ARGS[@]} " )
81
+ COMMAND=(" docker" " compose" " ${STACK_FILES[@] }" " -p" " ${INPUT_NAME} " " up" " -d" " -y" " ${EXTRA_ARGS[@]} " )
82
82
fi
83
83
```
84
84
85
+ Compose Note: ` "${STACK_FILES[@]}" ` is an array of ` -f docker-compose.yaml ` for every ` file ` in the argument.
86
+
85
87
</details >
86
88
87
89
** name:** Stack name for Swarm and project name for Compose.
88
90
91
+ ** file:** Stack file or Compose file(s). Multiple files can be provided, space seperated, and a ` -f ` will be prepended to each.
92
+ Example: ` web.yaml db.yaml ` .
93
+
89
94
** mode:** _ Compose only._ Set this to ` compose ` to use ` compose up ` instead of ` stack deploy ` for non-swarm hosts.
90
95
91
96
** args:** _ Compose only._ Compose arguments to pass to the ` compose up ` command. Only used for ` mode: compose ` deployments.
0 commit comments