-
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.
chore: changed CI/CD to github actions
- Loading branch information
Showing
6 changed files
with
113 additions
and
63 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 |
---|---|---|
@@ -0,0 +1,39 @@ | ||
name: Run Docker image build and tag | ||
|
||
on: workflow_dispatch | ||
|
||
# on: | ||
# push: | ||
# tags: | ||
# - '*' | ||
# branches: | ||
# - master | ||
# - develop | ||
# - hotfix/* | ||
# - release/* | ||
|
||
jobs: | ||
run: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
- name: Set up QEMU | ||
uses: docker/setup-qemu-action@v3 | ||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
- name: Login to Docker Hub | ||
uses: docker/login-action@v3 | ||
with: | ||
username: ${{ secrets.DOCKERHUB_USERNAME }} | ||
password: ${{ secrets.DOCKERHUB_TOKEN }} | ||
- name: Create image tag | ||
env: | ||
IMAGE_TAG: '${{ github.ref_name }}' | ||
run: echo "IMAGE_TAG=${IMAGE_TAG/\//-}" >> $GITHUB_ENV | ||
- name: Build and push | ||
uses: docker/build-push-action@v5 | ||
with: | ||
context: . | ||
push: true | ||
tags: heseya/roby-storefront:${{ env.IMAGE_TAG }} |
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,29 @@ | ||
name: Run Linters | ||
on: [push, pull_request] | ||
jobs: | ||
eslint: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
- name: Set up Node 18 | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 18 | ||
- name: Install dependencies | ||
run: yarn install | ||
- name: Run tests and collect coverage | ||
run: yarn lint:eslint | ||
vue-tsc: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
- name: Set up Node 18 | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 18 | ||
- name: Install dependencies | ||
run: yarn install | ||
- name: Run tests and collect coverage | ||
run: yarn lint:vue |
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,21 @@ | ||
name: Trigger external actions | ||
on: | ||
push: | ||
branches: | ||
- '*' | ||
tags: | ||
- '*' | ||
jobs: | ||
run: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
- name: Create image tag | ||
env: | ||
IMAGE_NAME: '${{ github.ref_name }}' | ||
run: echo "IMAGE_NAME=${IMAGE_NAME/\//-}" >> $GITHUB_ENV | ||
- name: curl | ||
uses: enflo/curl-action@master | ||
with: | ||
curl: -X POST -F token=${{ secrets.TRIGGER_TOKEN }} -F ref=main -F variables[IMAGE_NAME]=${{ env.IMAGE_NAME }} -F variables[CI_BRANCH]=${{ github.ref_name }} ${{ vars.TRIGGER_URL }} |
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,18 @@ | ||
name: Run tests and collect code coverage | ||
on: [push, pull_request] | ||
jobs: | ||
run: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
- name: Set up Node 18 | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 18 | ||
- name: Install dependencies | ||
run: yarn install | ||
- name: Run tests | ||
run: yarn test:unit | ||
# - name: Upload coverage to Codecov | ||
# uses: codecov/codecov-action@v3 |
This file was deleted.
Oops, something went wrong.
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