How Create a Limit-Template plan that allow install a Wordpress App

Discussion in 'Tips/Tricks/Mods' started by Luis Urbina G., Aug 18, 2019.

  1. Luis Urbina G.

    Luis Urbina G. New Member

    Hi guys
    I have a doudb, I want to know if it's possible on ISPconfig 3.1.14 that when I create a new hosting domain for a new client and select a special limit-template that trigger a script to create a wordpress automatically on a domain account to avoid my intervention and do everything automaticlly.
    the actions to do will be:
    1. Create a client with data received for parameters (I could do that right now) and select a special limit-template with all that I need to run Wordpress (space, variables, etc. this is possible when I create a limit-template)
    2. Install a Wordpress package from scratch automatically on this domain.
    3. And send a email to the new client with yours login credentials.

    It's possible? Or am I asking for a lot?
     
  2. nhybgtvfr

    nhybgtvfr Active Member

    you can create any client limit templates, so having 1 or more for specific wordpress installs (eg different space limits for personal wordpress site or business site) shouldn't be an issue.
    installing wordpress from scratch automatically. dunno. you may be able to start the aps package install via the api, never tried, so don't know for sure.
    you could via the api, create a temporary, fixed details, ssh user for the client account, and use eg ansible to install wordpress using wp-cli if installed on the server. you'd need to write the initial script. and I guess you'd need to include getting user details/site name etc for the install via the ispconfig api in that script along with scripting random password generation.
    email the client the login creds. I take it you mean the wordpress login details. doesn't wordpress automatically send those anyway?
    if not, it can be done as part of the wordpress installation script.
     
  3. Luis Urbina G.

    Luis Urbina G. New Member

    Thank you for your early answer NHYBGTVFR, that is the trick, could you give me any idea for How I could communicate with the ISPConfig API to try and had a hand the Api Doc Ref to review it, cause sounds good try to do by ssh?
    Thanks
     
  4. nhybgtvfr

    nhybgtvfr Active Member

    download and extract the ispconfig tar.
    the api stuff is somewhere within that, don't have one in front of me right now, so can't tell you the path.
    I believe the parameters for setting anything are the db table fields in that order. it should all be clearer when looking at the api examples and the database.
     
  5. Luis Urbina G.

    Luis Urbina G. New Member

    ok, Ths again
    I found this posted by Till once: https://git.ispconfig.org/ispconfig/ispconfig3/tree/master/remoting_client and reading I look a API Docs section and on the list I found a doc that talk about site aps install package: https://git.ispconfig.org/ispconfig...lient/API-docs/sites_aps_install_package.html I will review to try to understand it but thinking well I am thinking follow your advise and try to invoke a shell script to do a WP autoinstall on a specific client site using wp-cli could be more easy.
    thanks
     
  6. nhybgtvfr

    nhybgtvfr Active Member

    i'm not sure you can install an aps packaged wordpress automatically. it'll still ask on screen about databases, users, email addresses, passwords etc. so I don't think that can be fully automated.
    even using wp-cli, you'll need to specify some of those, you'll have to type them in at the start of the install, or use the ispconfig api to get the details and pass them in.
     
    Richard Foley likes this.

Share This Page