fractal-code / meteor-azure

Automate Meteor deployments on Azure App Service
MIT License
67 stars 20 forks source link

Slow build times / Request for Linux version #17

Closed tgoldenberg closed 7 years ago

tgoldenberg commented 7 years ago

When the Web App runs the deploy.sh script, it takes an incredibly long time during the meteor build process. Now, I am used to deploying on Ubuntu 16.06, and the build time then is ~2 minutes. This build process is taking up to 30 minutes. And I have tried on 3 different version of the Standard Plan on Azure.

Would you consider adding a deploy.sh to go with the newly available Web App Linux VM's? I am going to explore the process so can possibly contribute as well. In addition, if you have suggestions on how to speed up the build times, I'm all ears!

ramijarrar commented 7 years ago

Linux App Service is in public preview - so still too early to evaluate/consider migrating production deployments over (no SLA, downtime on restarts, limited functionality, regions, etc.)

But from what I've gathered, the platform is Docker-based and with respect to actual architecture - bears little resemblance to its Windows counterpart. Supporting the service wouldn't be a matter of writing another "deploy.sh" - it would be its own project with new requirements (i.e equivalent of IIS configuration, managing Node runtime, writing sync mechanism, etc.)

This isn't something were interested in pursuing or see ourselves well equipped to tackle, we are well-versed with the current set of technologies and appreciate best practices / benefits associated (e.g integrated debugging or multi-core through IISNode) while seeing little to be gained from moving to new, unfamiliar ones.

Regarding build speeds, this has been on our backlog for a while: I've actually just wrapped up a round of optimizations which should improve speeds by a factor of 2-3 (our application now deploys in ~8-10m down from 30-40)

If you're still getting slow times after that (latest release is v1.4.3), go ahead and open an issue so we can track further improvements.

yjarrar commented 7 years ago

I would add that the build time for the first deploy (or after upgrading the script) will be slower than usual - after that you should be able to get build time in the 10 minute range

tgoldenberg commented 7 years ago

So the new version is a lot faster, I definitely agree with that. I'm getting builds in the 5-10 minute range, which is a huge improvement. The Linux version would be desirable because then it's a system that is more easily migratable to other providers such as AWS, Digital Ocean, etc. I was under the impression that the only difference would be modifying the deploy.sh file, but I have already found that that isn't the case (apparently, the Linux VM cannot read the file as is, and needs some software such as wine or something).

In any case, this work you have done is a great contribution for the Azure and Meteor community. I hope that others (including Azure itself!) take up the work of better documenting the deployment process for both Windows and Linux systems.