From 814ba6c680d67974f7f44a978d8ff1c94bf79833 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 17:23:35 +0530 Subject: [PATCH 01/29] Create node.js.yml --- .github/workflows/node.js.yml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/node.js.yml diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml new file mode 100644 index 0000000000..f5c2b70c11 --- /dev/null +++ b/.github/workflows/node.js.yml @@ -0,0 +1,31 @@ +# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs + +name: Node.js CI + +on: + push: + branches: [ "master" ] + pull_request: + branches: [ "master" ] + +jobs: + build: + + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [14.x] + # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ + + steps: + - uses: actions/checkout@v3 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + cache: 'npm' + - run: npm ci + - run: npm run build --if-present + - run: npm test From 7ae34dab908983589f43deef89007b172c7e7325 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 17:32:39 +0530 Subject: [PATCH 02/29] Update node.js.yml --- .github/workflows/node.js.yml | 36 +++++++++++++++++------------------ 1 file changed, 17 insertions(+), 19 deletions(-) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index f5c2b70c11..019701287a 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -1,31 +1,29 @@ # This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node # For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs -name: Node.js CI +name: Node.js CI/CD on: push: - branches: [ "master" ] - pull_request: - branches: [ "master" ] + branches: + - main jobs: build: - runs-on: ubuntu-latest - strategy: - matrix: - node-version: [14.x] - # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ - steps: - - uses: actions/checkout@v3 - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - cache: 'npm' - - run: npm ci - - run: npm run build --if-present - - run: npm test + - name: Checkout Repository + uses: actions/checkout@v2 + + - name: Set up Node.js + uses: actions/setup-node@v3 + with: + node-version: 14 + cache: 'npm' + + - name: Install Dependencies + run: npm ci + + - name: Run Tests + run: npm test From fbb3a435b12c0b3a5d85cce92f332b65252f8b2f Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 17:35:35 +0530 Subject: [PATCH 03/29] Update node.js.yml --- .github/workflows/node.js.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index 019701287a..b478847ff0 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -26,4 +26,4 @@ jobs: run: npm ci - name: Run Tests - run: npm test + run: npm test From 170de69925940d97dcb278c68c735f00acc1d10f Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 17:39:18 +0530 Subject: [PATCH 04/29] Delete .github/workflows directory --- .github/workflows/main.yml | 33 --------------------------------- .github/workflows/node.js.yml | 29 ----------------------------- 2 files changed, 62 deletions(-) delete mode 100644 .github/workflows/main.yml delete mode 100644 .github/workflows/node.js.yml diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml deleted file mode 100644 index 58c79cde54..0000000000 --- a/.github/workflows/main.yml +++ /dev/null @@ -1,33 +0,0 @@ -name: Publish Docker image - -on: - push: - branches: ['master'] - -jobs: - push_to_registry: - name: Push Docker image to Docker Hub - runs-on: ubuntu-latest - steps: - - name: Check out the repo - uses: actions/checkout@v3 - - - name: Log in to Docker Hub - uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9 - with: - username: ${{ secrets.DOCKER_USERNAME }} - password: ${{ secrets.DOCKER_PASSWORD }} - - - name: Extract metadata (tags, labels) for Docker - id: meta - uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38 - with: - images: thetips4you/testjodejsapp - - - name: Build and push Docker image - uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc - with: - context: . - push: true - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml deleted file mode 100644 index b478847ff0..0000000000 --- a/.github/workflows/node.js.yml +++ /dev/null @@ -1,29 +0,0 @@ -# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node -# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs - -name: Node.js CI/CD - -on: - push: - branches: - - main - -jobs: - build: - runs-on: ubuntu-latest - - steps: - - name: Checkout Repository - uses: actions/checkout@v2 - - - name: Set up Node.js - uses: actions/setup-node@v3 - with: - node-version: 14 - cache: 'npm' - - - name: Install Dependencies - run: npm ci - - - name: Run Tests - run: npm test From 56e9808ed6bc8acfbf4f3034a7283e68f76c422d Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 17:39:55 +0530 Subject: [PATCH 05/29] Create node.js.yml --- .github/workflows/node.js.yml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/node.js.yml diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml new file mode 100644 index 0000000000..f5c2b70c11 --- /dev/null +++ b/.github/workflows/node.js.yml @@ -0,0 +1,31 @@ +# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs + +name: Node.js CI + +on: + push: + branches: [ "master" ] + pull_request: + branches: [ "master" ] + +jobs: + build: + + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [14.x] + # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ + + steps: + - uses: actions/checkout@v3 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + cache: 'npm' + - run: npm ci + - run: npm run build --if-present + - run: npm test From aa30f91a6500ae9a5597c3e1f460069196ece684 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 17:47:56 +0530 Subject: [PATCH 06/29] Delete .github/workflows directory --- .github/workflows/node.js.yml | 31 ------------------------------- 1 file changed, 31 deletions(-) delete mode 100644 .github/workflows/node.js.yml diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml deleted file mode 100644 index f5c2b70c11..0000000000 --- a/.github/workflows/node.js.yml +++ /dev/null @@ -1,31 +0,0 @@ -# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node -# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs - -name: Node.js CI - -on: - push: - branches: [ "master" ] - pull_request: - branches: [ "master" ] - -jobs: - build: - - runs-on: ubuntu-latest - - strategy: - matrix: - node-version: [14.x] - # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ - - steps: - - uses: actions/checkout@v3 - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - cache: 'npm' - - run: npm ci - - run: npm run build --if-present - - run: npm test From 08b9b18b9444b0af60b0def808a158dd2015a197 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 17:50:04 +0530 Subject: [PATCH 07/29] Create node.js.yml --- .github/workflows/node.js.yml | 51 +++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 .github/workflows/node.js.yml diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml new file mode 100644 index 0000000000..8b7ca87e01 --- /dev/null +++ b/.github/workflows/node.js.yml @@ -0,0 +1,51 @@ +# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs + +name: Node.js CI + +on: + push: + branches: [ "master" ] + pull_request: + branches: [ "master" ] + +jobs: + build: + + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [14.x] + # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ + + steps: + - uses: actions/checkout@v3 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + cache: 'npm' + - run: npm ci + - run: npm run build --if-present + - run: npm test + + - name: code checkout + uses: actions/checkout@v2 + + - name: install the gcloud cli + uses: google-github-actions/setup-gcloud@v0 + with: + project_id: ${{ secrets.GOOGLE_PROJECT }} + service_account_key: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS }} + install_components: 'gke-gcloud-auth-plugin' + export_default_credentials: true + + - name: build and push the docker image + env: + GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} + run: | + gcloud auth configure-docker us-central1-docker.pkg.dev + docker build -t us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/node:latest . + docker push us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/node:latest + From b11f3148616120fdab674aa2c73ee23f2f226672 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 17:51:41 +0530 Subject: [PATCH 08/29] Delete .github/workflows directory --- .github/workflows/node.js.yml | 51 ----------------------------------- 1 file changed, 51 deletions(-) delete mode 100644 .github/workflows/node.js.yml diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml deleted file mode 100644 index 8b7ca87e01..0000000000 --- a/.github/workflows/node.js.yml +++ /dev/null @@ -1,51 +0,0 @@ -# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node -# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs - -name: Node.js CI - -on: - push: - branches: [ "master" ] - pull_request: - branches: [ "master" ] - -jobs: - build: - - runs-on: ubuntu-latest - - strategy: - matrix: - node-version: [14.x] - # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ - - steps: - - uses: actions/checkout@v3 - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - cache: 'npm' - - run: npm ci - - run: npm run build --if-present - - run: npm test - - - name: code checkout - uses: actions/checkout@v2 - - - name: install the gcloud cli - uses: google-github-actions/setup-gcloud@v0 - with: - project_id: ${{ secrets.GOOGLE_PROJECT }} - service_account_key: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS }} - install_components: 'gke-gcloud-auth-plugin' - export_default_credentials: true - - - name: build and push the docker image - env: - GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} - run: | - gcloud auth configure-docker us-central1-docker.pkg.dev - docker build -t us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/node:latest . - docker push us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/node:latest - From 7b870aa63e7456ff3512e904227eb7f4c63eb4dc Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 17:52:39 +0530 Subject: [PATCH 09/29] Create node.js.yml --- .github/workflows/node.js.yml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/node.js.yml diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml new file mode 100644 index 0000000000..65541855ce --- /dev/null +++ b/.github/workflows/node.js.yml @@ -0,0 +1,31 @@ +# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs + +name: Node.js CI + +on: + push: + branches: [ "master" ] + pull_request: + branches: [ "master" ] + +jobs: + build: + + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [14.x] + # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ + + steps: + - uses: actions/checkout@v3 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + cache: 'npm' + - run: npm ci + - run: npm run build --if-present + - run: npm install From f1a817d026ca08935a71dc9c84b09de97640f95f Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 17:54:29 +0530 Subject: [PATCH 10/29] Update node.js.yml --- .github/workflows/node.js.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index 65541855ce..b8c87a8b4b 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -29,3 +29,19 @@ jobs: - run: npm ci - run: npm run build --if-present - run: npm install + + - name: install the gcloud cli + uses: google-github-actions/setup-gcloud@v0 + with: + project_id: ${{ secrets.GOOGLE_PROJECT }} + service_account_key: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS }} + install_components: 'gke-gcloud-auth-plugin' + export_default_credentials: true + + - name: build and push the docker image + env: + GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} + run: | + gcloud auth configure-docker us-central1-docker.pkg.dev + docker build -t us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/code:latest . + docker push us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/code:latest From a5de5b6b2262a7cddddbe0a0a7def4df0010f234 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 18:01:22 +0530 Subject: [PATCH 11/29] Update node.js.yml --- .github/workflows/node.js.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index b8c87a8b4b..73cf3ca095 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -45,3 +45,10 @@ jobs: gcloud auth configure-docker us-central1-docker.pkg.dev docker build -t us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/code:latest . docker push us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/code:latest + - name: deploy to gke + env: + GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} + run: | + gcloud container clusters get-credentials cluster-1 --region us-central1-c + sed -i "s/GOOGLE_PROJECT/$GOOGLE_PROJECT/g" deploymentservice.yml + kubectl apply -f deploymentservice.yml From 58a9416dde8b445f605bcfe8dc4989c03602d597 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 18:09:34 +0530 Subject: [PATCH 12/29] Update index.js --- index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.js b/index.js index 668a9f8ed6..abe0d5b180 100644 --- a/index.js +++ b/index.js @@ -2,7 +2,7 @@ var express = require('express'); var app = express(); app.get('/', function (req, res) { - res.send('{ "response": "Hello From Thetips4you" }'); + res.send('{ "response": "Welcome to Innodata" }'); }); app.get('/will', function (req, res) { From 2d3b7b11ca9b8a96ffb9d3cc37205f9493036595 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 18:14:19 +0530 Subject: [PATCH 13/29] Delete .github/workflows directory --- .github/workflows/node.js.yml | 54 ----------------------------------- 1 file changed, 54 deletions(-) delete mode 100644 .github/workflows/node.js.yml diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml deleted file mode 100644 index 73cf3ca095..0000000000 --- a/.github/workflows/node.js.yml +++ /dev/null @@ -1,54 +0,0 @@ -# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node -# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs - -name: Node.js CI - -on: - push: - branches: [ "master" ] - pull_request: - branches: [ "master" ] - -jobs: - build: - - runs-on: ubuntu-latest - - strategy: - matrix: - node-version: [14.x] - # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ - - steps: - - uses: actions/checkout@v3 - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - cache: 'npm' - - run: npm ci - - run: npm run build --if-present - - run: npm install - - - name: install the gcloud cli - uses: google-github-actions/setup-gcloud@v0 - with: - project_id: ${{ secrets.GOOGLE_PROJECT }} - service_account_key: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS }} - install_components: 'gke-gcloud-auth-plugin' - export_default_credentials: true - - - name: build and push the docker image - env: - GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} - run: | - gcloud auth configure-docker us-central1-docker.pkg.dev - docker build -t us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/code:latest . - docker push us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/code:latest - - name: deploy to gke - env: - GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} - run: | - gcloud container clusters get-credentials cluster-1 --region us-central1-c - sed -i "s/GOOGLE_PROJECT/$GOOGLE_PROJECT/g" deploymentservice.yml - kubectl apply -f deploymentservice.yml From fec758abd5530b36078ce6b397887de83cad6495 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 18:18:01 +0530 Subject: [PATCH 14/29] Create node.js.yml --- .github/workflows/node.js.yml | 54 +++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 .github/workflows/node.js.yml diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml new file mode 100644 index 0000000000..73cf3ca095 --- /dev/null +++ b/.github/workflows/node.js.yml @@ -0,0 +1,54 @@ +# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs + +name: Node.js CI + +on: + push: + branches: [ "master" ] + pull_request: + branches: [ "master" ] + +jobs: + build: + + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [14.x] + # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ + + steps: + - uses: actions/checkout@v3 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + cache: 'npm' + - run: npm ci + - run: npm run build --if-present + - run: npm install + + - name: install the gcloud cli + uses: google-github-actions/setup-gcloud@v0 + with: + project_id: ${{ secrets.GOOGLE_PROJECT }} + service_account_key: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS }} + install_components: 'gke-gcloud-auth-plugin' + export_default_credentials: true + + - name: build and push the docker image + env: + GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} + run: | + gcloud auth configure-docker us-central1-docker.pkg.dev + docker build -t us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/code:latest . + docker push us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/code:latest + - name: deploy to gke + env: + GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} + run: | + gcloud container clusters get-credentials cluster-1 --region us-central1-c + sed -i "s/GOOGLE_PROJECT/$GOOGLE_PROJECT/g" deploymentservice.yml + kubectl apply -f deploymentservice.yml From 56fdf4285a946bc0ba7d9d90ed3698f8474999c7 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 18:41:16 +0530 Subject: [PATCH 15/29] Update node.js.yml From 7bb51c066230f7d5cf5729896810dedab1457c0e Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 18:47:13 +0530 Subject: [PATCH 16/29] Update index.js --- index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.js b/index.js index abe0d5b180..b848ee1186 100644 --- a/index.js +++ b/index.js @@ -6,7 +6,7 @@ app.get('/', function (req, res) { }); app.get('/will', function (req, res) { - res.send('{ "response": "Hello World" }'); + res.send('{ "response": "Welcome" }'); }); app.get('/ready', function (req, res) { res.send('{ "response": " Great!, It works!" }'); From 4a27c60b9696af6fa025ddfe75aa740782cc3801 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 18:49:23 +0530 Subject: [PATCH 17/29] Update test.js --- test/test.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/test.js b/test/test.js index 2794ef1f03..bf4f29c332 100644 --- a/test/test.js +++ b/test/test.js @@ -1,7 +1,7 @@ var request = require('supertest'); var app = require('../index.js'); describe('GET /will', function() { - it('respond with hello world', function(done) { - request(app).get('/will').expect('{ "response": "Hello World" }', done); + it('respond with Welcome', function(done) { + request(app).get('/will').expect('{ "response": "Welcome" }', done); }); -}); \ No newline at end of file +}); From a4df0af9ea8b44c47bfb3369b236e01d4a3b4a80 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 18:52:25 +0530 Subject: [PATCH 18/29] Update deploymentservice.yml --- deploymentservice.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/deploymentservice.yml b/deploymentservice.yml index ab6f0b707d..6a5567b9f9 100644 --- a/deploymentservice.yml +++ b/deploymentservice.yml @@ -16,7 +16,7 @@ spec: spec: containers: - name: nodeserver - image: thetips4you/nodeapp:latest + image: us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/nodeapp:latest ports: - containerPort: 3000 @@ -33,6 +33,6 @@ spec: type: LoadBalancer ports: - protocol: TCP - port: 5000 + port: 8000 targetPort: 3000 nodePort: 31110 From 752d7407f886dee79ef276a52fa1f165b1616bb7 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 18:53:14 +0530 Subject: [PATCH 19/29] Update deployment.yml --- deployment.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deployment.yml b/deployment.yml index 8468bbd661..09fcc9e195 100644 --- a/deployment.yml +++ b/deployment.yml @@ -16,6 +16,6 @@ spec: spec: containers: - name: nodeserver - image: thetips4you/nodeapp:latest + image: us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/nodeapp:latest ports: - containerPort: 3000 From 745a162982d7ded162dbca5a73f012f93431c108 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Fri, 22 Dec 2023 18:53:30 +0530 Subject: [PATCH 20/29] Update service.yml --- service.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/service.yml b/service.yml index 1a0ab51485..dae0bb5df9 100644 --- a/service.yml +++ b/service.yml @@ -8,6 +8,6 @@ spec: type: LoadBalancer ports: - protocol: TCP - port: 5000 + port: 8000 targetPort: 3000 nodePort: 31110 From db29626a3d69d9f1fd52eb4091e71e12b556702e Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Wed, 27 Dec 2023 10:56:21 +0530 Subject: [PATCH 21/29] Update deploymentservice.yml --- deploymentservice.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deploymentservice.yml b/deploymentservice.yml index 6a5567b9f9..849efceaa7 100644 --- a/deploymentservice.yml +++ b/deploymentservice.yml @@ -16,7 +16,7 @@ spec: spec: containers: - name: nodeserver - image: us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/nodeapp:latest + image: asia-south1-docker.pkg.dev/goldengate-1/test-project/code:latest ports: - containerPort: 3000 From 88972c9a10fb4b3e468e444b02cfc4ef79dddfd2 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Wed, 27 Dec 2023 12:48:53 +0530 Subject: [PATCH 22/29] Update deployment.yml --- deployment.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deployment.yml b/deployment.yml index 09fcc9e195..722f844855 100644 --- a/deployment.yml +++ b/deployment.yml @@ -16,6 +16,6 @@ spec: spec: containers: - name: nodeserver - image: us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/nodeapp:latest + image: us-central1-docker.pkg.dev/goldengate-1/test-project/nodeapp:latest ports: - containerPort: 3000 From 84f124d34da90f03885f346eb7c83a75900b961e Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Wed, 27 Dec 2023 13:07:32 +0530 Subject: [PATCH 23/29] Update node.js.yml --- .github/workflows/node.js.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index 73cf3ca095..2d0bdd0b28 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -43,8 +43,8 @@ jobs: GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} run: | gcloud auth configure-docker us-central1-docker.pkg.dev - docker build -t us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/code:latest . - docker push us-central1-docker.pkg.dev/invertible-hook-406706/test-gcp/code:latest + docker build -t us-central1-docker.pkg.dev/goldengate-1/test-project/code/node:latest . + docker push us-central1-docker.pkg.dev/goldengate-1/test-project/node:latest - name: deploy to gke env: GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} From 3b08ed1810a26e77571f39a371e272cd3e2b7550 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Wed, 27 Dec 2023 13:12:12 +0530 Subject: [PATCH 24/29] Update node.js.yml --- .github/workflows/node.js.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index 2d0bdd0b28..f88f3c0027 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -43,12 +43,12 @@ jobs: GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} run: | gcloud auth configure-docker us-central1-docker.pkg.dev - docker build -t us-central1-docker.pkg.dev/goldengate-1/test-project/code/node:latest . + docker build -t us-central1-docker.pkg.dev/goldengate-1/test-project/node:latest . docker push us-central1-docker.pkg.dev/goldengate-1/test-project/node:latest - name: deploy to gke env: GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} run: | - gcloud container clusters get-credentials cluster-1 --region us-central1-c + gcloud container clusters get-credentials test-cluster --region asia-south1-c-c sed -i "s/GOOGLE_PROJECT/$GOOGLE_PROJECT/g" deploymentservice.yml kubectl apply -f deploymentservice.yml From f57e684f7b7804584a796a7a3fdcf64dea7a22ad Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Wed, 27 Dec 2023 13:18:02 +0530 Subject: [PATCH 25/29] Update node.js.yml From bde795ea81d9dcdf3e5eee8cf3b715ebbff7c652 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Wed, 27 Dec 2023 13:21:19 +0530 Subject: [PATCH 26/29] Update node.js.yml --- .github/workflows/node.js.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index f88f3c0027..7d5dc62f98 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -5,9 +5,9 @@ name: Node.js CI on: push: - branches: [ "master" ] + branches: [ "main" ] pull_request: - branches: [ "master" ] + branches: [ "main" ] jobs: build: @@ -49,6 +49,6 @@ jobs: env: GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} run: | - gcloud container clusters get-credentials test-cluster --region asia-south1-c-c + gcloud container clusters get-credentials test-cluster --region asia-south1-c sed -i "s/GOOGLE_PROJECT/$GOOGLE_PROJECT/g" deploymentservice.yml kubectl apply -f deploymentservice.yml From a44ffbdcefa82c2bed5ad49edee3effcddbd1b63 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Wed, 27 Dec 2023 13:22:29 +0530 Subject: [PATCH 27/29] Update node.js.yml From b3a3fc3d324603408eced95443f9fb617733f9bc Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Wed, 27 Dec 2023 13:23:36 +0530 Subject: [PATCH 28/29] Update node.js.yml --- .github/workflows/node.js.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index 7d5dc62f98..c340aacd2a 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -5,9 +5,9 @@ name: Node.js CI on: push: - branches: [ "main" ] + branches: [ "master" ] pull_request: - branches: [ "main" ] + branches: [ "master" ] jobs: build: From 8ecbd34d740c6aae0493e7427061d9dc43d36fb8 Mon Sep 17 00:00:00 2001 From: mnagaraju5628 <124573100+mnagaraju5628@users.noreply.github.com> Date: Wed, 27 Dec 2023 13:45:43 +0530 Subject: [PATCH 29/29] Update node.js.yml --- .github/workflows/node.js.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index c340aacd2a..7d5dc62f98 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -5,9 +5,9 @@ name: Node.js CI on: push: - branches: [ "master" ] + branches: [ "main" ] pull_request: - branches: [ "master" ] + branches: [ "main" ] jobs: build: