-
Notifications
You must be signed in to change notification settings - Fork 23
49 lines (39 loc) · 1.13 KB
/
s3_deploy.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: Deploy to S3
on:
push:
branches:
- main
jobs:
build:
if: "${{ contains(github.event.head_commit.message, 'chore(main): release') }}"
runs-on: ubuntu-latest
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
steps:
- uses: actions/checkout@v3
- uses: subosito/flutter-action@v2
with:
flutter-version: '3.10.5'
channel: stable
- name: Install Dependencies
run: flutter pub get
working-directory: ./example
- name: Run static analysis
run: flutter analyze .
- name: Run tests
run: flutter test
- name: Build Web
run: flutter build web
working-directory: ./example
- name: Deploy
uses: reggionick/s3-deploy@v3
with:
folder: example/build/web
bucket: ${{ secrets.S3_BUCKET }}
bucket-region: ${{ secrets.S3_BUCKET_REGION }}
invalidation: /
delete-removed: true
no-cache: true
private: true
filesToInclude: ".*/*,*/*,**"