CADViewer / NextCloud

CAD viewing, markup and collaboration on NextCloud for AutoCAD, MicroStation and advanced raster graphics.
GNU Affero General Public License v3.0
23 stars 3 forks source link

Issue with docker-compose - blank page #72

Closed overlaps1 closed 8 months ago

overlaps1 commented 1 year ago

Hi there,

Here is my setup:

Nginx ct as reverse proxy Caddy ct for lets-encrypt certificate Nextcloud ct

I have setup the permissions as mentionned on git and cadviewer doctor seems happy I have modified the .htaccess I have also modified in .htaccess "/apps/..." path to "/custom_apps/..." as of my nextcloud setup.

Here is the nextcloud log error:

,"app":"PHP","method":"POST","url":"/apps/cadviewer/ajax/cadviewer.php","message":"Undefined array key \"parameters\" at /var/www/html/custom_apps/cadviewer/lib/Controller/CadviewerController.php#302"

should PHP POST url be also "/custom_apps/...." ? in that case, where should I apply the right setup ?

Thanks

CADViewer commented 1 year ago

Hello @overlaps1 , I think you possibly inside your rewrite rules needs to add a Rewrite condition to include the proper path for the custom_apps path, please check your current .htaccsss and update accordingly. Below is the rewrite cond /rewrite rule only.

<IfModule mod_rewrite_c>
    RewriteCond %{REQUEST_FILENAME} !/custom_apps/cadviewer/converter/php/*\.*
    RewriteRule . index.php [PT,E=PATH_INFO:$1]
<IfModule>
overlaps1 commented 1 year ago

Thanks for your reply, I have done that already as mentionned in git readme file. but no success:

`<IfModule mod_rewrite.c>
  Options -MultiViews
  RewriteRule ^core/js/oc.js$ index.php [PT,E=PATH_INFO:$1]
  RewriteRule ^core/preview.png$ index.php [PT,E=PATH_INFO:$1]
  RewriteCond %{REQUEST_FILENAME} !\.(css|js|svg|gif|png|html|ttf|woff2?|ico|jpg|jpeg|map|webm|mp4|mp3|ogg|wav|wasm|tflite)$
  RewriteCond %{REQUEST_FILENAME} !/core/ajax/update\.php
  RewriteCond %{REQUEST_FILENAME} !/core/img/(favicon\.ico|manifest\.json)$
  RewriteCond %{REQUEST_FILENAME} !/(cron|public|remote|status)\.php
  RewriteCond %{REQUEST_FILENAME} !/ocs/v(1|2)\.php
  RewriteCond %{REQUEST_FILENAME} !/robots\.txt
  RewriteCond %{REQUEST_FILENAME} !/(ocm-provider|ocs-provider|updater)/
  RewriteCond %{REQUEST_URI} !^/\.well-known/(acme-challenge|pki-validation)/.*
  RewriteCond %{REQUEST_FILENAME} !/richdocumentscode(_arm64)?/proxy.php$
  RewriteCond %{REQUEST_FILENAME} !/custom_apps/cadviewer/converter/php/*\.*
  RewriteRule . index.php [PT,E=PATH_INFO:$1]
  RewriteBase /
  <IfModule mod_env.c>
    SetEnv front_controller_active true
    <IfModule mod_dir.c>
      DirectorySlash off
    </IfModule>
  </IfModule>
</IfModule>

`

overlaps1 commented 1 year ago

here is the full log line if it can help:

{"reqId":"mB6bF0XwOB2pw5lzF9Iy","level":3,"time":"2023-11-29T09:17:00+00:00","remoteAddr":"_external_ip_","user":"_username_","app":"PHP","method":"POST","url":"/apps/cadviewer/ajax/cadviewer.php","message":"Undefined array key \"lineWeightFactor\" at /var/www/html/custom_apps/cadviewer/lib/Controller/CadviewerController.php#276","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/119.0.0.0 Safari/537.36 Edg/119.0.0.0","version":"27.1.1.0","data":{"app":"PHP"}}

overlaps1 commented 1 year ago

from that I have 2 things that hit me: "remoteAddr":"_external_ip_" shouldn't it be the internal_ip ? "method":"POST","url":"/apps/cadviewer/ajax/cadviewer.php" shouldn't it be "method":"POST","url":"/custom_apps/cadviewer/ajax/cadviewer.php" ?

CADViewer commented 1 year ago

OK, we will try to emulate the setup and see what we get, will keep you posted.

overlaps1 commented 1 year ago

ok, thanks. If it helps, here is my setup: https://linuxiac.com/how-to-install-nextcloud-with-docker-compose/

CADViewer commented 1 year ago

thanks! - will revert in a few days -

Monoboy4ik commented 10 months ago

@overlaps1 try move /custom_apps/cadviewer to /apps/cadviewer and RewriteCond %{REQUEST_FILENAME} !/apps/cadviewer/converter/php/.

CADViewer commented 8 months ago

Hello @Monoboy4ik , with the latest version 9.47.1, we have added code to check the .httacess and update the rewrite conditions, and if there is insufficient permissions, we now provide an error message in the admin console with instructions. Please check this version and let us know! - If you have an issue, please re-open this ticket/create a new. - Thanks!

overlaps1 commented 8 months ago

Hi support team ! I didn't have time to check your Last resolution. I Will check asap. Thanks for your effort, it s really appreciated Keep on the good job

Envoyé de mon mobile Envoyé à partir de Outlook pour Androidhttps://aka.ms/AAb9ysg


From: CADViewer @.> Sent: Tuesday, March 5, 2024 11:08:51 AM To: CADViewer/NextCloud @.> Cc: overlaps1 @.>; Mention @.> Subject: Re: [CADViewer/NextCloud] Issue with docker-compose - blank page (Issue #72)

Hello @Monoboy4ikhttps://github.com/Monoboy4ik , with the latest version 9.47.1, we have added code to check the .httacess and update the rewrite conditions, and if there is insufficient permissions, we now provide an error message in the admin console with instructions. Please check this version and let us know! - If you have an issue, please re-open this ticket/create a new. - Thanks!

— Reply to this email directly, view it on GitHubhttps://github.com/CADViewer/NextCloud/issues/72#issuecomment-1978398742, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AY2NPXXD4W6HWXEILOEBA23YWWKTHAVCNFSM6AAAAAA77ED56GVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSNZYGM4TQNZUGI. You are receiving this because you were mentioned.Message ID: @.***>