Skip to content

Commit 194c1c4

Browse files
committed
Added recipe information
1 parent 816dc46 commit 194c1c4

File tree

4 files changed

+35
-5808
lines changed

4 files changed

+35
-5808
lines changed

docs/index.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,11 @@ A self hosted server for Symfony Flex allowing private recipes, customized recip
1616

1717
In order to get up and running quickly
1818

19-
* check out the [system requirements](prerequisites.md) and
19+
* check out the [system requirements](topics/prerequisites.md) and
2020
* read about [setting the server up](topics/setup.md).
2121

22+
Want to now, how the server resolves packages and recipes? Read more [here](topics/recipes.md).
23+
2224
### License
2325

2426
Published under the [MIT License](https://github.com/moay/symfony-flex-server/blob/master/LICENSE).

docs/topics/recipes.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# Recipes
2+
3+
The server is a pure delivery system and won't actually interact with or change your recipes.
4+
5+
Nevertheless, there are some thoughts on recipes and how they are handled that you should keep in mind.
6+
7+
### Package resolving
8+
9+
[Symfony Flex](https://github.com/symfony/flex) will ask the server for a set of packages which are installed by composer. The server will then try to resolve this set of packages and answer by providing the proper recipes for the request.
10+
11+
Recipes are basically a set of files and instructions. The most important file of a recipe is the manifest file which should contain all instructions related to the recipe. You can learn more about how recipes are built in the [official repo](https://github.com/symfony/recipes).
12+
13+
Once you have setup the server, it will follow some basic rules when resolving the packages:
14+
15+
1) **Provide the newest version.** If you request a package at version 1.3 and you have a local recipe for version 1.0 and up, but the official endpoint provides version 1.2 and up, the latter will be used.
16+
2) **Local recipes first.** If both a local recipe repo and the official endpoint have the same version, use the local recipe.
17+
3) **Private over official.** If there are more than one local recipe repos, same version recipes will be selected in the order `private` > `official` > `contrib`.
18+
19+
There currently is now way to mix up recipes. If you want to have a customized or extended version of an official recipe, you'll have to provide a complete copy. We are planning on setting up a way to create recipe extension which will allow to extend official recipes and live until the next major version.
20+
21+
### Invalid manifest files
22+
23+
The entire system is based on the belief that you are capable of providing a valid json file. If your `manifest.json` is invalid, the server will display a warning label.
24+
25+
![broken manifest](https://user-images.githubusercontent.com/3605512/36715244-ae810436-1b95-11e8-842c-6ca9d7f29723.png)

mkdocs.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,15 @@
11
site_name: 'Symfony Flex Server'
22
repo_url: 'https://github.com/moay/symfony-flex-server'
3+
repo_name: 'moay/symfony-flex-server'
34
pages:
45
- 'Introduction': 'index.md'
56
- 'Requirements': 'topics/prerequisites.md'
67
- 'Setup': 'topics/setup.md'
78
- 'Configuration': 'topics/configuration.md'
89
- 'Updating recipes': 'topics/recipe_updating.md'
9-
- 'Commands': 'topics/commands.md'
10+
- 'About recipes': 'topics/recipes.md'
11+
- 'Commands': 'topics/commands.md'
12+
theme:
13+
name: 'material'
14+
palette:
15+
primary: 'grey'

0 commit comments

Comments
 (0)