Code Monkey home page Code Monkey logo

zend-server-php-buildpack's Introduction

Overview

Welcome to the Zend Server PHP buildpack! This buildpack allows you to deploy your PHP apps on Cloud Foundry using Zend Server 6.2. Zend Server's integration with Cloud Foundry allows you to quickly get your PHP applications up and running on a highly available PHP production environment which includes, amongst other features, a highly reliable PHP stack, application monitoring, troubleshooting, and more.

Buildpack Components

  • Zend Server 6.3 Free edition
  • Zend Server 6.3 configuration files
  • PHP 5.4
  • Apache web server

Usage

  1. Download and install Cloud Foundry's 'cf v6' CLI. For installation instructions, see http://docs.run.pivotal.io/devguide/installcf/install-go-cli.html.
  2. Create a new folder on your workstation, and access it.
  3. If you have an application package (.zpk) ready for deployment, place it anywhere in your application. If not, create a new 'index.php' file in the root folder of your application, and paste the following code:
<?php
echo "Hello world!;
?>
  1. Enter the following command: cf push <application name> -m 512M -b https://github.com/zendtech/zend-server-php-buildpack.git Your application is deployed using the Zend Server buildpack. This may take a few minutes.
  2. Once successfully initialized and deployed, a success message with the URL at which your application is available at is displayed.
  3. To access the application, enter the supplied URL in your Web browser. Deployed .zpks can be accessed at: http://.pivotal.io/<.zpk name>
  4. To access Zend Server, add 'ZendServer' to the supplied URL. For example:http://<application URL>/ZendServer The Zend Server Login page is displayed.
  5. Log in using the following credentials: Username - admin, Password - enter the following command in your CLI to retrieve an initial password: cf file <application name> /app/zend-password
  6. To change the Zend Server UI password, or in case you misplace your password, enter the following command: cf set-env <application name> ZS_ADMIN_PASSWORD <new password>

Automatically Importing PHP Configurations

The Zend Server buildpack can optionally import PHP configurations from backup files. This allows you to easily deploy applications which require a change of directives. It also allows you to retain changes you made using the Zend Server GUI. To do so, follow these instructions:

  1. In your application's code (on your workstation) create a folder named .zend_config .
  2. Browse to: http://<application URL>/ZendServer/ImportExport/ .
  3. Click on the "Export Configuration" button.
  4. Move the saved file to the .zend_config folder in your app.
  5. Change directory into your app source code directory: cd <app_source_directory_on_your_workstation>
  6. Enter the following command to apply the changes: cf push

Tip: you can reuse this backup files for other applications that might require similar settings.

Known Issues

  • Zend Server Code Tracing may not work properly in this version.
  • Several issues might be encountered if you do not bind MySQL providing service to the app (mysql/MaraiaDB):
  • You can change settings using the Zend Server UI and apply them - but they will not survive application pushes and restarts, nor will they be propagated to new application instances.
  • Application packages deployed using Zend Server's deployment mechanism (.zpk packages) will not be propagated to new app instances.
  • Zend Server will not operate in cluster mode.
  • Application generated data is not persistent (this is a limitation of Cloud Foundry) unless saved to a third party storage provider (like S3).
  • MySQL is not used automatically - If you require MySQL then you will have to setup your own server and configure your app to use it.
  • If the application does not contain an 'index.php' file you will most likely encounter a "403 permission denied error".

Additional Resources

The following resources will help you understand Cloud Foundry concepts and workflows:

zend-server-php-buildpack's People

Contributors

danielberman avatar davidl-zend avatar dintel avatar dror-g avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.