apuntes:cicd
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| apuntes:cicd [2025/03/23 17:47] – Santiago Faci | apuntes:cicd [2026/09/27 22:39] (current) – [Publicar una imagen docker en Docker Hub] Santiago Faci | ||
|---|---|---|---|
| Line 5: | Line 5: | ||
| </ | </ | ||
| - | ===== CI/CD Testing ====== | + | ===== Testing ====== |
| + | |||
| + | Workflow: **Node.js** | ||
| <code yaml> | <code yaml> | ||
| Line 39: | Line 41: | ||
| </ | </ | ||
| - | ===== CI/CD Crear una imagen docker ====== | + | ===== Crear una imagen docker ====== |
| + | |||
| + | Workflow: **Docker Image** | ||
| <code yaml> | <code yaml> | ||
| Line 62: | Line 66: | ||
| </ | </ | ||
| - | ===== CI/CD Lanzar un análisis de código con Sonarqube ====== | + | ===== Publicar una imagen docker en Docker Hub ====== |
| + | |||
| + | Workflow: **Publish Docker Image** | ||
| + | |||
| + | <code yaml> | ||
| + | name: Publish docker image | ||
| + | |||
| + | on: | ||
| + | push: | ||
| + | branches: | ||
| + | - main | ||
| + | |||
| + | jobs: | ||
| + | publish-docker-image: | ||
| + | runs-on: ubuntu-latest | ||
| + | steps: | ||
| + | - uses: docker/login-action@v4 | ||
| + | with: | ||
| + | username: ${{ secrets.DOCKER_HUB_USERNAME }} | ||
| + | password: ${{ secrets.DOCKER_HUB_PASSWORD }} | ||
| + | - uses: actions/ | ||
| + | - uses: actions/ | ||
| + | with: | ||
| + | distribution: | ||
| + | java-version: | ||
| + | - run: mvn package | ||
| + | - run: docker build -t sfaci/games . | ||
| + | - run: docker compose up -d | ||
| + | - run: npm install -g newman | ||
| + | - run: newman run games.postman_collection.json -e local.postman_environment.json | ||
| + | - run: docker push sfaci/ | ||
| + | </ | ||
| + | |||
| + | ===== Lanzar un análisis de código con Sonarqube ====== | ||
| + | |||
| + | Workflow: **SonarQube** | ||
| <code yaml> | <code yaml> | ||
apuntes/cicd.1742752043.txt.gz · Last modified: by Santiago Faci
