@@ -46,16 +46,67 @@ jobs:
4646 # AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
4747```
4848
49- ## Specify a particular version
49+ ## Configuration
50+
51+ | ` with: ` | Description | Required | Default |
52+ | --- | --- | --- | --- |
53+ | ` args ` | Arguments passed to ` serverless ` | ` true ` |
54+ | ` aws-credentials ` | Whether to use credentials stored in the local environment (` AWS_ACCESS_KEY_ID ` , ` AWS_SECRET_ACCESS_KEY ` ) | ` false ` | |
55+ | ` entrypoint ` | Serverless entrypoint. For example: ` /bin/sh ` | ` false ` | ` /entrypoint.sh ` |
56+ | ` install-packages ` | Comma-separated list of packages to install prior to running ` serverless {args} ` | ` false ` | |
57+ | ` serverless-version ` | Version of the Serverless Framework to use | ` false ` | ` latest ` |
58+ | ` working-directory ` | Folder where your configuration is located | ` false ` | ` . ` |
59+
60+ ## Examples
61+
62+ ### Minimal example
63+ ``` yaml
64+ - name : Deploy
65+ uses : serverless/github-action@v3.2
66+ with :
67+ args : deploy
68+ ` ` `
69+
70+ ### Use local credentials
71+ ` ` ` yaml
72+ - name : Deploy with local credentials
73+ uses : serverless/github-action@v3.2
74+ with :
75+ aws-credentials : true # or yes
76+ args : deploy
77+ env :
78+ AWS_ACCESS_KEY_ID : ${{ secrets.AWS_ACCESS_KEY_ID }}
79+ AWS_SECRET_ACCESS_KEY : ${{ secrets.AWS_SECRET_ACCESS_KEY }}
80+ ` ` `
81+
82+ ### Use a different entrypoint
83+ ` ` ` yaml
84+ - name : Deploy with a different entrypoint
85+ uses : serverless/github-action@v3.2
86+ with :
87+ entrypoint : /bin/sh
88+ args : -c "serverless deploy"
89+ ` ` `
90+
91+ ### Install packages and deploy
92+ ` ` ` yaml
93+ - name : Install packages and deploy
94+ uses : serverless/github-action@v3.2
95+ with :
96+ install-packages : serverless-offline,serverless-prune-plugin
97+ args : deploy
98+ ` ` `
99+
100+ ### Use a particular Serverless Framework CLI version
50101` ` ` yaml
51- - name : Deploy with a particular version
102+ - name : Deploy using a particular version of serverless
52103 uses : serverless/github-action@v3.2
53104 with :
54- serverless-version : 3
105+ serverless-version : 2
55106 args : deploy
56107` ` `
57108
58- ## Change your working directory
109+ ### Change your working directory
59110` ` ` yaml
60111 - name : Deploy from a particular working directory
61112 uses : serverless/github-action@v3.2
0 commit comments