Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[4.1.x] fix: adapt Management API to serve the assets useful for template pre… #3077

Merged
merged 1 commit into from
Oct 6, 2023

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Oct 5, 2023

This is an automatic copy of pull request #3063 done by Mergify.


…view

in previous implementation assets were provided by the UI but behind reverse proxy

it was not working properly if some path transformations were put in place

fixes AM-754


Cherry-pick of ca3d99b has failed:

On branch mergify/bp/4.1.x/pr-3063
Your branch is up to date with 'origin/4.1.x'.

You are currently cherry-picking commit ca3d99b4dc.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   gravitee-am-management-api/gravitee-am-management-api-rest/src/main/java/io/gravitee/am/management/handlers/management/api/authentication/controller/LoginController.java
	modified:   gravitee-am-management-api/gravitee-am-management-api-rest/src/main/java/io/gravitee/am/management/handlers/management/api/preview/PreviewBuilder.java
	modified:   gravitee-am-management-api/gravitee-am-management-api-rest/src/main/java/io/gravitee/am/management/handlers/management/api/preview/PreviewService.java
	new file:   gravitee-am-management-api/gravitee-am-management-api-rest/src/main/java/io/gravitee/am/management/handlers/management/api/utils/RedirectUtils.java
	renamed:    gravitee-am-ui/src/assets/css/access_error.css -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/css/access_error.css
	renamed:    gravitee-am-ui/src/assets/css/main.css -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/css/main.css
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-500.eot -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-500.eot
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-500.svg -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-500.svg
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-500.ttf -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-500.ttf
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-500.woff -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-500.woff
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-500.woff2 -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-500.woff2
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-700.eot -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-700.eot
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-700.svg -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-700.svg
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-700.ttf -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-700.ttf
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-700.woff -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-700.woff
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-700.woff2 -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-700.woff2
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-900.eot -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-900.eot
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-900.svg -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-900.svg
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-900.ttf -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-900.ttf
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-900.woff -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-900.woff
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-900.woff2 -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-900.woff2
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-regular.eot -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-regular.eot
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-regular.svg -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-regular.svg
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-regular.ttf -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-regular.ttf
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-regular.woff -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-regular.woff
	renamed:    gravitee-am-ui/src/assets/font-roboto/roboto-v30-latin-regular.woff2 -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/font-roboto/roboto-v30-latin-regular.woff2
	renamed:    gravitee-am-ui/src/assets/fonts/MaterialIconsOutlined-Regular.otf -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/fonts/MaterialIconsOutlined-Regular.otf
	renamed:    gravitee-am-ui/src/assets/fonts/MaterialIconsOutlined-Regular.woff2 -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/fonts/MaterialIconsOutlined-Regular.woff2
	renamed:    gravitee-am-ui/src/assets/ico/favicon.ico -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/ico/favicon.ico
	renamed:    gravitee-am-ui/src/assets/images/FCboutons-10.svg -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/images/FCboutons-10.svg
	renamed:    gravitee-am-ui/src/assets/images/flags.png -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/images/flags.png
	renamed:    gravitee-am-ui/src/assets/images/[email protected] -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/images/[email protected]
	renamed:    gravitee-am-ui/src/assets/images/gravitee-logo.svg -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/images/gravitee-logo.svg
	renamed:    gravitee-am-ui/src/assets/images/invalid.svg -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/images/invalid.svg
	renamed:    gravitee-am-ui/src/assets/images/valid.svg -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/images/valid.svg
	renamed:    gravitee-am-ui/src/assets/js/intl-tel-input-17.0.8-utils.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/intl-tel-input-17.0.8-utils.js
	renamed:    gravitee-am-ui/src/assets/js/intl-tel-input-17.0.8.min.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/intl-tel-input-17.0.8.min.js
	renamed:    gravitee-am-ui/src/assets/js/jquery-3.5.1.min.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/jquery-3.5.1.min.js
	renamed:    gravitee-am-ui/src/assets/js/jspdf.umd.min.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/jspdf.umd.min.js
	renamed:    gravitee-am-ui/src/assets/js/password-validation-v2.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/password-validation-v2.js
	renamed:    gravitee-am-ui/src/assets/js/placeholder.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/placeholder.js
	renamed:    gravitee-am-ui/src/assets/js/remember-device/fingerprintjs-v3-pro.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/remember-device/fingerprintjs-v3-pro.js
	renamed:    gravitee-am-ui/src/assets/js/remember-device/fingerprintjs-v3.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/remember-device/fingerprintjs-v3.js
	renamed:    gravitee-am-ui/src/assets/js/webauthn-fido2-login.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/webauthn-fido2-login.js
	renamed:    gravitee-am-ui/src/assets/js/webauthn-login-v2.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/webauthn-login-v2.js
	renamed:    gravitee-am-ui/src/assets/js/webauthn-login.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/webauthn-login.js
	renamed:    gravitee-am-ui/src/assets/js/webauthn-register-v2.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/webauthn-register-v2.js
	renamed:    gravitee-am-ui/src/assets/js/webauthn-register.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/webauthn-register.js
	renamed:    gravitee-am-ui/src/assets/js/webauthn.auth-v2.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/webauthn.auth-v2.js
	renamed:    gravitee-am-ui/src/assets/js/webauthn.auth.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/js/webauthn.auth.js
	renamed:    gravitee-am-ui/src/assets/material/fonts/MaterialIcons-Regular.ttf -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/material/fonts/MaterialIcons-Regular.ttf
	renamed:    gravitee-am-ui/src/assets/material/fonts/MaterialIcons-Regular.woff -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/material/fonts/MaterialIcons-Regular.woff
	renamed:    gravitee-am-ui/src/assets/material/fonts/MaterialIcons-Regular.woff2 -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/material/fonts/MaterialIcons-Regular.woff2
	renamed:    gravitee-am-ui/src/assets/material/fonts/materialIcons-regular.eot -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/material/fonts/materialIcons-regular.eot
	renamed:    gravitee-am-ui/src/assets/material/material.blue_grey-blue.min.css -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/material/material.blue_grey-blue.min.css
	renamed:    gravitee-am-ui/src/assets/material/material.icons.css -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/material/material.icons.css
	renamed:    gravitee-am-ui/src/assets/material/material.min.js -> gravitee-am-management-api/gravitee-am-management-api-rest/src/main/resources/assets/preview/material/material.min.js
	modified:   gravitee-am-management-api/gravitee-am-management-api-rest/src/test/java/io/gravitee/am/management/handlers/management/api/preview/PreviewServiceTest.java
	modified:   gravitee-am-management-api/gravitee-am-management-api-rest/src/test/java/io/gravitee/am/management/handlers/management/api/resources/PreviewResourceTest.java
	modified:   pom.xml

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   gravitee-am-management-api/gravitee-am-management-api-rest/src/main/java/io/gravitee/am/management/handlers/management/api/resources/organizations/environments/domains/PreviewResource.java
	both modified:   gravitee-am-management-api/gravitee-am-management-api-rest/src/test/java/io/gravitee/am/management/handlers/management/api/JerseySpringTest.java
	both modified:   gravitee-am-ui/src/app/domain/settings/theme/theme.component.ts

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/github/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally

@mergify mergify bot requested a review from a team as a code owner October 5, 2023 11:18
@mergify mergify bot added the conflicts label Oct 5, 2023
…view

  in previous implementation assets were provided by the UI but behind reverse proxy

  it was not working properly if some path transformations were put in place

fixes AM-754

(cherry picked from commit ca3d99b)

# Conflicts:
#	gravitee-am-management-api/gravitee-am-management-api-rest/src/main/java/io/gravitee/am/management/handlers/management/api/resources/organizations/environments/domains/PreviewResource.java
#	gravitee-am-management-api/gravitee-am-management-api-rest/src/test/java/io/gravitee/am/management/handlers/management/api/JerseySpringTest.java
#	gravitee-am-ui/src/app/domain/settings/theme/theme.component.ts
@sonarcloud
Copy link

sonarcloud bot commented Oct 5, 2023

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 1 Code Smell

0.0% 0.0% Coverage
0.0% 0.0% Duplication

warning The version of Java (11.0.17) you have used to run this analysis is deprecated and we will stop accepting it soon. Please update to at least Java 17.
Read more here

idea Catch issues before they fail your Quality Gate with our IDE extension sonarlint SonarLint

@leleueri leleueri merged commit 24dc033 into 4.1.x Oct 6, 2023
25 of 26 checks passed
@leleueri leleueri deleted the mergify/bp/4.1.x/pr-3063 branch October 6, 2023 07:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant