Deploy Angular Backend API on Azure - html

I have made a backend API that connects to the sql that is also hosted on my azure account, however im not sure how to deploy this api on azure and make it available on there so that i can deploy my angular app to connect to this url instead of localhost.
Do you guys know of any tutorials or advice on how to deploy a backend typescript based api on to azure
thanks

There's a new service in Azure that sounds like it fits your needs perfectly: Azure Static Web Apps.
You can find a tutorial in the documentation: Quickstart: Building your first static web app.
Azure Static Web Apps is a service that automatically builds and deploys full stack web apps to Azure from a GitHub repository.
and
What you can do with Static Web Apps
Build modern JavaScript applications with frameworks and libraries like Angular, React, Svelte, Vue with an Azure Functions back-end.
Publish static sites with frameworks like Gatsby, Hugo, VuePress.
Deploy web applications with frameworks like Next.js and Nuxt.js.
Source: What is Azure Static Web Apps Preview?
EDIT:
In short, this service enables you to build a frontend using libraries like Angular, Vue and React, and also provides a way to build and deploy an API using JavaScript or TypeScript Azure Functions. You could, of course, do this manually, but if there's an integrated service for it...
As posted in the comments: I do not mean Static website hosting in Azure Storage, although that could work perfectly fine although it doesn't provide a solution for the API.

Related

How to deploy Angular-Flask-MySQL Project on Heroku which Stored in Github repo

I am currently working on a project that uses Angular as frontend framework, Flask as backend framework and MySQL as database.
Furthermore, the developement of the application is completed and the source code is stored in private Github repo.
My next step is to deploy this project on heroku server. After done some research l found that i have to change the database to Clear DB which is the database available in heroku. As a newbie this is my first web app deployment to heroku server.
Is there any online source where i can refer that can fullfiill my requirement or if somebody has done this approach previousely could please list down the steps so i can follow them. Your help will be highly appreciated.
Thanks and best regards.
I had done a project related to angular and flask. I faced the same issue when it comes to app deployment phase.
I deployed the angular app and the flask app in two separate heroku servers. Using this method it is easy for you to do the furthure developments of the application as well.
Following are some reliable sources you can refer,
Deploy flask app to heroku
https://stackabuse.com/deploying-a-flask-application-to-heroku/
Deploy angular app to heroku
https://www.javaguides.net/2020/11/how-to-deploy-angular-application-to-heroku.html?m=1
After deploy both these frameworks separately you can replace your angular api call from https://localhost:5000/api/ to https://yourbackendserver.herokuapp.com/api/

How to deploy Java Web Start under Apache Karaf?

One of our enterprise application is running over Apache Karaf , this application is accessed through web client.
We have another standalone desktop Java Swing based application. We want to invoke this application from browser.
So , we decided to deploy this application as Java Web Start and allow clients to invoke this application.
We have lot of examples how to deploy Java Web Start with tomcat like web servers.
But we want to deploy this in Apache Karaf . Anyone is having tutorial or notes for this?
I would strongly advise against Java Web Start.
If you don't want to rewrite the app, have a look at webswing. I have never used it but they claim they can convert Swing Apps to Web Apps instantly. I also have no idea how that would work with OSGi. Depends on what they actually do it may be easy or impossible.
If you are OK with some changes you can try JavaFX or Vaadin. Both are quite similar to Swing in terms of development style so it should be relatively easy to convert your app. Both can run inside OSGi container with some minor limitations and after some adjustments.

How can I deploy an HTML5 web application in Google Cloud platform?

I am working on an HTML5 web application, which I need to host in Google cloud platform.
How can I deploy the web application, which is based on HTML5/CSS3, jQuery to Google Cloud platform/App Engine?
Clarification:
My web application is build using HTML5/CSS3 with javascript to process data. I am using Visual Studio IDE for development of the same. As per my understanding, apart from the supported languages like java, Python, etc, we can deploy html5 web application to Google cloud platform. How can I package my HTML5 application, which is not using any specific language and deploy to App Engine?
Thanks
Ambily
You can deploy to a bucket directly:
The Website Configuration feature enables you to configure a Google
Cloud Storage bucket to simulate the behavior of a static website. You
can define main pages or directory indices (for example, index.html)
for buckets and "directories". Also, you can define a custom error
page in case a requested resource does not exist.
No programming language at all required :)
Google Cloud Storage
You need a account with Google Cloud Platform to start with. Assuming you have that.
Go to cloud console where you find all the admin menus for creating instances.
You need to create a compute engine instance, if you want to create full fledged website.
Steps to follow:
Create a instance (linux, 10GB disk, 1.7GB memmory) and configure it for all required components.
After this you can move your files to your website folder usually "htdocs"
You will be assigned with an empirical IP address.
Using zone management tools you can add a new domain. All that using the admin panel, no complexity involved.
You may required to configure proxy, if you need access to other machines.

Dynamic Web App to Phonegap

I'm trying to turn a simple webapp into an Android app by using Phonegap Build. My webapp has some simple jQuery AJAX methods (GET/POST). I'm not sure how to go about this -- when I upload the zip to Phonegap Build, the zip includes the html file, the css file, and a js script which is basically the Node.js server.
My HTML file includes some javascript that relies on GET/POST from the server, but it never runs in the android app that is built. I have tried whitelisting the localhost in the config.xml file (10.0.2.2) but this is also not working. Anyone have an idea? Should I not be using Phonegap Build? Thanks.
PhoneGap will not allow you to run any node.js script. Node.js - is server side solution.
What you are looking for is to make front-end in html+css+js, that will speak to your node.js using AJAX. But node.js have to run on hosting that will be available online. So that way your application will speak to node.js process that will server all clients (PhoneGap applications) via HTTP (AJAX).
Please remember, that StackOverflow helps with specific code problem, not knowledge or generic questions.

Integrating a Swing App With Tomcat

I recently created a web application with GWT. Then re-used most of the code to create a Swing version of the application that accesses a local database in offline mode. I am now implementing the 'online' mode of the application and want to access the same data as my GWT application.
Any ideas? Considered connecting directly to the MySQL server via SSL, but that's not working and doesn't seem as scalable. Should I use REST?
Any suggestions would be helpful.
To solve this problem in the past, we've used Jersey to create REST Web services which returns protocol buffers. The Swing app would then interact with the protocol buffers. The GWT app would ask for content type 'json' and receive protostuff objects in return. It worked quite well. That way, both apps can communicate with the server in the exact way.
Edit:
To allow your swing app to communicate with GWT-RPC, look at this blog article.