My Blog

CakePHP on cloud

1-click AWS Deployment   1-click Azure Deployment 1-click Google Deployment

Overview

CakePHP makes building web applications simpler, faster and require less code.
CakePHP is a rapid development framework for PHP which uses commonly known design patterns like Active Record, Association Data Mapping, Front Controller and MVC.

CakePHP is owned by CakePHP (https://cakephp.org/) and they own all related trademarks and IP rights for this software.

Cognosys provides hardened and ready to run images of CakePHP on all public cloud ( AWS marketplace and Azure).
Deploy your CakePHP securely on cloud i.e. AWS marketplace and Azure with Reliable Services offered by Cognosys at one-click with easy written and video tutorials.

Secured CakePHP on Windows 2012 R2

         Secured cakephp on centos

CakePHP on cloud For AWS

CakePHP on cloud For Azure

Our primary goal is to provide a structured framework that enables PHP users at all levels to rapidly develop robust web applications, without any loss to flexibility.

Features

Major Features Of CakePHP

  • Build Quickly- Use code generation and scaffolding features to rapidly build prototypes.
  • No Configuration- No complicated XML or YAML files. Just setup your database and you’re ready to bake.
  • Friendly License- CakePHP is licensed under the MIT license which makes it perfect for use in commercial applications.
  • Batteries Included- The things you need are built-in. Translations, database access, caching, validation, authentication and much more are all built into one of the original PHP MVC frameworks.
  • Clean MVC Conventions- Instead of having to plan where things go, CakePHP comes with a set of conventions to guide you in developing your application.
  • Secure- CakePHP comes with built-in tools for input validation, CSRF protection, Form tampering protection, SQL injection prevention and XSS prevention, helping you keep your application safe & secure.

AWS

Installation Instructions For Ubuntu

Step 1) SSH Connection: To connect to the deployed instance, Please follow Instructions to Connect to Ubuntu instance on Azure Cloud

1) Download Putty.

2) Connect to virtual machine using following SSH credentials :

  • Hostname: PublicDNS  / IP of machine
  • Port : 22

Username: To connect to the operating system, use SSH and the username is ubuntu.
Password : Please Click here  to know how to  get password .

Step 2) Database Login Details :

  • MYSQL Username : root
  • MYSQL Password : Passw@rd123

Note :-Please change password immediately after first login.

Step 3) Application URL: Access the application via a browser at http://PublicDNS/Cakephp. 

Note: How to find PublicDNS in Azure

Step 4) Other Information:

1.Default installation path: will be in your web root folder “/var/www/html/cakephp”.

2.Default ports:

  • Linux Machines:  SSH Port – 22
  • Http: 80
  • Https: 443
  • Mysql ports: By default these are not open on Public Endpoints. Internally Mysql server: 3306


Configure custom inbound and outbound rules using this link

Installation Instructions for Windows

Note:  How to find PublicDNS in AWS

Step 1) RDP  Connection: To connect to the deployed instance, Please follow Instructions to Connect to Windows  instance on AWS Cloud

1) Connect to virtual machine using following RDP credentials :

  • Hostname: PublicDNS  / IP of machine
  • Port : 3389

Username: To connect to the operating system, use RDP and the username is Administrator.
Password : Please Click here  to know how to  get password .

Step 2) Database Login Details :

  • MYSQL Username : root
  • MYSQL Password : Passw@rd123

Please change the password immediately after the first login.

Step 3) Application URL: Access the application via a browser at http://PublicDNS/Cakephp

Step 4) Other Information:

1.Default installation path: will be in your web root folder “C:\inetpub\wwwroot\Cakephp
2.Default ports:

  • Windows Machines:  RDP Port – 3389
  • Http: 80
  • Https: 443
  • Mysql ports: By default these are not open on Public Endpoints. Internally Mysql server: 3306

Configure custom inbound and outbound rules using this link

AWS Step by Step Screenshots

Azure

Installation Instructions For Ubuntu

Version:- CakePHP 3.4.4

Note : How to find PublicDNS in Azure

Step 1) SSH Connection: To connect to the deployed instance, Please follow Instructions to Connect to Ubuntu instance on Azure Cloud

1) Download Putty.

2) Connect to virtual machine using following SSH credentials :

  • Hostname: PublicDNS  / IP of machine
  • Port : 22

Step 2) Database Login Details :

  • MYSQL Username : root
  • MYSQL Password : Passw@rd123

Note :-For Stack Database: DB cakephp with user cakephpuser and password Passw@rd123 has already been created.Please use this database for you Stack Configuration.
You can create a new cakephp application with below command
composer create-project –prefer-dist cakephp/app YourAppname
If you create a new app please change the path in Apache2 config

Note :-Please change password immediately after first login.

Step 3) Application URL: Access the application via a browser at http://PublicDNS/. 

Step 4) Other Information:
1.Default installation path: will be on your web root folder “/var/www/html/”.
2.Default ports:

    • Linux Machines:  SSH Port – 22
    • Http: 80
    • Https: 443
    • Sql or Mysql ports: By default these are not open on Public Endpoints. Internally Sql server: 1433. Mysql :3306


Configure custom inbound and outbound rules using this link

Installation Instructions for Windows

Note: How to find PublicDNS in Azure

Step1 ) RDP Connection: To connect to the deployed instance, Please follow Instructions to Connect to Windows instance on Azure Cloud

1) Connect to virtual machine using following RDP credentials :

  • Hostname: PublicDNS  / IP of machine
  • Port : 3389

Username: Your chosen username when you created the machine ( For example:  Azureuser)
Password : Your Chosen Password when you created the machine ( How to reset the password if you do not remember)

Step 2) Database Login Details :

  • MYSQL Username : root
  • MYSQL Password : Passw@rd123

Step 3) Application URL: Access the application via a browser at http://PublicDNS/Cakephp

Step 4) Other Information:

1.Default installation path: will be on your web root folder “C:\inetpub\wwwroot\Cakephp
2.Default ports:

  • Windows Machines:  RDP Port – 3389
  • Http: 80
  • Https: 443
  • Sql or Mysql ports: By default these are not open on Public Endpoints. Internally Sql server: 1433. Mysql :3306


Configure custom inbound and outbound rules using this link

Installation Instructions For CentOS 

Note : How to find PublicDNS in Azure

Step 1) SSH Connection: To connect to the deployed instance, Please follow Instructions to Connect to Centos instance on Azure Cloud

1) Download Putty.

2) Connect to virtual machine using following SSH credentials :

  • Hostname: PublicDNS  / IP of machine
  • Port : 22

Step 2) Database Login Details :

  • MYSQL Username : root
  • MYSQL Password : Passw@rd123

Note :-For Stack Database: DB cakephp with user cakephpuser and password Passw@rd123 has already been created.Please use this database for you Stack Configuration.

You can create a new cakephp application with below commands
cd /var/www/html
composer create-project –prefer-dist cakephp/app YourAppname
If you create a new app please change the path in Http config

Note :-Please change password immediately after first login.

Step 3) Application URL: Access the application via a browser at http://PublicDNS/. 

Step 4) Other Information:
1.Default installation path: will be on your web root folder “/var/www/html/”.
2.Default ports:

  • Linux Machines:  SSH Port – 22
  • Http: 80
  • Https: 443
  • Sql or Mysql ports: By default these are not open on Public Endpoints. Internally Sql server: 1433. Mysql :3306

Configure custom inbound and outbound rules using this link

Azure Step by Step Screenshots 

Google

Installation Instructions For Ubuntu

Installation Instructions for Ubuntu

Step 1) VM Creation:

  1. Click the Launch on Compute Engine button to choose the hardware and network settings.
  2. You can see at this page, an overview of Cognosys Image as well as estimated cost of running the instance.
  3. In the settings page, you can choose the number of CPUs and amount of RAM, the disk size and type etc.

Step 2) SSH Connection:To initialize the DB Server connect to the deployed instance, Please follow Instructions to Connect to Ubuntu instance on Google Cloud

1) Download Putty.

2) Connect to the virtual machine using SSH key

  • Hostname: PublicDNS  / IP of machine
  • Port : 22

Step 3) Database Login Details:

The below screen appears after successful deployment of the image.

successful deployment of the image

For local MySQL root password, please use the temporary password generated automatically during image creation as shown above.

i) Please connect to Remote Desktop as given in step 2 to ensure stack is properly configured and DB is initialized.
ii) You can use MySQL server instance as localhost, username root and password as shown above.

If you have closed the deployment page you can also get the MySQL root password from VM Details  “Custom metadata” Section.

Note: You shall see a error “CakePHP is NOT able to connect to the database.” You are required to enter the database and credentials information in /var/www/cakephp/config/app.php under Data-sources section
Please use MySQL root user with the password which was generated during the deployment to configure same.

Step 4) Application URL: Access the application via a browser at http://PublicDNS/Cakephp. 

Step 5) Other Information:

1.Default installation path: will be in your web root folder “/var/www/html/cakephp”.

2.Default ports:

  • Linux Machines:  SSH Port – 22
  • Http: 80
  • Https: 443
  • Mysql ports: By default these are not open on Public Endpoints. Internally Mysql server: 3306

Videos

Secured CakePHP on Windows 2012 R2

Secured cakephp on centos

CakePHP  Introduction & Installation

CakePHP on cloud

Related Posts