-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
create deployment github action workflow
- Loading branch information
1 parent
3e06ff7
commit 9a02f28
Showing
2 changed files
with
38 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# here we define a workflow with two jobs | ||
# the two jobs will run in parallel | ||
# this may not be ideal | ||
# typically you would want your tests to pass before | ||
# deploying the code | ||
name: Deploy Project | ||
on: push | ||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Get code from repository | ||
uses: actions/[email protected] | ||
- name: Install NodeJS | ||
uses: actions/[email protected] | ||
with: | ||
node-version: 18 | ||
- name: Install dependencies | ||
run: npm ci | ||
- name: Run tests | ||
run: npm test | ||
deploy: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Get code from repository | ||
uses: actions/[email protected] | ||
- name: Install NodeJS | ||
uses: actions/[email protected] | ||
with: | ||
node-version: 18 | ||
- name: Install dependencies | ||
run: npm ci | ||
- name: Build project | ||
run: npm run build | ||
- name: Deploy | ||
run: echo "Deploying to AWS" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters