Skip to content

Commit

Permalink
Merge pull request #629 from noi-techpark/development
Browse files Browse the repository at this point in the history
putting current state in production
  • Loading branch information
RudiThoeni authored Oct 17, 2024
2 parents 212bfe2 + f359d07 commit 969ab5c
Show file tree
Hide file tree
Showing 182 changed files with 4,859 additions and 800 deletions.
99 changes: 48 additions & 51 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ jobs:
VITE_APP_IMAGE_UPLOAD_URL: "https://api.tourism.testingmachine.eu/v1/FileUpload/Image"
VITE_APP_FILE_UPLOAD_URL: "https://api.tourism.testingmachine.eu/v1/FileUpload/"
VITE_APP_ODH_LOOKUP_BASE_URL: "https://api.tourism.testingmachine.eu"
VITE_APP_HOTJAR_ID: "3316333"
VITE_APP_ENV_BADGE: "TESTING"
steps:
- name: Checkout source code
Expand Down Expand Up @@ -74,55 +73,54 @@ jobs:
docker-password: ${{ secrets.GH_PERSONAL_ACCESS_TOKEN }}
project-name: ${{ env.PROJECT_NAME }}

deploy-beta:
runs-on: ubuntu-22.04
if: github.ref == 'refs/heads/main'
needs: test
concurrency: deploy-beta
env:
SERVER_PORT: 1005
DOCKER_TAG: ${{ github.sha }}-beta
VITE_APP_KEYCLOAK_URL: "https://auth.opendatahub.com/auth"
VITE_APP_KEYCLOAK_REALM: "noi"
VITE_APP_KEYCLOAK_CLIENT_ID: "it.bz.opendatahub.databrowser"
VITE_APP_KEYCLOAK_REDIRECT_URI: "https://v2-beta.databrowser.opendatahub.com/silent-check-sso.html"
VITE_APP_IMAGE_UPLOAD_URL: "https://tourism.opendatahub.com/v1/FileUpload/Image"
VITE_APP_FILE_UPLOAD_URL: "https://tourism.opendatahub.com/v1/FileUpload"
VITE_APP_ODH_LOOKUP_BASE_URL: "https://tourism.opendatahub.com"
VITE_APP_HOTJAR_ID: "3316285"
VITE_APP_ENV_BADGE: "BETA"
steps:
- name: Checkout source code
uses: actions/checkout@v2
- name: Build code
uses: noi-techpark/github-actions/npm-build@v2
with:
working-directory: databrowser
node-version: ${{ env.NODE_VERSION }}
- name: Create .env file
uses: noi-techpark/github-actions/env-file@v2
with:
working-directory: ${{ env.WORKING_DIRECTORY }}
env:
X_COMPOSE_PROJECT_NAME: ${{ env.PROJECT_NAME }}
X_SERVER_PORT: ${{ env.SERVER_PORT }}
X_DOCKER_IMAGE: ${{ env.DOCKER_IMAGE }}
X_DOCKER_TAG: ${{ env.DOCKER_TAG }}
- name: Build and push images
uses: noi-techpark/github-actions/docker-build-and-push@v2
with:
working-directory: infrastructure
docker-username: ${{ github.actor }}
docker-password: ${{ secrets.GITHUB_TOKEN }}
- name: Deploy application
uses: noi-techpark/github-actions/docker-deploy@v2
with:
working-directory: infrastructure/ansible
hosts: "prod"
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
docker-username: "noi-techpark-bot"
docker-password: ${{ secrets.GH_PERSONAL_ACCESS_TOKEN }}
project-name: ${{ env.PROJECT_NAME }}
# deploy-beta:
# runs-on: ubuntu-22.04
# if: github.ref == 'refs/heads/main'
# needs: test
# concurrency: deploy-beta
# env:
# SERVER_PORT: 1005
# DOCKER_TAG: ${{ github.sha }}-beta
# VITE_APP_KEYCLOAK_URL: "https://auth.opendatahub.com/auth"
# VITE_APP_KEYCLOAK_REALM: "noi"
# VITE_APP_KEYCLOAK_CLIENT_ID: "it.bz.opendatahub.databrowser"
# VITE_APP_KEYCLOAK_REDIRECT_URI: "https://v2-beta.databrowser.opendatahub.com/silent-check-sso.html"
# VITE_APP_IMAGE_UPLOAD_URL: "https://tourism.opendatahub.com/v1/FileUpload/Image"
# VITE_APP_FILE_UPLOAD_URL: "https://tourism.opendatahub.com/v1/FileUpload"
# VITE_APP_ODH_LOOKUP_BASE_URL: "https://tourism.opendatahub.com"
# VITE_APP_ENV_BADGE: "BETA"
# steps:
# - name: Checkout source code
# uses: actions/checkout@v2
# - name: Build code
# uses: noi-techpark/github-actions/npm-build@v2
# with:
# working-directory: databrowser
# node-version: ${{ env.NODE_VERSION }}
# - name: Create .env file
# uses: noi-techpark/github-actions/env-file@v2
# with:
# working-directory: ${{ env.WORKING_DIRECTORY }}
# env:
# X_COMPOSE_PROJECT_NAME: ${{ env.PROJECT_NAME }}
# X_SERVER_PORT: ${{ env.SERVER_PORT }}
# X_DOCKER_IMAGE: ${{ env.DOCKER_IMAGE }}
# X_DOCKER_TAG: ${{ env.DOCKER_TAG }}
# - name: Build and push images
# uses: noi-techpark/github-actions/docker-build-and-push@v2
# with:
# working-directory: infrastructure
# docker-username: ${{ github.actor }}
# docker-password: ${{ secrets.GITHUB_TOKEN }}
# - name: Deploy application
# uses: noi-techpark/github-actions/docker-deploy@v2
# with:
# working-directory: infrastructure/ansible
# hosts: "prod"
# ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
# docker-username: "noi-techpark-bot"
# docker-password: ${{ secrets.GH_PERSONAL_ACCESS_TOKEN }}
# project-name: ${{ env.PROJECT_NAME }}

deploy-prod:
runs-on: ubuntu-22.04
Expand All @@ -139,7 +137,6 @@ jobs:
VITE_APP_IMAGE_UPLOAD_URL: "https://tourism.opendatahub.com/v1/FileUpload/Image"
VITE_APP_FILE_UPLOAD_URL: "https://tourism.opendatahub.com/v1/FileUpload"
VITE_APP_ODH_LOOKUP_BASE_URL: "https://tourism.opendatahub.com"
VITE_APP_HOTJAR_ID: "3316285"
steps:
- name: Checkout source code
uses: actions/checkout@v2
Expand Down
1 change: 0 additions & 1 deletion databrowser/.env.example
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,4 @@ VITE_APP_KEYCLOAK_REDIRECT_URI=http://localhost:3000/silent-check-sso.html
VITE_APP_IMAGE_UPLOAD_URL=https://api.tourism.testingmachine.eu/v1/FileUpload/Image
VITE_APP_FILE_UPLOAD_URL=https://api.tourism.testingmachine.eu/v1/FileUpload
VITE_APP_ODH_LOOKUP_BASE_URL=https://api.tourism.testingmachine.eu
VITE_APP_HOTJAR_ID=123456
VITE_APP_ENV_BADGE=TESTING
15 changes: 12 additions & 3 deletions databrowser/guideline.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ If something is not specified below, it is advisable to try to search for a simi

- [Coding Style](#coding-style)
- [Platform assumptions](#platform-assumptions)
- [Deprecations](#deprecations)
- [Reuse Compliance](#reuse-compliance)

### Coding Style
Expand All @@ -31,7 +32,7 @@ withDefaults(
);
```

2. The Tailwind classes shall be included in the Elements template and non separated in the <style> section of the component.
2. The Tailwind classes shall be included in the Elements template and non separated in the `<style>` section of the component.
3. Date manipulation should be performed using the date-fns library [https://date-fns.org/](https://date-fns.org/).
4. SVGs should be inserted without fixed dimensions, without safety spaces, and without specifying the fill/stroke color. Instead, the currentColor property should be used.
5. Plugins/libraries that are not useful throughout the project should only be included asynchronously in the individual component and not in main.ts, using the following method:
Expand Down Expand Up @@ -61,10 +62,18 @@ const MyLibrary = defineAsyncComponent(() =>
3. The list of components included in registerForComponentRender.ts must be entered in alphabetical order.
4. As a general rule, avoid retrieving data within your component. If it's necessary to do so, please ask for before on GitHub.

### Deprecations

#### TooltipCustom Component Deprecation

- **What:** The `TooltipCustom` component will be deprecated in the future.
- **Why:** The functionalities of `TooltipCustom` largely overlap with `PopoverCustom`, which is more widely used throughout the project. To simplify maintenance and improve consistency, we will remove `TooltipCustom` in favor of `PopoverCustom`.
- **Alternative:** Use the `PopoverCustom` component instead of `TooltipCustom` for similar functionality in all future implementations.

### Reuse Compliance

1. All files either have to be mentioned in the [dep5](/.reuse/dep5) file of the project or contain a header containing SPDX copyright and licensing information.
2. Files which cannot recieve a header e.g. .json or .png files should not have a respective FILE_NAME.FILE_EXT.license file (as would also compliant with the REUSE standards) but rather be mentioned in the dep5 file.
3. Configuration or informative files e.g. .md or .config.js files should be licensed CC0-1.0, preferably within their header.
3. Configuration or informative files e.g. .md or .config.js files should be licensed CC0-1.0, preferably within their header.
4. Source code files should be licensed AGPL-3.0-or-later, preferably within their header.
4. Find more information about REUSE guidelines in NOI Techpark projects [here](https://github.com/noi-techpark/odh-docs/wiki/REUSE)
5. Find more information about REUSE guidelines in NOI Techpark projects [here](https://github.com/noi-techpark/odh-docs/wiki/REUSE)
62 changes: 26 additions & 36 deletions databrowser/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions databrowser/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
"vue-diff": "^1.2.4",
"vue-draggable-next": "^2.1.1",
"vue-fuse": "^4.1.1",
"vue-hotjar-next": "^1.4.0",
"vue-i18n": "^9.2.2",
"vue-json-pretty": "^2.2.3",
"vue-router": "^4.2.2"
Expand All @@ -56,9 +55,9 @@
"openapi-types": "^12.1.3",
"postcss": "^8.4.20",
"prettier": "^2.8.8",
"tailwindcss": "^3.3.2",
"tailwindcss": "^3.4.12",
"typescript": "^5.0.4",
"vite": "^5.0.11",
"vue-tsc": "^1.8.27"
}
}
}
Loading

0 comments on commit 969ab5c

Please sign in to comment.