📀 Build AMI - dvsa/des-workflow-actions GitHub Wiki
Description
This workflow automates the process of building an Amazon Machine Image (AMI). It starts an EC2 runner, checks out the relevant repositories (Packer and Puppet), configures AWS credentials, and then uses Packer to validate and build the AMI based on the provided input parameters. After the AMI is built, it stops the EC2 runner.
Workflow Triggers
On Workflow Call
This workflow is called from the des-packer repository when the workflow is manually run.
Environment Variables
Name | Description |
---|---|
PACKER_LOG | Whether to enable detailed logging |
BUILD_ID | Unique ID for the GitHub Actions workflow run |
ENVIRONMENT | Indicates the environment where the AMI is being built |
NODETYPE | The type of AMI to build |
VOLUME_SIZE | Specifies the size of the disk volume for the AMI |
SKIP_AMI | Whether to skip the AMI creation |
HOME | Path to the home directory |
Inputs
Name | Description | Options |
---|---|---|
puppet-branch | The puppet branch to use to build an AMI against | N/A |
packer-branch | The packer branch to use to build an AMI against | N/A |
node-type | The type of AMI to build | bastion | sonarqube | squidnat | dbaclient | dbbastion | gha-runner |
volume-size | Specifies the size of the disk volume for the AMI | N/A |
packer-log | Whether to enable detailed logging | N/A |
skip-ami-creation | Whether to skip the AMI creation | true | false |
Notes
- GitHub Actions secrets required: AWS_ACCOUNT_ID, GH_TOKEN, MES_DEPLOYER_KEY, & PUPPET_REPO_KEY