oxidized
oxidized copied to clipboard
environment when running docker...
Hi Team,
just want to say fantastic work to all involved in this project, we've been using oxidized and haven't had any operational issues.
Keep up the great work!!
Just on the question of having variables when running in docker - unfortunately, they aren't available in the execution of the hooks for example, but even in the config YAML itself,
anyway, to fix the config bit, i made some minor changes....
https://github.com/ytti/oxidized/compare/master...j-oss2023:oxidized:master
So now i can do this:
docker
services:
oxidized:
restart: always
image: oxidized/oxidized:0.30.1
environment:
CONFIG_RELOAD_INTERVAL: 600
NETBOX_API_TOKEN: ${NETBOX_API_TOKEN}
NETBOX_URL: ${NETBOX_URL}
SSH_USERNAME: ${SSH_USERNAME}
SSH_PASSWORD: ${SSH_PASSWORD}
oxidized
---
username: <%= ENV['SSH_USERNAME'] %>
password: <%= ENV['SSH_PASSWORD'] %>
...
source:
default: http
http:
url: <%= ENV['NETBOX_URL'] %>/api/dcim/devices/?tag=oxidized
scheme: https
hosts_location: results
delimiter: !ruby/regexp /:/
read_timeout: 120
user: false
secure: true
map:
name: name
model: platform.slug
group: platform.slug
ip: name
headers:
Authorization: Token <%= ENV['NETBOX_API_TOKEN'] %>
...
Check it out - I'm in a mad rush with other projects at the moment, but i'm happy to clean that up or adjust and contribute...
I should say, I am no ruby developer (at all) - in fact this was with the help of my good friend ChatGPT
Thanks !!!