Skip to content

Manually update puppeteer sharp dependencies #84

Manually update puppeteer sharp dependencies

Manually update puppeteer sharp dependencies #84

name: Validate Nuget Package Docker Build
on: [pull_request]
jobs:
lambda-docker-build-dotnet:
strategy:
fail-fast: false
matrix:
version: [6, 7, 8]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v3
with:
dotnet-version: ${{ matrix.version }}.x
- run: dotnet tool install -g Amazon.Lambda.Tools
- name: Build and package nuget
uses: cake-build/cake-action@v1
with:
cake-version: 1.3.0
- name: Build and package lambda
working-directory: ./sample/SampleLambda-dotnet${{ matrix.version }}
run: dotnet lambda package SampleLambda --profile default --region us-west-1
- name: Run docker
run: docker run --detach -p 9000:8080 samplelambda-dotnet${{ matrix.version }}:latest
- name: Test function
run: |
curl -XPOST "http://localhost:9000/2015-03-31/functions/function/invocations" -d '{}' -o /tmp/lambda_result.txt
if $(grep -q iVB /tmp/lambda_result.txt); then
echo "SUCCESS: The lambda rendered a PNG"
exit 0
else
echo "FAILURE: The lambda did not return expected png value starting with iVB"
cat /tmp/lambda_result.txt
exit 1
fi
shell: bash