mirror of
https://github.com/meysamhadeli/booking-microservices.git
synced 2026-05-03 11:21:53 +08:00
commit
4ab2c1700e
5
.github/release-drafter.yml
vendored
5
.github/release-drafter.yml
vendored
@ -8,11 +8,12 @@
|
|||||||
# This release drafter follows the conventions from https://keepachangelog.com, https://common-changelog.org/
|
# This release drafter follows the conventions from https://keepachangelog.com, https://common-changelog.org/
|
||||||
# https://www.conventionalcommits.org
|
# https://www.conventionalcommits.org
|
||||||
|
|
||||||
|
name-template: 'v$RESOLVED_VERSION'
|
||||||
|
tag-template: 'v$RESOLVED_VERSION'
|
||||||
template: |
|
template: |
|
||||||
## What Changed 👀
|
## What Changed 👀
|
||||||
$CHANGES
|
$CHANGES
|
||||||
|
**Full Changelog**: https://github.com/$OWNER/$REPOSITORY/compare/$PREVIOUS_TAG...v$RESOLVED_VERSION
|
||||||
categories:
|
categories:
|
||||||
- title: 🚀 Features
|
- title: 🚀 Features
|
||||||
labels:
|
labels:
|
||||||
|
|||||||
13
.github/workflows/ci.yml
vendored
13
.github/workflows/ci.yml
vendored
@ -16,6 +16,7 @@ jobs:
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
|
|
||||||
- name: Setup .NET
|
- name: Setup .NET
|
||||||
uses: actions/setup-dotnet@v2
|
uses: actions/setup-dotnet@v2
|
||||||
with:
|
with:
|
||||||
@ -27,6 +28,7 @@ jobs:
|
|||||||
key: ${{ runner.os }}-dotnet-nuget
|
key: ${{ runner.os }}-dotnet-nuget
|
||||||
path: ~/.nuget/packages
|
path: ~/.nuget/packages
|
||||||
|
|
||||||
|
|
||||||
- name: Restore dependencies
|
- name: Restore dependencies
|
||||||
run: dotnet restore
|
run: dotnet restore
|
||||||
|
|
||||||
@ -43,17 +45,18 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
|
||||||
- name: Login to DockerHub
|
- name: Login to DockerHub
|
||||||
if: github.ref == 'refs/heads/main'
|
|
||||||
uses: docker/login-action@v2
|
uses: docker/login-action@v2
|
||||||
|
if: ${{ github.ref == 'refs/heads/main' && success() && steps.last_release.outputs.tag_name != '' }}
|
||||||
with:
|
with:
|
||||||
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
||||||
password: ${{ secrets.DOCKERHUB_PASSWORD }}
|
password: ${{ secrets.DOCKERHUB_PASSWORD }}
|
||||||
|
|
||||||
##ref: https://docs.docker.com/language/golang/configure-ci-cd/
|
##ref: https://docs.docker.com/language/golang/configure-ci-cd/
|
||||||
##ref: https://event-driven.io/en/how_to_buid_and_push_docker_image_with_github_actions
|
##ref: https://event-driven.io/en/how_to_buid_and_push_docker_image_with_github_actions
|
||||||
- name: Build Docker Image
|
- name: Build Docker Image
|
||||||
if: github.ref == 'refs/heads/main'
|
if: ${{ github.ref == 'refs/heads/main' && success() && steps.last_release.outputs.tag_name != '' }}
|
||||||
run: |
|
run: |
|
||||||
docker build -t ${{ secrets.DOCKERHUB_USERNAME }}/booking-microservices-flight:${{ steps.last_release.outputs.tag_name }} -f "${{ github.workspace }}/src/Services/Flight/Dockerfile" .
|
docker build -t ${{ secrets.DOCKERHUB_USERNAME }}/booking-microservices-flight:${{ steps.last_release.outputs.tag_name }} -f "${{ github.workspace }}/src/Services/Flight/Dockerfile" .
|
||||||
docker build -t ${{ secrets.DOCKERHUB_USERNAME }}/booking-microservices-identity:${{ steps.last_release.outputs.tag_name }} -f "${{ github.workspace }}/src/Services/Identity/Dockerfile" .
|
docker build -t ${{ secrets.DOCKERHUB_USERNAME }}/booking-microservices-identity:${{ steps.last_release.outputs.tag_name }} -f "${{ github.workspace }}/src/Services/Identity/Dockerfile" .
|
||||||
@ -61,7 +64,7 @@ jobs:
|
|||||||
docker build -t ${{ secrets.DOCKERHUB_USERNAME }}/booking-microservices-booking:${{ steps.last_release.outputs.tag_name }} -f "${{ github.workspace }}/src/Services/Booking/Dockerfile" .
|
docker build -t ${{ secrets.DOCKERHUB_USERNAME }}/booking-microservices-booking:${{ steps.last_release.outputs.tag_name }} -f "${{ github.workspace }}/src/Services/Booking/Dockerfile" .
|
||||||
|
|
||||||
- name: Publish Docker Image
|
- name: Publish Docker Image
|
||||||
if: github.ref == 'refs/heads/main'
|
if: ${{ github.ref == 'refs/heads/main' && success() && steps.last_release.outputs.tag_name != '' }}
|
||||||
run: |
|
run: |
|
||||||
docker push ${{ secrets.DOCKERHUB_USERNAME }}/booking-microservices-flight:${{ steps.last_release.outputs.tag_name }}
|
docker push ${{ secrets.DOCKERHUB_USERNAME }}/booking-microservices-flight:${{ steps.last_release.outputs.tag_name }}
|
||||||
docker push ${{ secrets.DOCKERHUB_USERNAME }}/booking-microservices-identity:${{ steps.last_release.outputs.tag_name }}
|
docker push ${{ secrets.DOCKERHUB_USERNAME }}/booking-microservices-identity:${{ steps.last_release.outputs.tag_name }}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user