diff options
Diffstat (limited to 'share/hoarder/awscli2/unix/linux')
-rw-r--r-- | share/hoarder/awscli2/unix/linux/files/awscli2.asc | 29 | ||||
-rwxr-xr-x | share/hoarder/awscli2/unix/linux/install | 45 |
2 files changed, 74 insertions, 0 deletions
diff --git a/share/hoarder/awscli2/unix/linux/files/awscli2.asc b/share/hoarder/awscli2/unix/linux/files/awscli2.asc new file mode 100644 index 0000000..5951848 --- /dev/null +++ b/share/hoarder/awscli2/unix/linux/files/awscli2.asc @@ -0,0 +1,29 @@ +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mQINBF2Cr7UBEADJZHcgusOJl7ENSyumXh85z0TRV0xJorM2B/JL0kHOyigQluUG +ZMLhENaG0bYatdrKP+3H91lvK050pXwnO/R7fB/FSTouki4ciIx5OuLlnJZIxSzx +PqGl0mkxImLNbGWoi6Lto0LYxqHN2iQtzlwTVmq9733zd3XfcXrZ3+LblHAgEt5G +TfNxEKJ8soPLyWmwDH6HWCnjZ/aIQRBTIQ05uVeEoYxSh6wOai7ss/KveoSNBbYz +gbdzoqI2Y8cgH2nbfgp3DSasaLZEdCSsIsK1u05CinE7k2qZ7KgKAUIcT/cR/grk +C6VwsnDU0OUCideXcQ8WeHutqvgZH1JgKDbznoIzeQHJD238GEu+eKhRHcz8/jeG +94zkcgJOz3KbZGYMiTh277Fvj9zzvZsbMBCedV1BTg3TqgvdX4bdkhf5cH+7NtWO +lrFj6UwAsGukBTAOxC0l/dnSmZhJ7Z1KmEWilro/gOrjtOxqRQutlIqG22TaqoPG +fYVN+en3Zwbt97kcgZDwqbuykNt64oZWc4XKCa3mprEGC3IbJTBFqglXmZ7l9ywG +EEUJYOlb2XrSuPWml39beWdKM8kzr1OjnlOm6+lpTRCBfo0wa9F8YZRhHPAkwKkX +XDeOGpWRj4ohOx0d2GWkyV5xyN14p2tQOCdOODmz80yUTgRpPVQUtOEhXQARAQAB +tCFBV1MgQ0xJIFRlYW0gPGF3cy1jbGlAYW1hem9uLmNvbT6JAlQEEwEIAD4WIQT7 +Xbd/1cEYuAURraimMQrMRnJHXAUCXYKvtQIbAwUJB4TOAAULCQgHAgYVCgkICwIE +FgIDAQIeAQIXgAAKCRCmMQrMRnJHXJIXEAChLUIkg80uPUkGjE3jejvQSA1aWuAM +yzy6fdpdlRUz6M6nmsUhOExjVIvibEJpzK5mhuSZ4lb0vJ2ZUPgCv4zs2nBd7BGJ +MxKiWgBReGvTdqZ0SzyYH4PYCJSE732x/Fw9hfnh1dMTXNcrQXzwOmmFNNegG0Ox +au+VnpcR5Kz3smiTrIwZbRudo1ijhCYPQ7t5CMp9kjC6bObvy1hSIg2xNbMAN/Do +ikebAl36uA6Y/Uczjj3GxZW4ZWeFirMidKbtqvUz2y0UFszobjiBSqZZHCreC34B +hw9bFNpuWC/0SrXgohdsc6vK50pDGdV5kM2qo9tMQ/izsAwTh/d/GzZv8H4lV9eO +tEis+EpR497PaxKKh9tJf0N6Q1YLRHof5xePZtOIlS3gfvsH5hXA3HJ9yIxb8T0H +QYmVr3aIUes20i6meI3fuV36VFupwfrTKaL7VXnsrK2fq5cRvyJLNzXucg0WAjPF +RrAGLzY7nP1xeg1a0aeP+pdsqjqlPJom8OCWc1+6DWbg0jsC74WoesAqgBItODMB +rsal1y/q+bPzpsnWjzHV8+1/EtZmSc8ZUGSJOPkfC7hObnfkl18h+1QtKTjZme4d +H17gsBJr+opwJw/Zio2LMjQBOqlm3K1A4zFTh7wBC7He6KPQea1p2XAMgtvATtNe +YLZATHZKTJyiqA== +=vYOk +-----END PGP PUBLIC KEY BLOCK----- diff --git a/share/hoarder/awscli2/unix/linux/install b/share/hoarder/awscli2/unix/linux/install new file mode 100755 index 0000000..edb9cfa --- /dev/null +++ b/share/hoarder/awscli2/unix/linux/install @@ -0,0 +1,45 @@ +#!/usr/bin/env sh +# +# Install AWS Command Line v2 +# + +# Parameters +SHARE="$1" +LIB="$2" + +# Include basic functions +. $LIB/trashman/functions || exit 1 + +# Requirements +trashman_require wget + +# Additional parameters +FILE="awscli-exe-linux-`uname -m`.zip" +URL="https://awscli.amazonaws.com/$FILE" +WORK="`mktemp -d`" || exit 1 + +# Download +wget "$URL" -O $WORK/$FILE || exit 1 + +# Verify +gpg --homedir $WORK/.gnupg --import $SHARE/awscli2/unix/linux/files/awscli2.asc || exit 1 +gpg --homedir $WORK/.gnupg --verify $WORK/$FILE || exit 1 +rm -rf $WORK/.gnupg || exit 1 + +# Unpack +unzip $WORK/$FILE -d $WORK || exit 1 + +# Prepare +mkdir -p $HOME/.local/share || exit 1 +cd $HOME/.local/share || exit 1 +rm -rf aws-cli || exit 1 + +# Install +$WORK/aws/install -i $HOME/.local/share/aws-cli -b $HOME/.local/bin || exit 1 + +# Cleanup +rm -rf $WORK || exit 1 + +# Inform +trashman_installed at $HOME/.local/share/aws-cli +trashman_run_with $HOME/.local/bin/aws |