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

environment when running docker... #3175

Open
jseifeddine opened this issue May 26, 2024 · 1 comment
Open

environment when running docker... #3175

jseifeddine opened this issue May 26, 2024 · 1 comment

Comments

@jseifeddine
Copy link

jseifeddine commented May 26, 2024

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....

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 !!!

@jseifeddine
Copy link
Author

jseifeddine commented May 28, 2024

For those having issues with git... i made a forceful gitlab-pusher, who you can totally offload the git pushing to

https://github.com/jseifeddine/gitlab-pusher

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

1 participant