tt
tt copied to clipboard
cluster: publish a new instance configuration
@TarantoolBot document
Title: tt cluster publish can publish a new instance configuration
This patchs adds an ability to publish a new instance configuration with tt cluster publish.
Prior this patch this command returns an error if the instance is not found in the config.
Now, to create a new instance configuration, a replicaset name with --replicaset can be specified,
and, if it's not enough, a group name with --group.
For example:
$ tt cluster show http://localhost:2379/foo
/foo/config/all
credentials:
users:
guest:
roles:
- super
groups:
group-001:
replicasets:
replicaset-001:
instances:
instance-001:
iproto:
listen:
- uri: localhost:3301
instance-002:
iproto:
listen: {}
$ tt cluster publish http://localhost:2379/foo?name=instance-003 inst.yml
⨯ failed to create an instance "instance-003" configuration: replicaset name is not specified
$ tt cluster publish --replicaset replicaset-001 http://localhost:2379/foo?name=instance-003 inst.yml
$ tt cluster show http://localhost:2379/foo
credentials:
users:
guest:
roles:
- super
groups:
group-001:
replicasets:
replicaset-001:
instances:
instance-001:
iproto:
listen:
- uri: localhost:3301
instance-002:
iproto:
listen: {}
instance-003:
database:
mode: rw
Part of https://github.com/tarantool/tt/issues/316
Please, add a message for TarantoolBot with the update.
Please, add a message for TarantoolBot with the update.
Thank you! Added.