![]() Local the orange AWS button ( ) on the toolbar.Check the installation box next to the following packages:.Enter AWS for the name and for the location, and click OK. Click the "Add" button next to "Work with".Allow the installation to complete, and restart Eclipse. Select next/finish and accept the licenses. Check the installation box next to the following packages, enabling database access in Eclipse:ĭatabase Development -> Data Tools Platform Enablement Extender SDKĭatabase Development -> Data Tools Platform Extender SDK.Choose Work with: Mars () (assuming that you have the "Mars" version of Eclipse installed).Note that the JRE (Java Runtime Environment) is *not* sufficient - you actually need to be able to compile Java code. Download and install the latest 1.7.x version of the Java SE Development Kit (JDK) from Oracle.Note that the "Standard" edition will not have all the required features. Download and install the latest 4.5.x "Mars" version of Eclipse IDE for Java Developers from.If you have any feedback or feature requests, tell us about them in the comments. Give it a try and see whether it can improve how you deploy your Java web project to your EC2 instances. It also allows you to quickly set up an AppSpec template that represents a repeatable and configurable deployment task. It eliminates the need to repeat the manual operations of building, packaging and preparing revision. The AWS CodeDeploy plugin for Eclipse allows you to easily initiate a deployment directly from your source development environment. the AppSpec and command script template filesįeel free to customize the source for your specific need, and keep in mind that we are always open to pull-requests if you want to contribute your own templates that might be useful for other Java developers.If you are interested in the Tomcat 7 running on Linux template we used in the walkthrough, you can find the source code in our GitHub repo. For example, you can define your own template that deploys your Java web app to other servlet containers such us Jetty and JBoss. You can use the AppSpec template system to create more complicated deployment tasks. In the future, if you ever want to repeat this operation on your EC2 instances, just kick off another deployment in Eclipse using the same Stop Apache HTTP Server template, and you are done! You can see that the httpd service was successfully stopped during the ApplicationStart event: 00:28:04 LifecycleEvent - ApplicationStart In this example, you are expected to get the following log output. home/hanshuo/stop-httpd-server-appspec/template.md /logs/scripts.log The final step is to create a metadata file for it, which is in a specific JSON format understood by the Eclipse plugin. ![]() Now that we have created our template which consists of all the necessary AppSpec and command script files.Since this is the only phase mentioned, it basically tells the service to run this single script as the whole deployment process – that’s all we need! You can find more information about the AppSpec file in the AWS CodeDeploy Developer Guide. This AppSpec file asks CodeDeploy to run stop-httpd.sh as the root user during the ApplicationStart phase of the deployment. home/hanshuo/stop-httpd-server-appspec/template/appspec.yml version: 0.0 Next, inside the same directory, let’s create a simple AppSpec file that specifies our shell script as the command for the ApplicationStart lifecycle event.Later, you will learn how this could help you create a configurable deployment task in Eclipse. To make it a little bit fancier, instead of hardcoding httpd as the service name, we instead use a place holder #HTTPD_SERVICE_NAME#. home/hanshuo/stop-httpd-server-appspec/template/stop-httpd.sh #!/bin/bash First, let’s create a shell script that executes the command we need to run on our instances:.In this part of the series, we will show you how easy it is to run deployment commands on your EC2 fleet with the help of the AWS CodeDeploy plugin for Eclipse.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |