Comments (16)
Sail really should have an option to convert it to a production-ready container, or at least to publish Sail's dockerfiles or something similar. Making it development-only largely defeats the purpose of having a containerized workflow. One of the key selling-points of containerization is to have consistent and predictable environments. Not giving users the ability to deploy their Sail-based applications directly is a huge miss, imo. Having to essentially roll your own containers for production makes using Sail pointless, since we might as well just use those same containers for development as well.
from sail.
a very kind & open request...
Accepting that Sail is a development tool, is there a tutorial, howto, dummys guide to transitioning from Sail to production?
I, like many others, have such limited expeience with Docker, we use Sail to develop on. now, once we are in a position to push to production, I for one, have no idea where to start the transition.
do i rip Sail out?
do i edit the Sail docker files to include nginx and any other bits needed like ffmpeg, gmp etc?
*is Sail just the CLI part and so not actually part of the docker thing anyways?
Would you or someone who understands please help demistify the process for us. ty.
from sail.
what is the purpose for containerization then :D
from sail.
Hi @dbelyaeff. Sail is meant as a development tool and not as a production tool.
from sail.
@mmdglmr I already answered those. Sail is a development tool, not a production tool.
from sail.
But are there know dangers of using Sail in production env?
from sail.
a very kind & open request...
Accepting that Sail is a development tool, is there a tutorial, howto, dummys guide to transitioning from Sail to production?
I, like many others, have such limited expeience with Docker, we use Sail to develop on. now, once we are in a position to push to production, I for one, have no idea where to start the transition.
do i rip Sail out? do i edit the Sail docker files to include nginx and any other bits needed like ffmpeg, gmp etc?
*is Sail just the CLI part and so not actually part of the docker thing anyways?
Would you or someone who understands please help demistify the process for us. ty.
Sail has nothing to do with the production environment. It uses php artisan serve
command to run the webserver so you can't use Nginx config files.
If you need docker for production you can build your own image. If you don't need it at all, you can use Nginx for production.
The following link documents the needed configurations:
https://laravel.com/docs/8.x/deployment
from sail.
Well,
Below could be one of the solution.
1 . Install docker on your hosting machine (aws, azure, gcp, etc...)
2 . go to the root directory of your app
3 . type below command to install software dependencies.
docker run --rm \
-u "$(id -u):$(id -g)" \
-v $(pwd):/var/www/html \
-w /var/www/html \
laravelsail/php81-composer:latest \
composer install --ignore-platform-reqs
4 . make docker container run in the detach mode (sail up -d)
from sail.
sometimes I need testing api some services, and they want https. If you will add nginx + php-fpm will great
from sail.
@dbelyaeff, you can publish and override Dockerfile
and docker-compose.yml
or using traefik
from sail.
@driesvints: would you answer to above questions, please? specific @alagiesellu question.
from sail.
We are currently using sail for development and docker based deployments on Laravel Vapor. We have a requirement for FFMPEG so we've updated our sail container to build FFMPEG. This works well and we have spent a lot of time ironing out issues during development. We also followed the advice at https://blog.laravel.com/vapor-docker-based-deployments to add ffmpeg to our vapor container.
Our problem is that we have different versions of ffmpeg installed on development and on vapor. These version mismatches are causing intermittent errors on staging and production that are extrememly difficult to debug.
We are relatively new to docker and thats why we used Laravel Sail. We chose this as we believed the benefits were that our production, staging and local environments would behave exactly the same.
Some potential options below
- Can we deploy the sail 8.0/Dockerfile so that our production environment is exactly the same as our local?
- Can we use the laravelphp/vapor:php80 locally within sail so that our local environment matches our production and staging?
If I am missing something please point me in the correct direction to understand my options here.
TIA
from sail.
I found a very amazing tool for Laravel deployment LaraSail
https://github.com/thedevdojo/larasail
Does the work well.
from sail.
I found a very amazing tool for Laravel deployment LaraSail
https://github.com/thedevdojo/larasail
Does the work well.
This is 'DigitalOceon' Specific. May not work for other hosting providers (AWS, Azure, GCP)
from sail.
Refer this url for deploying laravel sail over aws,
from sail.
Laravel offers paid service - Laravel Forge - for serving Laravel applications for production using real webservers.
If they would include a sail build-for-production-with-nginx command, and extend the docker setup with Nginx and PHP-FPM, it would kill their business of their paid services...
from sail.
Related Issues (20)
- MacOs Dockerfile failed on NO_PUBKEY 4F4EA0AAE5267A6C HOT 2
- Sail + Dusk not picking up Dusk specific .env file (.env.dusk.local) HOT 9
- Unable to pull PHP packages from ondrej repo HOT 1
- Hi, I have a problem with base_path HOT 1
- E: Unable to locate package postgresql-client-15 HOT 2
- Don't create DB after use command "sail up". HOT 1
- fresh install laravel 11 using bash don't remove comment from dotenv DB_DATABASE HOT 4
- Error on build: failed to solve: process "/bin/sh -c apt-get update ..." HOT 3
- SQLSTATE[HY000] [2002] php_network_getaddresses: getaddrinfo for mysql failed: Temporary failure in name resolution HOT 1
- docker-compose: command not found HOT 3
- Can't navigate to any links after sharing my site by "sail share" HOT 1
- sail up -d creates new docker container instead of using correct one HOT 10
- Hash Sum mismatch HOT 2
- [Bag] pgsql throw an error HOT 2
- I cannot create new app with mariadb service HOT 8
- Sail installation fails if the user asks for MariaDB 10 or 11 HOT 1
- SQLSTATE[08006] [7] could not send SSL negotiation packet: Resource temporarily unavailable HOT 4
- Sail share does not work for linux hosts HOT 1
- When adding a service to existing setup it breaks the existing configuration HOT 1
- Very slow on MacOS HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sail.