Search Posts

Category: amazon-web-services

Best practice for storing server endpoint configurations for static web application

We are hosting our Angular based static web application on AWS S3. This web application tries to access AWS Lambda based backend via APIGateway or directly access using AWS Javascript SDK. But these endpoints are embedded in our web application and we try to move these static endpoints to configuration file decoupling from the web application to make them dynamic. What is the best practice to accomplish this?, storing endpoints in Dynamodb table and accessing […]

Setup WordPress, Django and AngularJS application on single AWS instance

I currently have the AWS free tier and need to host the following instances in the most effective/cheap way possible. There won’t be a lot of traffic on the website, so I want to maximise the free tier: 1 – WordPress (simple installation, need a blog setup – so this will require an SQL database) 2 – Django application (will also be setting up admin front end – also requires SQL database) 3 – two […]

Developing Angular/React apps in AWS EC2

I am currently working on a test project on AWS EC2 with Angular. I’m new at Angular. Pretty much everyone knows that this is VPS and it doesn’t come with cPanel or any GUI either. I can install cPanel but it is a paid software and is also a bit expensive for test. Also Angular comes with a lot of editing, so it is very difficult for me to just develop through CLI. So any […]

AWS EBS NodeJS : npm not found while generating the build with AngularJS

I am using the AWS Elastic Beanstalk for Angularjs Application. There on the associated EC2, I found some hooks for PRE and POST deployment. under /opt/elasticbeanstalk/hooks/appdeploy/pre/ there are some pre-defined hooks available like Once I try to put my own commands for Angular build generation then it does not recognise NPM npm run ng-build –prod –named-chunks I need to add my own certain commands but it does not allow me to use npm like […]

Rest Service not working when deployed on AWS

This is my Rest Service. @RestController public class ProjectController { @RequestMapping(method = RequestMethod.GET, value = “/getProjects”) public ArrayList<Project> getProjects() { ArrayList<Project> projectList = new ArrayList<Project>(); ProjectDao obj = new ProjectDao(); projectList = obj.getProjects(); return projectList; } } And this is my Angular script to invoke this service. $http({ method: “GET”, url: “/getProjects” }) .then( function success(response) { … }, function error { alert(“Error”); } ); These are working fine when I run the application on […]

Deploy Java backend and angularjs frontend to elastic beanstalk

I am new to AWS elastic beanstalk. I will like anyone in the house to share their experience with me on how you deploy Java (Backend) and Angularjs (Frontend) to Elastic beanstalk. I tried to deploy an application using Java (Backend) and Angularjs (Frontend) but with no success. After download both codes (java & angularjs) from gitbucket, I zip all the code in one file and upload to beanstalk using both cli and graphic interface. […]

Angular how to download file from S3 Amazon using ng-click

I am trying to download a file from my amazon S3 bucket by using angular ng-click. But instead of file it returns me with blank file on download. HTML <div class=”details-field”> RC Book <font class=”digit” >({{rcCount}})</font> : <i class=”fa fa-angle-down fa-button” ng-click=download() ></i> </div> Angular script var awsUrl = ; $ = function() { $http.get(awsUrl, { responseType: “arraybuffer” }) .success(function(data) { var anchor = angular.element(‘<a/>’); var blob = new Blob([data]); anchor.attr({ href: window.URL.createObjectURL(blob), target: […]

How to install ng on elastic beanstalk

I am new to elastic beanstalk, I am trying to deploy my angular-cli app on node.js elastic beanstalk. I am getting following error. /var/log/nodejs/nodejs.log ————————————- npm ERR! Failed at the [email protected] start script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. > [email protected] start /var/app/current > ng serve sh: ng: command not found npm ERR! file sh npm ERR! code ELIFECYCLE npm ERR! errno ENOENT npm […]

deploy angular app on aws without using node.js

I have a very simple angular app which I want to deploy on AWS. Currently I have created an ec2 instance with MEAN Certified by Bitnami-3-4-9-0 on Ubuntu. I ssh’d into it and cloned by git repository. But the problem I am facing is I don’t want to run it through node server.I don’t have any npm dependencies and have no need to add node.js. Is it possible to run it without node server? Should […]

Website not updating content and files deployed on AWS

I have an angularjs website Hosted at AWS Elastic Beanstalk. Earlier website had a HTML smart table grid. which we later replaced it with simple table with ng-repeat. For pagination dirpagination.js is used. Everything works fine locally. But when deployed on AWS environment content doesn’t get updated . sometimes Network tab (browser) shows dirpagination cannot be found, while sometimes it loads. Any help would be grateful. Source: AngularJS

Next Page »