From 56fcef83b8a064daf6a4162877a1834ca9a110db Mon Sep 17 00:00:00 2001 From: Agustin Diaz Date: Wed, 1 Mar 2023 12:52:15 -0300 Subject: [PATCH 1/3] test --- function/lambda_function.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/function/lambda_function.py b/function/lambda_function.py index 2809ce09b..96a4f6afa 100644 --- a/function/lambda_function.py +++ b/function/lambda_function.py @@ -8,7 +8,7 @@ def lambda_handler(event, context): Returns: string: greeting response """ - print('Starting functions\n---------------------------------------------' + print('Starting functions\n---------------------------------------------') if event["input"] == "Hello": From f997955b8f19e39d592ee0e531fc23ee543ae707 Mon Sep 17 00:00:00 2001 From: Agustin Diaz Date: Thu, 2 Mar 2023 14:52:58 -0300 Subject: [PATCH 2/3] Test --- .github/workflows/action.yaml | 35 +++++++++++++++++++++++++++++++++++ .github/workflows/init.yaml | 12 ------------ 2 files changed, 35 insertions(+), 12 deletions(-) create mode 100644 .github/workflows/action.yaml delete mode 100644 .github/workflows/init.yaml diff --git a/.github/workflows/action.yaml b/.github/workflows/action.yaml new file mode 100644 index 000000000..46e344c49 --- /dev/null +++ b/.github/workflows/action.yaml @@ -0,0 +1,35 @@ +name: Deploy function to lambda + +on: + push: + branches: + - main + +jobs: + build: + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v2 + + - name: Set up python + uses: actions/setup-python@v2 + with: + python-version: 3.8 + + - name: Install Libraries + run: | + cd function + python -m pip install --upgrade pip + if [ -f requirements.txt ]; then pip install -r requirements.txt -t .;fi + + - name: Create zip bundle + run: | + cd function + zip -r ../${{ github.sha }}.zip . + + - name: Archive Artifact + uses: actions/upload-artifact@v2 + with: + name: zipped-bundle + path: ${{ github.sha }}.zip diff --git a/.github/workflows/init.yaml b/.github/workflows/init.yaml deleted file mode 100644 index 95482ee7a..000000000 --- a/.github/workflows/init.yaml +++ /dev/null @@ -1,12 +0,0 @@ -# This is a placeholder so actions won't default to a getting started page - -name: Placeholder - -on: push - -jobs: - init: - runs-on: ubuntu-latest - steps: - - name: Run a one-line script - run: echo Hello, world! From 0748948331d445a5a350a9143c81f3330e219c51 Mon Sep 17 00:00:00 2001 From: Agustin Diaz Date: Thu, 2 Mar 2023 15:36:48 -0300 Subject: [PATCH 3/3] rollbAK --- function/lambda_function.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/function/lambda_function.py b/function/lambda_function.py index 96a4f6afa..2809ce09b 100644 --- a/function/lambda_function.py +++ b/function/lambda_function.py @@ -8,7 +8,7 @@ def lambda_handler(event, context): Returns: string: greeting response """ - print('Starting functions\n---------------------------------------------') + print('Starting functions\n---------------------------------------------' if event["input"] == "Hello":