Deploying a pre-compiled Vapor service - swift

Our team has a Vapor service that we deploy on a Mac through an NGINX reverse proxy. It works as expected.
The problem is, every time we deploy a new instance via sudo swift run, Vapor compiles the code from scratch, checks for dependencies, etc.
Is there a way to pre-compile the service and simply have it deployed out of the box?

Related

How to deploy Mindmeld project with production server mode?

The documentation explains how to run the service locally, but it does not explain how to deploy to the production server. I tried using a new flask service to call Mindmeld app. Although the service started successfully, it didn't load any data. Can you tell me how to deploy to the production?
server.py

Is it possible to deploy only Application Parameters (cloud.xml) in Service Fabric without having to change the Application version?

Is there a possibility to deploy only Application Parameters (cloud.xml) somehow without having to redeploy the code or upgrade the application version? For example after deploying the Application on Service fabric cluster, there could be a minor thing I might need to change in one of the parameters in cloud.xml. And it won't make sense to upgrade the version of the Application for this minor change.
I have combed through various sites but did not find anything suitable.
I'd say - no, you can't do this. Here is what Service Fabric application upgrade says on this -
During an upgrade, Service Fabric compares the new application manifest with the previous version and determines which services in the application require updates. Service Fabric compares the version numbers in the service manifests with the version numbers in the previous version. If a service has not changed, that service is not upgraded.

How to deploy Kitura generated Server Side Swift Build on Tomcat

I wanted to check if somebody has explored the option of deploying Kitura compiled project on TomCat? Basically, is it possible to deploy the build outside IBM cloud environment?
Please note that you can run Kitura instead of Tomcat. Kitura is an embedded web server, you do not need other web server to run a Kitura application. So you can build a Kitura application on macOS/Linux and run the compiled executable on macOS/Linux. It will listen to the port you specify, receive HTTP requests and route them to the request handling code of your application.

Deploying Treeline

I'm trying to deploy a Treeline app on my Ubuntu/Digital Ocean server with no luck.
I have worked successfully with sails (using "forever") before and tried to install treeline the same way.
npm install treeline -g
But after the installation, when trying to do something else, it always returns:
treeline.py: cannot connect to X server
I don't know if this error is due to my lack of experience deploying node or the earlier stage of the treeline project (which, on the other hand, is really awesome).
Thank you in advance.
Deploying a Treeline app is exactly the same as deploying a Sails app, because the files that get synched down from the Treeline server are Sails apps--they were just generated for you instead of you having to write the code. You don't need to npm install treeline -g on your server; that's only for previewing your app locally as you make changes to it on treeline.io. Instead, when you're ready to deploy, just follow whatever procedure that worked for your previous Sails apps and it will work for your Treeline app.
As far as the treeline.py error--that appears to be coming from a conflicting file pre-installed on Ubuntu!

Deploying Play 2.3 on production

I have developed a Scala/Play webapp and now I am trying to deploy it on production.
What is the recommended "best way" of doing that?
The documentation mentions only runnig it from play console, which does not seem very robust (in case of machine restarts etc).
There are apporaches to wrap the app into a war file and deploy on Tomcat7 (e.g. play2war), but they do not seem to be actively developed (e.g. there is only beta support for 2.3, the plugin is not available from maven repo etc).
What is the right way of doing this?
If you host the application on Windows then take a look at Yet Another Java Service Wrapper which wraps the application in a Windows service that will keep it running, even after restarts.
If you run it on Linux then take a look at Supervisord and Monit, which monitors the application and starts, restarts and stops it when needed.
See the following links for tutorials:
How do I run a Play Framework 2.0 application as a Windows service?
http://marcovanduijn.blogspot.nl/2011/08/run-play-framework-application-as.html
http://blog.fgribreau.com/2013/09/how-to-make-play-framework-2-work-with.html