Heroku free account limited? - blogs

Currently, I am running wordpress as my blog engine on free hosting, but I'm planning to move to use git-based blog engine(Jekyll, Toto) on Ruby platform. Then I see Heroku provides free account features, but I don't see any detail on bandwidth, disk spaces, requests?

Heroku provides, for free, a 5MB database
Heroku provides, for free, 1 dyno. A dyno is an instance of your application running and responding to requests. If each instance of your application can serve each request in 100ms, then you get 600 requests/minute with the free account.
Your application code and its assets (the slug) are limited to 300 MB in total. Your application also has access to the local filesystem, which can serve as an ephemeral scratch space for that specific dyno, and should be able to store at least 1 GB of data.
There is a 2TB/month limit on bandwidth.

Here is the problem I had....
"We have photo and file upload for several features in our app, but they do not save.
I have read on stackoverflow that "You are limited to 100MB of disk space, but you are not permitted to save any files (including user uploads) to disk because the filesystem is readonly. The 100MB of disk space is for your application code and other assets. The 100MB is the maximum slug size, and includes all gems referenced by your project."
We need our users to be able to successfully upload files and have them save. How do we make this happen?"
Here is Heroku Support's response...
"Hi, the filesystem is writeable on cedar, and can handle significantly more than 100MB; at least 1GB.
That said, it's dyno-local and ephemeral; see https://devcenter.heroku.com/articles/dynos#ephemeral-filesystem
For permanent storage, we recommend something like S3: https://devcenter.heroku.com/articles/s3
Hope this helps."

For those who are going to come here after me, you can get the hobby pack if you are a student and have the GitHub developer pack, Here are the details: Heroku for GitHub students

Heads up: Heroku free tier is going away soon
"Starting November 28, 2022, free Heroku Dynos, free Heroku Postgres, and free Heroku Data for RedisĀ® plans will no longer be available. If you have apps using any of these resources, you must upgrade to paid plans by this date to ensure your apps continue to run and retain your data. See our blog and FAQ for more info."
"What happens if I take no action on my free apps or databases or do not upgrade to a paid plan?
free dynos will be scaled down to 0 and hobby-dev databases will be deleted starting November 28, 2022."
REF:
https://devcenter.heroku.com/articles/free-dyno-hours
https://help.heroku.com/RSBRUH58/removal-of-heroku-free-product-plans-faq
https://blog.heroku.com/next-chapter

Also, loading your page might take a long time (5-10 sec)
If a free dyno isn't accessed frequently it goes into sleep mode. After that there is a delay for the dyno to become active again. For me this takes 5-10sec. You cannot fool the system by accessing it frequently because this is consuming your free dyno hours.

Related

Angular SPA for Offline Use (with DDBB)

I am developing an invoice app with Angular + NodeJs + MySql.
The thing is, the app is planned to be used by one employee in his office. No need for online servers.
It is not problematic to deploy the app online, but the internet is unstable in the zone (Latinamerican problem. You may lose connection for hours, and even voltage variations that may shut down the PC).
So the app must be self sufficient to always work offline.
So my questions are:
Can I simply deploy the app offline? Like in local. If that is the case, I would need for everything to be initialized automatically when the user opens the app (server open, database connected...).
If I have no way but to deploy the app online, should I use Firebase? Also, what happen if the internet service shut downs for hours? Is there a way for the database to be available offline and sync when the internet gets back?
You could build the app as an Electron App, then its becomes a locally run program. https://www.electronjs.org/
You can host it anywhere, but turn the app in to a PWA, which means it will work locally in the browser after a successful visit (gets installed with a service worker in browser) For the database it self, you can store data in the browser but some are limited to 5mb of data in the localstorage / sessionStorage / indexdb. Firebase does have some locally cached data. But if the browser is closed it can be lost.
If it needs to run locally i would go the electron route. Its slightly harder to do but it fills out your usecase better.
You can use both ways if you want to be sync like situation you have to hold data if your internet is not working in local storage or indexed db.
and it is fine you can deploy locally also or make one dedicated server which is always on.so any body in same network can use that angular app easily.
Just take care of backup plan when you system corrupt you should have proper backup of database for such scenario.

Retrieving files from Google Compute Engine

So I was using the free Google Compute engine trial. But I didn't realize in time that the trial is about to end, and now there are important files on the compute engine I'd really need to get.
How would I go on about retrieving files from it?
The support told me that the project is still active, just my billing is closed (since the trial ran out)
I tried to use the scp command in gcloud SDK shell, but couldn't really understand how to use it.
The virtual machine is running Windows Server 2016 (desktop).
Any help is highly appreciated.
I'm not very experienced here, but would really need the files nevertheless.
Thanks.
According to the documentation, once the free trial ends, all virtual machines still exist but are stopped (so you won't be able to access them -- and scp doesn't work on Windows anyway).
If you need access to the data, you'll need to upgrade the trial to a paid account, start the virtual machine, copy the data off it, and then stop it; you'll be billed for the time the virtual machine is running (so you may wish to downsize it to save money before you start it).
You only have 30 days from the end of the trial to do this; after this time, the VMs (and their disks) will be deleted (and unrecoverable by anyone).

OpenShift Pro - How To Increase Storage For Application

I have a Tomcat 8 web app running on OpenShift Pro, it has 2Gb storage allocated to it.
I want to increase the amount of storage to 4Gb.
In the Web Console, when I look at the Persistent Storage Claim the only Action available is Delete. I am reluctant to do this for obvious reasons...
What is the correct way to increase the storage available to an application?
Apparently there is no way to modify storage for an application. You will need to create a new one of the required size. You can then start a pod which mounts both volumes and copy contents from one to the other. When you have cut over to new volume and happy release claim on the original.
1) I think you should be able to edit the size of a persistent volume using the CLI interface. If you execute:
oc edit pvc <name of volume>
You should get an editor with a YAML representation of the persistent volume, where you can edit the size of the claim.
2) This is really a feature which Red Hat should support. I would open a ticket on the support page so that this gets added in the future.

How best to deploy this multi-tier app?

We currently have an application that runs on one dedicated server. I'd like to move it to OpenShift. It has:
A public-facing web app written in PhP
A Java app for administrators running on Wildfly
A Mysql database
A filesystem containing lots of images and documents that must be accessible to both the Java and PhP apps. A third party ftp's a data file to the server every day, and a perl script loads that into the db and the file system.
A perl script occasionally runs ffmpeg to generate videos, reading images from and writing videos to the filesystem.
Is Openshift a good solution for this, or would it be better to use AWS directly instead (for instance because they have dedicated file system components?)
Thanks
Michael Davis
Ottawa
The shared file system will definitely be the biggest issue here. You could get around it by setting up your applications to use Amazon S3 or some other shared Cloud file system though fairly easily.
As for the rest of the application, if I were setting this up I would:
Setup a scaled PHP application, even if you set the scaling to just use 1 gear this will allow you to put the MySQL database on it's own gear, and even choose a different size for it, such as having medium web gears (that run php) and a large gear that runs the MySQL database. This will also allow your wildfly gear to access the database since it will have a FQDN (fully qualified domain name) that any of your applications on your account can reach. However, keep in mind that it will use a non-standard port instead of 3306.
Then you can setup your WildFly server as whatever size you want, but, keep in mind that the MySQL connection variables will not be there, you will have to put them into your java application manually.
As for the perl script, depending on how intensive it is, you could run it on it's own whatever sized gear with some extra storage, or you could co-locate it with either the php or java application as a cron job. You can have it store the files on Amazon S3 and pull them down/upload them as it does the ffmpeg operations on them. Since OpenShift is also hosted on Amazon (In the US-EAST region) these operations should be pretty fast, as long as you also put your S3 bucket in the US-EAST region.
Those are my thoughts, hope it helps. Feel free to ask questions if you have them. You can also visit http://help.openshift.com and under "Contact Us" click on "Submit a request" and make sure you reference this StackOverflow question so I know what you are talking about, you can ask any questions you might have and we can discuss solutions for them.

Server for mobile feed app (like Instagram, Twitter...)?

I've made a mobile native app with a feed system like Instagram/Twitter. In development mode I was just running a PHP/MySQL Apache local server, but now I need to publish the app and work with a real server. Which kind of server do I need? I just need to send http requests (JSON), loads of them!
Do I just need a hosting server like 1and1? (http://www.1and1.com/linux-web-hosting?__lf=Static)
But this one, it only has 1GB MySQL databases... not enough
Is there any kind of app/server whatever? Which kind of server does Instagram use?
These days lots of users are moving to the cloud.
Check out Amazon EC2: http://aws.amazon.com/ec2/
You can setup a micro instance server and it is very cheap to run tests on and get off the ground. Then if you like how it's running, you can simply upgrade to a more powerful server without having to re-install everything.
It also allows you to scale if your application gets really popular by just cloning the server.
Really worth checking out.