Skip to content
This repository has been archived by the owner on Jul 8, 2024. It is now read-only.

Commit

Permalink
Merge pull request #31 from floriaaan/gateway
Browse files Browse the repository at this point in the history
Gateway
  • Loading branch information
PierreLbg authored Oct 18, 2023
2 parents b6ab7a7 + 5ae4a6e commit 5434bf7
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 0 deletions.
52 changes: 52 additions & 0 deletions .github/workflows/user.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: User Microservice CI/CD

on:
push:
branches: [user]
pull_request:
branches: [dev, main]

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: 1.20.3

- name: Build
run: cd services/user && go build .

test:
runs-on: ubuntu-latest
needs: build
steps:
- uses: actions/checkout@master
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: 1.20.3

- name: Execute tests
run: cd services/user && go test -v .

publish:
runs-on: ubuntu-latest
needs: [build, test]
steps:
- name: Checkout code
uses: actions/checkout@master
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v4
with:
context: ./services/
file: ./services/user/Dockerfile
push: true
tags: floriaaan/goodfood-user:latest
1 change: 1 addition & 0 deletions services/user/proto

0 comments on commit 5434bf7

Please sign in to comment.