diff options
author | Ava Hahn <a.hahn@f5.com> | 2024-04-22 13:26:34 +0100 |
---|---|---|
committer | avahahn <110854134+avahahn@users.noreply.github.com> | 2024-04-30 09:14:55 -0700 |
commit | db3cf3e42d93112278f5e86cca2c886627ef48b2 (patch) | |
tree | 3c546922404965b3fc7773d319388b9241f9896b /tools/unitctl/Dockerfile | |
parent | b26c119f4e535f617c9ffb10076f15c4ee54414d (diff) | |
download | unit-db3cf3e42d93112278f5e86cca2c886627ef48b2.tar.gz unit-db3cf3e42d93112278f5e86cca2c886627ef48b2.tar.bz2 |
tools: Add unitctl CLI
* Pull in entire unit-rust-sdk project
* not included: CLA, COC, License
* not included: duplicate openapi spec
* not included: CI workflows
* not included: changelog tooling
* not included: commitsar tooling
* not included: OpenAPI Web UI feature
* update links in unitctl manpage
* remove IDE configuration from .gitignore
* rename Containerfile.debian to Dockerfile
* simplify call to uname
* keep Readmes and Makefiles to 80 character lines
* outline specifically how to build unitctl
for any desired target, and where to then
find the binary for use
* remove a section on the vision of the CLI
which was superfluous given the state of
completeness of the code and its use in
unit
* remove out of date feature proposals from readme
* makefile: do not run when Rustup is not present
* bump mio version to latest
* generate openapi client library on demand
* generate-openapi only runs when not present
* generate-openapi now a dependency of binary build targets
* deleted autogenerated code
* reverted readme and Cargo document to autogenerated state
* add additional build requirement to Readme
Co-developed-by: Elijah Zupancic <e.zupancic@f5.com>
Signed-off-by: Elijah Zupancic <e.zupancic@f5.com>
Signed-off-by: Ava Hahn <a.hahn@f5.com>
Reviewed-by: Andrew Clayton <a.clayton@nginx.com> # non rust stuff
[ tools/cli => tools/unitctl and subject tweak - Andrew ]
Signed-off-by: Andrew Clayton <a.clayton@nginx.com>
Diffstat (limited to 'tools/unitctl/Dockerfile')
-rw-r--r-- | tools/unitctl/Dockerfile | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/tools/unitctl/Dockerfile b/tools/unitctl/Dockerfile new file mode 100644 index 00000000..812ce28c --- /dev/null +++ b/tools/unitctl/Dockerfile @@ -0,0 +1,37 @@ +FROM rust:slim-bullseye + +ADD https://unit.nginx.org/keys/nginx-keyring.gpg \ + /usr/share/keyrings/nginx-keyring.gpg + +RUN set -eux \ + export DEBIAN_FRONTEND=noninteractive; \ + echo 'fc27fd284cceb4bf6c8ac2118dbb5e834590836f8d6ba3944da0e0451cbadeca /usr/share/keyrings/nginx-keyring.gpg' |\ + sha256sum --check -; \ + chmod 0644 /usr/share/keyrings/nginx-keyring.gpg; \ + echo "deb [signed-by=/usr/share/keyrings/nginx-keyring.gpg] https://packages.nginx.org/unit/debian/ bullseye unit" > /etc/apt/sources.list.d/unit.list; \ + apt-get -qq update; \ + apt-get -qq upgrade --yes; \ + apt-get -qq install --yes --no-install-recommends --no-install-suggests \ + bsdmainutils \ + ca-certificates \ + git \ + gzip \ + grep \ + gawk \ + sed \ + make \ + rpm \ + pkg-config \ + libssl-dev \ + dpkg-dev \ + musl-dev \ + musl-tools \ + unit \ + gcc-aarch64-linux-gnu \ + libc6-dev-arm64-cross \ + gcc-x86-64-linux-gnu \ + libc6-dev-amd64-cross; \ + rustup target install x86_64-unknown-linux-gnu aarch64-unknown-linux-gnu x86_64-unknown-linux-musl; \ + cargo install --quiet cargo-deb cargo-generate-rpm; \ + rm -rf /var/lib/apt/lists/* /var/tmp/* /tmp/*; \ + git config --global --add safe.directory /project |