feat(rust): add binary to compile custom branding command binaries #8744
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.
Binary to compile branded
ockam
versionsThere is a new script at
ockam_command/src/bin/brand.rs
that can be run to compile theockam
binary with some configurable options.The script needs a configuration that can be either passed inline, or as a path to a file. The configuration is a yaml with he following format:
We can run the script as follows:
cargo run --bin brand ./config.yaml
Custom branding
The
ockam_command
crate now will use the compile-time env varsOCKAM_COMMAND_BIN_NAME
andOCKAM_COMMAND_BRAND_NAME
to replace theockam
andOckam
references in:We can also customize:
OCKAM_HOME
to be used, which will default to$HOME/.$BIN_NAME
ockam
likeockam-relay
orockam-role
. Should we change this prefix?source location
leaks the crates names)ockam enroll
has a lot of ockam related output (links to docs, links to our github, the ascii header), but this command should only be used by admins anywayNew Cargo features in ockam_command
I've removed the
orchestrator
feature, which wasn't being used consistently, and I've added two new features:admin_commands
: enroll, create/delete spaces and projects, authority, sidecar, ...advanced_commands
: experimental or not widely used commands (tcp-listener/connection, flow control, secure-channel, ...)So, by default, we will include the core commands that are used to create nodes, portals, relays, policies, ...