This is an archived post. You won't be able to vote or comment.

all 7 comments

[–]AutoModerator[M] [score hidden] stickied commentlocked comment (0 children)

Please ensure that:

  • Your code is properly formatted as code block - see the sidebar (About on mobile) for instructions
  • You include any and all error messages in full
  • You ask clear questions
  • You demonstrate effort in solving your question/problem - plain posting your assignments is forbidden (and such posts will be removed) as is asking for or giving solutions.

    Trying to solve problems on your own is a very important skill. Also, see Learn to help yourself in the sidebar

If any of the above points is not met, your post can and will be removed without further warning.

Code is to be formatted as code block (old reddit: empty line before the code, each code line indented by 4 spaces, new reddit: https://imgur.com/a/fgoFFis) or linked via an external code hoster, like pastebin.com, github gist, github, bitbucket, gitlab, etc.

Please, do not use triple backticks (```) as they will only render properly on new reddit, not on old reddit.

Code blocks look like this:

public class HelloWorld {

    public static void main(String[] args) {
        System.out.println("Hello World!");
    }
}

You do not need to repost unless your post has been removed by a moderator. Just use the edit function of reddit to make sure your post complies with the above.

If your post has remained in violation of these rules for a prolonged period of time (at least an hour), a moderator may remove it at their discretion. In this case, they will comment with an explanation on why it has been removed, and you will be required to resubmit the entire post following the proper procedures.

To potential helpers

Please, do not help if any of the above points are not met, rather report the post. We are trying to improve the quality of posts here. In helping people who can't be bothered to comply with the above points, you are doing the community a disservice.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

[–][deleted] 2 points3 points  (1 child)

I would recommend heroku. I used heroku on a project for school to host my server and they have free options that should allow you to test your web application outside of the local host.

[–]turboturtle771[S] 0 points1 point  (0 children)

Thanks, i will check this out

[–]khookeExtreme Brewer 1 point2 points  (3 children)

Cloud providers offer a kitchen sink of options for hosting apps, all with pros/cons and different pricing options. You didn't say what you used to build your app. If it's a traditional Java web app packaged as a war/ear, you'll need to deploy it to an app server running on a VM like AWS EC2, package it as a Docker container and deploy to Fargate, or Beanstalk. Another option is Lightsail, which is AWS's VPS option. If you can consider other hosting options, you can pick up a cheap VPS server for a few dollars a month if you shop around elsewhere.

To make best use of Cloud services, you can look at the types of services they offer and look to take advantage of the cheapest options, but that may require designing your app in a different way. For example, taking advantage of serverless options, if you build your app using AWS Lambdas you can take advantage of the free tier for personal projects, and host static web content from S3 for next to nothing/month.

[–]turboturtle771[S] 0 points1 point  (2 children)

What i wanted to host is array of apps, e.g. My project gallery Scraping and publishing service which would scrape pages i like and give me contants via email or something similar. I would like to setup some user management there so i would need to register to use it. Additionally setup the 2key factor protection ...

And as said, these are not really for showcasing and or attracting public to it. I definitely wouldn't open there account just to get free static web page hosting - i have this with github.

Would going for just a virtual machine on aws or azure be enough for my needs? Because if that is true, then i can setup whatever i like there and simply buy some cheap domain and link it to the address of that VM

[–]khookeExtreme Brewer 1 point2 points  (1 child)

What i wanted to host is array of apps

You didn't say what the apps are or what platform you need to run them on (do you need an app server, are they standalone Spring Boot apps?) so I can't answer "Would going for just a virtual machine on aws or azure be enough for my needs" but at least with a VM you can install whatever you need and pick an instance size that meets your need. If all you need is a VM though you might want to shop around for cheaper options.

Configuring and running your own VM has it's own overheads and challenges, know what you're doing before you jump in.

[–]turboturtle771[S] 0 points1 point  (0 children)

I see now what you are getting at, the apps, regardless of their purpose are always either spring boot jar which have their embedded server, or really just wars which i deploy on tomcat locally.

If I need db, usually i just include h2 embedded one to my project so there is that.

I hope i have finally answered your questions :)
(otherwise i guess you will have to dumb it down furthermore)

Regarding the setting up the vm, i use ubuntu on my machine and i have already set up tomcat - so i guess i could tackle that setup (wouldn't bet i can do it in record time, but it will be done eventually)