nats-io/nsc

nsc edit is checking if JetStream is available

sty-holdings opened this issue · 4 comments

When you enter the following command:
nsc edit account SYS -k OD.....2Y --tag A
You will get the following error:
Error: jetstream not available for system account
NSC-1

I observe the same error:

root@instance: nsc edit account -n SYS --tag "System account, used by nsc push" --config-dir $HOME/server_config   --data-dir $HOME/server_data   --keystore-dir $HOME/server_keys
Error: jetstream not available for system account

nsc doesn't check for sys account, it is simply reporting an error received from the nats-server.
@kimjarvis can you include your server config please?

root@instance:/# cat $HOME/server.config
include resolver.conf
http_port: 8222
log_file: /root/server.log
debug: True
trace: True
jetstream: enabled
root@instance:/# nsc edit account -n SYS --tag "System account, used by nsc push" -H $HOME/O
Error: jetstream not available for system account

@sty-holdings @kimjarvis finally tracked this - indeed this was nsc - however the error was due to default edits having unlimited values for JetStream - system account cannot have these, so values for all the jetstream options needed to be specified with 0. I added a --js-disable flag, which sets all the necessary flags to 0, and updated the error message to direct you to rerun the command with the --js-disable flag.