Skip to content

Commit cf2bc66

Browse files
authored
best practices for c3i forks (#4276)
1 parent 60d9360 commit cf2bc66

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

devops/conancenter/hosting_binaries.rst

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,17 @@ Hosting your own copy of the packages you need in your server could be done by j
88

99
- Create a fork of the ConanCenter Github repository: https://github.com/conan-io/conan-center-index
1010
- Create a list of the packages and versions you need for your projects. This list can be added to the fork too, and maintained there (packages can be added and removed with PRs when the teams need them).
11-
- Create a script that first ``conan export`` all the packages in your list, then ``conan create --build=missing`` them. Do not add ``user/channel`` to these packages, it is way simpler to use them as ``zlib/1.2.13`` without user-channel. The ``user/channel`` part would be mostly recommended for your own proprietary packages, but not for open source ConanCenter packages.
11+
- Create a script that first ``conan export`` all the packages in your list, then ``conan create --build=missing`` them.
1212
- Upload your build packages to your own server, that you use in production, instead of ConanCenter.
1313

14+
.. note::
15+
16+
**Best practices**
17+
18+
- Do not add ``user/channel`` to packages created from ConanCenter forks, it is way simpler to create and use them as ``zlib/1.2.13`` without user-channel. The ``user/channel`` part would be mostly recommended for your own proprietary packages, but not for open source ConanCenter packages. It adds more divergence from the upstream and consequently more maintenance with little added value.
19+
- Do not mix packages and recipes created from your fork of ``conan-center-index`` Github repo with the ones from ConanCenter central server. Once you create some binaries for third parties from your fork, it is strongly recommended to fully disconnect from ConanCenter (you can remove the ``remote``, and you can add the ``remotes.json`` file with your own remotes to the configuration you can distribute and install with ``conan config install/install-pkg``), and create all your third-party packages from your fork.
20+
21+
1422
This is the basic flow idea. We will be adding examples and tools to further automate this flow as soon as possible.
1523

1624

0 commit comments

Comments
 (0)