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

kie-tools#2695: [SonataFlow Management Console Image] Use mod_proxy to proxy request to the data-index #2750

Open
wants to merge 13 commits into
base: main
Choose a base branch
from

Conversation

fantonangeli
Copy link
Contributor

@fantonangeli fantonangeli commented Nov 18, 2024

Closes #2695

Description:
Currently, the SonataFlow Management Console attempts to trigger workflows using internal Endpoint URLs returned by the Data Index (DI). These URLs are not accessible from outside the cluster, leading to errors when users attempt to initiate workflows through the console.

Please configure Apache Httpd in the Image using mod_proxy to expose the Data-Index outside of the cluster, doing the communication on the server-side.

Preview:
kie-tools-issues#2695.webm

How to test:

  • Run the Docker Image Locally from packages/sonataflow-management-console-image

    1. This command will start the container and configure it to access your local data-index service from the container.
      Replace <HOST_IP_ADDRESS> with the IP address of your host machine.

      docker run --rm -it -p 8080:8080 \
        -e SONATAFLOW_MANAGEMENT_CONSOLE_KOGITO_ENV_MODE='DEV' \
        -e SONATAFLOW_MANAGEMENT_CONSOLE_DATA_INDEX_ENDPOINT='http://<HOST_IP_ADDRESS>:4000/graphql' \
        docker.io/apache/incubator-kie-sonataflow-management-console:main
    2. In a separate terminal, start Sonataflow Dev App for the Data Index service.

       cd ../sonataflow-dev-app
       pnpm start
  • There is also a pre-built image of this branch on my Quay profile:

quay.io/fabrizio_antonangeli/incubator-kie-sonataflow-management-console:kie-tools-issues-2695

@fantonangeli fantonangeli added the pr: DO NOT MERGE Draft PR, not ready for merging label Nov 19, 2024
@fantonangeli
Copy link
Contributor Author

Changed this PR to "DO NOT MERGE": Doing some extra tests I found a bug in the communication between MGMT deployment and DI deployment on OCP using SSL.

@fantonangeli
Copy link
Contributor Author

The fix is working on my OCP

@fantonangeli fantonangeli removed the pr: DO NOT MERGE Draft PR, not ready for merging label Nov 19, 2024
@tiagobento
Copy link
Contributor

Not blocking this PR, but this seems to fix a very specific problem on a very specific environment... Would it be possible to plan for some E2E tests that validate it?

@tiagobento tiagobento changed the title kie-tools-issues#2695: [SonataFlow Management Console Image] Use mod_proxy to proxy request to the data-index kie-tools#2695: [SonataFlow Management Console Image] Use mod_proxy to proxy request to the data-index Nov 22, 2024
@fantonangeli fantonangeli added pr: DO NOT MERGE Draft PR, not ready for merging pr: wip PR is still under development labels Dec 5, 2024
@fantonangeli
Copy link
Contributor Author

@ricardozanini now I'm trying with 172.18.0.1 , which should be the docker bridge IP and should not change between environments

…95-SonataFlow-Management-Console-Image-Use-modproxy-to-proxy-request-to-the-data-index
…95-SonataFlow-Management-Console-Image-Use-modproxy-to-proxy-request-to-the-data-index
…95-SonataFlow-Management-Console-Image-Use-modproxy-to-proxy-request-to-the-data-index
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:sonataflow pr: DO NOT MERGE Draft PR, not ready for merging pr: wip PR is still under development
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants