mirror of
https://github.com/deployphp/action.git
synced 2025-04-02 03:16:35 +00:00
Fix handling of config options
This commit is contained in:
parent
eed58e3496
commit
098e6b1c9f
2 changed files with 6 additions and 3 deletions
|
@ -24,9 +24,12 @@
|
||||||
sub-directory: "..."
|
sub-directory: "..."
|
||||||
|
|
||||||
# Config options for the Deployer. Same as the `-o` flag in the CLI.
|
# Config options for the Deployer. Same as the `-o` flag in the CLI.
|
||||||
|
# Must be a JSON object.
|
||||||
# Optional.
|
# Optional.
|
||||||
options:
|
options: |
|
||||||
keep_releases: 7
|
{
|
||||||
|
"keep_releases": 7
|
||||||
|
}
|
||||||
|
|
||||||
# Private key for connecting to remote hosts. To generate private key:
|
# Private key for connecting to remote hosts. To generate private key:
|
||||||
# `ssh-keygen -o -t rsa -C 'action@deployer.org'`.
|
# `ssh-keygen -o -t rsa -C 'action@deployer.org'`.
|
||||||
|
|
2
index.js
2
index.js
|
@ -110,7 +110,7 @@ async function dep() {
|
||||||
let verbosity = core.getInput('verbosity')
|
let verbosity = core.getInput('verbosity')
|
||||||
let options = []
|
let options = []
|
||||||
try {
|
try {
|
||||||
for (let [key, value] in Object.entries(JSON.parse(core.getInput('options')))) {
|
for (let [key, value] of Object.entries(JSON.parse(core.getInput('options')))) {
|
||||||
options.push('-o', `${key}=${value}`)
|
options.push('-o', `${key}=${value}`)
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|
Loading…
Add table
Reference in a new issue