Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.

  • Staff

    @derin Is the site itself working and is only the REST API giving errors?

  • yes the site itself its totally working. Just the rest-api isnt, which is a problem because I intended to use it as my design template library. The core functionality requires the rest-api to work. Which is probably what caused it to error. My not deactivating the plugin before I packaged it for migration. Im just not sure how to go about fixing it.

    the site is

  • I had two plugins that used the rest api in a way that could have caused this, they are both deactivated and the error on the rest api still persists. Do i delete their options tables or amm I thinking in the wrong way? I got the same error when I tried to do anything related to the sites functions which prompted me to deactivate all plugins, problem persisted.

  • Staff

    The REST API does seem to work:

    $ curl -X OPTIONS -i
    HTTP/2 200 
    server: nginx
    date: Wed, 14 Oct 2020 04:12:14 GMT
    content-length: 0
    strict-transport-security: max-age=15768000
    x-xss-protection: 1; mode=block
    x-download-options: noopen
    x-content-type-options: nosniff
    x-permitted-cross-domain-policies: none
    referrer-policy: no-referrer-when-downgrade

    Could it be related to permalink style? It's under Settings in the WP dashboard (because I notice that your posts are of the year/month/date format)

  • Staff

    @derin If you go to the app's configure view and then Console -> Logs. It will probably show some error in the logs. Anything interesting there?

  • I didn't see anything out of the ordinary. Perhaps you will. log.txt

    If not I may just migrate again with all plugins deactivated prior to packaging to see if works.

  • Staff

    @derin I see the 404 in the logs

    2020-10-14T04:13:02.000Z - - [14/Oct/2020:04:13:02 +0000] "GET /2020/09/01/hello-world/ HTTP/1.1" 404 457 "" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:81.0) Gecko/20100101 Firefox/81.0"

    So, just to double check: the posts are inside the admin panel just fine but getting the pages like above doesn't work? Usually, this just means that either htaccess is messed up OR the permalink structure is wrong. When you navigate to the post via the WordPress Dashbaord what do you see in the URL bar?

  • Going to the posts is seems fine at the moment. The things that do not work are when the system tries to make an api call out. So for example, i attempted to re-authenticate a plugin - Envato Elements using my api key and it displayed the error shown above. Then I tried contect to an external website that this would feed data to using another plugin called Project Huddle, and I got the same API error. I actually had not attempted to even look at a post. This site will serve as a repository of elementor templates. So I can store all the templates I create and easily push changes to the client sites connected. There isnt a plan for a front end except to check if a template looks good.

    Created a test post which worked after I updated permalink structure which was set incorrectly.

  • Wait the permalink thing fixed the error I believe.