-
Notifications
You must be signed in to change notification settings - Fork 1
37 lines (35 loc) · 1.16 KB
/
publish-configuration.yaml
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
name: Bundle, lint and publish configuration files to S3 bucket
on:
push:
branches:
- main
jobs:
deploy:
name: Bundle, lint and publish
runs-on: ubuntu-latest
environment: prod
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v1
with:
bun-version: "1.0.0"
- name: Install packages 📦
run: bun install
- name: Lint the config files 🧹
run: bun lint
- name: Build the config files 🍞
run: bun dle
- uses: actions/upload-artifact@v3
with:
name: oazo-configuration
path: ${{ vars.SOURCE_CONFIGURATION_FILE_PATH }}
if-no-files-found: error
- name: Copy a file to AWS S3 bucket 🪣
uses: prewk/s3-cp-action@v2
with:
aws_access_key_id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws_secret_access_key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws_region: ${{ vars.AWS_DEFAULT_REGION }}
source: ${{ vars.SOURCE_CONFIGURATION_FILE_PATH }}
dest: "s3://${{ vars.AWS_BUCKET_NAME }}/${{ vars.DESTINATION_CONFIGURATION_FILE_PATH }}"
flags: --acl public-read --recursive