Installer not showing as complete



  • Hello all,

    I've recently gotten PufferPanel/Scales setup in a development environment and I've encountered a small problem that I can't seem to figure out. So that you can properly assess my situation I'll will provide details about my current setup.

    Pufferpanel is setup on 3 separate servers, all of which process PHP on their own but share the same MYSQL server and Memcached server for sessions. All 3 of these servers are load balanced, I understand that this is a very non-standard PP setup but other than this small problem everything else is working great. The domain is also behind Cloudflare which points to the Load Balancer, all Cloudflare features are disabled, its only acting as a proxy. My goal is to verify that the problem I am having is not caused by my custom setup.

    When I create a new server Scales successfully creates and installs the gameserver, but PP is not notified that the installation is complete, which forces me to use the "Force Installer Completion" button. Scales is aware that the installation is complete and claims to have notified PP:

    [2016-12-13 23:02:43] [VERBOSE] Installer process has completed for for 886e4b93-d297-41cc-9eb8-743fe60c31db
    [2016-12-13 23:02:43] [VERBOSE] Major install process completed and PufferPanel notified.

    Everything works fine after I force the installer completion, but I would like the process to be automatic. If anyone has any information or ideas please let me know!

    ps. All 3 web nodes are Ubuntu 16.04 running PHP-7/NGINX.

    Thanks!



  • Had the same problem. If the window displays it's done you can force complete without a problem.
    If you want that process automated you could do it with a JavaScript I think.

    The code for the force install button is

    <form action="{{ server.id }}/override" id="overrideInstaller" method="POST">
        <input type="submit" name="override" class="btn btn-sm btn-danger" value="Force installer completion">
    </form>
    

    that means the action we need to perform in JS when the ConsoleLog contains a certain string is {{ server.id }}/override

    so you could basically check the textarea [which has the ID "live_console" above for the query
    [VERBOSE] Major install process completed and PufferPanel notified.
    and then just submit the button programmatically

    Like that:

    //We get the value we need from the lice_console here
    var log = document.getElementById('live_console');
    var finishedflag = '[VERBOSE] Major install process completed and PufferPanel notified.';
    var val=log.value;
    if (val.indexOf(finishedflag)!=-1)
    {
        //Thne we just submit the form with JavaScript instead of making a new POST request
        //The ID of the form is "overrideInstaller"
        document.forms("overrideInstaller").submit();
        return;
    }
    

    This would go as script into [wherever you installed puffer]/app/views/admin/server/view.html
    So for me it's /srv/pufferpanel/app/views/admin/server/view.html

    Not sure if that works tho. I didn't test it.



  • @NullDev Hi, thanks for the reply!

    I really appreciate the help. I'm going to go test this and I'll report back soon.



  • Hi,

    Sadly I couldn't get this working, this is what I used:

    <script type="text/javascript">
    // Completion Status
          var log = document.getElementById('live_console');
          var finishedflag = 'Install completed successfully.';
          var val=log.value;
          if (val.indexOf(finishedflag)!=-1)
       {
    // Submit via JS
          document.forms("overrideInstaller").submit();
          return;
       }
    </script>
    

    I'm going to play around with it and see if I can figure it out.



  • Where did you put it?

    Maby do it with an interval

    <script type="text/javascript">  
       function checkLog(){
           var log = document.getElementById('live_console');
           var finishedflag = 'Install completed successfully.';
           var val=log.value;
           if (val.indexOf(finishedflag)!=-1){
               document.forms("overrideInstaller").submit();
           }
       }
       setInterval(checkLog, 1000);
    </script>
    

Log in to reply
 

Looks like your connection to PufferPanel Community was lost, please wait while we try to reconnect.