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


Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Bookmarks
  • Search
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

Cloudron Forum

Apps | Demo | Docs | Install
  1. Cloudron Forum
  2. LAMP
  3. Web app installer on LAMP Cloudron cannot connect to server.

Web app installer on LAMP Cloudron cannot connect to server.

Scheduled Pinned Locked Moved Solved LAMP
9 Posts 4 Posters 1.6k Views 4 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • ShaiS Offline
      ShaiS Offline
      Shai
      wrote on last edited by
      #1

      I'm trying to install the photo management app Piwigo onto a Lamp Cloudron.

      The Piwigo web installer is saying it cannot connect to the database.

      I can log into the database via phpmyadmin.

      On the installer fields on the web form I'm using the explicit credentials for mysql found in /app/data/credentials.txt. (My plan was to manually edit the file created by the installer after installation and replace the explicit credentials with the environment variables. I didn't get that far.)

      Upon submit of the web form installer I get the error "Cannot connect to server."

      Any ideas?

      J 1 Reply Last reply
      0
      • ShaiS Shai

        I'm trying to install the photo management app Piwigo onto a Lamp Cloudron.

        The Piwigo web installer is saying it cannot connect to the database.

        I can log into the database via phpmyadmin.

        On the installer fields on the web form I'm using the explicit credentials for mysql found in /app/data/credentials.txt. (My plan was to manually edit the file created by the installer after installation and replace the explicit credentials with the environment variables. I didn't get that far.)

        Upon submit of the web form installer I get the error "Cannot connect to server."

        Any ideas?

        J Offline
        J Offline
        JLX89
        wrote on last edited by JLX89
        #2

        @shai Did you go into the file manager and ensure the file permissions in /app/data/public/ are set to www-data? I had this issue a little while back and that was the issue.

        ShaiS 1 Reply Last reply
        0
        • J JLX89

          @shai Did you go into the file manager and ensure the file permissions in /app/data/public/ are set to www-data? I had this issue a little while back and that was the issue.

          ShaiS Offline
          ShaiS Offline
          Shai
          wrote on last edited by
          #3

          @jlx89 File ownership is www-data. File permissions are 777 for the config directory.

          1 Reply Last reply
          0
          • scookeS Offline
            scookeS Offline
            scooke
            wrote on last edited by scooke
            #4

            Is it not connecting to the db before the DB configuration page appears? Or after you've entered the info and pressed "Start Installation"? One thing that I regularly overlook is that the Connection ("Host" at the top of the 'Database connection' section) is not the usual "localhost", but "mysql" for the LAMP app. Be sure you've used that before we try to figure out anything else.

            A life lived in fear is a life half-lived

            ShaiS 1 Reply Last reply
            0
            • scookeS scooke

              Is it not connecting to the db before the DB configuration page appears? Or after you've entered the info and pressed "Start Installation"? One thing that I regularly overlook is that the Connection ("Host" at the top of the 'Database connection' section) is not the usual "localhost", but "mysql" for the LAMP app. Be sure you've used that before we try to figure out anything else.

              ShaiS Offline
              ShaiS Offline
              Shai
              wrote on last edited by
              #5

              @scooke I get the error after I've entered the values and clicked "start installation."

              Yes, I know that "mysql" is the value for "host" and not "localhost".

              Thanks in advance for further troubleshooting.

              murgeroM 1 Reply Last reply
              0
              • scookeS Offline
                scookeS Offline
                scooke
                wrote on last edited by
                #6

                Is the included .htaccess file messing things up in the public folder of the LAMP app? Try renaming it. I'm going to try an install myself tomorrow and see what pops up.

                A life lived in fear is a life half-lived

                1 Reply Last reply
                0
                • ShaiS Shai

                  @scooke I get the error after I've entered the values and clicked "start installation."

                  Yes, I know that "mysql" is the value for "host" and not "localhost".

                  Thanks in advance for further troubleshooting.

                  murgeroM Offline
                  murgeroM Offline
                  murgero
                  App Dev
                  wrote on last edited by
                  #7

                  @shai Hello,

                  I was able to get this going by following the on screen instructions.

                  the database name and username are the same here, make sure to read credentials.txt in /app/data/ folder as well.

                  Can you show any logs during the install, screenshots, etc so we can see what went wrong?

                  --
                  https://urgero.org
                  ~ Professional Nerd. Freelance Programmer. ~

                  ShaiS 1 Reply Last reply
                  2
                  • murgeroM murgero

                    @shai Hello,

                    I was able to get this going by following the on screen instructions.

                    the database name and username are the same here, make sure to read credentials.txt in /app/data/ folder as well.

                    Can you show any logs during the install, screenshots, etc so we can see what went wrong?

                    ShaiS Offline
                    ShaiS Offline
                    Shai
                    wrote on last edited by Shai
                    #8

                    @murgero I had downloaded the zip archive, pushed it to the Cloudron and then unzipped it. I got to the installer by just navigating to the site url. With the original method I never succeeded or figured out what the problem was.

                    However, I started over and this time used Piwigo's netinstaller option where I only push one php file and then navigate to that file... the install went perfectly, no problems connecting to db.

                    My next step is to manually go into the config file and replace the credentials there with Cloudron environment variables.

                    Thanks to you and @scooke and @JLX89 who responded with helpful suggestions.

                    scookeS 1 Reply Last reply
                    2
                    • ShaiS Shai

                      @murgero I had downloaded the zip archive, pushed it to the Cloudron and then unzipped it. I got to the installer by just navigating to the site url. With the original method I never succeeded or figured out what the problem was.

                      However, I started over and this time used Piwigo's netinstaller option where I only push one php file and then navigate to that file... the install went perfectly, no problems connecting to db.

                      My next step is to manually go into the config file and replace the credentials there with Cloudron environment variables.

                      Thanks to you and @scooke and @JLX89 who responded with helpful suggestions.

                      scookeS Offline
                      scookeS Offline
                      scooke
                      wrote on last edited by
                      #9

                      @shai Glad to hear it, I was going to give it a try this weekend, so this saves me a bit of time. Congrats.

                      A life lived in fear is a life half-lived

                      1 Reply Last reply
                      1
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                        • Login

                        • Don't have an account? Register

                        • Login or register to search.
                        • First post
                          Last post
                        0
                        • Categories
                        • Recent
                        • Tags
                        • Popular
                        • Bookmarks
                        • Search