Step1: Login to your Amazon AWS account.
Step2: Click on the OpsWork option under the Management Tools.
Step3: Click on the button in blue Add your first stack.
Step4: Select the type of stack which you want to create, Configure the settings and click on Add stack.
Note-: In this tutorial we have select the Chef 12 Stack among the types of stack.
Advance options settings
Step5: Next step is to add layer to your stack, click on Add a layer.
Step6: Specify the name and a short name to your layer, click on Add layer
Step7: Under the DemoLayer , click on security from the list of options.
Step8: Under the Security groups select AWS-OpsWork-WebApp, click on save .
Step9: On the left most part of the page click on Apps option, click on Add an app or Add app.
Step10: Configure the settings for an App, click on Add app.
Step11: Select Instance option from the left most part of the web page, click on Add an instance.
Step12: Configure your instance with options specified below, click on Add instance.
Step13: Start your instance & wait till status change from stopped to online.
Note-: It take few minute to change the status from stopped to online.
Step14: Use chef Recipes to deploy the app on instance,Click on layers & select Recipes option from the list of options.
Step15: Specify the Recipe to deploy an application, Under Deploy type nodejs_demo::default & press Enter, click on save.
Step16: Click on Apps on the left most part of the web page , click on deploy under the Actions.
Step17: Configure Deploy App Settings, click on Deploy .
Successfully Deployment Of App
Step18: Test the sample App, by copying the public Ip from the instance & paste on the browser.