Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pre-start configuration using vctl #177

Open
craig8 opened this issue Jun 23, 2023 · 3 comments
Open

Pre-start configuration using vctl #177

craig8 opened this issue Jun 23, 2023 · 3 comments
Labels
enhancement New feature or request

Comments

@craig8
Copy link
Contributor

craig8 commented Jun 23, 2023

Is your feature request related to a problem? Please describe.
Configuration in the new modular with messagebus, auth and dynamically loaded classes could be a barrier for adoption. This feature will address that.

Describe the solution you'd like
Create a vctl system subparser for configuration of the messagebus and the local/remote client connections. Looking back at the original guidlines for modular we see.

image

Proposed commands

  • # Allow the user to specify the messagebus pypi packages and discover the correct MessageBusInterface 
    # from the installed pypi packages.  The with auth would be able automatically included just like our current 
    # platform is "authenticated by default" but allows a --without-auth to turn the whole auth system off.  
    
    vctl system messagebus volttron-lib-zmq  --with-auth   --without-auth
    vctl system messagebus volttron-lib-xxmq --with-auth
    
  •  # With autocomplete using click/typer etc we can then discover the messagebus, auth, and service configurations 
     # available for the local sytem
    
     vctl system status
     vctl system service servicename --list  # Shows the configuration for servicename
     vctl system service my.auth.system param value   # Sets the name/value pairs
     vctl system service my.auth.system yamlfile # More advanced complete wipe of the configuration for my.auth.system
    
    
  • Allow an agent to run in the foreground against a host configuration.
    vctl run agent host
    
  • # Allow the system to start up i.e. run volttron in background etc
    vctl system start / stop
    
@craig8 craig8 added the enhancement New feature or request label Jun 23, 2023
@craig8
Copy link
Contributor Author

craig8 commented Jun 23, 2023

After talking with @shwethanidd the ultimate goal of the command line options is to handle the following configuration files.

~/.volttron/config
[volttron]
instance-name = WE40572
address = tcp://127.0.0.1:22916
agent-isolation-mode = False
message-bus = volttron.messagebus.zmq

auth = True/False

And service_config.yml which I haven't copied an example of.

.volttron/service_config.yml

@craig8
Copy link
Contributor Author

craig8 commented Jun 23, 2023

Original with all the bells

[volttron]
instance-name = WE40572
address = tcp://127.0.0.1:22916
agent-isolation-mode = False
message-bus = volttron.messagebus.zmq.ZmqMessageBus
agent-core = volttron.messagebus.zmq.ZmqCore
authentication-class = volttron.messagebus.zmq.ZmqAuthentication
authorization-class = volttron.messagebus.zmq.ZmqAuthorization
auth-service = volttron.services.auth
service-config = /home/d3m614/.volttron_crap/service_config.yml

@craig8
Copy link
Contributor Author

craig8 commented Jun 23, 2023

Example of zmq

python3.10 -m venv .venv

source .venv/bin/activate

# Assume that Authentication and Authorization are implement within a dependency of volttron-zmq
pip install volttron-zmq volttron-lib-auth

volttron -vv

Example mqtt

python3.10 -m venv .venv

source .venv/bin/activate

pip install volttron-mqtt spiffy volttron-spiffy volttron-lib-auth volttron-tls

volttron -vv

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant