Skip to content

Commit

Permalink
feat: adding debug flag
Browse files Browse the repository at this point in the history
  • Loading branch information
sandromodarelli authored and aexvir committed Mar 31, 2022
1 parent 17f90e5 commit 20173de
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ the most used values. So, technically there is a single required argument
| path | Path to the build context. Defaults to `.` | false | . |
| tag_with_latest | Tags the built image with additional latest tag | false | |
| target | Sets the target stage to build | false | |
| debug | Enables trace for entrypoint.sh | false | |

**Here is where it gets specific, as the optional arguments become required depending on the registry targeted**

Expand Down
3 changes: 3 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ inputs:
target:
description: Sets the target stage to build
required: false
debug:
description: Enables trace for entrypoint.sh
required: false
runs:
using: "docker"
image: "Dockerfile"
3 changes: 3 additions & 0 deletions entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
#!/busybox/sh
set -e pipefail
if [[ "$INPUT_DEBUG" == "true" ]]; then
set -o xtrace
fi

export REGISTRY=${INPUT_REGISTRY:-"docker.io"}
export IMAGE=${INPUT_IMAGE}
Expand Down

0 comments on commit 20173de

Please sign in to comment.