From f3d3c4d07d086862ca9a7ea48325e8d6260f6654 Mon Sep 17 00:00:00 2001 From: Nicolas B <46492476+nicolegrimpeur@users.noreply.github.com> Date: Mon, 16 Jan 2023 15:10:47 +0100 Subject: [PATCH 01/17] Create maven-publish.yml --- .github/workflows/maven-publish.yml | 33 +++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 .github/workflows/maven-publish.yml diff --git a/.github/workflows/maven-publish.yml b/.github/workflows/maven-publish.yml new file mode 100644 index 00000000..cbedd97a --- /dev/null +++ b/.github/workflows/maven-publish.yml @@ -0,0 +1,33 @@ +# This workflow will build a package using Maven and then publish it to GitHub packages when a release is created +# For more information see: https://github.com/actions/setup-java/blob/main/docs/advanced-usage.md#apache-maven-with-a-settings-path + +name: Maven Package + +on: + workflow_dispatch: + +jobs: + build: + + runs-on: ubuntu-latest + permissions: + contents: read + packages: write + + steps: + - uses: actions/checkout@v3 + - name: Set up JDK 11 + uses: actions/setup-java@v3 + with: + java-version: '11' + distribution: 'temurin' + server-id: github # Value of the distributionManagement/repository/id field of the pom.xml + settings-path: ${{ github.workspace }} # location for the settings.xml file + + - name: Build with Maven + run: mvn -B package --file pom.xml + + - name: Publish to GitHub Packages Apache Maven + run: mvn deploy -s $GITHUB_WORKSPACE/settings.xml + env: + GITHUB_TOKEN: ${{ github.token }} From 3220371281de4819540c5749bcd24e0b45f8c94c Mon Sep 17 00:00:00 2001 From: Nicolas B <46492476+nicolegrimpeur@users.noreply.github.com> Date: Mon, 16 Jan 2023 15:10:59 +0100 Subject: [PATCH 02/17] Delete deploy-pages-action.yml --- .github/workflows/deploy-pages-action.yml | 25 ----------------------- 1 file changed, 25 deletions(-) delete mode 100644 .github/workflows/deploy-pages-action.yml diff --git a/.github/workflows/deploy-pages-action.yml b/.github/workflows/deploy-pages-action.yml deleted file mode 100644 index 78bdc7a9..00000000 --- a/.github/workflows/deploy-pages-action.yml +++ /dev/null @@ -1,25 +0,0 @@ -name: Build and Deploy to github pages - -on: - push: - branches: - - main -jobs: - build-and-deploy: - runs-on: ubuntu-latest - steps: - - name: Checkout 🛎️ - uses: actions/checkout@v3.0.0 - - - name: Install and Build 🔧 # This example project is built using npm and outputs the result to the 'build' folder. Replace with the commands required to build your project, or remove this step entirely if your site is pre-built. - run: | - cd docs - npm ci - npm run docs:build - - - name: Deploy 🚀 - uses: JamesIves/github-pages-deploy-action@v4.2.5 - with: - branch: gh-pages # The branch the action should deploy to. - folder: docs/.vuepress/dist # The folder the action should deploy. - single-commit: true From 24aca01844141662b4d0176a60f0a5b50a8301d9 Mon Sep 17 00:00:00 2001 From: Nicolas Date: Mon, 16 Jan 2023 15:51:55 +0100 Subject: [PATCH 03/17] Modification groupId --- pw/pw-jwt-oauth/server/pom.xml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/pw/pw-jwt-oauth/server/pom.xml b/pw/pw-jwt-oauth/server/pom.xml index cf2a3b68..fc599368 100644 --- a/pw/pw-jwt-oauth/server/pom.xml +++ b/pw/pw-jwt-oauth/server/pom.xml @@ -9,12 +9,20 @@ - com.worldline.bookstore + nicob.nicolegrimpeur.bookstore bookstore 0.0.1-SNAPSHOT war Bookstore + + + github + GitHub Packages + https://maven.pkg.github.com/octocat/hello-world + + + 3.0.0 From 189234b30fc0b9d25b1dcee032e6f4f7c3df919c Mon Sep 17 00:00:00 2001 From: Nicolas B <46492476+nicolegrimpeur@users.noreply.github.com> Date: Mon, 16 Jan 2023 15:53:57 +0100 Subject: [PATCH 04/17] Update maven-publish.yml --- .github/workflows/maven-publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-publish.yml b/.github/workflows/maven-publish.yml index cbedd97a..2dbe7bd9 100644 --- a/.github/workflows/maven-publish.yml +++ b/.github/workflows/maven-publish.yml @@ -25,7 +25,7 @@ jobs: settings-path: ${{ github.workspace }} # location for the settings.xml file - name: Build with Maven - run: mvn -B package --file pom.xml + run: mvn -B package --file /pw/pw-jwt-oauth/server/pom.xml - name: Publish to GitHub Packages Apache Maven run: mvn deploy -s $GITHUB_WORKSPACE/settings.xml From d214f6e45d7f97eb3db68b8401ba5571814882ac Mon Sep 17 00:00:00 2001 From: Nicolas B <46492476+nicolegrimpeur@users.noreply.github.com> Date: Mon, 16 Jan 2023 15:55:21 +0100 Subject: [PATCH 05/17] Update maven-publish.yml --- .github/workflows/maven-publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-publish.yml b/.github/workflows/maven-publish.yml index 2dbe7bd9..85ef318a 100644 --- a/.github/workflows/maven-publish.yml +++ b/.github/workflows/maven-publish.yml @@ -25,7 +25,7 @@ jobs: settings-path: ${{ github.workspace }} # location for the settings.xml file - name: Build with Maven - run: mvn -B package --file /pw/pw-jwt-oauth/server/pom.xml + run: mvn -B package --file pw/pw-jwt-oauth/server/pom.xml - name: Publish to GitHub Packages Apache Maven run: mvn deploy -s $GITHUB_WORKSPACE/settings.xml From 290e1c51515fb79a2570b74c495030566a1784a5 Mon Sep 17 00:00:00 2001 From: Nicolas B <46492476+nicolegrimpeur@users.noreply.github.com> Date: Mon, 16 Jan 2023 15:57:24 +0100 Subject: [PATCH 06/17] Update maven-publish.yml --- .github/workflows/maven-publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-publish.yml b/.github/workflows/maven-publish.yml index 85ef318a..95efd8c8 100644 --- a/.github/workflows/maven-publish.yml +++ b/.github/workflows/maven-publish.yml @@ -28,6 +28,6 @@ jobs: run: mvn -B package --file pw/pw-jwt-oauth/server/pom.xml - name: Publish to GitHub Packages Apache Maven - run: mvn deploy -s $GITHUB_WORKSPACE/settings.xml + run: cd pw/pw-jwt-oauth/server && mvn deploy -s $GITHUB_WORKSPACE/settings.xml env: GITHUB_TOKEN: ${{ github.token }} From 955d4abcd05da91ea8ddce0eefd5bdff6c75b570 Mon Sep 17 00:00:00 2001 From: Nicolas Date: Mon, 16 Jan 2023 16:18:37 +0100 Subject: [PATCH 07/17] Correction url --- pw/pw-jwt-oauth/server/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pw/pw-jwt-oauth/server/pom.xml b/pw/pw-jwt-oauth/server/pom.xml index fc599368..bcc04463 100644 --- a/pw/pw-jwt-oauth/server/pom.xml +++ b/pw/pw-jwt-oauth/server/pom.xml @@ -19,7 +19,7 @@ github GitHub Packages - https://maven.pkg.github.com/octocat/hello-world + https://maven.pkg.github.com/nicolegrimpeur/angular-security-training From e281ac9123842afa54854b43dd000320c2e0c3f2 Mon Sep 17 00:00:00 2001 From: DpMarine <60691542+DpMarine@users.noreply.github.com> Date: Mon, 16 Jan 2023 16:24:12 +0100 Subject: [PATCH 08/17] Create npm-publish.yml --- .github/workflows/npm-publish.yml | 33 +++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 .github/workflows/npm-publish.yml diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml new file mode 100644 index 00000000..24524404 --- /dev/null +++ b/.github/workflows/npm-publish.yml @@ -0,0 +1,33 @@ +# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created +# For more information see: https://docs.github.com/en/actions/publishing-packages/publishing-nodejs-packages + +name: Node.js Package + +on: + workflow_dispatch: + + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-node@v3 + with: + node-version: 16 + - run: npm ci + - run: npm test + + publish-npm: + needs: build + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-node@v3 + with: + node-version: 16 + registry-url: https://registry.npmjs.org/ + - run: npm ci + - run: npm publish + env: + NODE_AUTH_TOKEN: ${{secrets.npm_token}} From 456a681ae812579c57595cc1b2f706870586d161 Mon Sep 17 00:00:00 2001 From: DpMarine <60691542+DpMarine@users.noreply.github.com> Date: Mon, 16 Jan 2023 16:36:39 +0100 Subject: [PATCH 09/17] Change path --- .github/workflows/npm-publish.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml index 24524404..865e82a0 100644 --- a/.github/workflows/npm-publish.yml +++ b/.github/workflows/npm-publish.yml @@ -15,8 +15,8 @@ jobs: - uses: actions/setup-node@v3 with: node-version: 16 - - run: npm ci - - run: npm test + - run: cd pw\pw-jwt-aouth\client && npm ci + - run: cd pw\pw-jwt-oauth\client && npm test publish-npm: needs: build @@ -27,7 +27,7 @@ jobs: with: node-version: 16 registry-url: https://registry.npmjs.org/ - - run: npm ci - - run: npm publish + - run: cd pw\pw-jwt-aouth\client && npm ci + - run: cd pw\pw-jwt-oauth\client && npm publish env: NODE_AUTH_TOKEN: ${{secrets.npm_token}} From a20124b315e0719eaa9c2e9be137af4ff6742554 Mon Sep 17 00:00:00 2001 From: DpMarine <60691542+DpMarine@users.noreply.github.com> Date: Mon, 16 Jan 2023 16:40:58 +0100 Subject: [PATCH 10/17] Update npm-publish.yml --- .github/workflows/npm-publish.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml index 865e82a0..4044ecff 100644 --- a/.github/workflows/npm-publish.yml +++ b/.github/workflows/npm-publish.yml @@ -15,8 +15,8 @@ jobs: - uses: actions/setup-node@v3 with: node-version: 16 - - run: cd pw\pw-jwt-aouth\client && npm ci - - run: cd pw\pw-jwt-oauth\client && npm test + - run: cd pw/pw-jwt-aouth/client && npm ci + - run: cd pw/pw-jwt-oauth/client && npm test publish-npm: needs: build @@ -27,7 +27,7 @@ jobs: with: node-version: 16 registry-url: https://registry.npmjs.org/ - - run: cd pw\pw-jwt-aouth\client && npm ci - - run: cd pw\pw-jwt-oauth\client && npm publish + - run: cd pw/pw-jwt-aouth/client && npm ci + - run: cd pw/pw-jwt-oauth/client && npm publish env: NODE_AUTH_TOKEN: ${{secrets.npm_token}} From 899df0a8f2e765284d590f7a96d44663f519a266 Mon Sep 17 00:00:00 2001 From: DpMarine <60691542+DpMarine@users.noreply.github.com> Date: Mon, 16 Jan 2023 16:44:05 +0100 Subject: [PATCH 11/17] Update npm-publish.yml --- .github/workflows/npm-publish.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml index 4044ecff..4ad16067 100644 --- a/.github/workflows/npm-publish.yml +++ b/.github/workflows/npm-publish.yml @@ -15,7 +15,7 @@ jobs: - uses: actions/setup-node@v3 with: node-version: 16 - - run: cd pw/pw-jwt-aouth/client && npm ci + - run: cd pw/pw-jwt-oauth/client && npm ci - run: cd pw/pw-jwt-oauth/client && npm test publish-npm: @@ -27,7 +27,7 @@ jobs: with: node-version: 16 registry-url: https://registry.npmjs.org/ - - run: cd pw/pw-jwt-aouth/client && npm ci + - run: cd pw/pw-jwt-oauth/client && npm ci - run: cd pw/pw-jwt-oauth/client && npm publish env: NODE_AUTH_TOKEN: ${{secrets.npm_token}} From 58d8cb77627af2007347ae95e9800af689352c6c Mon Sep 17 00:00:00 2001 From: DpMarine <60691542+DpMarine@users.noreply.github.com> Date: Mon, 16 Jan 2023 16:53:31 +0100 Subject: [PATCH 12/17] Update npm-publish.yml --- .github/workflows/npm-publish.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml index 4ad16067..c0966042 100644 --- a/.github/workflows/npm-publish.yml +++ b/.github/workflows/npm-publish.yml @@ -16,7 +16,6 @@ jobs: with: node-version: 16 - run: cd pw/pw-jwt-oauth/client && npm ci - - run: cd pw/pw-jwt-oauth/client && npm test publish-npm: needs: build From 6eaad0256294cd2d5b63d7d7d5399b58e6a90270 Mon Sep 17 00:00:00 2001 From: DpMarine <60691542+DpMarine@users.noreply.github.com> Date: Mon, 16 Jan 2023 16:59:33 +0100 Subject: [PATCH 13/17] Update package.json --- pw/pw-jwt-oauth/client/package.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pw/pw-jwt-oauth/client/package.json b/pw/pw-jwt-oauth/client/package.json index 5b9af23d..bd516aaf 100644 --- a/pw/pw-jwt-oauth/client/package.json +++ b/pw/pw-jwt-oauth/client/package.json @@ -8,7 +8,6 @@ "watch": "ng build --watch --configuration development", "test": "ng test" }, - "private": true, "dependencies": { "@angular/animations": "~13.0.0", "@angular/common": "~13.0.0", @@ -37,4 +36,4 @@ "karma-jasmine-html-reporter": "~1.7.0", "typescript": "~4.4.3" } -} \ No newline at end of file +} From 82a852250061ec39021a8c483dd31975644b034e Mon Sep 17 00:00:00 2001 From: Nicolas B <46492476+nicolegrimpeur@users.noreply.github.com> Date: Mon, 16 Jan 2023 15:10:59 +0100 Subject: [PATCH 14/17] Revert "Delete deploy-pages-action.yml" This reverts commit 3220371281de4819540c5749bcd24e0b45f8c94c. --- .github/workflows/deploy-pages-action.yml | 25 +++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .github/workflows/deploy-pages-action.yml diff --git a/.github/workflows/deploy-pages-action.yml b/.github/workflows/deploy-pages-action.yml new file mode 100644 index 00000000..78bdc7a9 --- /dev/null +++ b/.github/workflows/deploy-pages-action.yml @@ -0,0 +1,25 @@ +name: Build and Deploy to github pages + +on: + push: + branches: + - main +jobs: + build-and-deploy: + runs-on: ubuntu-latest + steps: + - name: Checkout 🛎️ + uses: actions/checkout@v3.0.0 + + - name: Install and Build 🔧 # This example project is built using npm and outputs the result to the 'build' folder. Replace with the commands required to build your project, or remove this step entirely if your site is pre-built. + run: | + cd docs + npm ci + npm run docs:build + + - name: Deploy 🚀 + uses: JamesIves/github-pages-deploy-action@v4.2.5 + with: + branch: gh-pages # The branch the action should deploy to. + folder: docs/.vuepress/dist # The folder the action should deploy. + single-commit: true From 1f36f8d79c4a4f4a340da0a170487948c4eb9e92 Mon Sep 17 00:00:00 2001 From: Nicolas Date: Mon, 23 Jan 2023 17:05:38 +0100 Subject: [PATCH 15/17] Passage en jar --- pw/pw-jwt-oauth/server/pom.xml | 1 - 1 file changed, 1 deletion(-) diff --git a/pw/pw-jwt-oauth/server/pom.xml b/pw/pw-jwt-oauth/server/pom.xml index bcc04463..e5270cb8 100644 --- a/pw/pw-jwt-oauth/server/pom.xml +++ b/pw/pw-jwt-oauth/server/pom.xml @@ -12,7 +12,6 @@ nicob.nicolegrimpeur.bookstore bookstore 0.0.1-SNAPSHOT - war Bookstore From d2856992139aa69522eb383a0b6d69fb5dc18c3d Mon Sep 17 00:00:00 2001 From: Nicolas B <46492476+nicolegrimpeur@users.noreply.github.com> Date: Mon, 23 Jan 2023 17:16:23 +0100 Subject: [PATCH 16/17] Update package.json --- pw/pw-jwt-oauth/client/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pw/pw-jwt-oauth/client/package.json b/pw/pw-jwt-oauth/client/package.json index bd516aaf..d913553e 100644 --- a/pw/pw-jwt-oauth/client/package.json +++ b/pw/pw-jwt-oauth/client/package.json @@ -1,6 +1,6 @@ { "name": "secure-angular-training-app", - "version": "0.0.0", + "version": "0.0.1", "scripts": { "ng": "ng", "start": "ng serve", From e79a99c43ff547a009ee90acd0555a673ef376ec Mon Sep 17 00:00:00 2001 From: Nicolas B <46492476+nicolegrimpeur@users.noreply.github.com> Date: Mon, 6 Feb 2023 14:58:04 +0100 Subject: [PATCH 17/17] Update package.json --- pw/pw-jwt-oauth/client/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pw/pw-jwt-oauth/client/package.json b/pw/pw-jwt-oauth/client/package.json index d913553e..20189826 100644 --- a/pw/pw-jwt-oauth/client/package.json +++ b/pw/pw-jwt-oauth/client/package.json @@ -1,6 +1,6 @@ { "name": "secure-angular-training-app", - "version": "0.0.1", + "version": "0.0.2", "scripts": { "ng": "ng", "start": "ng serve",