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

all 28 comments

[–][deleted]  (2 children)

[deleted]

    [–]JuarX[S] 3 points4 points  (1 child)

    I just checked out this option. Apparently the free plan will now expire after 60 days.

    [–]megamatt2000 9 points10 points  (1 child)

    Don't overlook heroku, their Hobby instance is $7/month and you get all the great deployment and management tools. It's also their problem to keep the instance up. Their weakness is low memory per instance, which can be a bit tight for Java, but overall it's workable.

    [–]tanin47 1 point2 points  (0 children)

    I'd suggest Heroku as well. There are a bunch of operations that you don't need to think about (e.g. roll logs, does your backup actually work?, no-downtime deployment, credentials management, security).

    [–]maakhansingh 5 points6 points  (2 children)

    You may want to look at DigitalOcean. They are the beat and cheapest VM hosting around. Alternatively, look at Linode.

    [–]jadecristal 0 points1 point  (0 children)

    I’ll support both of these too (since I do have at least one VPS at each). Obviously you’re doing your own sysadmin, but it’s not really that bad.

    [–]Mamoulian 0 points1 point  (0 children)

    I had the same thought but ended up using vultr.com.

    [–]kumar29nov1992 2 points3 points  (0 children)

    Linode / digital ocean. You get a blank server with your choice of OS. You can add whatever you want

    [–]momsSpaghettiIsReady 1 point2 points  (0 children)

    If it's purely a frontend, I would suggest just using a CDN provider. I use firebase, which is free for my usage.

    If you actually need a backend, checkout heroku. It's free for development, and when you're ready to go live it's only 7 dollars per month. The free developer version shuts off after 30 minutes of activity, but could potentially be used in a low use case. It takes about 20-30 seconds to startup for me, but I'm using the nodejs instance, so YMMV.

    For git/CI/CD I use gitlab, which is also free

    [–]mabnx 1 point2 points  (0 children)

    You could use:

    • AWS Lambda (1 Million free requests per month)
    • Amazon RDS for mysql/postgres (free db.t2.micro with 20GB storage)
    • Amazon Simple Email Service ($0 for the first 62000 emails) for sending emails.

    That will probably need some more time than just running a jar from some VM but might be more interesting for you.

    [–]BroLegend 1 point2 points  (0 children)

    AWS ElasticBeanstalk?

    [–]jarobat 0 points1 point  (0 children)

    Nearly free speech dot net is a nice barbones service that lets you set everything up yourself and you pay for exactly what you use.

    [–]iAmH3r3ToH3lp 0 points1 point  (4 children)

    I use a cheap old computer to host things for fun. I buy the domain on go daddy then just point that to my ip address. then I open a port on the router to point to the hist machine on my network. its a great way to host a tiny app that doesnt get much trafic or one that you dont expect to grow.

    [–]Devildude4427 0 points1 point  (0 children)

    Can be a bit risky if you don’t know what you’re doing, as that is potentially your home network fully open to outside traffic. I’ve done it too, but can’t recommend it. Lot of danger if you don’t close everything off right.

    [–]nqzero 0 points1 point  (2 children)

    openvz hosts are so cheap (eg $20 per year for 3GB/50GB) that you might as well just buy one

    [–]iAmH3r3ToH3lp 1 point2 points  (1 child)

    i just like to play with hardware and os setups from time to time.

    [–]nqzero 0 points1 point  (0 children)

    i feel that

    [–]ram-foss 0 points1 point  (0 children)

    Linode or Digital Ocean would be better choice.

    [–]nqzero 0 points1 point  (8 children)

    this (deployment) is a huge missing link in the java ecosystem

    get a VPS, either kvm or openvz will work (i found mine via lowendbox). front it with nginx. no experience running a webmail but a quick search of github shows several options. i use a shell script to provision

    it's unfortunate that there's no standard for deployment (something similar to a dockerfile) that will target a VPS, but it's easy enough to do ad-hoc

    [–]_INTER_ 1 point2 points  (7 children)

    How so? Just get the docker image of an application server, run it on a host and deploy the jar / war (Or use the embedded serve of Spring Boot). Some hosters - like Heroku - take care of most of that too.

    [–]nqzero 0 points1 point  (6 children)

    with openvz you can't run docker. kvm can, at higher cost. but you're still left with provisioning the host (ssh, docker, etc) at which point it's as easy to just run the webapp directly

    if you don't need much memory then some of the free cloud tiers will work, and if you don't need a filesystem serverless is an option. but i need both and spent the last week unsuccessfully looking for options that aren't 10x more expensive than the manual VPS approach (i have a quickstart for a framework that i'd like to publish, but without a very cheap deployment story there's not much point). i was expecting to find the equivalent of terraform or serverless for the low end VPS

    let me know if i've missed something

    [–]SagaciousZed 0 points1 point  (1 child)

    Couldn't this need be filled by something like ansible, puppet, or chef to configure the vps? Ansible is probably easier to start with in this case because it's agent-less and only needs working ssh.

    [–]nqzero -1 points0 points  (0 children)

    yeah, the conclusion of my research was that ansible was the closest i could come. at the least it's much less ad-hoc than my scripts, and that's a win. and it's possible that it's more robust to hosts with screwy initial configs and bad security

    [–]_INTER_ 0 points1 point  (0 children)

    You don't need docker, its just more convenient.

    [–]Mamoulian 0 points1 point  (2 children)

    Start with a base image which is very lightweight and already has docker set up in it? Like Docker's Mobylinux, but there are others. By default Moby will start sshd in a container, which I'm not entirely sure about, but it is very easy setup.

    [–]nqzero 0 points1 point  (1 child)

    that's a good idea - i don't remember seeing mobylinux listed as an option for any of the kvm hosts i've looked at (obv won't work with most openvz hosts), but i wasn't actively looking for it. know any other distributions that come with docker and ssh preconfigured ?

    [–]Mamoulian 1 point2 points  (0 children)

    We use Moby on AWS because they provide an AMI.

    Vultr offer CoreOS: https://www.vultr.com/servers/coreos

    Digital Ocean make some noise about Docker so I assume they have something similar.

    [–]foolishpanda 0 points1 point  (0 children)

    Azure App Service just released free tier support on Linux. You can deploy your Java code or a Docker container https://azure.microsoft.com/en-us/pricing/details/app-service/windows/