From 5538f5f2b77b74a0009664f202cf35b63ba7aa64 Mon Sep 17 00:00:00 2001 From: Muhammad Salman Aziz <85288719+salman-aziz-4425@users.noreply.github.com> Date: Tue, 26 Dec 2023 15:39:12 +0500 Subject: [PATCH] Update node.js.yml --- .github/workflows/node.js.yml | 38 +++++++++++++++++------------------ 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index 9206a9b..ed29d29 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -26,24 +26,24 @@ jobs: run: | npm ci - # docker-build: - # runs-on: self-hosted - # needs: build - # steps: - # - name: Checkout Repository - # uses: actions/checkout@v3 + docker-build: + runs-on: self-hosted + needs: build + steps: + - name: Checkout Repository + uses: actions/checkout@v3 - # - name: Build Docker Image - # run: | - # sudo docker build -t instagram-reimaged-fe:latest . - # sudo docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }} - # sudo docker push salman4425/instagram-frontend-fe:instagram-reimaged-fe:latest + - name: Build Docker Image + run: | + sudo docker build -t salman4425/instagram-frontend-fe:v1.0 . + sudo docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }} + sudo docker push salman4425/instagram-frontend-fe:v1.0 - # deploy: - # runs-on: self-hosted - # needs: docker-build - # steps: - # - name: Deploy with Docker - # run: | - # sudo docker pull instagram-reimaged-fe:latest - # sudo docker run -d -p 3000:3001 --name instagram-reimaged-fe:latest + deploy: + runs-on: self-hosted + needs: docker-build + steps: + - name: Deploy with Docker + run: | + sudo docker pull salman4425/instagram-frontend-fe:v1.0 + sudo docker run -d -p 3000:3001 --name salman4425/instagram-frontend-fe:v1.0