Skip to content
This repository has been archived by the owner on Aug 25, 2024. It is now read-only.

Merge pull request #165 from jongwooo/dependabot/npm_and_yarn/eslint-… #487

Merge pull request #165 from jongwooo/dependabot/npm_and_yarn/eslint-…

Merge pull request #165 from jongwooo/dependabot/npm_and_yarn/eslint-… #487

Workflow file for this run

name: Deploy to Lambda
on:
push:
branches: [ main ]
jobs:
deploy:
name: Build and Deploy Lambda
strategy:
matrix:
node-version: [ 16.x ]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: npm
- name: Install dependencies
run: npm ci
- name: Run npm build
run: npm run build --if-present
- name: zip
uses: montudor/[email protected]
with:
args: zip -qq -r ./bundle.zip ./
- name: Default deploy
uses: appleboy/lambda-action@master
with:
aws_access_key_id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws_secret_access_key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws_region: ap-northeast-2
function_name: chatbot
zip_file: bundle.zip
- name: Notify the deploy results with Slack
uses: 8398a7/action-slack@v3
with:
status: ${{ job.status }}
author_name: Deploy to Lambda
fields: repo, message, commit, author, eventName, workflow
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_DEPLOY_WEBHOOK_URL }}
if: always()