[2.x] [API stack] Improve installation for Sail projects and ensure consistency in env files#466
Closed
josephmiclaus wants to merge 4 commits intolaravel:2.xfrom
Closed
[2.x] [API stack] Improve installation for Sail projects and ensure consistency in env files#466josephmiclaus wants to merge 4 commits intolaravel:2.xfrom
josephmiclaus wants to merge 4 commits intolaravel:2.xfrom
Conversation
This was referenced Feb 5, 2025
.env.example
Member
|
We are rebuilding our starter kits now. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Improves the API stack installation considering Sail projects and ensures consistency between
.envand.env.example.Consistency between
.envand.env.exampleChanges that were previously applied only to
.envare now also applied to.env.example. This ensures that the.env.examplefile contains all the necessary environment variables, making it easier for team developers to set up the project. (Especially important for Sail projects, see below.)Considering API stack
Remove
VITE_PORTfromdocker-compose.ymlandVITE_APP_NAMEfrom environment files: Since Vite is not used in the API stack, these are not needed.Considering Sail projects
Add
APP_PORTto environment files: This is needed because when runningsail up, the API is only accessible at http://localhost:80 instead of the intended http://localhost:8000. WhenAPP_PORTis not set in the.envfile, the sail binary defaults it to port 80, causing this issue. Modifying the ports indocker-compose.ymldoesn't resolve this issue (as attempted in #464), because thesailbinary exportsAPP_PORTbeforedocker-compose.ymlis applied. AddingAPP_PORTto.envresolves the issue.This PR combines the changes from #463 + #465, since they were interrelated.