Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tuftool dockerfile #710

Merged
merged 5 commits into from
Nov 16, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ documentation, we greatly value feedback and contributions from our community.
Please read through this document before submitting any issues or pull requests to ensure we have all the necessary
information to effectively respond to your bug report or contribution.


## Security issue notifications
If you discover a potential security issue in this project we ask that you notify AWS/Amazon Security via our [vulnerability reporting page](http://aws.amazon.com/security/vulnerability-reporting/). Please do **not** create a public github issue.

Expand Down
7 changes: 7 additions & 0 deletions tuftool/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# syntax=docker/dockerfile:1

FROM rust:slim
RUN apt update && apt install -y openssl
RUN cargo install --force --locked tuftool
RUN mkdir /share
ENTRYPOINT ["tuftool"]
19 changes: 19 additions & 0 deletions tuftool/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,25 @@ tuftool download \

`tuftool` respects the `HTTPS_PROXY` and `NO_PROXY` environment variables.

## Container

You can build a simple container image to avoid needing to install the Rust toolchain and dependencies or your local machine.

To build the image use Docker or Finch (same argument syntax, just replace
`docker` for `finch`):

```shell
docker build -t tuftool .
```

To use tuftool, mount the host working directory to `/share`.

For example, to mount the current directory for `download` you would do something like:

```shell
docker run -it -v $(pwd):/share tuftool download "/share/some_directory" ...
```

## Testing

Unit tests are run in the usual manner: `cargo test`.
Expand Down