Skip to content

Merge pull request #108 from Apes2getherStrong/WTG-16-no-ability-to-e… #10

Merge pull request #108 from Apes2getherStrong/WTG-16-no-ability-to-e…

Merge pull request #108 from Apes2getherStrong/WTG-16-no-ability-to-e… #10

Workflow file for this run

name: Build and Push Docker Image
on:
push:
branches:
- main
jobs:
build-and-push:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '20'
- name: Install dependencies
run: npm install
- name: Build Angular app
run: npm run build --prod
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Log in to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Build and push Docker image
uses: docker/build-push-action@v4
with:
context: .
push: true
tags: ${{ secrets.DOCKER_USERNAME }}/angular-waytogo:latest