Skip to content

Commit

Permalink
Merge pull request #53 from tj-actions/chore/remove-support-for-versi…
Browse files Browse the repository at this point in the history
…on-input

Remove support for version input
  • Loading branch information
jackton1 authored Jul 5, 2021
2 parents 128f3d5 + 6dddfda commit da41744
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 8 deletions.
5 changes: 5 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@ FROM python:3.9-slim-buster

LABEL maintainer="Tonye Jack <jtonye@ymail.com>"

RUN python3 -m venv /venv && \
/venv/bin/pip3 install bandit

ENV PATH="/venv/bin:${PATH}"

COPY entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
ENTRYPOINT ["/entrypoint.sh"]
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
- name: Run bandit
uses: tj-actions/bandit@v4.1
with:
version: "1.7.0"
targets: | # or a single string "."
test_package
options: "-r"
Expand All @@ -40,7 +39,6 @@
| Input | type | required | default | description |
|:-------------:|:-----------:|:-------------:|:----------------------------:|:-------------:|
| version | `string` | `true` | `1.7.0` | Bandit version to be installed ([possible choices](https://github.com/PyCQA/bandit/tags)) |
| targets | `string[] or string` | `true` | `.` | Targets to run bandit checks |
| options | `string` | `true` | `-r` | Extra options ([possible choices](https://github.com/tj-actions/bandit/blob/main/action.yml#L13)) |

Expand Down
4 changes: 0 additions & 4 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@ name: Run bandit
description: A security linter from PyCQA
author: tj-actions
inputs:
version:
description: bandit version to be used
required: true
default: '1.7.0'
targets:
description: Module(s)/Package(s) to run bandit checks
required: true
Expand Down
2 changes: 0 additions & 2 deletions entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,5 @@

set -e

pip3 install bandit=="${INPUT_VERSION}". --no-cache-dir

# shellcheck disable=SC2086
bandit ${INPUT_OPTIONS} ${INPUT_TARGETS}

0 comments on commit da41744

Please # to comment.