Step 6: Deploy and Run PhotoApp - AWS OpsWorks

Step 6: Deploy and Run PhotoApp

Important

The AWS OpsWorks Stacks service reached end of life on May 26, 2024 and has been disabled for both new and existing customers. We strongly recommend customers migrate their workloads to other solutions as soon as possible. If you have questions about migration, reach out to the AWS Support Team on AWS re:Post or through AWS Premium Support.

For this example, the application has also been implemented for you and is stored in a public GitHub repository. You just need to add the app to the stack, deploy it to the application servers, and run it.

To add the app to the stack and deploy it to the application servers
  1. Open the Apps page and choose Add an app.

  2. On the Add App page, do the following:

    • Set Name to PhotoApp.

    • Set App type to PHP.

    • Set Document root to web.

    • Set Repository type to Git.

    • Set Repository URL to git://github.com/awslabs/opsworks-demo-php-photo-share-app.git.

    • Choose Add App to accept the defaults for the other settings.

    Form to add an app with fields for name, type, document root, and repository details.
  3. On the Apps page, choose deploy in the PhotoApp app's Actions column.

    Apps page showing PhotoApp with deploy, edit, and delete options in the Actions column.
  4. Accept the defaults and choose Deploy to deploy the app to the server.

To run PhotoApp, go to the Instances page and choose the PHP App Server instance's public IP address.

PHP App Server instance details showing hostname, status, and public IP address.

You should see the following user interface. Choose Add a Photo to store a photo on the Amazon S3 bucket and the metadata in the back-end data store.

User interface section titled "My Photos" with an "Add a Photo" button.