{"id":273,"date":"2016-06-03T10:31:46","date_gmt":"2016-06-03T10:31:46","guid":{"rendered":"http:\/\/kevingoedecke.com\/?p=273"},"modified":"2016-06-03T10:35:52","modified_gmt":"2016-06-03T10:35:52","slug":"setup-jira-on-aws-ec2-using-port-80","status":"publish","type":"post","link":"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/","title":{"rendered":"Setup JIRA on AWS EC2 using port 80"},"content":{"rendered":"<p>Hosting JIRA on an Amazon EC2 instance is quite easy and can save you a lot of money. Compare $10 per month to a one-time payment of $10 for the self hosted solution. The setup per se is quite easy but by default JIRA doesn&#8217;t\u00a0allow you to use port 80 as it&#8217;s default access port. In this tutorial we are going to look into how to still achieve this using iptables on a Linux system.<\/p>\n<p>I recommend using Amazon RDS as the database for JIRA, to increase redundancy and data safety in general.<\/p>\n<p>The first step is to set up an Amazon RDS database, afterwards you can go ahead fire up an EC2 instance and install JIRA. I used the recommended Amazon Linux Image for my installation.<\/p>\n<p>After the machine is up and running you simply get the latest JIRA binary and execute it.<br \/>\nGet the\u00a0download link of the latest version here:\u00a0<a href=\"https:\/\/www.atlassian.com\/software\/jira\/download\">https:\/\/www.atlassian.com\/software\/jira\/download<br \/>\n<\/a><\/p>\n<p>Afterwards use wget to download the file onto your EC2 instance:<\/p>\n<pre class=\"lang:default decode:true\">wget https:\/\/downloads.atlassian.com\/software\/jira\/downloads\/atlassian-jira-software-7.1.7-jira-7.1.7-x64.bin\r\n<\/pre>\n<p>Now all you have to do is make the file executable and then run it and follow the steps in the guided installation:<\/p>\n<pre class=\"lang:default decode:true\">sudo chmod a+x atlassian-jira-software-7.1.7-jira-7.1.7-x64.bin\r\n<\/pre>\n<pre class=\"lang:default decode:true\">sudo .\/atlassian-jira-software-7.1.7-jira-7.1.7-x64.bin<\/pre>\n<p>After you have finished the installation guide, you need to change the port mapping using iptables.<\/p>\n<p>Set the iptables configuration using the following commands:<\/p>\n<pre class=\"lang:default decode:true\">sudo iptables -A INPUT -i eth0 -p tcp --dport 80 -j ACCEPT\r\nsudo iptables -A INPUT -i eth0 -p tcp --dport 8080 -j ACCEPT\r\nsudo iptables -A PREROUTING -t nat -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 8080<\/pre>\n<p>Afterwards the iptables configuration needs to be stored to a local file, which late on is going to be used to load the configuration at boot of the host system.<\/p>\n<p>Store the configuration under\u00a0<span class=\"lang:default decode:true crayon-inline\">\/etc\/iptables.rules<\/span><\/p>\n<pre class=\"lang:default decode:true\">sudo bash -c \"iptables-save &gt; \/etc\/iptables.rules\"<\/pre>\n<p>In order to load this file after the system has been booted, edit\u00a0<span class=\"lang:default decode:true crayon-inline \">\/etc\/rc.local<\/span>\u00a0 and append\u00a0the following command at the very end of it:<\/p>\n<pre class=\"lang:default decode:true\">iptables-restore &lt; \/etc\/iptables.rules<\/pre>\n<p>Save the file and reboot your system. Double check if everything is working properly, use <span class=\"lang:default decode:true crayon-inline\">sudo iptables -L<\/span>\u00a0to see if the custom rules have been loaded during the boot. The output should look similar to this:<\/p>\n<pre class=\"lang:default decode:true\">Chain INPUT (policy ACCEPT)\r\ntarget     prot opt source               destination         \r\nACCEPT     tcp  --  anywhere             anywhere             tcp dpt:http\r\nACCEPT     tcp  --  anywhere             anywhere             tcp dpt:webcache\r\n\r\nChain FORWARD (policy ACCEPT)\r\ntarget     prot opt source               destination         \r\n\r\nChain OUTPUT (policy ACCEPT)\r\ntarget     prot opt source               destination<\/pre>\n<p>Afterwards you can continue to use your JIRA by accessing the web interface through port 80.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Hosting JIRA on an Amazon EC2 instance is quite easy and can save you a lot of money. Compare $10 per month to a one-time payment of $10 for the self hosted solution. The setup per se is quite easy but by default JIRA doesn&#8217;t\u00a0allow you to use port 80 as it&#8217;s default access port. [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":280,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_exactmetrics_skip_tracking":false,"_exactmetrics_sitenote_active":false,"_exactmetrics_sitenote_note":"","_exactmetrics_sitenote_category":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[25],"tags":[],"class_list":["post-273","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-devops"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v24.8.1 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Setup JIRA on AWS EC2 using port 80 - Kevin Goedecke<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Setup JIRA on AWS EC2 using port 80 - Kevin Goedecke\" \/>\n<meta property=\"og:description\" content=\"Hosting JIRA on an Amazon EC2 instance is quite easy and can save you a lot of money. Compare $10 per month to a one-time payment of $10 for the self hosted solution. The setup per se is quite easy but by default JIRA doesn&#8217;t\u00a0allow you to use port 80 as it&#8217;s default access port. [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/\" \/>\n<meta property=\"og:site_name\" content=\"Kevin Goedecke\" \/>\n<meta property=\"article:published_time\" content=\"2016-06-03T10:31:46+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2016-06-03T10:35:52+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/kevingoedecke.com\/blog\/wp-content\/uploads\/2016\/06\/jira-on-aws-port-80@2x.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1800\" \/>\n\t<meta property=\"og:image:height\" content=\"900\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Kevin Goedecke\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Kevin Goedecke\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/\",\"url\":\"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/\",\"name\":\"Setup JIRA on AWS EC2 using port 80 - Kevin Goedecke\",\"isPartOf\":{\"@id\":\"https:\/\/kevingoedecke.com\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/kevingoedecke.com\/blog\/wp-content\/uploads\/2016\/06\/jira-on-aws-port-80@2x.png\",\"datePublished\":\"2016-06-03T10:31:46+00:00\",\"dateModified\":\"2016-06-03T10:35:52+00:00\",\"author\":{\"@id\":\"https:\/\/kevingoedecke.com\/#\/schema\/person\/4b156cd6453e1af4bab9076b0a663871\"},\"breadcrumb\":{\"@id\":\"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/#primaryimage\",\"url\":\"https:\/\/kevingoedecke.com\/blog\/wp-content\/uploads\/2016\/06\/jira-on-aws-port-80@2x.png\",\"contentUrl\":\"https:\/\/kevingoedecke.com\/blog\/wp-content\/uploads\/2016\/06\/jira-on-aws-port-80@2x.png\",\"width\":1800,\"height\":900},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/kevingoedecke.com\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Setup JIRA on AWS EC2 using port 80\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/kevingoedecke.com\/#website\",\"url\":\"https:\/\/kevingoedecke.com\/\",\"name\":\"Kevin Goedecke\",\"description\":\"Founder. Entrepreneur.\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/kevingoedecke.com\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/kevingoedecke.com\/#\/schema\/person\/4b156cd6453e1af4bab9076b0a663871\",\"name\":\"Kevin Goedecke\",\"url\":\"https:\/\/kevingoedecke.com\/blog\/author\/kgoedecke\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Setup JIRA on AWS EC2 using port 80 - Kevin Goedecke","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/","og_locale":"en_US","og_type":"article","og_title":"Setup JIRA on AWS EC2 using port 80 - Kevin Goedecke","og_description":"Hosting JIRA on an Amazon EC2 instance is quite easy and can save you a lot of money. Compare $10 per month to a one-time payment of $10 for the self hosted solution. The setup per se is quite easy but by default JIRA doesn&#8217;t\u00a0allow you to use port 80 as it&#8217;s default access port. [&hellip;]","og_url":"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/","og_site_name":"Kevin Goedecke","article_published_time":"2016-06-03T10:31:46+00:00","article_modified_time":"2016-06-03T10:35:52+00:00","og_image":[{"width":1800,"height":900,"url":"https:\/\/kevingoedecke.com\/blog\/wp-content\/uploads\/2016\/06\/jira-on-aws-port-80@2x.png","type":"image\/png"}],"author":"Kevin Goedecke","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Kevin Goedecke","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/","url":"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/","name":"Setup JIRA on AWS EC2 using port 80 - Kevin Goedecke","isPartOf":{"@id":"https:\/\/kevingoedecke.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/#primaryimage"},"image":{"@id":"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/#primaryimage"},"thumbnailUrl":"https:\/\/kevingoedecke.com\/blog\/wp-content\/uploads\/2016\/06\/jira-on-aws-port-80@2x.png","datePublished":"2016-06-03T10:31:46+00:00","dateModified":"2016-06-03T10:35:52+00:00","author":{"@id":"https:\/\/kevingoedecke.com\/#\/schema\/person\/4b156cd6453e1af4bab9076b0a663871"},"breadcrumb":{"@id":"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/#primaryimage","url":"https:\/\/kevingoedecke.com\/blog\/wp-content\/uploads\/2016\/06\/jira-on-aws-port-80@2x.png","contentUrl":"https:\/\/kevingoedecke.com\/blog\/wp-content\/uploads\/2016\/06\/jira-on-aws-port-80@2x.png","width":1800,"height":900},{"@type":"BreadcrumbList","@id":"https:\/\/kevingoedecke.com\/blog\/2016\/06\/03\/setup-jira-on-aws-ec2-using-port-80\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/kevingoedecke.com\/"},{"@type":"ListItem","position":2,"name":"Setup JIRA on AWS EC2 using port 80"}]},{"@type":"WebSite","@id":"https:\/\/kevingoedecke.com\/#website","url":"https:\/\/kevingoedecke.com\/","name":"Kevin Goedecke","description":"Founder. Entrepreneur.","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/kevingoedecke.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/kevingoedecke.com\/#\/schema\/person\/4b156cd6453e1af4bab9076b0a663871","name":"Kevin Goedecke","url":"https:\/\/kevingoedecke.com\/blog\/author\/kgoedecke\/"}]}},"jetpack_featured_media_url":"https:\/\/kevingoedecke.com\/blog\/wp-content\/uploads\/2016\/06\/jira-on-aws-port-80@2x.png","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/kevingoedecke.com\/blog\/wp-json\/wp\/v2\/posts\/273","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kevingoedecke.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kevingoedecke.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kevingoedecke.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/kevingoedecke.com\/blog\/wp-json\/wp\/v2\/comments?post=273"}],"version-history":[{"count":3,"href":"https:\/\/kevingoedecke.com\/blog\/wp-json\/wp\/v2\/posts\/273\/revisions"}],"predecessor-version":[{"id":279,"href":"https:\/\/kevingoedecke.com\/blog\/wp-json\/wp\/v2\/posts\/273\/revisions\/279"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/kevingoedecke.com\/blog\/wp-json\/wp\/v2\/media\/280"}],"wp:attachment":[{"href":"https:\/\/kevingoedecke.com\/blog\/wp-json\/wp\/v2\/media?parent=273"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kevingoedecke.com\/blog\/wp-json\/wp\/v2\/categories?post=273"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kevingoedecke.com\/blog\/wp-json\/wp\/v2\/tags?post=273"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}