https://github.com/charles-hsiao/packer-aws-ubuntu-ami-quorum
Packer for AWS AMI of Quorum nodes
https://github.com/charles-hsiao/packer-aws-ubuntu-ami-quorum
Last synced: about 2 months ago
JSON representation
Packer for AWS AMI of Quorum nodes
- Host: GitHub
- URL: https://github.com/charles-hsiao/packer-aws-ubuntu-ami-quorum
- Owner: charles-hsiao
- Created: 2019-09-15T10:31:42.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2020-01-28T07:46:18.000Z (over 5 years ago)
- Last Synced: 2025-06-25T02:44:54.793Z (4 months ago)
- Language: Shell
- Homepage:
- Size: 6.79 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# packer-aws-ubuntu-ami-quorum
## Installation
### 1. Set-up AWS credentials
Please reference: [Configuring the AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-getting-started.html)### 2. Install Packer: [Official Document](https://www.packer.io/intro/getting-started/install.html)
On Mac
```
brew install packer
```On Ubuntu
```
# Download the latest precompiled binary, get the suitable package here: https://www.packer.io/downloads.html
# ex: https://releases.hashicorp.com/packer/1.3.2/packer_1.3.2_linux_amd64.zip
wget ${PACKAGE_URL}
# ex: packer_1.3.2_linux_amd64.zip
unzip ${PACKER_ZIP_FILE}
```### 3. Install jq: [Official Download website](https://stedolan.github.io/jq/download/)
On Mac
```
brew install jq
```On Ubuntu
```
sudo apt-get install jq
```### 4. Install gnu-sed (Only on MacOS)
OSX's sed is BSD version. In order to align the sed command on Ubuntu GNU version, please install gnu-sed.
On MacOS
```
brew install gnu-sed
```## Usage( Build Ubuntu AMI)
### Use init-packer.sh to build AMI
init-packer.sh will check:
1. Upstream Ubuntu official AMI
2. Latest git commit hashCommand
```
bash init-packer.sh ${AWS_OWNER} ${AWS_REGION} ${UBUNTU_VERSION} ${AWS_VOLUME} ${AMI_ARCH}
```Example
```
bash init-packer.sh 100005588888 us-west-2 16.04 hvm:ebs-ssd amd64
```## Usage ( Build quorum nodes AMI )
### Use `build-packer.sh` to build AMI
Command
```
bash build-packer.sh ${AWS_REGION} ${UBUNTU_VERSION} ${AWS_VOLUME} ${AMI_ARCH} ${TEMPLATE}
```Example
```
bash build-packer.sh us-west-2 16.04 hvm:ebs-ssd amd64 templates/quorum_ubuntu_1604.json
```