# Bug OP-18248 - The URL for the background job dialog is not generated correctly.

Project: OpenProject
Status: closed
URL: https://community.openproject.org/work_packages/OP-18248

## Open points

_No work packages_

## Details

| Attribute | Value |
| --- | --- |
| Date |  |
| Priority | High |
| Module | Modules and project features / Export, Frontend components and Primer design system |
| Target versions | 17.0.0 |
| Observed in versions | 16.6.0 |
| Sprint | 17.0.0 |
| Backlog bucket |  |
| Bug found in version (deprecated) | 16.6.x |
| Found in mobile app version |  |
| Follow-up feedback e-mail |  |
| Requires doc change | No |
| Accessibility | No |
| Pull preview |  |
| List |  |
| Labels |  |

## People

| Attribute | Value |
| --- | --- |
| Assignee |  |
| Accountable | Andrej Sandorf |
| Product manager |  |
| Developers | OP Dev Polaris Team |
| Designer |  |
| Ordered by |  |
| Signed off by |  |
| Interest by |  |

## Planning

| Attribute | Value |
| --- | --- |
| Relevance |  |

## Costs

| Attribute | Value |
| --- | --- |
| Votes |  |
| Work |  |
| Labor costs |  |

## Description

I have installed OpenProject 16.6.0 Community on my web server.

My OS is Oracle Linux 8.1.  
My web server is managed by Apache/2.4.37.  
On this server, it was decided that Apache would serve as a reverse proxy for OpenProject, and that it could be accessed this way: <https://apps.my-domain.com/openproject>.

OpenProject was installed using Docker Compose, with the configuration detailed below.

And Apache was configured using the configuration detailed below.

And everything worked correctly.

<br>

The problem is found in <https://apps.my-domain.com/openproject/projects>, within the Export option.

This modal is generated.

<img class="image_resized op-uc-image op-uc-image_inline" style="width:346px;" src="/api/v3/attachments/852543/content">

<br>

But when one selects any of the options, it is displayed like this:

<img class="image_resized op-uc-image op-uc-image_inline" style="width:468px;" src="/api/v3/attachments/852546/content">

And in the browser console, this is displayed: <https://apps.my-domain.com/job\_statuses/7b62175a-9eab-4f33-b091-faf4936e4d3a/dialog>. You can see that the generated URL doesn't have the "openproject/" subdirectory.

The suggestion to modify app/config.ru was tried, a suggestion found here: <https://community.openproject.org/topics/4787> (but it didn't work).

<br>

docker-compose.yml  
services:  
 openproject:  
   image: openproject/openproject:16.6.0-slim  
   container\_name: openproject  
   restart: always  
   ports:  
     - "8087:8080"

   \#un usuario administrador  
   user: "1000:1000"  
   environment:  
     SECRET\_KEY\_BASE: secret\_text  
     OPENPROJECT\_HOST\_\_NAME: apps.mi-dominio.com  
     OPENPROJECT\_HTTPS: true  
     OPENPROJECT\_RAILS\_\_RELATIVE\_\_URL\_\_ROOT: /openproject/  
     RAILS\_RELATIVE\_URL\_ROOT: /openproject/  
     DATABASE\_URL: postgresql://user:password@host:5432/database  
   volumes:  
     - /mnt/repositorio:/var/git\_repos:ro  
     - /mnt/proyectos:/var/openproject/assets:rw

Configuration of Apache

   RequestHeader set X-Forwarded-Proto "https"  
   RequestHeader set X-Forwarded-Ssl "on"  
   ProxyPreserveHost On  
   ProxyRequests Off  
   AllowEncodedSlashes NoDecode

   RequestHeader set X-Forwarded-Host "%{Host}e" env=Host  
   RequestHeader set X-Forwarded-Port "443"

   ProxyTimeout 60

   Header set Content-Security-Policy "object-src 'self' <https://releases.openproject.com>;"

   \# OPENPROJECT (Aplicación principal)  
   ProxyPass /openproject <http://localhost:8087/openproject> nocanon  
   ProxyPassReverse /openproject <http://localhost:8087/openproject>

   \# OPENPROJECT (Websockets para notificaciones en tiempo real) ws:// para la conexión interna  
   ProxyPass /openproject/websocket ws://localhost:8087/openproject/websocket nocanon  
   ProxyPassReverse /openproject/websocket ws://localhost:8087/openproject/websocket

   \# Soporte para WebSockets  
   Header always set Connection "Upgrade"  
   Header always set Upgrade "websocket"

It was tested on another server as a test, but Apache was configured as follows:

ProxyPass /openproject <http://localhost:8087> nocanon

ProxyPassReverse /openproject <http://localhost:8087>

And Docker Compose was configured as follows: OPENPROJECT\_HOST\_\_NAME=10.0.48.209:8087

That is, without a subdirectory, and that way it hasn't caused any problems. It has been theorized that it could be some script that does not take into account the absolute path (<https://apps.my-domain.com/openproject/>). Instead, it assumes that everything is in the root directory (<https://apps.my-domain.com/>).
