Created
April 21, 2021 17:39
-
-
Save tashian/5f1bd171e30dbc8692f1f47d8e7a3460 to your computer and use it in GitHub Desktop.
Build step-ca on an AWS VM
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
### Basic build environment ####### | |
apt update | |
apt install -y make gcc ack libpcsclite-dev pkg-config unzip debhelper | |
apt upgrade -y | |
cd /root | |
## Install golang | |
GO_VERSION=1.16.3 | |
curl -LO https://golang.org/dl/go$GO_VERSION.linux-amd64.tar.gz | |
tar -C /usr/local -xzf go$GO_VERSION.linux-amd64.tar.gz | |
cat<<EOF >> /etc/profile | |
export PATH=\$PATH:/usr/local/go/bin | |
EOF | |
# Install AWS CLI | |
curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" | |
unzip awscliv2.zip | |
./aws/install | |
### On first login: | |
cat<<EOF >> .profile | |
export PATH=\$PATH:\$HOME/go/bin | |
EOF | |
git clone https://github.com/smallstep/cli | |
git clone https://github.com/smallstep/certificates |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment