Has anyone successfully used Sendy.co in the LAMP app?



  • I am interesting in using Sendy (from sendy.co) but it would need to be in a LAMP app. Has anyone done this? If so, what pros or cons should I be aware of? Thank you.



  • @scooke Well, I'm going to go ahead and give it a try. I'll report back later.



  • @scooke It should work, let us know here if it doesn't.



  • Unfortunately I've run into a problem with the VPS from SSDnodes. I had used a VPS from them before for Cloudron and it worked fine. This time around the VPS differs somehow even though they say it is the same. The new VPS uses Virtuozzo for the KVM, and the disk is XFS. They claim all their VPSs are like this... so how did my Cloudron work last time on their machines? Anyways, I am trying to get that sorted out (isn't looking hopeful, just a lot of canned responses), so for now don't bother with SSDnodes for Cloudron.



  • @scooke Thanks, we will get in touch with SSDNodes



  • @girish Well, the issue was that the install script was failing at a check for the file system to be ext4. I wrote alot with ssdnodes support and we missed each other's points, it seemed to me. Finally I mentioned that some site I read said Docker needed ext4, and they responded saying they've had no issue with customers running Docker (but did that mean there is no one running Docker, or that customers are running Docker but haven't had problems?). So to find out I went and installed Docker and it worked. Apparently it works on XFS if there is some device driver something or other, overlay2. I checked and the VPS from SSDnodes, while running XFS, did have that overlay2, and thus Docker was running. So that made me wonder why Cloudron wouldn't run. So I actually edited out the ext4 check in the install script, and every thing installed fine, and thus far is running fine, mostly. I have noticed the Graphs page sometimes freezes, and displays only the RAM portion (for example, I have 12 GB RAM free), not the Disk Usage.

    So next I will try to migrate my sendy.co installation to the LAMP app on Cloudron.



  • @girish Well, I managed to upload the files, and the populate the db, but I have some questions about the db side since I get an error stating the app can't reach the db.

    The way the config file for sendy is written looks like this:

    /*  MySQL database connection credentials (please place values between the apostrophes) */
            $dbHost = 'localhost'; //MySQL Hostname
            $dbUser = 'mydbuser'; //MySQL Username
            $dbPass = 'mydnpasswd'; //MySQL Password
            $dbName = 'mydbname'; //MySQL Database Name
    

    The way cloudron's mysql add is written looks like this:

       getenv("MYSQL_HOST")
       getenv("MYSQL_PORT")
       gettenv("MYSQL_USERNAME")
       getenv("MYSQL_PASSWORD")
       getenv("MYSQL_DATABASE")
    
    1. do I even need to use a username and password since phpmyadmin tells me there are no privileges, and I can't seem to add any. Or is the username/passwrd the cloudron username/passwrd?
    2. How do I reconcile the two db configs? I am guessing that since they are written differently they won't be read the same?

    Thank you.



  • @scooke Yes, phpmyadmin requires the cloudron username/password and not the database username/password. When you login to phpmyadmin, you will get access to the database that has already been provisioned for the app.

    So, you want to edit sendy's config to look like this:

            $dbHost =    getenv("MYSQL_HOST");
            $dbUser =  getenv("MYSQL_USERNAME");
            $dbPass = getenv("MYSQL_PASSWORD");
            $dbName = getenv("MYSQL_DATABASE");
    

    Does that work?



  • @girish Hi, thank you for helping out. I understand that phpmyadmin requires the cloudron user/passwd, but the actual database info appears to be different. I ran sudo cloudron exec --app long-app-name env | grep MYSQL and it returned a db name, a user name, a password, and a MYSQL_URL (instead of localhost).

    So the info would then look like?:

            $dbHost = getenv("mysql://username:password@mysql/database");
            $dbUser = getenv("username");
            $dbPass = getenv("password");
            $dbName = getenv("database");
    

    I think the wording of Host is what's stopping the app from connecting to the db.
    I heard from the sendy.co dev and he said that the following should not be altered, so I am not sure what to do. I will try your suggestion, and let you know if it worked or not.

    /*  MySQL database connection credentials (please place values between the apostrophes) */
            $dbHost = 'localhost'; //MySQL Hostname
            $dbUser = 'mydbuser'; //MySQL Username
            $dbPass = 'mydnpasswd'; //MySQL Password
            $dbName = 'mydbname'; //MySQL Database Name
    


  • @scooke Can you ping me on our chat ? I feel I need to understand sendy a bit better to help you further



  • OK, this had to do with dbHost not being set correctly. Solved after that.



  • Much thanks to @girish for helping me figure out what was wrong. Sendy (sendy.co) is working well in the LAMP app. Yay! It was simply an issue of changing the
    $dbHost = 'localhost';

    to

    $dbHost = 'mysql';


Log in to reply