ferrum-migration 1.0.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- ferrum_migration-1.0.1/LICENSE +131 -0
- ferrum_migration-1.0.1/LICENSE-COMMERCIAL.md +31 -0
- ferrum_migration-1.0.1/PKG-INFO +434 -0
- ferrum_migration-1.0.1/README.md +403 -0
- ferrum_migration-1.0.1/pyproject.toml +54 -0
- ferrum_migration-1.0.1/setup.cfg +4 -0
- ferrum_migration-1.0.1/src/ferrum_migration/__init__.py +23 -0
- ferrum_migration-1.0.1/src/ferrum_migration/__main__.py +8 -0
- ferrum_migration-1.0.1/src/ferrum_migration/cli.py +284 -0
- ferrum_migration-1.0.1/src/ferrum_migration/envprofile.py +289 -0
- ferrum_migration-1.0.1/src/ferrum_migration/errors.py +20 -0
- ferrum_migration-1.0.1/src/ferrum_migration/ferrum.py +3321 -0
- ferrum_migration-1.0.1/src/ferrum_migration/limits.py +25 -0
- ferrum_migration-1.0.1/src/ferrum_migration/matching.py +374 -0
- ferrum_migration-1.0.1/src/ferrum_migration/model.py +319 -0
- ferrum_migration-1.0.1/src/ferrum_migration/redact.py +84 -0
- ferrum_migration-1.0.1/src/ferrum_migration/report.py +142 -0
- ferrum_migration-1.0.1/src/ferrum_migration/safe_load.py +323 -0
- ferrum_migration-1.0.1/src/ferrum_migration/sources/__init__.py +23 -0
- ferrum_migration-1.0.1/src/ferrum_migration/sources/common.py +1773 -0
- ferrum_migration-1.0.1/src/ferrum_migration/sources/envoy.py +1754 -0
- ferrum_migration-1.0.1/src/ferrum_migration/sources/istio.py +1597 -0
- ferrum_migration-1.0.1/src/ferrum_migration/sources/kong.py +1950 -0
- ferrum_migration-1.0.1/src/ferrum_migration/sources/nginx.py +2696 -0
- ferrum_migration-1.0.1/src/ferrum_migration/sources/traefik.py +2046 -0
- ferrum_migration-1.0.1/src/ferrum_migration/util.py +1019 -0
- ferrum_migration-1.0.1/src/ferrum_migration/writer.py +358 -0
- ferrum_migration-1.0.1/src/ferrum_migration.egg-info/PKG-INFO +434 -0
- ferrum_migration-1.0.1/src/ferrum_migration.egg-info/SOURCES.txt +50 -0
- ferrum_migration-1.0.1/src/ferrum_migration.egg-info/dependency_links.txt +1 -0
- ferrum_migration-1.0.1/src/ferrum_migration.egg-info/entry_points.txt +2 -0
- ferrum_migration-1.0.1/src/ferrum_migration.egg-info/requires.txt +1 -0
- ferrum_migration-1.0.1/src/ferrum_migration.egg-info/top_level.txt +1 -0
- ferrum_migration-1.0.1/tests/test_cli.py +735 -0
- ferrum_migration-1.0.1/tests/test_defensive.py +282 -0
- ferrum_migration-1.0.1/tests/test_discovery.py +164 -0
- ferrum_migration-1.0.1/tests/test_emitter.py +892 -0
- ferrum_migration-1.0.1/tests/test_envoy.py +1568 -0
- ferrum_migration-1.0.1/tests/test_ferrum_reference.py +935 -0
- ferrum_migration-1.0.1/tests/test_frontend_protocols.py +324 -0
- ferrum_migration-1.0.1/tests/test_istio.py +1301 -0
- ferrum_migration-1.0.1/tests/test_kong.py +1537 -0
- ferrum_migration-1.0.1/tests/test_load.py +134 -0
- ferrum_migration-1.0.1/tests/test_nginx.py +3963 -0
- ferrum_migration-1.0.1/tests/test_path_composition.py +377 -0
- ferrum_migration-1.0.1/tests/test_regex_alternation.py +87 -0
- ferrum_migration-1.0.1/tests/test_release_check.py +1034 -0
- ferrum_migration-1.0.1/tests/test_resilience.py +197 -0
- ferrum_migration-1.0.1/tests/test_safe_load.py +238 -0
- ferrum_migration-1.0.1/tests/test_sticky_cookies.py +154 -0
- ferrum_migration-1.0.1/tests/test_traefik.py +2090 -0
- ferrum_migration-1.0.1/tests/test_version.py +91 -0
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
# PolyForm Noncommercial License 1.0.0
|
|
2
|
+
|
|
3
|
+
<https://polyformproject.org/licenses/noncommercial/1.0.0>
|
|
4
|
+
|
|
5
|
+
## Acceptance
|
|
6
|
+
|
|
7
|
+
In order to get any license under these terms, you must agree
|
|
8
|
+
to them as both strict obligations and conditions to all
|
|
9
|
+
your licenses.
|
|
10
|
+
|
|
11
|
+
## Copyright License
|
|
12
|
+
|
|
13
|
+
The licensor grants you a copyright license for the
|
|
14
|
+
software to do everything you might do with the software
|
|
15
|
+
that would otherwise infringe the licensor's copyright
|
|
16
|
+
in it for any permitted purpose. However, you may
|
|
17
|
+
only distribute the software according to [Distribution
|
|
18
|
+
License](#distribution-license) and make changes or new works
|
|
19
|
+
based on the software according to [Changes and New Works
|
|
20
|
+
License](#changes-and-new-works-license).
|
|
21
|
+
|
|
22
|
+
## Distribution License
|
|
23
|
+
|
|
24
|
+
The licensor grants you an additional copyright license
|
|
25
|
+
to distribute copies of the software. Your license
|
|
26
|
+
to distribute covers distributing the software with
|
|
27
|
+
changes and new works permitted by [Changes and New Works
|
|
28
|
+
License](#changes-and-new-works-license).
|
|
29
|
+
|
|
30
|
+
## Notices
|
|
31
|
+
|
|
32
|
+
You must ensure that anyone who gets a copy of any part of
|
|
33
|
+
the software from you also gets a copy of these terms or the
|
|
34
|
+
URL for them above, as well as copies of any plain-text lines
|
|
35
|
+
beginning with `Required Notice:` that the licensor provided
|
|
36
|
+
with the software. For example:
|
|
37
|
+
|
|
38
|
+
> Required Notice: Copyright Ferrum Edge LLC (https://github.com/ferrum-edge)
|
|
39
|
+
|
|
40
|
+
## Changes and New Works License
|
|
41
|
+
|
|
42
|
+
The licensor grants you an additional copyright license to
|
|
43
|
+
make changes and new works based on the software for any
|
|
44
|
+
permitted purpose.
|
|
45
|
+
|
|
46
|
+
## Patent License
|
|
47
|
+
|
|
48
|
+
The licensor grants you a patent license for the software that
|
|
49
|
+
covers patent claims the licensor can license, or becomes able
|
|
50
|
+
to license, that you would infringe by using the software.
|
|
51
|
+
|
|
52
|
+
## Noncommercial Purposes
|
|
53
|
+
|
|
54
|
+
Any noncommercial purpose is a permitted purpose.
|
|
55
|
+
|
|
56
|
+
## Personal Uses
|
|
57
|
+
|
|
58
|
+
Personal use for research, experiment, and testing for
|
|
59
|
+
the benefit of public knowledge, personal study, private
|
|
60
|
+
entertainment, hobby projects, amateur pursuits, or religious
|
|
61
|
+
observance, without any anticipated commercial application,
|
|
62
|
+
is use for a permitted purpose.
|
|
63
|
+
|
|
64
|
+
## Noncommercial Organizations
|
|
65
|
+
|
|
66
|
+
Use by any charitable organization, educational institution,
|
|
67
|
+
public research organization, public safety or health
|
|
68
|
+
organization, environmental protection organization,
|
|
69
|
+
or government institution is use for a permitted purpose
|
|
70
|
+
regardless of the source of funding or obligations resulting
|
|
71
|
+
from the funding.
|
|
72
|
+
|
|
73
|
+
## Fair Use
|
|
74
|
+
|
|
75
|
+
You may have "fair use" rights for the software under the
|
|
76
|
+
law. These terms do not limit them.
|
|
77
|
+
|
|
78
|
+
## No Other Rights
|
|
79
|
+
|
|
80
|
+
These terms do not allow you to sublicense or transfer any of
|
|
81
|
+
your licenses to anyone else, or prevent the licensor from
|
|
82
|
+
granting licenses to anyone else. These terms do not imply
|
|
83
|
+
any other licenses.
|
|
84
|
+
|
|
85
|
+
## Patent Defense
|
|
86
|
+
|
|
87
|
+
If you make any written claim that the software infringes or
|
|
88
|
+
contributes to infringement of any patent, your patent license
|
|
89
|
+
for the software granted under these terms ends immediately. If
|
|
90
|
+
your company makes such a claim, your patent license ends
|
|
91
|
+
immediately for work on behalf of your company.
|
|
92
|
+
|
|
93
|
+
## Violations
|
|
94
|
+
|
|
95
|
+
The first time you are notified in writing that you have
|
|
96
|
+
violated any of these terms, or done anything with the software
|
|
97
|
+
not covered by your licenses, your licenses can nonetheless
|
|
98
|
+
continue if you come into full compliance with these terms,
|
|
99
|
+
and take practical steps to correct past violations, within
|
|
100
|
+
32 days of receiving notice. Otherwise, all your licenses
|
|
101
|
+
end immediately.
|
|
102
|
+
|
|
103
|
+
## No Liability
|
|
104
|
+
|
|
105
|
+
***As far as the law allows, the software comes as is, without
|
|
106
|
+
any warranty or condition, and the licensor will not be liable
|
|
107
|
+
to you for any damages arising out of these terms or the use
|
|
108
|
+
or nature of the software, under any kind of legal claim.***
|
|
109
|
+
|
|
110
|
+
## Definitions
|
|
111
|
+
|
|
112
|
+
The **licensor** is the entity offering these terms, and the
|
|
113
|
+
**software** is the software the licensor makes available under
|
|
114
|
+
these terms.
|
|
115
|
+
|
|
116
|
+
**You** refers to the individual or entity agreeing to these
|
|
117
|
+
terms.
|
|
118
|
+
|
|
119
|
+
**Your company** is any legal entity, sole proprietorship,
|
|
120
|
+
or other kind of organization that you work for, plus all
|
|
121
|
+
organizations that have control over, are under the control of,
|
|
122
|
+
or are under common control with that organization. **Control**
|
|
123
|
+
means ownership of substantially all the assets of an entity,
|
|
124
|
+
or the power to direct its management and policies by vote,
|
|
125
|
+
contract, or otherwise. Control can be direct or indirect.
|
|
126
|
+
|
|
127
|
+
**Your licenses** are all the licenses granted to you for the
|
|
128
|
+
software under these terms.
|
|
129
|
+
|
|
130
|
+
**Use** means anything you do with the software requiring one
|
|
131
|
+
of your licenses.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Commercial License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Ferrum Edge LLC
|
|
4
|
+
|
|
5
|
+
The software in this repository is licensed under the PolyForm Noncommercial
|
|
6
|
+
License 1.0.0 for noncommercial use. See the [LICENSE](LICENSE) file for details.
|
|
7
|
+
|
|
8
|
+
## Commercial Use
|
|
9
|
+
|
|
10
|
+
If you wish to use Ferrum Migration for commercial purposes, you must obtain a
|
|
11
|
+
separate commercial license from Ferrum Edge LLC.
|
|
12
|
+
|
|
13
|
+
Commercial use includes, but is not limited to:
|
|
14
|
+
|
|
15
|
+
- Using Ferrum Migration as part of a paid product or service
|
|
16
|
+
- Using Ferrum Migration in a for-profit company's infrastructure
|
|
17
|
+
- Offering Ferrum Migration as a managed or hosted service
|
|
18
|
+
- Bundling or distributing Ferrum Migration with commercial software
|
|
19
|
+
|
|
20
|
+
## Obtaining a Commercial License
|
|
21
|
+
|
|
22
|
+
For commercial licensing inquiries, email **contact@ferrumedge.com**.
|
|
23
|
+
|
|
24
|
+
## Dual Licensing Summary
|
|
25
|
+
|
|
26
|
+
| Use Case | License | Cost |
|
|
27
|
+
|----------|---------|------|
|
|
28
|
+
| Personal / hobby projects | PolyForm Noncommercial 1.0.0 | Free |
|
|
29
|
+
| Research / education | PolyForm Noncommercial 1.0.0 | Free |
|
|
30
|
+
| Nonprofit organizations | PolyForm Noncommercial 1.0.0 | Free |
|
|
31
|
+
| Commercial use | Commercial License | Paid |
|
|
@@ -0,0 +1,434 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: ferrum-migration
|
|
3
|
+
Version: 1.0.1
|
|
4
|
+
Summary: Offline, best-effort, fail-closed translation of Kong, NGINX, Traefik, Envoy and Istio configuration into Ferrum Edge declarative config
|
|
5
|
+
License-Expression: PolyForm-Noncommercial-1.0.0
|
|
6
|
+
Project-URL: Homepage, https://github.com/ferrum-edge/ferrum-migration
|
|
7
|
+
Project-URL: Documentation, https://github.com/ferrum-edge/ferrum-migration/blob/main/docs/mappings.md
|
|
8
|
+
Project-URL: Source, https://github.com/ferrum-edge/ferrum-migration
|
|
9
|
+
Project-URL: Issues, https://github.com/ferrum-edge/ferrum-migration/issues
|
|
10
|
+
Project-URL: Changelog, https://github.com/ferrum-edge/ferrum-migration/blob/main/CHANGELOG.md
|
|
11
|
+
Project-URL: Ferrum Edge, https://github.com/ferrum-edge/ferrum-edge
|
|
12
|
+
Keywords: ferrum,ferrum-edge,api-gateway,migration,kong,nginx,traefik,envoy,istio
|
|
13
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
14
|
+
Classifier: Environment :: Console
|
|
15
|
+
Classifier: Intended Audience :: System Administrators
|
|
16
|
+
Classifier: Operating System :: MacOS
|
|
17
|
+
Classifier: Operating System :: POSIX :: Linux
|
|
18
|
+
Classifier: Programming Language :: Python :: 3
|
|
19
|
+
Classifier: Programming Language :: Python :: 3 :: Only
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
21
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
22
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
23
|
+
Classifier: Topic :: Internet :: Proxy Servers
|
|
24
|
+
Classifier: Topic :: System :: Systems Administration
|
|
25
|
+
Requires-Python: >=3.11
|
|
26
|
+
Description-Content-Type: text/markdown
|
|
27
|
+
License-File: LICENSE
|
|
28
|
+
License-File: LICENSE-COMMERCIAL.md
|
|
29
|
+
Requires-Dist: PyYAML<7,>=6.0.1
|
|
30
|
+
Dynamic: license-file
|
|
31
|
+
|
|
32
|
+
<p align="center">
|
|
33
|
+
<img src="https://raw.githubusercontent.com/ferrum-edge/ferrum-migration/main/docs/ferrum_migration.png" alt="Ferrum Migration" width="400" />
|
|
34
|
+
</p>
|
|
35
|
+
|
|
36
|
+
<h1 align="center">Ferrum Migration</h1>
|
|
37
|
+
|
|
38
|
+
<p align="center"><b>Translate your config. Move to the Edge.</b></p>
|
|
39
|
+
|
|
40
|
+
<p align="center">
|
|
41
|
+
<a href="#status"><img src="https://img.shields.io/badge/status-stable%20%281.x%29-brightgreen" alt="Status: stable (1.x)" /></a>
|
|
42
|
+
<a href="https://github.com/ferrum-edge/ferrum-migration/actions/workflows/ci.yml"><img src="https://github.com/ferrum-edge/ferrum-migration/actions/workflows/ci.yml/badge.svg?branch=main" alt="CI" /></a>
|
|
43
|
+
<a href="https://github.com/ferrum-edge/ferrum-migration/blob/main/LICENSE"><img src="https://img.shields.io/badge/license-PolyForm%20Noncommercial-blue" alt="License" /></a>
|
|
44
|
+
<img src="https://img.shields.io/badge/python-3.11%20%7C%203.12%20%7C%203.13-blue?logo=python&logoColor=white" alt="Python 3.11, 3.12, 3.13" />
|
|
45
|
+
<img src="https://img.shields.io/badge/migrates%20from-Kong%20%7C%20NGINX%20%7C%20Traefik%20%7C%20Envoy%20%7C%20Istio-orange" alt="Migrates from Kong, NGINX, Traefik, Envoy, Istio" />
|
|
46
|
+
<a href="https://github.com/ferrum-edge/ferrum-edge/releases/tag/v1.0.1"><img src="https://img.shields.io/badge/Ferrum%20Edge-v1.0.1-brightgreen" alt="Mappings verified against Ferrum Edge v1.0.1" /></a>
|
|
47
|
+
</p>
|
|
48
|
+
|
|
49
|
+
Offline, best-effort, **fail-closed** migration of existing gateway, reverse-proxy and
|
|
50
|
+
service-mesh configuration into [Ferrum Edge](https://github.com/ferrum-edge/ferrum-edge)
|
|
51
|
+
declarative config, so you can try Ferrum without rewriting every route by hand. The output is
|
|
52
|
+
a starting point for review, not a guaranteed equivalent of the source: whatever the tool
|
|
53
|
+
cannot reproduce is refused or reported.
|
|
54
|
+
|
|
55
|
+
| Source | Input accepted |
|
|
56
|
+
|---|---|
|
|
57
|
+
| Kong Gateway | DB-less `kong.yml` or a decK dump (`deck gateway dump`), YAML or JSON. Both share one schema, so `--from kong` handles either; no extra flag is needed, and the report states which flavor was detected. The tool never talks to a Kong database or Admin API. |
|
|
58
|
+
| NGINX OSS | One `nginx.conf`-syntax file with an `http {}` block (or bare `server {}` blocks). Includes are never followed. |
|
|
59
|
+
| Traefik OSS | Dynamic configuration for the file provider (`http` section), YAML, TOML or JSON. The static configuration (entryPoints) and other providers are not read, so forwarding routes are refused unless you pass `--assert-traefik-input-includes-effective-controls` (see Options). |
|
|
60
|
+
| Envoy | v3 static bootstrap (`static_resources`) with HTTP connection managers and inline `route_config`. |
|
|
61
|
+
| Istio | Networking CRDs (`Gateway`, `VirtualService`, `DestinationRule`, `ServiceEntry`) as multi-document YAML or a `kind: List`. This is an **ingress projection**: only Gateway-bound routes become Ferrum edge proxies. Mesh routing, sidecars and workload mTLS are reported, not migrated. |
|
|
62
|
+
|
|
63
|
+
It writes, into a private output directory:
|
|
64
|
+
|
|
65
|
+
* `resources.yaml`: Ferrum file-mode resources (proxies, upstreams, consumers, plugin_configs)
|
|
66
|
+
with a `resource_counts` truncation seal.
|
|
67
|
+
* `ferrum.conf`: `KEY=value` settings for the run mode you pick (`file`, `database`, `cp`, `dp`).
|
|
68
|
+
It contains no secrets. Values from the source (certificate, key and client CA paths, bind
|
|
69
|
+
address) are quoted when Ferrum's parser needs it. A value that cannot be read back unchanged
|
|
70
|
+
(line breaks or other non-printable characters) rejects the input (exit 3) before anything is
|
|
71
|
+
written.
|
|
72
|
+
* `migration-report.md` and `migration-report.json`: every caveat, refusal and safe omission,
|
|
73
|
+
plus next steps. These never contain credential values.
|
|
74
|
+
|
|
75
|
+
Mappings were verified against Ferrum Edge `v1.0.1` at
|
|
76
|
+
`a2974b9f1594de32fec3722612f899946486a8ab` (config structs, plugin validators, and the settings
|
|
77
|
+
inventory). See [docs/mappings.md](https://github.com/ferrum-edge/ferrum-migration/blob/main/docs/mappings.md).
|
|
78
|
+
|
|
79
|
+
## Install
|
|
80
|
+
|
|
81
|
+
Python 3.11+ and PyYAML. See [Status](#status) and
|
|
82
|
+
[docs/compatibility.md](https://github.com/ferrum-edge/ferrum-migration/blob/main/docs/compatibility.md)
|
|
83
|
+
for the `1.x` compatibility contract.
|
|
84
|
+
|
|
85
|
+
From a release tag (`vX.Y.Z`; see the
|
|
86
|
+
[releases](https://github.com/ferrum-edge/ferrum-migration/releases) and the
|
|
87
|
+
[changelog](https://github.com/ferrum-edge/ferrum-migration/blob/main/CHANGELOG.md)):
|
|
88
|
+
|
|
89
|
+
```bash
|
|
90
|
+
python -m pip install "ferrum-migration @ git+https://github.com/ferrum-edge/ferrum-migration@vX.Y.Z"
|
|
91
|
+
ferrum-migrate --version
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
Each GitHub release also carries the wheel, the sdist, a `SHA256SUMS` file and GitHub build
|
|
95
|
+
provenance attestations. To install a downloaded wheel only if both checks pass (on macOS,
|
|
96
|
+
use `shasum -a 256 -c -` in place of `sha256sum --strict -c -`):
|
|
97
|
+
|
|
98
|
+
```bash
|
|
99
|
+
wheel=ferrum_migration-X.Y.Z-py3-none-any.whl
|
|
100
|
+
grep -F " $wheel" SHA256SUMS | sha256sum --strict -c - &&
|
|
101
|
+
gh attestation verify "$wheel" -R ferrum-edge/ferrum-migration &&
|
|
102
|
+
python -m pip install "$wheel"
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
From a checkout of this repository:
|
|
106
|
+
|
|
107
|
+
```bash
|
|
108
|
+
python -m pip install . # or: python -m pip install -e .
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
From PyPI (publishing is configured for releases from `v1.0.1` onward via GitHub Actions
|
|
112
|
+
Trusted Publishing; `v1.0.0` is GitHub-only—see
|
|
113
|
+
[docs/releasing.md](https://github.com/ferrum-edge/ferrum-migration/blob/main/docs/releasing.md)).
|
|
114
|
+
Once a release is listed on
|
|
115
|
+
[pypi.org/project/ferrum-migration](https://pypi.org/project/ferrum-migration/), install it with:
|
|
116
|
+
|
|
117
|
+
```bash
|
|
118
|
+
python -m pip install ferrum-migration # or: python -m pip install ferrum-migration==X.Y.Z
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
## Use
|
|
122
|
+
|
|
123
|
+
```bash
|
|
124
|
+
ferrum-migrate platforms
|
|
125
|
+
ferrum-migrate check kong.yaml --from kong # report only, writes nothing
|
|
126
|
+
ferrum-migrate convert kong.yaml --from kong --out ./ferrum-out
|
|
127
|
+
ferrum-migrate convert nginx.conf --from nginx --out ./ferrum-out --tls-only
|
|
128
|
+
ferrum-migrate convert dynamic.yml --from traefik --out ./ferrum-out --run-mode database \
|
|
129
|
+
--assert-traefik-input-includes-effective-controls # only after the checklist under Options
|
|
130
|
+
ferrum-migrate convert envoy.yaml --from envoy --out ./ferrum-out
|
|
131
|
+
ferrum-migrate convert istio.yaml --from istio --out ./ferrum-out
|
|
132
|
+
|
|
133
|
+
# then, with a ferrum-edge binary:
|
|
134
|
+
cd ferrum-out && ferrum-edge validate --settings ferrum.conf --spec resources.yaml
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
Options:
|
|
138
|
+
|
|
139
|
+
| Option | Meaning |
|
|
140
|
+
|---|---|
|
|
141
|
+
| `--run-mode file\|database\|cp\|dp` | Which Ferrum operating mode `ferrum.conf` targets (default `file`). For database/cp, validate in file mode, then import through Ferrum's documented Admin API. This tool does no network I/O. |
|
|
142
|
+
| `--tls-only` | Disable Ferrum's plaintext listener so routes that were HTTPS-only in the source can be migrated. This is chosen automatically when every migrated route requires HTTPS. Routes the source served over plaintext only are then refused (`frontend-protocol-scope`), because Ferrum would serve them on its HTTPS listener. |
|
|
143
|
+
| `--assert-traefik-input-includes-effective-controls` | Traefik only (refused with exit 2 for other sources). Your scoped statement, made after you verified the Traefik deployment, that the input includes every effective routing, TLS and access control that applies within the converted scope (static, dynamic or from another provider), or that no additional control applies. Checklist, for every converted router: **static entryPoints** (file, CLI flags or environment) used by it (named in `entryPoints`, or the default entryPoints of routers that name none) add no TLS (`http.tls`), middlewares (`http.middlewares`), redirections (`http.redirections`), forwarded-header or PROXY protocol trust (`forwardedHeaders`, `proxyProtocol`) or bind restriction (`address`), and routers naming no entryPoints share the entryPoint the other routers of their protocol use; **omitted TLS options**: no TLS options from another provider or file apply, in particular no `default` TLS options outside the input (Traefik applies them to TLS routers that name none and to connections whose SNI no router claims); **SNI option conflicts**: no router outside the input maps the same host names to other TLS options; **competing routers**: no router of another provider or file matches the same hosts and paths on those entryPoints; and no middleware, service or `serversTransport` outside the input applies. The tool cannot check any of this; it is your representation, not a validation. Without it, every Traefik route that would forward traffic is refused (`traefik-controls-unverified`). With it, the report carries a `traefik-controls-asserted` warning, and everything the input states still applies or refuses, whatever you state: router `tls` (HTTPS-only), the one global handshake policy (HTTPS routes are translated only under the `default` TLS options, reached by naming no options, an empty reference or exactly `default`; any other TLS options definition or reference, including a provider-qualified `default@file`, refuses every HTTPS route, `traefik-tls-options-scope`), `default` `clientAuth` and `sniStrict` (enabled `sniStrict` refuses every HTTPS route, `traefik-sni-strict`), unresolved references (other providers, undefined names), middlewares, and explicit `entryPoints` lists (routers that leave out the entryPoint the other routers of their protocol share are refused, `traefik-entrypoint-scope`). An input that itself contains a static `entryPoints` section stays refused (`traefik-entrypoints-in-input`), and an input with a typed field spelled other than canonically is rejected outright (exit 3; see Safety model). |
|
|
144
|
+
| `--kubernetes-service-discovery` | Istio only (refused with exit 2 for other sources). Resolve destinations that are in-cluster Kubernetes Services (`<name>.<namespace>.svc.cluster.local`, no ServiceEntry) through Ferrum's Kubernetes service discovery: Ferrum lists the Service's EndpointSlices and balances across ready pods, as Istio's gateway does, instead of sending to the Service DNS name (its cluster IP). Include the Kubernetes `Service` objects in the input: they map the destination's Service port to the EndpointSlice port name. Discovery is used only where Ferrum reproduces Istio's endpoint set exactly; a destination whose Service is missing, an ExternalName, node-local (`internalTrafficPolicy: Local`), publishes not-ready addresses, has invalid names, or whose port is ambiguous keeps its DNS name (`istio-k8s-sd-port`); a non-TCP Service port refuses the route; a weighted split over several destinations keeps DNS names (`istio-k8s-sd-weighted`). HTTPS destinations keep verifying the Service name (`backend_tls_sni`). Ferrum must then run in the cluster with permission to list `discovery.k8s.io` EndpointSlices, and trust the API server through its outbound trust store: add the cluster CA (`/var/run/secrets/kubernetes.io/serviceaccount/ca.crt`) to the container's system roots, or set `FERRUM_TLS_CA_BUNDLE_PATH` to a bundle containing it and every other root Ferrum's outbound TLS needs (it replaces the system roots; Ferrum does not read the service account's `ca.crt` itself). The report spells this out (`kubernetes-service-discovery`). |
|
|
145
|
+
| `--include-secrets` | Explicit opt-in to write migratable plaintext credentials (Kong key-auth keys) into the resources file. Kong JWT secrets are never written (see Safety model). Output files are always mode `0600`; on POSIX, the output directory must be owned by you with no group/world access or extended ACLs, and when plaintext credentials are emitted a `.gitignore` containing `*` is also written. |
|
|
146
|
+
| `--strict` | Treat warnings as "review required" (exit 4). |
|
|
147
|
+
| `--max-input-bytes N` | Input size cap (default 8 MiB). |
|
|
148
|
+
| `--resources-format yaml\|json` | Output format for the resources file. A resources file of the other format already in the output directory is refused (exit 5), even with `--force`, because Ferrum discovers `resources.yaml` before `resources.json`. Pass `--spec` explicitly when you run Ferrum. |
|
|
149
|
+
| `--force` | Replace existing output files (atomic rename). |
|
|
150
|
+
|
|
151
|
+
There is no option to turn backend TLS verification off. The former `--allow-insecure-backend-tls` flag
|
|
152
|
+
is refused with exit code 2, and nothing is written.
|
|
153
|
+
|
|
154
|
+
### Exit codes
|
|
155
|
+
|
|
156
|
+
| Code | Meaning |
|
|
157
|
+
|---|---|
|
|
158
|
+
| 0 | Migrated; no error-level caveats (warnings allowed unless `--strict`). |
|
|
159
|
+
| 1 | Internal error; nothing written. The exception text is never printed, because it could echo input. |
|
|
160
|
+
| 2 | Usage error. |
|
|
161
|
+
| 3 | Input rejected (syntax, duplicate keys, size/node/depth/alias limits, unsupported shape such as a Traefik typed field spelled other than canonically, or a Traefik router whose `parentRefs` is set to anything but an empty list); nothing written. |
|
|
162
|
+
| 4 | Output written, but it contains items that need review: refused or fail-closed routes, unmigrated credentials, or approximations that are less strict (also warnings with `--strict`). |
|
|
163
|
+
| 5 | Output could not be written safely (existing files without `--force`, symlinked target, permissions). |
|
|
164
|
+
|
|
165
|
+
## Safety model
|
|
166
|
+
|
|
167
|
+
The tool is conservative. When it cannot reproduce something faithfully, it fails closed
|
|
168
|
+
rather than opening routes or downgrading security:
|
|
169
|
+
|
|
170
|
+
* **Refused routes become placeholders.** A route that cannot be translated (unknown or
|
|
171
|
+
unsupported auth/policy plugin, unrepresentable rewrite, HTTPS-only route in a mixed config, and so on)
|
|
172
|
+
is replaced by a proxy with the same hosts, path and port. Its only plugin is
|
|
173
|
+
`request_termination` (HTTP 503), which Ferrum runs before authentication. The refused
|
|
174
|
+
traffic therefore cannot fall through to a broader, less protected route.
|
|
175
|
+
* **Unrepresentable matches poison overlaps.** Routes that match on headers, queries, SNI,
|
|
176
|
+
regex hosts or similar cannot be expressed in Ferrum. Every route Ferrum would prefer for the
|
|
177
|
+
overlapping requests is refused too.
|
|
178
|
+
* **Case-insensitive paths keep only their exact case.** Envoy `case_sensitive: false` and Istio
|
|
179
|
+
`ignoreUriCase` matches stay migrated for their exact-case path, because Ferrum matches paths
|
|
180
|
+
case-sensitively. Every other route that could receive their case variants (`/API` for `/api`) is
|
|
181
|
+
refused instead of forwarding them; overlap checks compare such paths case-folded.
|
|
182
|
+
* **Precedence is checked, not assumed.** The tool checks first-match order (Envoy, Istio), router
|
|
183
|
+
priorities (Traefik) and regex-versus-prefix precedence (NGINX, Kong) against Ferrum's specificity
|
|
184
|
+
order. Unreachable routes are dropped and contradictory pairs are refused.
|
|
185
|
+
* **Prefix semantics are guarded.** The source prefix matchers listed below match plain strings,
|
|
186
|
+
so `/api` also matches `/apix`, while Ferrum matches by path segment. Where a broader route has a different
|
|
187
|
+
policy, a `request_termination` guard (`trigger.path_prefix`) is added so `/apix` cannot
|
|
188
|
+
reach it. Trailing-slash prefixes get an exact 404 route for the bare path. Routes are never
|
|
189
|
+
widened to cover `/apix`. When `/apix` would not reach an equivalent route in Ferrum, the report
|
|
190
|
+
carries a `prefix-string-siblings` error (exit 4) instead of a silent 404. This applies to NGINX
|
|
191
|
+
prefix locations, Kong `paths`, Traefik `PathPrefix`, Envoy `prefix` and Istio `uri.prefix`
|
|
192
|
+
(except in VirtualServices Istio generates from Ingress or Gateway API resources, marked
|
|
193
|
+
`internal.istio.io/route-semantics`, whose prefixes match by path segment like Ferrum's).
|
|
194
|
+
It does not apply to Envoy `path_separated_prefix` (already segment-based), exact or regex
|
|
195
|
+
matches, or prefixes ending in `/`. A refused route's placeholder is guarded the same way, so
|
|
196
|
+
`/adminx` cannot reach a broader, open route when `/admin` was refused. If the broader route
|
|
197
|
+
serves more hosts, the guard still applies to all of them and a `prefix-divergence-refused`
|
|
198
|
+
error reports the extra 404s. Regex routes that the source's priority kept away from such
|
|
199
|
+
siblings (an NGINX `^~` prefix, an earlier Envoy/Istio prefix) are guarded the same way when no
|
|
200
|
+
prefix route in the host tier catches the siblings first. For a refused route, or a competing
|
|
201
|
+
regex route, a guard that cannot be scoped exactly is still added (fail closed) and reported.
|
|
202
|
+
* **No cross-host fallthrough.** An NGINX server, Envoy virtual host or Istio host never falls
|
|
203
|
+
through to another host's routes. Ferrum can, so a host-only 404 route closes each such scope.
|
|
204
|
+
When another host-only route overlaps a scope without closing exactly its host names, a regex
|
|
205
|
+
route matching every path (`~/.*`, 404, emitted after the scope's own routes) closes it instead.
|
|
206
|
+
If that is not possible either, the routes that would receive its unmatched requests are refused
|
|
207
|
+
(`scope-closure-skipped`). A wildcard scope that covers another scope's narrower wildcard
|
|
208
|
+
(`*.example.com` and `*.team.example.com`) has its routes refused (`nested-wildcard-scope`),
|
|
209
|
+
because Ferrum's wildcard tier compares the path routes of every matching pattern. An NGINX
|
|
210
|
+
default server whose own `server_name` another server on the same listener covers keeps its
|
|
211
|
+
named routes instead of becoming a catch-all (error `nginx-default-server-named`; unknown host
|
|
212
|
+
names are then not routed to it). Default-server roles are decided on the listeners Ferrum
|
|
213
|
+
actually serves (dropped extra ports do not count). A server that is the default on only some of
|
|
214
|
+
them keeps its named hosts (`nginx-default-server-listener`), and different default servers on
|
|
215
|
+
the main plaintext and TLS listeners have their catch-all routes refused
|
|
216
|
+
(`nginx-default-server-conflict`).
|
|
217
|
+
* **Credentials are handled narrowly.** The only credentials that can be carried over are Kong
|
|
218
|
+
key-auth keys. They are written only with `--include-secrets`, and only where Ferrum's semantics
|
|
219
|
+
match: key length minimums and no shared keys. Kong HMAC JWT secrets are never written, not even
|
|
220
|
+
with `--include-secrets` (`kong-jwt-credential-withheld`, or `kong-jwt-multiple-credentials`).
|
|
221
|
+
Kong selects a JWT credential by its exact `key`. Ferrum's `jwt_auth` resolves the claim against
|
|
222
|
+
every alias of a consumer (username, id, custom_id) and accepts the consumer-wide secret, so
|
|
223
|
+
the one-to-one binding between a key and its secret cannot be reproduced. The `jwt_auth`
|
|
224
|
+
plugin, the consumer and its other credentials are still migrated, so JWT authentication fails
|
|
225
|
+
closed. A route that combines JWT with another authentication method is refused outright
|
|
226
|
+
(`kong-auth-composition`), because the other method's credentials could still migrate. Issue a new random secret per consumer in Ferrum, and keep the Kong credential until
|
|
227
|
+
clients have switched. No other source's credentials, and no other credential type, are portable.
|
|
228
|
+
Password hashes (Kong basic-auth, htpasswd, Traefik `basicAuth`) cannot be converted.
|
|
229
|
+
The matching auth plugin is emitted with no credentials, so nobody can authenticate until
|
|
230
|
+
you create new Ferrum credentials. Consumers with consumer-scoped plugins or consumer groups
|
|
231
|
+
are quarantined (credentials withheld). Kong input with `_transform: false` declares its
|
|
232
|
+
credentials as stored (pre-transformed) values, so its key-auth keys and JWT secrets are never
|
|
233
|
+
migrated. Static values for credential-like headers or query parameters (`Authorization`,
|
|
234
|
+
`X-Api-Key`, `Cookie`, `apikey=`...) are never copied: the route is refused instead.
|
|
235
|
+
* **Backend TLS verification is always on.** NGINX, Kong and Envoy often do not verify upstream
|
|
236
|
+
certificates by default, and Traefik/Istio can skip verification. Ferrum output always verifies
|
|
237
|
+
(`backend_tls_verify_server_cert: true`), and there is no opt-out. Requests to backends with
|
|
238
|
+
private CAs fail closed until you provide the CA. CA paths named by the source must exist on the
|
|
239
|
+
Ferrum host, because Ferrum checks them when it loads the config. A Kong service whose
|
|
240
|
+
`ca_certificates` restrict backend trust is refused rather than falling back to Ferrum's default
|
|
241
|
+
trust store.
|
|
242
|
+
* **Client-certificate trust is never merged.** Ferrum file mode has one frontend client CA bundle
|
|
243
|
+
per listener. It is configured only when every migrated mTLS scope used the same CA file. Different
|
|
244
|
+
CA bundles from separate servers/listeners are never concatenated: the affected routes are refused
|
|
245
|
+
with a `frontend-client-ca-scope` error, and you configure a separate Ferrum frontend per trust boundary.
|
|
246
|
+
Client-certificate requirements are never dropped as metadata. Istio `MUTUAL` servers with `subjectAltNames`,
|
|
247
|
+
`verifyCertificateSpki`, `verifyCertificateHash` or `caCrl` are refused (`istio-client-ca`).
|
|
248
|
+
When a plaintext and an HTTPS Istio server bind the same host, the shared routes keep the HTTPS
|
|
249
|
+
server's client CA or refusal. A `match.port` route in such a shared projection is refused.
|
|
250
|
+
When the two servers' host scopes overlap through different names (a wildcard and a host it
|
|
251
|
+
covers) and the HTTPS server is stricter or routes depend on `match.port`, both projections are
|
|
252
|
+
refused (`istio-shared-host-scope`). Separate Gateway bindings (other VirtualServices, or the same
|
|
253
|
+
one through another Gateway) are checked together on the final plan, refused projections included:
|
|
254
|
+
overlapping hosts served through different frontends (plaintext vs HTTPS, different client CA, or
|
|
255
|
+
a refused frontend) refuse every projection involved (`istio-frontend-scope-conflict`).
|
|
256
|
+
* **Traefik HTTPS needs one global handshake policy.** Traefik chooses TLS options during the handshake, by
|
|
257
|
+
SNI, for every path of an entryPoint at once, while Ferrum's HTTPS listener applies one policy to every
|
|
258
|
+
connection. HTTPS routes are therefore translated only when every TLS router uses the `default` TLS options
|
|
259
|
+
(or Traefik's built-in default) and the input defines no other TLS options. Traefik stores `default` globally,
|
|
260
|
+
without a provider qualifier, so a router uses it only when its `tls.options` is unset, empty or exactly
|
|
261
|
+
`default`. This is checked on every router of the input as written, before rule parsing or shadowing. Any other
|
|
262
|
+
TLS options definition (used or not, including a differently cased `Default`), or a reference to named,
|
|
263
|
+
provider-qualified (`default@file` included), malformed (such as `default@`), undefined or unreadable options,
|
|
264
|
+
refuses every HTTPS route whatever its hosts or paths (`traefik-tls-options-scope`). Per-route SNI selection is not reconstructed and no partial SNI
|
|
265
|
+
equivalence is claimed. Plaintext routes are unaffected, and refused HTTPS routes stay HTTPS-only placeholders.
|
|
266
|
+
Under that policy, `default` `clientAuth` becomes the client CA of every HTTPS route, or refuses them all
|
|
267
|
+
when it cannot be reproduced (several or inline CA files, unverified certificate types, malformed;
|
|
268
|
+
`traefik-client-auth`). Enabled `sniStrict` in `default` is an admission control Ferrum's listener cannot
|
|
269
|
+
reproduce, so every HTTPS route is refused (`traefik-sni-strict`).
|
|
270
|
+
* **Traefik typed fields must be spelled canonically.** Traefik's file provider matches the field names of its typed
|
|
271
|
+
configuration case-insensitively (`TLS` and `clientauth` act like `tls` and `clientAuth`), while this tool reads
|
|
272
|
+
only the canonical spelling Traefik documents. A typed field spelled in another letter case, or given more than
|
|
273
|
+
once in different letter case, rejects the whole input (exit 3, nothing written), with or without
|
|
274
|
+
`--assert-traefik-input-includes-effective-controls`. This covers the top-level sections, `http` and `tls`,
|
|
275
|
+
routers and their `tls` block, TLS options (`clientAuth` included), certificates and stores, services, load
|
|
276
|
+
balancers, weighted and mirroring services, `serversTransports`, the middleware type key and the configuration of
|
|
277
|
+
every middleware type the tool translates. The error names the canonical field path only. Names of routers,
|
|
278
|
+
services, middlewares, `serversTransports`, TLS options and stores are case-sensitive identifiers in Traefik and
|
|
279
|
+
are never folded: `Backend` and `backend` are two services, and `Default` is not the `default` TLS options.
|
|
280
|
+
* **Traefik child routers are never migrated as root routes.** Traefik v3.6 runs a router whose `parentRefs` names
|
|
281
|
+
parent routers inside those parents: after the parents' middlewares, and under the parents' entryPoint and TLS
|
|
282
|
+
constraints. The tool does not translate this inheritance, and serving the child as an independent route would drop
|
|
283
|
+
the parents' controls. A router with `parentRefs` absent or exactly an empty list (`[]`) is an ordinary root router.
|
|
284
|
+
Any other value on any router of the input (a nonempty list, an explicit null, or any other shape) rejects the
|
|
285
|
+
whole input (exit 3, nothing written), with or without `--assert-traefik-input-includes-effective-controls`. The
|
|
286
|
+
error names the canonical field path and a router count only. Other spellings of `parentRefs` are rejected by the
|
|
287
|
+
canonical spelling check above.
|
|
288
|
+
* **Each route is served only on the protocols the source used.** Ferrum serves every route on each
|
|
289
|
+
listener its profile opens, whatever the host names, so host names that look disjoint, unknown hosts
|
|
290
|
+
or a missing TLS setting prove nothing (Ferrum opens HTTPS on its default port as soon as a frontend
|
|
291
|
+
certificate is configured). Every translator records which main frontends (plaintext, HTTPS) served
|
|
292
|
+
each route, and the output opens only protocols that every live route was served on:
|
|
293
|
+
both listeners when every live route was served on both. When a live route was plaintext-only,
|
|
294
|
+
HTTPS-only routes are refused and HTTPS is disabled explicitly (`FERRUM_PROXY_HTTPS_PORT=0`, no
|
|
295
|
+
frontend TLS settings; `frontend-https-disabled`). With `--tls-only` or HTTPS-only sources, the
|
|
296
|
+
plaintext listener is disabled (`FERRUM_PROXY_HTTP_PORT=0`) and plaintext-only routes are refused. This
|
|
297
|
+
holds even when the source's HTTPS listener was not migrated (Envoy RDS, skipped listeners). A route
|
|
298
|
+
without that information refuses the whole plan (`frontend-protocol-unknown`). The rendered `ferrum.conf`
|
|
299
|
+
is checked against the decision before anything is written.
|
|
300
|
+
* **Traefik controls outside the input are never assumed.** The file provider input is dynamic configuration
|
|
301
|
+
only. The entryPoints a router is attached to can add TLS, client certificate options, prepended middlewares,
|
|
302
|
+
redirections, forwarded-header trust and bind restrictions; another provider can define the `default` TLS
|
|
303
|
+
options, map the same hosts to other TLS options, or add competing routers. So a router without a `tls` block is
|
|
304
|
+
not proven plaintext, and one with a `tls` block is not proven free of other controls. By default every Traefik
|
|
305
|
+
route that would forward traffic is refused (503 placeholder, error `traefik-controls-unverified`, with the
|
|
306
|
+
operator checklist). Only `--assert-traefik-input-includes-effective-controls`, given after you verified that the
|
|
307
|
+
input includes every effective control within the converted scope (or that none is added), lets them forward;
|
|
308
|
+
the tool records it as your unverified statement and still applies or refuses every control the input states.
|
|
309
|
+
* **Restricted listeners stay restricted.** NGINX `listen`, Envoy listener and Istio `Server.bind`
|
|
310
|
+
addresses are reproduced only when every server shares one address (`FERRUM_PROXY_BIND_ADDRESS`).
|
|
311
|
+
Otherwise the address-restricted servers (and Unix sockets) are skipped, never exposed on
|
|
312
|
+
Ferrum's shared address.
|
|
313
|
+
* **Extra listeners are not migrated.** Ferrum's router selects host and path before it compares
|
|
314
|
+
ports, and port-agnostic routes serve every HTTP listener, so a route scoped to an extra plaintext
|
|
315
|
+
port (`listen_port`) cannot be kept apart from the main routes. Servers, Envoy listeners and Istio
|
|
316
|
+
Gateway servers that only listen on another plaintext port get no proxy at all
|
|
317
|
+
(`extra-listener-refused`), so Ferrum does not serve that port. The output never contains
|
|
318
|
+
`listen_port`. A server that also listens on a main port is served on the main ports only.
|
|
319
|
+
* **Auth is not silently skipped.** Auth plugins, middlewares, directives and HTTP filters the
|
|
320
|
+
tool cannot translate refuse their routes (see above). A Kong route whose effective policy (global,
|
|
321
|
+
service and route plugins together) combines several authentication methods is refused
|
|
322
|
+
(`kong-auth-composition`): Kong's composition and the consumer it selects are not proven
|
|
323
|
+
equivalent in Ferrum, even when one method's credentials are withheld. One method per route is
|
|
324
|
+
migrated as before. In addition, an Envoy route or virtual host whose
|
|
325
|
+
`typed_per_filter_config` could enable or change an HTTP filter is refused. An Istio
|
|
326
|
+
`AuthorizationPolicy`/`RequestAuthentication`/`EnvoyFilter`/`WasmPlugin` refuses a Gateway's
|
|
327
|
+
routes unless it provably does not apply to the gateway pods, whatever namespace it lives in
|
|
328
|
+
(neither the gateway pods' namespace nor their labels are part of the input). Only a `targetRef`
|
|
329
|
+
to another resource, or a selector that pins one of the Gateway selector's label keys to another
|
|
330
|
+
value, counts as proof. Extra label keys do not, and namespace-wide policies (no selector) always
|
|
331
|
+
refuse.
|
|
332
|
+
* **No secrets in diagnostics.** Parser errors keep positions but withhold quoted spans.
|
|
333
|
+
Reports name resources and counts, never values. PEM blocks, vault references and Kubernetes
|
|
334
|
+
Secrets are never read into output.
|
|
335
|
+
* **Bounded, offline input handling.** Inputs are read from one regular file with size, node,
|
|
336
|
+
depth, alias, document, token and route ceilings. YAML duplicate keys, merge keys and unsafe
|
|
337
|
+
tags are rejected, and multi-document input is accepted only for Istio. Includes are not
|
|
338
|
+
followed. There is no network, database or subprocess use.
|
|
339
|
+
|
|
340
|
+
See [docs/design.md](https://github.com/ferrum-edge/ferrum-migration/blob/main/docs/design.md) for details and [SECURITY.md](https://github.com/ferrum-edge/ferrum-migration/blob/main/SECURITY.md) for reporting issues.
|
|
341
|
+
|
|
342
|
+
## Limitations (read before serving any traffic)
|
|
343
|
+
|
|
344
|
+
* This is a starting point for trying Ferrum, not a production-readiness check. **Review every
|
|
345
|
+
error in the report** before serving real traffic.
|
|
346
|
+
* Behavior has been checked only with original synthetic fixtures: unit tests, `ferrum-edge
|
|
347
|
+
validate` admission, and loopback runtime acceptance against Ferrum Edge v1.0.1. It has not
|
|
348
|
+
been validated against real deployments, so equivalence with your source configuration is not
|
|
349
|
+
established.
|
|
350
|
+
* Only HTTP(S) reverse proxying is migrated. TCP/UDP/TLS-passthrough, mail, static file serving,
|
|
351
|
+
dynamic xDS and Istio subsets (which need pod labels) are reported, not translated. Kubernetes service
|
|
352
|
+
discovery is used only with `--kubernetes-service-discovery` (Istio).
|
|
353
|
+
* Ferrum file mode serves one default frontend certificate. With several source certificates
|
|
354
|
+
you must pick one, or use a SAN certificate.
|
|
355
|
+
* Rate limits keep the average rate but not burst/delay semantics. Kong `cluster`/`redis`
|
|
356
|
+
policies become per-node limits unless you configure Ferrum's Redis sync.
|
|
357
|
+
* Live databases are never migrated. Export Kong with decK first. For Ferrum database/cp
|
|
358
|
+
mode, validate in file mode, then import through Ferrum's Admin API yourself. Convert the
|
|
359
|
+
resources to JSON and drop the file-mode-only `resource_counts` key first. Then choose:
|
|
360
|
+
`POST /batch` is an **additive**, all-or-nothing import next to existing configuration
|
|
361
|
+
(1 MiB request limit). `POST /restore?confirm=true` **replaces** the namespace's whole
|
|
362
|
+
configuration, so take `GET /backup` first. Neither import path is runtime-tested by this
|
|
363
|
+
project.
|
|
364
|
+
* Istio output is an ingress projection only; it makes no claim about mesh behavior.
|
|
365
|
+
`*.svc.cluster.local` destinations are emitted as plain DNS names that must resolve from the
|
|
366
|
+
Ferrum host, unless `--kubernetes-service-discovery` is given (see Options).
|
|
367
|
+
* Host-level refusals (regex `server_name`, unrepresentable domains) only poison catch-all
|
|
368
|
+
routes; the residual cross-scope risk is described in docs/design.md.
|
|
369
|
+
* Every Ferrum behavior the mappings rely on is cited to Ferrum Edge source in
|
|
370
|
+
[docs/mappings.md](https://github.com/ferrum-edge/ferrum-migration/blob/main/docs/mappings.md)
|
|
371
|
+
("Resolved from Ferrum Edge source" and "Forwarded path composition").
|
|
372
|
+
|
|
373
|
+
## Development
|
|
374
|
+
|
|
375
|
+
```bash
|
|
376
|
+
python -m pip install -r requirements-ci.txt
|
|
377
|
+
python -m unittest discover -s tests -v
|
|
378
|
+
python -m unittest discover -s acceptance/tests -v # runtime harness self-tests (stdlib only)
|
|
379
|
+
# optional, against Ferrum itself:
|
|
380
|
+
FERRUM_EDGE_SRC=../refs/ferrum-edge python -m unittest discover -s tests -p 'test_ferrum_reference.py' -v
|
|
381
|
+
FERRUM_EDGE_BIN=/path/to/ferrum-edge python -m unittest discover -s tests -p 'test_ferrum_reference.py' -v
|
|
382
|
+
# runtime acceptance on loopback against a checksum-verified ferrum-edge v1.0.1:
|
|
383
|
+
python acceptance/run.py --ferrum-bin /path/to/ferrum-edge --converter-env PYTHONPATH="$PWD/src"
|
|
384
|
+
```
|
|
385
|
+
|
|
386
|
+
The binary admission test generates a throwaway synthetic CA with `openssl` for fixtures that
|
|
387
|
+
name operator-supplied backend CA files. See [acceptance/README.md](https://github.com/ferrum-edge/ferrum-migration/blob/main/acceptance/README.md) for
|
|
388
|
+
the runtime harness. CI runs it on Linux against the pinned published v1.0.1 binary.
|
|
389
|
+
|
|
390
|
+
Test fixtures under `tests/fixtures/` are original synthetic configurations; every credential
|
|
391
|
+
in them is a fake test string. See [CONTRIBUTING.md](https://github.com/ferrum-edge/ferrum-migration/blob/main/CONTRIBUTING.md).
|
|
392
|
+
|
|
393
|
+
## Status
|
|
394
|
+
|
|
395
|
+
**Stable (`1.x`).** Ferrum Migration is a stable `1.x` release in the Ferrum 1.0 product family
|
|
396
|
+
(Ferrum Edge and its companion tools), following
|
|
397
|
+
[Semantic Versioning 2.0.0](https://semver.org/spec/v2.0.0.html). Output is a starting point for
|
|
398
|
+
review and has been validated with synthetic fixtures rather than live deployments (see
|
|
399
|
+
Limitations).
|
|
400
|
+
|
|
401
|
+
* **`1.x` compatibility contract.** CLI subcommands, flags, exit codes `0` through `5`, output
|
|
402
|
+
filenames, and `migration-report.json` (`schema_version: "1"`) follow the additive stability
|
|
403
|
+
contract documented in
|
|
404
|
+
[docs/compatibility.md](https://github.com/ferrum-edge/ferrum-migration/blob/main/docs/compatibility.md)
|
|
405
|
+
and recorded in the
|
|
406
|
+
[changelog](https://github.com/ferrum-edge/ferrum-migration/blob/main/CHANGELOG.md). Fail-closed
|
|
407
|
+
safety fixes are never considered breaking changes.
|
|
408
|
+
* **One target Edge release per version.** The output of this version targets Ferrum Edge
|
|
409
|
+
**v1.0.1** (`a2974b9f1594de32fec3722612f899946486a8ab`). CI validates it against that
|
|
410
|
+
exact release binary, verified against the release's checksum and a digest pinned in CI:
|
|
411
|
+
every fixture's output must pass `ferrum-edge validate`, and the loopback runtime acceptance
|
|
412
|
+
suite serves it with that binary. Other Edge versions are not validated; output may use
|
|
413
|
+
settings or fields an older Edge lacks, and a newer Edge may behave differently. Two weekly,
|
|
414
|
+
non-gating CI jobs detect drift early: one runs the same checks against Edge's newest
|
|
415
|
+
published release, the other against the newest signed Edge `main` image, where it also
|
|
416
|
+
checks the keys in every test fixture's output (one fixture set per source, including sticky
|
|
417
|
+
cookie hashing) against Edge `main`'s source and files a tracking issue labelled
|
|
418
|
+
`edge-main-drift` when anything fails. These key checks are fixture-based: they cover what
|
|
419
|
+
the fixtures exercise.
|
|
420
|
+
* `ferrum-migrate --version` and both reports name the tool version and the Ferrum Edge
|
|
421
|
+
commit the mappings were verified against.
|
|
422
|
+
|
|
423
|
+
Releases are `vX.Y.Z` Git tags with GitHub releases; see
|
|
424
|
+
[docs/releasing.md](https://github.com/ferrum-edge/ferrum-migration/blob/main/docs/releasing.md).
|
|
425
|
+
|
|
426
|
+
## License
|
|
427
|
+
|
|
428
|
+
Ferrum Migration is licensed under the [PolyForm Noncommercial License 1.0.0](https://github.com/ferrum-edge/ferrum-migration/blob/main/LICENSE).
|
|
429
|
+
For commercial use, see [LICENSE-COMMERCIAL.md](https://github.com/ferrum-edge/ferrum-migration/blob/main/LICENSE-COMMERCIAL.md).
|
|
430
|
+
Ferrum Edge is a separate product governed by its own license; the terms here cover
|
|
431
|
+
Ferrum Migration only.
|
|
432
|
+
|
|
433
|
+
Kong, NGINX, Traefik, Envoy and Istio are trademarks of their respective owners. This
|
|
434
|
+
project is not affiliated with them and contains no code from them.
|