mirror of
https://github.com/netbox-community/Device-Type-Library-Import.git
synced 2025-02-08 05:29:33 +01:00
This commit is contained in:
parent
98857fc649
commit
362056e552
12
README.md
12
README.md
@ -13,7 +13,7 @@ This script will clone a copy of the `netbox-community/devicetype-library` repos
|
||||
1. This script is written in Python, so lets setup a virtual environment.
|
||||
|
||||
```
|
||||
git clone https://github.com/minitriga/Netbox-Device-Type-Library-Import
|
||||
git clone https://github.com/netbox-community/Device-Type-Library-Import.git
|
||||
cd Netbox-Device-Type-Library-Import
|
||||
python3 -m venv venv
|
||||
source venv/bin/activate
|
||||
@ -58,7 +58,7 @@ To import only device by APC, for example:
|
||||
./nb-dt-import.py --vendors apc
|
||||
```
|
||||
|
||||
`--vendors` can also accept a comma separated list of vendors if you want to import multiple.
|
||||
`--vendors` can also accept a comma separated list of vendors if you want to import multiple.
|
||||
|
||||
```
|
||||
./nb-dt-import.py --vendors apc,juniper
|
||||
@ -66,9 +66,9 @@ To import only device by APC, for example:
|
||||
|
||||
## Docker build
|
||||
|
||||
It's possible to use this project as a docker container.
|
||||
It's possible to use this project as a docker container.
|
||||
|
||||
To build :
|
||||
To build :
|
||||
|
||||
```
|
||||
docker build -t netbox-devicetype-import-library .
|
||||
@ -80,7 +80,7 @@ Alternatively you can pull a pre-built image from Github Container Registry (ghc
|
||||
docker pull ghcr.io/minitriga/netbox-device-type-library-import
|
||||
```
|
||||
|
||||
The container supports the following env var as configuration :
|
||||
The container supports the following env var as configuration :
|
||||
|
||||
- `REPO_URL`, the repo to look for device types (defaults to _https://github.com/netbox-community/devicetype-library.git_)
|
||||
- `REPO_BRANCH`, the branch to check out if appropriate, defaults to master.
|
||||
@ -88,7 +88,7 @@ The container supports the following env var as configuration :
|
||||
- `NETBOX_TOKEN`, token for accessing netbox
|
||||
- `VENDORS`, a comma-separated list of vendors to import (defaults to None)
|
||||
|
||||
To run :
|
||||
To run :
|
||||
|
||||
```
|
||||
docker run -e "NETBOX_URL=http://netbox:8080/" -e "NETBOX_TOKEN=98765434567890" ghcr.io/minitriga/netbox-device-type-library-import
|
||||
|
Loading…
Reference in New Issue
Block a user