Skip to content

Commit e5abc3f

Browse files
committed
ci: agregar workflow de build (backend y frontend)
1 parent 5e6ea1e commit e5abc3f

1 file changed

Lines changed: 37 additions & 0 deletions

File tree

.github/workflows/ci.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: CI
2+
3+
on:
4+
pull_request:
5+
branches: [ "main" ]
6+
push:
7+
branches: [ "main" ]
8+
9+
jobs:
10+
docker-build:
11+
runs-on: ubuntu-latest
12+
permissions:
13+
contents: read
14+
strategy:
15+
fail-fast: false
16+
matrix:
17+
service:
18+
- name: backend
19+
context: ./backend
20+
- name: frontend
21+
context: ./frontend
22+
23+
steps:
24+
- name: Checkout
25+
uses: actions/checkout@v4
26+
27+
- name: Set up Docker Buildx
28+
uses: docker/setup-buildx-action@v3
29+
30+
- name: Build ${{ matrix.service.name }}
31+
uses: docker/build-push-action@v6
32+
with:
33+
context: ${{ matrix.service.context }}
34+
push: false
35+
tags: devops-portfolio/${{ matrix.service.name }}:ci
36+
cache-from: type=gha
37+
cache-to: type=gha,mode=max

0 commit comments

Comments
 (0)