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

Agents arent provided API key by default #39

Closed
0xtavian opened this issue Nov 28, 2018 · 3 comments
Closed

Agents arent provided API key by default #39

0xtavian opened this issue Nov 28, 2018 · 3 comments
Assignees

Comments

@0xtavian
Copy link

The ansible workload should add the APIs keys to every agent. This prevents having to manually login to all agents to add them yourself.

@derpadoo
Copy link
Contributor

@0xtavian Let me know how it works for you.

  1. Update the branch
git clone https://github.com/rackerlabs/scantron.git
git checkout issue-39-prefill-agent-api-key
  1. Switch utilize_static_api_token_across_agents to True in scantron/ansible-playbooks/group_vars/all
  2. Run the master playbook first (I need to update README info), so the API key can be generated. It dumps it to group_vars/static_api_key, so make sure that file is created.
  3. Run the agent playbook, which fills an agent_config.json.j2 template with the API key found in group_vars/static_api_key.

@derpadoo derpadoo self-assigned this Dec 12, 2018
@derpadoo
Copy link
Contributor

Added logic to randomize the user_agent in agent_config.json to avoid scan agent name collisions. So now, you'd never need to log into the agents to update anything. You'd still have to add the user on Master though since that's how scheduled scans are filtered. Does that seem reasonable?

@derpadoo
Copy link
Contributor

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

No branches or pull requests

2 participants