I'm developing a server application with Dart(Shelf).
I want to define different settings for the prod and dev environment.
Do you know any way to achieve this?
Related
I am trying to find the best way to achieve the following scenario;
I am currently working on getting a complex enterprise web application that consist on:
DB
BPM Engine
SOA Engine
Reporting Engine
Web Application Server
IDE
The applications is currently running in non-prod and prod environment but each environment is independent (no infra as a code, and deployments go from dev -> ... -> prod).
When a new developer comes in, they can't run the system in their local machine as it involves too many components (will come to this later). So they do development in their local machine and to test, they need to publish and deploy to dev. Test, rinse and repeat.
I am currently working on reverse engineer the whole thing so I can get it working on my local machine provided that I can install and run all the components. I am nearly there after fiddling with a lot of configuration, settings, etc.
This work I would like others to use, so they can also run the project in their local machines. In fact, since we will be migrating soon, I would like to pack the whole thing in a way that I can deploy it anywhere (the app already working and configured) and parametrised somehow whether is DEV, SYS, UAT, PROD. This, according to my understanding is what a docker image would do for you correct? You do all the work and then you create an image out of it? Then you can have this image running in a container and that way, other people can 'reuse' your work?
Is this the correct way of doing it? Any hints / comments would be appreciated
Apologies for my writing.
i have a rails app developed with 4.2.6 and ruby 2.2.4. Its my application so I am the only one responsible for the development, testing and deployment.Now I have few questions related to deployment and would appreciate if someone can help me.
I have two separate servers on digital ocean for staging and production.So how can i deploy my application or what should be the order of deployment when i am done with the development and testing.So..
i should be deploying the code on Staging(quite obvious) and then after testing successfully, in the staging server, deploy it to the production.Is this the way to go ahead.
Or deploy the code on staging and after testing, just deploy the changes only to the production and restart the production server.
Moreover, having separate git repository for both pro and staging good or how should i proceed with code maintenance.
What is the best approach.Is there something which i really need to understand or missing.Kindly help me the goodies with deployment and what suits the best?
Thanks in advance.
First, Yes your first assumption is correct you run you app in development on your local machine then when you are satisfied you test in in a production like environment which is staging then if you test everything an its fine then do a final deploy to production where its ready to be accessed by your users.
Second you dont need to have different git repos for both you should have a main branch where everything goes when its ready for production most of the times this is called master....then for the feature you are working create a separate branch where the changes goes and this is the branch where you add new features to your application usually known as develop or the name of the feature or name bug you are fixing...capistrano will allow you to choose what branch to deploy
Third afer you install capistrano it generates 2 file a staging and production file in the directory config/deploy customize this individually place the ip or endpoin/url of staging server in staging.rb and for production server inproduction.rb
Hi I have an API built with swagger. I need to deploy it to my production server and keep it running. How can I do this? Like a normal node project? What tools I can use to deploy it?
I read some articles stating that application configs/parameters should be kept out of version control and be set as environment variables in the production environment.
My question is: How do you manage these environment variables?
Using a configuration management tool like Puppet? What if you are deploying a new version of your app and need to add some new configuration variables?
Your deploy scripts will probably also be in version control so if you set any production variable in there everyone with deploy access can see it. (and tools like Capistrano stores the deploy scripts together with application source code.)
What are the common practice for this?
Thank you for your help.
What exactly is the difference in rails between dev and prod environments.
When I develop an application in dev mode, do I have peformance problems, or others if I clone my dev environment on prod?
Environments are similar to rails initializers, here's a short list of common differences:
Dev mode loads the development environment, production loads the production environment. You can find the files/settings for each in /config/environments/*.rb.
The development environment is usually set to display rendering information, system information, and RJS errors.
The development environment will usually have caching disabled.
I'm not sure if this still holds true, but the rails development environment has been known to have issues with memory leaks and should never be used on applications running on machines with production software.
Documentation on settings that can be used within the environment configurations can be found here: http://guides.rubyonrails.org/configuring.html
Dev mode won't cache your code, won't cache SQL, it will show you exceptions including your code, no optimizations, etc. Not recommended to distribute it like that, even though you can configure all those under config/environments/development.rb