From 3b66ab1d54afedf2af04f5534fad437debcc7bcb Mon Sep 17 00:00:00 2001 From: David Arnold <10138997+djaboxx@users.noreply.github.com> Date: Wed, 14 Aug 2024 12:25:26 -0700 Subject: [PATCH] Create workflow.yaml.tpl --- workflow.yaml.tpl | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 workflow.yaml.tpl diff --git a/workflow.yaml.tpl b/workflow.yaml.tpl new file mode 100644 index 0000000..5fa3d80 --- /dev/null +++ b/workflow.yaml.tpl @@ -0,0 +1,33 @@ +# This is a basic workflow to help you get started with Actions +name: S3 Upload + +on: + push: + branches: [ "main" ] + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +# A workflow run is made up of one or more jobs that can run sequentially or in parallel +jobs: + # This workflow contains a single job called "build" + build: + # The type of runner that the job will run on + runs-on: [ ${repo_name} ] + env: + AWS_SECRET_ACCESS_KEY: "${{ secrets.AWS_SECRET_ACCESS_KEY }}" + AWS_ACCESS_KEY_ID: "${{ vars.AWS_ACCESS_KEY_ID }}" + AWS_SESSION_TOKEN: "${{ secrets.AWS_SESSION_TOKEN }}" + + + # Steps represent a sequence of tasks that will be executed as part of the job + steps: + # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it + - uses: actions/checkout@v3 + + - uses: CSVD/gh-actions-setup-node@v3 + with: + node-version: 16 + + - run: | + zip ${repo_name}.zip * + aws s3 cp ${repo_name}.zip s3://${bucket_name}