-
Notifications
You must be signed in to change notification settings - Fork 50
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
Setting Root Agent #38
Comments
I think I'll add some logic to atomic-lib for reading and writing configuration, which will be used both in atomic-cli and atomic-server. Some of the configuration (at the very least the private key for the agent, and its URL) should be accessible for the CLI. |
Some design considerations.
|
Upon initialization, the server checks the default config file location. If there is a file there, it reads it and checks if the agent exists. The server panics when the agent is not available. If there is no config file, a new agent is created and the config file is saved. The CLI checks that same config file if the user wants to write data (e.g. This mostly works, but it's far from ideal.
So where do we go from here? Let's explore some more considerations:
|
Any change to data needs to be signed by some Agent. As Agents themselves are just resources, they need to be created by some other Agent. I'll call the very first Agent the Root Agent. The Root Agent is a user that has the highest of rights - e.g. create admins, destroy everything. So how should a Root Agent be created? Some options:
atomic-server
for creating Agents, e.g.atomic-server agent new
. A bit more of a hassle, but I'm very likely to need more CLI tooling in server at some point anyhow..env
which generates the root Agent.~/.config/atomic
, and check for a config file. If it does not exist, create one with some defaults and a newly created author.I think multiple of these should be possible.
Relates to client server interaction #6 and authentication #13. Also to atomic-data authorization.
The text was updated successfully, but these errors were encountered: