forked from Scaffold-Stark/scaffold-stark-2
-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c2afed3
commit 84d45c6
Showing
4 changed files
with
13 additions
and
19 deletions.
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 |
---|---|---|
|
@@ -3,16 +3,15 @@ run-name: Build and deploy number ${{github.run_number}} started by @${{ github. | |
|
||
on: | ||
pull_request: | ||
types: [ closed ] | ||
branches: [ main ] | ||
types: [closed] | ||
branches: [main] | ||
paths: | ||
- "packages/nextjs/**" | ||
|
||
env: | ||
REGION: us-east-1 | ||
|
||
jobs: | ||
|
||
build: | ||
runs-on: ubuntu-22.04 | ||
outputs: | ||
|
@@ -21,7 +20,6 @@ jobs: | |
TAG: ${{ steps.bump-version.outputs.NEW_VERSION }} | ||
|
||
steps: | ||
|
||
- name: Checkout Files | ||
uses: actions/checkout@v4 | ||
with: | ||
|
@@ -102,7 +100,6 @@ jobs: | |
git push origin HEAD:$GITHUB_REF_NAME --follow-tags | ||
deploy: | ||
|
||
runs-on: ubuntu-22.04 | ||
needs: build | ||
if: ${{ success() }} | ||
|
@@ -112,17 +109,15 @@ jobs: | |
TAG: ${{ needs.build.outputs.TAG }} | ||
|
||
steps: | ||
|
||
- name: Setup SSH | ||
uses: webfactory/[email protected] | ||
with: | ||
ssh-private-key: ${{ secrets.PRIVATE_KEY }} | ||
|
||
- name: Add server to known hosts | ||
run: | | ||
mkdir -p ~/.ssh | ||
ssh-keyscan -H ${{ secrets.REMOTE_SERVER_ADDRESS }} >> ~/.ssh/known_hosts | ||
- name: Create container from ECR | ||
if: success() | ||
|
@@ -187,21 +182,20 @@ jobs: | |
nginx: | ||
runs-on: ubuntu-22.04 | ||
needs: [build,deploy] | ||
needs: [build, deploy] | ||
if: ${{ success() }} | ||
|
||
steps: | ||
|
||
- name: Setup SSH | ||
uses: webfactory/[email protected] | ||
with: | ||
ssh-private-key: ${{ secrets.PRIVATE_KEY }} | ||
|
||
- name: Add server to known hosts | ||
run: | | ||
mkdir -p ~/.ssh | ||
ssh-keyscan -H ${{ secrets.REMOTE_SERVER_ADDRESS }} >> ~/.ssh/known_hosts | ||
- name: Setup nginx | ||
if: success() | ||
run: | | ||
|
@@ -269,4 +263,4 @@ jobs: | |
channel-id: ${{ secrets.SLACK_CHANNEL_ID }} | ||
slack-message: "GitHub build result: ${{ job.status }}\nRepository Name: ${{ github.repository }}\n${{ github.event.pull_request.html_url || github.event.head_commit.url }}" | ||
env: | ||
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} | ||
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} |
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 |
---|---|---|
|
@@ -7,4 +7,3 @@ module.exports = { | |
return plugin; | ||
} | ||
}; | ||
|
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
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