Generate blueprints #110
Workflow file for this run
This file contains 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
name: Generate blueprints | |
on: | |
workflow_dispatch: | |
defaults: | |
run: | |
shell: bash | |
jobs: | |
Generate-files: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout source code | |
uses: actions/checkout@v4 | |
- name: build docker image | |
working-directory: aws-rds/aws-modules-rds/tools | |
run: | | |
docker build -t scaffold:latest . | |
shell: bash | |
- name: Download latest Core module | |
run: | | |
curl -L https://github.com/dfds/terraform-aws-rds/archive/refs/tags/0.14.1.tar.gz > terraform-aws-rds.tar.gz | |
tar -xf terraform-aws-rds.tar.gz ; mv terraform-aws-rds-0.14.1 aws-modules-rds ; rm -rf terraform-aws-rds.tar.gz | |
ls -al . | |
shell: bash | |
- name: Run script | |
run: | | |
input=$(pwd)/aws-rds/aws-modules-rds/ | |
output=$(pwd)/aws-rds/basic/ | |
if [ -d $output ]; then | |
rm -rf $output | |
fi | |
mkdir -p $output | |
docker run -v $input:/input -v $output:/output scaffold:latest | |
shell: bash | |
- name: setup git config | |
run: | | |
# setup the username and email. I tend to use 'GitHub Actions Bot' with no email by default | |
git config user.name "GitHub Actions Bot" | |
git config user.email "<>" | |
- name: commit | |
run: | | |
git status | |
# Stage the file, commit and push | |
git add $(pwd)/aws-rds/basic/ | |
git commit -m "update blueprints for RDS module" | |
git push |