Skip to content

Commit

Permalink
Merge pull request #76 from yeha98555/ci/remove-test-temporary
Browse files Browse the repository at this point in the history
ci: Remove GitHub Actions test temporarily
  • Loading branch information
yeha98555 committed Jun 18, 2023
2 parents de9cbdd + fa26079 commit c424482
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 93 deletions.
45 changes: 0 additions & 45 deletions .github/workflows/aws.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,39 +6,7 @@ on:
- main

jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
uses: actions/checkout@v3

- name: Use Node.js
uses: actions/setup-node@v3

- name: Install Dependencies
run: yarn install

- name: Copy .env.test to .env
run: cp .env.test .env

- name: Run tests
run: yarn test

- name: Rollback
if: ${{ failure() && github.event_name == 'push' }}
run: |
git checkout ${{ github.sha }}^1
git push --force
# Post a comment on the pull request
curl -X POST \
-H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
-H "Content-Type: application/json" \
-d '{"body": "The CI job has failed. The last commit has been rolled back."}' \
"https://api.github.com/repos/${GITHUB_REPOSITORY}/issues/${{ github.event.pull_request.number }}/comments"
deploy:
needs: test
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
Expand Down Expand Up @@ -68,16 +36,3 @@ jobs:
region: ${{ secrets.AWS_REGION }}
deployment_package: deploy.zip
use_existing_version_if_available: true

- name: Rollback
if: ${{ failure() && github.event_name == 'push' }}
run: |
git checkout ${{ github.sha }}^1
git push --force
# Post a comment on the pull request
curl -X POST \
-H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
-H "Content-Type: application/json" \
-d '{"body": "The CI job has failed. The last commit has been rolled back."}' \
"https://api.github.com/repos/${GITHUB_REPOSITORY}/issues/${{ github.event.pull_request.number }}/comments"
48 changes: 0 additions & 48 deletions .github/workflows/render.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,42 +7,7 @@ on:
- develop

jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16.x]
steps:
- name: Checkout Repo
uses: actions/checkout@v3

- name: Use Node.js
uses: actions/setup-node@v3

- name: Install Dependencies
run: yarn install

- name: Copy .env.test to .env
run: cp .env.test .env

- name: Run tests
run: yarn test

- name: Rollback
if: ${{ failure() && github.event_name == 'push' }}
run: |
git checkout ${{ github.sha }}^1
git push --force
# Post a comment on the pull request
curl -X POST \
-H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
-H "Content-Type: application/json" \
-d '{"body": "The CI job has failed. The last commit has been rolled back."}' \
"https://api.github.com/repos/${GITHUB_REPOSITORY}/issues/${{ github.event.pull_request.number }}/comments"
deploy:
needs: test
runs-on: ubuntu-latest
strategy:
matrix:
Expand All @@ -65,16 +30,3 @@ jobs:
with:
service-id: ${{ secrets.SERVICE_ID_DEVELOP }} # Can be found as part of the Deploy Hook
api-key: ${{ secrets.RENDER_API_KEY }} # Create your API key in Render Dashboard > Account Settings

- name: Rollback
if: ${{ failure() && github.event_name == 'push' }}
run: |
git checkout ${{ github.sha }}^1
git push --force
# Post a comment on the pull request
curl -X POST \
-H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
-H "Content-Type: application/json" \
-d '{"body": "The CI job has failed. The last commit has been rolled back."}' \
"https://api.github.com/repos/${GITHUB_REPOSITORY}/issues/${{ github.event.pull_request.number }}/comments"

0 comments on commit c424482

Please sign in to comment.