From 59c39c6ad2a27bfe92b58d78b6c7ec688f627eb0 Mon Sep 17 00:00:00 2001 From: justodevop Date: Sat, 24 Jan 2026 15:25:26 -0500 Subject: [PATCH 01/20] continuous nitergrstion --- .github/workflows/ci.yml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..215e09f --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,27 @@ +name: nodejs CI + +on: + push: + branches: + - master + +jobs: + continuous_integration: + runs-on: ubuntu-latest + steps: + - name: checkout repository + uses: actions/checkout@v3 + + - name: setup node js 22 + uses: actions/setup-node@v4 + with: + node-version: "22" + cache: "npm" + + - name: install dependencies + run: npm install + + - name: buil d application + run: npm run build + + \ No newline at end of file From c11ab33d73c5d8d74badc25bc9b7f00dfabbcb77 Mon Sep 17 00:00:00 2001 From: justo1 Date: Sat, 7 Feb 2026 13:45:40 -0500 Subject: [PATCH 02/20] my new commit --- .github/workflows/ci.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 215e09f..7793a91 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -22,6 +22,8 @@ jobs: run: npm install - name: buil d application - run: npm run build - + run: echo "building application" + run:echo "runing untit tests" + -name:run intergration tests + run: echo "runing intergration tests" \ No newline at end of file From caeeccd7466fae7a4460bfa1c7c363be4b66eaaa Mon Sep 17 00:00:00 2001 From: justo1 Date: Sat, 7 Feb 2026 14:09:46 -0500 Subject: [PATCH 03/20] my 2nd commit --- .github/workflows/ci.yml | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7793a91..7ea4f40 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -21,9 +21,11 @@ jobs: - name: install dependencies run: npm install - - name: buil d application - run: echo "building application" - run:echo "runing untit tests" - -name:run intergration tests - run: echo "runing intergration tests" - \ No newline at end of file + - name: build application + run: echo "Building application" + + - name: run unit tests + run: echo "running unit tests" + + - name: run itergration tests + run: echo "running integration tests" \ No newline at end of file From 8f3b06f72e8a923435ebd164b6439483239ff98a Mon Sep 17 00:00:00 2001 From: justo1 Date: Sat, 7 Feb 2026 14:24:27 -0500 Subject: [PATCH 04/20] update pipeline --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7ea4f40..6682b4d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,7 +1,7 @@ -name: nodejs CI +name: nodejs CI... on: - push: + pull_request: branches: - master From 8e1344309741569df1422e4aee23b37e83de403a Mon Sep 17 00:00:00 2001 From: justo1 Date: Sat, 7 Feb 2026 15:20:44 -0500 Subject: [PATCH 05/20] my 3rd update --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6682b4d..db18df8 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,7 +19,7 @@ jobs: cache: "npm" - name: install dependencies - run: npm install + run: npm instal - name: build application run: echo "Building application" From b7ee4a84a17ebbc813199774da6be8055e2ccf84 Mon Sep 17 00:00:00 2001 From: justo1 Date: Sun, 8 Feb 2026 07:10:45 -0500 Subject: [PATCH 06/20] my 4th update --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index db18df8..4602268 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,7 +19,7 @@ jobs: cache: "npm" - name: install dependencies - run: npm instal + run: npm in - name: build application run: echo "Building application" From f378bdb58a9ea1698071badf724748f4ab5fea7a Mon Sep 17 00:00:00 2001 From: justo1 Date: Sat, 14 Feb 2026 15:01:56 -0500 Subject: [PATCH 07/20] created docker file and part of CD script --- .github/workflows/cd.yml | 22 ++++++++++++++++++++++ Dockerfile | 6 ++++++ 2 files changed, 28 insertions(+) create mode 100644 .github/workflows/cd.yml create mode 100644 Dockerfile diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml new file mode 100644 index 0000000..9267c78 --- /dev/null +++ b/.github/workflows/cd.yml @@ -0,0 +1,22 @@ +name: nodejs CD + +on: + push: + branches: + - master + +jobs: + continuous_deployment: + runs-on: ubuntu-latest + steps: + - name: checkout repository + uses: actions/checkout@v3 + + - name: setup docker + uses: docker/setup-buildx-action@v2 + + - name: build docker image + run: docker build -t user/app:latest . + - name: tag Docker image + run: docker tag user/app:latest justodock/nodejs-test-app:latest + \ No newline at end of file diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..db4fa18 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,6 @@ +FROM node:20-alpine +WORKDIR /app +ADD . /app +RUN npm install +EXPOSE 3000 +CMD ["npm" , "run" ,"start:dev"] \ No newline at end of file From 0cc231bea34312469fb183ad48546c16cec9cfb6 Mon Sep 17 00:00:00 2001 From: justo1 Date: Sun, 15 Feb 2026 15:27:24 -0500 Subject: [PATCH 08/20] my cd new commit --- .github/workflows/cd.yml | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index 9267c78..faa7096 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -18,5 +18,14 @@ jobs: - name: build docker image run: docker build -t user/app:latest . - name: tag Docker image - run: docker tag user/app:latest justodock/nodejs-test-app:latest - \ No newline at end of file + run: docker tag user/app:latest ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest + + + - name: LOGIN TO DOCKER HUB + uses: docker/login-action@v3 + with: + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} + - name: push docker image to docker hub + run: docker push ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest + \ No newline at end of file From 925a7031c1e88887036826950b85568bac5bb929 Mon Sep 17 00:00:00 2001 From: justo1 Date: Mon, 16 Feb 2026 06:47:56 -0500 Subject: [PATCH 09/20] my cd kub clos --- .github/workflows/cd.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index faa7096..ee6f532 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -28,4 +28,6 @@ jobs: password: ${{ secrets.DOCKER_PASSWORD }} - name: push docker image to docker hub run: docker push ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest - \ No newline at end of file + + - name: deploy to kubernetes cluster + run: echo "deploying to kubernetes cluster" \ No newline at end of file From d1b3eae6f3b122887f8424dd8b26972fe3174033 Mon Sep 17 00:00:00 2001 From: justo1 Date: Sat, 21 Feb 2026 13:08:13 -0500 Subject: [PATCH 10/20] my ci new e2e --- .github/workflows/cd.yml | 3 ++- .github/workflows/ci.yml | 4 +++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index ee6f532..3eb9e79 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -30,4 +30,5 @@ jobs: run: docker push ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest - name: deploy to kubernetes cluster - run: echo "deploying to kubernetes cluster" \ No newline at end of file + run: echo "deploying to kubernetes cluster" + \ No newline at end of file diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4602268..6507b4e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -28,4 +28,6 @@ jobs: run: echo "running unit tests" - name: run itergration tests - run: echo "running integration tests" \ No newline at end of file + run: echo "running integration tests" + - name: run e2e tests + \ No newline at end of file From 0ef59944aa55f8f0700de3aef64952e0f961c138 Mon Sep 17 00:00:00 2001 From: justo1 Date: Sat, 21 Feb 2026 15:29:39 -0500 Subject: [PATCH 11/20] my new deployment server --- .github/workflows/cd.yml | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index 3eb9e79..cb07583 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -29,6 +29,20 @@ jobs: - name: push docker image to docker hub run: docker push ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest - - name: deploy to kubernetes cluster - run: echo "deploying to kubernetes cluster" - \ No newline at end of file + - name: add ssh private key + run: | + + mkdir -p ~/.ssh + echo "${{ secrets.SSH_PRIVATE_KEY }}" > ~/.ssh/id_rsa + chmod 600 ~/.ssh/id_rsa + - name: add SSH known hosts + run: ssh-keyscan -t rsa ${{{secrets.SSH_HOST }}} >> ~/.ssh/known_hosts + - name: deploy to server + run: + ssh -o StrictHostKeyChecking=no ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }} << 'EOF' + + EOF + sudo docker pull ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest + sudo docker stop nodejs-test-app || true + sudo docker rm nodejs-test-app || trues + sudo docker run -d --name nodejs-test-app -p 80:3000 ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest From 04feeb34bab8459ccb883b9b1361f2823f44ee08 Mon Sep 17 00:00:00 2001 From: justo1 Date: Sat, 21 Feb 2026 15:49:08 -0500 Subject: [PATCH 12/20] my new commit-G --- .github/workflows/ci.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6507b4e..36c9540 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -7,8 +7,8 @@ on: jobs: continuous_integration: - runs-on: ubuntu-latest - steps: + runs-on: ubuntu-latest + steps: - name: checkout repository uses: actions/checkout@v3 @@ -29,5 +29,4 @@ jobs: - name: run itergration tests run: echo "running integration tests" - - name: run e2e tests - \ No newline at end of file + From 79f3d76aa1bd5c21d7f4d9674f9df50794e1df2e Mon Sep 17 00:00:00 2001 From: justo1 Date: Sat, 21 Feb 2026 16:01:02 -0500 Subject: [PATCH 13/20] my new commit-G --- .github/workflows/cd.yml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index cb07583..9a4cdd7 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -7,8 +7,8 @@ on: jobs: continuous_deployment: - runs-on: ubuntu-latest - steps: + runs-on: ubuntu-latest + steps: - name: checkout repository uses: actions/checkout@v3 @@ -36,13 +36,13 @@ jobs: echo "${{ secrets.SSH_PRIVATE_KEY }}" > ~/.ssh/id_rsa chmod 600 ~/.ssh/id_rsa - name: add SSH known hosts - run: ssh-keyscan -t rsa ${{{secrets.SSH_HOST }}} >> ~/.ssh/known_hosts + run: ssh-keyscan -t rsa ${{secrets.SSH_HOST }}>> ~/.ssh/known_hosts - name: deploy to server run: - ssh -o StrictHostKeyChecking=no ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }} << 'EOF' - - EOF + ssh -o StrictHostKeyChecking=no ubuntu@${ secrets.SSH_HOST }} << 'EOF' sudo docker pull ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest sudo docker stop nodejs-test-app || true - sudo docker rm nodejs-test-app || trues + sudo docker rm nodejs-test-app || true sudo docker run -d --name nodejs-test-app -p 80:3000 ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest + EOF + From f1f0b6e3c1b7e8154dbcf07e959a22d44a6c7dd8 Mon Sep 17 00:00:00 2001 From: justo1 Date: Sat, 21 Feb 2026 16:05:53 -0500 Subject: [PATCH 14/20] my new commit-G --- .github/workflows/cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index 9a4cdd7..0183751 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -39,7 +39,7 @@ jobs: run: ssh-keyscan -t rsa ${{secrets.SSH_HOST }}>> ~/.ssh/known_hosts - name: deploy to server run: - ssh -o StrictHostKeyChecking=no ubuntu@${ secrets.SSH_HOST }} << 'EOF' + ssh -o StrictHostKeyChecking=no ubuntu@${{secrets.SSH_HOST }} << 'EOF' sudo docker pull ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest sudo docker stop nodejs-test-app || true sudo docker rm nodejs-test-app || true From 9186f04ddd5b931d0405f4102a36c4518f0f64d2 Mon Sep 17 00:00:00 2001 From: justo1 Date: Sun, 22 Feb 2026 14:26:04 -0500 Subject: [PATCH 15/20] my new cd commit --- .github/workflows/cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index 0183751..579ae84 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -44,5 +44,5 @@ jobs: sudo docker stop nodejs-test-app || true sudo docker rm nodejs-test-app || true sudo docker run -d --name nodejs-test-app -p 80:3000 ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest - EOF + EOF From a347fe56daa08653825887add85c39bca23310bd Mon Sep 17 00:00:00 2001 From: justo1 Date: Sun, 22 Feb 2026 14:34:43 -0500 Subject: [PATCH 16/20] my new cd commit --- .github/workflows/cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index 579ae84..f4c603e 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -36,7 +36,7 @@ jobs: echo "${{ secrets.SSH_PRIVATE_KEY }}" > ~/.ssh/id_rsa chmod 600 ~/.ssh/id_rsa - name: add SSH known hosts - run: ssh-keyscan -t rsa ${{secrets.SSH_HOST }}>> ~/.ssh/known_hosts + run: ssh-keyscan -t rsa ${{secrets.SSH_HOST }} >> ~/.ssh/known_hosts - name: deploy to server run: ssh -o StrictHostKeyChecking=no ubuntu@${{secrets.SSH_HOST }} << 'EOF' From aea3cd37b8c8cdcc3ef2cdb484711a8f3275a98e Mon Sep 17 00:00:00 2001 From: justo1 Date: Sun, 22 Feb 2026 15:09:17 -0500 Subject: [PATCH 17/20] my new cd commit1 --- .github/workflows/cd.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index f4c603e..718c208 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -3,7 +3,7 @@ name: nodejs CD on: push: branches: - - master + - justo/login_page jobs: continuous_deployment: @@ -40,7 +40,7 @@ jobs: - name: deploy to server run: ssh -o StrictHostKeyChecking=no ubuntu@${{secrets.SSH_HOST }} << 'EOF' - sudo docker pull ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest + sudo docker pull justodock/nodejs-test-app:latest sudo docker stop nodejs-test-app || true sudo docker rm nodejs-test-app || true sudo docker run -d --name nodejs-test-app -p 80:3000 ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest From 88e0181b42a378ee4dffb2e75b23b369b5383e5d Mon Sep 17 00:00:00 2001 From: justo1 Date: Sun, 22 Feb 2026 15:21:53 -0500 Subject: [PATCH 18/20] my new cd commit2 --- .github/workflows/cd.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index 718c208..3fe728f 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -37,10 +37,10 @@ jobs: chmod 600 ~/.ssh/id_rsa - name: add SSH known hosts run: ssh-keyscan -t rsa ${{secrets.SSH_HOST }} >> ~/.ssh/known_hosts - - name: deploy to server - run: - ssh -o StrictHostKeyChecking=no ubuntu@${{secrets.SSH_HOST }} << 'EOF' - sudo docker pull justodock/nodejs-test-app:latest + - name: Deploy to Server + run: | + ssh -o StrictHostKeyChecking=no ubuntu@${{ secrets.SSH_HOST }} << 'EOF' + sudo docker pull ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest sudo docker stop nodejs-test-app || true sudo docker rm nodejs-test-app || true sudo docker run -d --name nodejs-test-app -p 80:3000 ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest From d34e2eb1740088ef5a1f8073677401e673c6403a Mon Sep 17 00:00:00 2001 From: justo1 Date: Sun, 22 Feb 2026 15:25:47 -0500 Subject: [PATCH 19/20] my new cd commit3 --- .github/workflows/cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index 3fe728f..ef4f685 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -43,6 +43,6 @@ jobs: sudo docker pull ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest sudo docker stop nodejs-test-app || true sudo docker rm nodejs-test-app || true - sudo docker run -d --name nodejs-test-app -p 80:3000 ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest + sudo docker run -d --name nodejs-test-app -p 81:3000 ${{ secrets.DOCKER_USERNAME }}/nodejs-test-app:latest EOF From c8cb780bf08ca2fa7c413e53d120347e89ae759c Mon Sep 17 00:00:00 2001 From: justo1 Date: Mon, 23 Feb 2026 02:35:42 -0500 Subject: [PATCH 20/20] my new cd commit3 --- .github/workflows/cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index ef4f685..9adab50 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -3,7 +3,7 @@ name: nodejs CD on: push: branches: - - justo/login_page + - master jobs: continuous_deployment: