Skip to content

Commit

Permalink
remove vue.js pages from deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
sboeckelmann committed Jun 20, 2024
1 parent aaec162 commit 8f7677d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 114 deletions.
106 changes: 1 addition & 105 deletions .github/workflows/maven-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,58 +9,9 @@ on:
- 'v*'

jobs:
build-vue-js-job:
runs-on: ubuntu-latest
steps:
- name: checkout git submodules
uses: actions/checkout@v4
with:
submodules: recursive

- name: Checkout openepcis-web
uses: actions/checkout@v4
with:
repository: "openepcis/openepcis-web.git"
github-server-url: "https://code.company-group.com"
path: modules/openepcis-web
ref: "main"
token: ${{ secrets.OPENEPCIS_WEB_TOKEN }}

- name: vus.js ui build
uses: actions/setup-node@v4
with:
node-version: 20

- name: "Create VUE.JS Artifact"
run: |
cd modules/openepcis-web
export API_URL="../api"
export COPYRIGHT_TEXT="Copyright benelog GmbH & Co. KG | 2023-2024"
export NUXT_APP_BASE_URL="/ui/"
export ACTIVATE_FEATURES=input-template
cd openepcis-components
npm install
cd ../openepcis-test-data-generator
npm install
cd ../openepcis-tools
npm install
cd ../openepcis-test-data-designer
npm install
npm run generate
cd ../..
- name: 'Upload VUE.JS Artifact'
if: contains(github.ref, 'v')
uses: actions/upload-artifact@v4
with:
name: 'testdata-generator-ui-dist'
path: 'modules/openepcis-web/openepcis-test-data-designer/.output/public'



build-jar-job:
runs-on: ubuntu-latest
needs: [ build-vue-js-job ]
steps:
- name: checkout git submodules
uses: actions/checkout@v4
Expand Down Expand Up @@ -89,19 +40,6 @@ jobs:
cat <(echo -e "${{ secrets.OSSRH_GPG_SECRET_KEY }}") | gpg --batch --import
gpg --batch --list-secret-keys --keyid-format LONG
- name: 'Download VUE.JS Artifact'
if: contains(github.ref, 'v')
uses: actions/download-artifact@v4
with:
name: 'testdata-generator-ui-dist'
path: 'modules/openepcis-web/openepcis-test-data-designer/.output/public'

- name: "integrate vus.js ui into quarkus rest api"
run: |
rm -Rf testdata-generator-quarkus-rest-app/src/main/resources/static-web/ui
mv modules/openepcis-web/openepcis-test-data-designer/.output/public testdata-generator-quarkus-rest-app/src/main/resources/static-web/ui
shell: "bash"

- name: deploy testdata generator modules
env:
OPENEPCIS_OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
Expand Down Expand Up @@ -173,7 +111,6 @@ jobs:

build-quarkus-container-images:
name: "Build Container Images"
needs: [ build-vue-js-job ]
runs-on: 'ubuntu-latest'
steps:
- name: checkout from git
Expand Down Expand Up @@ -207,19 +144,6 @@ jobs:
distribution: 'graalvm-community'
cache: maven

- name: 'Download VUE.JS Artifact'
if: contains(github.ref, 'v')
uses: actions/download-artifact@v4
with:
name: 'testdata-generator-ui-dist'
path: 'modules/openepcis-web/openepcis-test-data-designer/.output/public'

- name: "integrate vus.js ui into quarkus rest api"
run: |
rm -Rf testdata-generator-quarkus-rest-app/src/main/resources/static-web/ui
mv modules/openepcis-web/openepcis-test-data-designer/.output/public testdata-generator-quarkus-rest-app/src/main/resources/static-web/ui
shell: "bash"

- name: "Prepare Build"
run: >
mvn --no-transfer-progress --batch-mode clean package -Pci-build -DskipTests
Expand Down Expand Up @@ -268,7 +192,6 @@ jobs:

build-quarkus-native-container-images:
name: "Build Native Container Image"
needs: [ build-vue-js-job ]

strategy:
matrix:
Expand Down Expand Up @@ -310,19 +233,6 @@ jobs:
distribution: 'graalvm-community'
cache: maven

- name: 'Download VUE.JS Artifact'
if: contains(github.ref, 'v')
uses: actions/download-artifact@v4
with:
name: 'testdata-generator-ui-dist'
path: 'testdata-generator-ui/dist'

- name: "integrate vus.js ui into quarkus rest api"
run: |
rm -Rf testdata-generator-quarkus-rest-app/src/main/resources/static-web/ui
mv testdata-generator-ui/dist testdata-generator-quarkus-rest-app/src/main/resources/static-web/ui
shell: "bash"

- name: "Prepare Build"
run: >
mvn --no-transfer-progress --batch-mode clean package -Pci-build -DskipTests
Expand Down Expand Up @@ -378,7 +288,7 @@ jobs:
build-quarkus-native-executable:
name: "Build Quarkus Service Native Executable"
needs: [build-jar-job, build-vue-js-job]
needs: [build-jar-job]

strategy:
matrix:
Expand Down Expand Up @@ -438,20 +348,6 @@ jobs:
native-image-job-reports: 'true'
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: 'Download VUE.JS Artifact'
if: contains(github.ref, 'v')
uses: actions/download-artifact@v4
with:
name: 'testdata-generator-ui-dist'
path: 'testdata-generator-ui/dist'

- name: "integrate vus.js ui into quarkus rest api"
run: |
rm -Rf testdata-generator-quarkus-rest-app/src/main/resources/static-web/ui
mv testdata-generator-ui/dist testdata-generator-quarkus-rest-app/src/main/resources/static-web/ui
shell: "bash"


- name: "Prepare Build"
run: |
mvn --no-transfer-progress --batch-mode -Pci-build clean package -DskipTests
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,18 +55,10 @@ public JsonFactory createJsonFactory() {
return new JsonFactory().setCodec(objectMapper);
}


@Route(regex = "/ui/.*", path = "ui/index.html", methods = Route.HttpMethod.GET)
@Operation(hidden = true)
@jakarta.ws.rs.Produces(MediaType.TEXT_HTML)
void ui(RoutingContext rc) {
StaticHandler.create(FileSystemAccess.RELATIVE, "static-web").handle(rc);
}

@Route(path = "/", methods = Route.HttpMethod.GET)
@Operation(hidden = true)
void baseUrl(RoutingContext rc) {
rc.redirect("/ui/");
rc.redirect("/q/swagger-ui/");
}

}

0 comments on commit 8f7677d

Please sign in to comment.