How to Distribute EasyApache Files Over Multiple Servers

Overview

You can move EasyApache profiles between servers.

Profile are located in the /var/cpanel/easy/apache/profile/custom directory. The filename will be identical to the name with which you save it, plus the .yaml file extension.

After you finish a profile’s configuration, you can move it to the /var/cpanel/easy/apache/profile/custom directory on the destination server.

You can use any available data transfer protocols that you have available.  These protocols include the following:

  • SCP
  • FTP
  • SFTP
  • rsync

Example

For example, the following steps demonstrate how to move a profile called myprofile.yaml with scp:

  1. Run the following command at the command line as the root user:
    1
    scp /var/cpanel/easy/apache/profile/custom/myprofile.yaml !root@$IP:/var/cpanel/easy/apache/profile/custom/myprofile.yaml

    Note:

     Replace $IP with the IP address of the machine to which you wish to connect

  2. If you choose not to use key authentication, enter the password when you are prompted.
    • The file will transfer to the /var/cpanel/easy/apache/profile/custom directory on the destination server.
  3. Run the following command on the new server:
    1
    /scripts/easyapache --build --profile=myprofile

Remember:

  • You may also copy raw opts (custom configure flags) and environment variables with the same method and transfer them to the appropriate directory on the new server.
  • You will also need to transfer the Apache profile’s preferences file (/var/cpanel/easy/apache/prefs.yaml) to the remote server.
Advertisement

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s