Commit graph

180 commits

Author SHA1 Message Date
ramnes
bab2d26ad0 Setup tests 2020-02-02 20:24:01 +01:00
ThomasADavis
2280169cd9 Use choices api (#107)
* Ask netbox for choices using the API
2020-01-28 11:18:56 +01:00
ThomasADavis
405cce3995 Gets the right chassis serial number (#104) 2020-01-25 12:03:30 +01:00
Solvik
6497261708
better error handling when DeviceRole or DeviceType don't exist (#91) 2019-10-23 12:14:50 +02:00
gardar
8ef94272a1 Update inventory.py (#89)
Replace all special characters in slug with a dash rather than just spaces and dots
2019-10-21 14:32:22 +02:00
Solvik
a1297813ef
fix rack comparison while updating location (#84) 2019-09-12 17:47:41 +02:00
Solvik
06328e745c
Revert "fix rack comparison while updating location (#82)" (#83)
This reverts commit e9ec69bc3b.
2019-09-12 17:43:39 +02:00
Solvik
e9ec69bc3b
fix rack comparison while updating location (#82) 2019-09-12 12:03:13 +02:00
Solvik
5f851ec619
add config to set hostname command (#81) 2019-09-12 11:15:12 +02:00
Solvik
93af39e780
do not initialize RAID class when scanning for binary raid (to be reworked obviously) (#80) 2019-09-12 11:12:32 +02:00
Solvik
9f7f29c190
fix rack association (#79) 2019-09-11 17:35:27 +02:00
Solvik
458d1f83c2
fix {'part_id': ['This field may not be null.']} error (#78) 2019-09-11 14:22:32 +02:00
Solvik
8c25ab483d
add more vendors (#76) 2019-09-11 14:22:07 +02:00
Solvik
a0106675e0
handle more PSU dmidecode format (#75) 2019-09-11 10:37:31 +02:00
Solvik
4303312b17
fix PSU power parsing (#74) 2019-09-10 14:48:16 +02:00
Solvik
93c6444105
more strip from shitty dmidecode (#73) 2019-09-10 14:46:04 +02:00
Solvik
5c1e15f9e6
strip dmidecode data, because vendor dont (#72) 2019-09-10 13:39:22 +02:00
Solvik
0cf2d4fa90
fix raid creation on server's registration (#71) 2019-09-10 11:51:05 +02:00
Solvik
d402b5620c
add omreport RAID support (#69) 2019-09-10 11:44:23 +02:00
Solvik
ba8f58180e
make InventoryItem's name attribute <50 char for memory DIMM (#67) 2019-09-09 16:52:25 +02:00
Solvik
f68fed18b4
handle multiple vlans in lldp (#66) 2019-09-09 15:32:14 +02:00
Solvik
fb68907efd
parse lldp only if configuration says so (#63) 2019-09-09 12:25:11 +02:00
ThomasADavis
b7b22ae316 use lshw for inventory (#58)
* Use lshw for inventory
* Add motherboard to inventory
* Handle non raid devices
* Handle nvme drives
2019-09-05 15:13:36 +02:00
Solvik
8d0168acb5
Add power supply support (#56) 2019-09-05 13:47:10 +02:00
Solvik
1c44ab36fb
fix inventory typo (#59) 2019-09-04 11:18:44 +02:00
Solvik
d12ac49d50
new config system (#53) 2019-09-03 13:16:37 +02:00
Solvik
c5707e8413
do not make netbox call if lldp doesnt return switch ip and interface (#54) 2019-09-03 11:57:17 +02:00
Solvik
197a8babaf
Handle anycast IP (#51) 2019-08-30 11:06:16 +02:00
ThomasADavis
6ec08e8669 Several minor fixes (#47)
Several minor fixes:
- raid_array check should return an empty array, not NoneType
- not all systems will have IPv6 defined, handle this case
- Vendor Supermicro was incomplete.
2019-08-29 17:33:27 +02:00
Solvik
0faee59bde
Supermicro server can guess their slot via the config file (#50) 2019-08-29 16:13:04 +02:00
Solvik
136a356cec
Fix QCT vendor class (#48) 2019-08-28 12:06:45 +02:00
Solvik
de3c59a675
Local inventory (#16)
- Create and update CPU
- Create and update Memory
- Create and update RAID Cards (HP and Storcli)
- Create and update Physical disks
2019-08-26 16:54:48 +02:00
Solvik
1902b24c13
add QCT as vendor (#45) 2019-08-26 16:39:36 +02:00
Solvik
0e8b470062
Add Supermicro as a vendor (#44) 2019-08-26 15:38:44 +02:00
Solvik
8de682f46d
add ipv6 addresses (#43) 2019-08-26 14:02:07 +02:00
Solvik
33c55340b7
Add LLDP auto cabling (#41) 2019-08-26 11:05:41 +02:00
Solvik
5826966ea4
support HPE BL460c Gen10 and its stupid dmidecode info (#39) 2019-08-21 16:17:01 +02:00
Solvik Blum
fddac3c5e5
typo in dmidecode for dell 2019-08-20 13:50:38 +02:00
Solvik
770a97bc57
create server/rack/chassis with Rack location if found (#34) 2019-08-14 11:17:24 +02:00
Solvik
955579df0d
make sure to update IPMI interface when mac changed (#32) 2019-08-12 17:21:46 +02:00
Solvik
980f14236f
Fix late comments (#29)
* more fixes
* add external binary requirements
* better error handling for bonding
2019-08-09 13:26:51 +02:00
Solvik
2988a8bd6a
Rework all network part (#21)
* rework network part by ignoring devices and ip from config file

* update config file

* associate slave device to bond device with Netbox LAG

* update README

* make sure every interface attribute is ok

* some fixes after  test

* tox

* add ipmi feature

* fix bug in LAG

* ipmi class

* update README

* network update

* delete print

* update README
2019-08-09 12:08:11 +02:00
Solvik Blum
9519a43277
fixes 2019-08-08 14:46:06 +02:00
Solvik Blum
048fa22b1e
fix blade slot 2019-08-08 14:37:02 +02:00
Solvik
a7d766a5fb
Merge pull request #19 from Solvik/feature/python3.5
be python3.4 compatible
2019-08-08 10:43:09 +02:00
Solvik Blum
896a011173
simpler way to be python3.4 compatibble 2019-08-08 10:42:43 +02:00
Solvik Blum
14e061159d
ignore unused statement 2019-08-07 15:37:14 +02:00
Solvik Blum
b60860e0f5
fix bug while testing server creation 2019-08-07 15:36:47 +02:00
Solvik Blum
d7af66b325
fix bug while testing debug with an interface not existing while updating 2019-08-07 15:36:24 +02:00
Solvik Blum
49731644fd
fix bug while testing debug 2019-08-07 15:36:03 +02:00
Solvik Blum
f991ac85f7
call logging.py for setup 2019-08-07 15:12:38 +02:00
Solvik Blum
e8a9d318cc
simpler logging, log_level from config file 2019-08-07 10:32:23 +02:00
Solvik Blum
a22b648b8a
be python3.5 compatible 2019-08-06 18:15:08 +02:00
Solvik Blum
cc08300fee
add some logging 2019-08-06 18:11:26 +02:00
Solvik Blum
c5226b288d
hotfix - assign interface to ip while updating server 2019-08-05 17:41:03 +02:00
Solvik
18e29638e7
Merge branch 'master' into feature/rack_awareness 2019-08-05 17:07:36 +02:00
Solvik Blum
69a9327b18
flake8 fixes 2019-08-05 16:55:37 +02:00
Solvik Blum
bea1bf8614
flake8 fixes 2019-08-05 16:55:22 +02:00
Solvik Blum
165f911631
handle network update 2019-08-05 16:51:01 +02:00
Solvik Blum
e80d8b941c
wip - update in progress, working for blades/hostname 2019-08-05 16:03:35 +02:00
Solvik Blum
42b81a1f78
should have used git mv 2019-08-05 12:03:06 +02:00
Solvik Blum
cd97fe4d3a
wip 2019-08-05 12:02:42 +02:00
Solvik Blum
acbb767e22
rack awareness 2019-08-05 11:54:06 +02:00
Solvik Blum
0edc88823a
flake8 2019-08-04 23:42:08 +02:00
Solvik Blum
0c5ca003a6
handle ethtool not installed and add known limitations to README 2019-08-04 23:24:51 +02:00
Solvik Blum
15faf59182
better ethool and device type guessing 2019-08-04 21:48:06 +02:00
Solvik
4ddbb89c18
Merge branch 'master' into feature/network 2019-08-04 20:27:58 +02:00
Solvik Blum
9f0db28ed8
use first capture group in regex 2019-08-04 19:51:36 +02:00
Solvik Blum
d90eac3fe6
no more upper() and use slug for dc search 2019-08-04 19:33:09 +02:00
Solvik Blum
f2195cf9e6
tox fix 2019-08-04 19:32:52 +02:00
Solvik Blum
87939d3e35
check for get() function 2019-08-04 19:18:11 +02:00
Solvik Blum
d5673d4992
WIP - create netbox interfaces with IP 2019-08-04 15:14:36 +02:00
Solvik Blum
1063ec63e0
WIP - handle network 2019-08-04 14:37:51 +02:00
Solvik Blum
0e0ceb7811
datacenter awareness - a bit of a docstring 2019-08-04 09:55:10 +02:00
Solvik Blum
6b24b4b000
add support for a datacenter driver in a separate file 2019-08-04 09:48:42 +02:00
Solvik Blum
8b8cd68ff2
add datacenter location awareness with pseudo-driver (cmd and file) 2019-08-04 01:21:20 +02:00
Solvik
396c4b5d10 Project cleanup (#6)
* add requirements.txt

* Create LICENSE

* add test directory

* code cleanup

* flake8 fixes and code cleanup

* setup.py and tox.ini

* more fixes
2019-08-04 00:00:22 +02:00
Solvik Blum
ab4ea42466 pizza box (server) netbox creation 2019-08-03 15:57:06 +02:00
Solvik Blum
8960df61dc * new dmidecode code
* move netbox creation server to ServerBase class
* HP blades support
2019-08-03 15:46:21 +02:00
Solvik Blum
94e0437427 wip - should change the name of manufacturers, maybe other classes than Server etc 2019-08-02 18:39:05 +02:00