Instance for revisions of lab documents and code. Host on cnap or mcp? gitlab docker guide
Alt. portainer på curve server. Kör dashboard där, installera portainer-agent på 193.10.203.20 maskinen för remote agent access.
https://docs.portainer.io/start/install-ce/server/docker/linux
https://www.virtualizationhowto.com/2022/12/portainer-agent-manage-remote-docker-environment/
crimsonjadewhisper
On mcp or cnap? .237 vs .203
https://hub.docker.com/r/linuxserver/netbox
Netbox requires a postgre and redis instance as well
---
version: "2.1"
services:
netbox:
image: lscr.io/linuxserver/netbox:latest
container_name: netbox
environment:
- PUID=1000
- PGID=1000
- TZ=<TZ>
- SUPERUSER_EMAIL=<SUPERUSER_EMAIL>
- SUPERUSER_PASSWORD=<SUPERUSER_PASSWORD>
- ALLOWED_HOST=<ALLOWED_HOST>
- DB_NAME=<DB_NAME>
- DB_USER=<DB_USER>
- DB_PASSWORD=<DB_PASSWORD>
- DB_HOST=<DB_HOST>
- DB_PORT=<DB_PORT>
- REDIS_HOST=<REDIS_HOST>
- REDIS_PORT=<REDIS_PORT>
- REDIS_PASSWORD=<REDIS_PASSWORD>
- REDIS_DB_TASK=<REDIS_DB_TASK>
- REDIS_DB_CACHE=<REDIS_DB_CACHE>
- BASE_PATH=<BASE_PATH> #optional
- REMOTE_AUTH_ENABLED=<REMOTE_AUTH_ENABLED> #optional
- REMOTE_AUTH_BACKEND=<REMOTE_AUTH_BACKEND> #optional
- REMOTE_AUTH_HEADER=<REMOTE_AUTH_HEADER> #optional
- REMOTE_AUTH_AUTO_CREATE_USER=<REMOTE_AUTH_AUTO_CREATE_USER> #optional
- REMOTE_AUTH_DEFAULT_GROUPS=<REMOTE_AUTH_DEFAULT_GROUPS> #optional
- REMOTE_AUTH_DEFAULT_PERMISSIONS=<REMOTE_AUTH_DEFAULT_PERMISSIONS> #optional
volumes:
- <path to data on host>:/config
ports:
- 8000:8000
restart: unless-stopped
# docker-compose.yml
version: '3'
services:
database:
image: "postgres" # use latest official postgres version
env_file:
- database.env # configure postgres
volumes:
- ./host-folder/:/var/lib/postgresql/data/ # persist data even if container shuts down
# database.env
POSTGRES_USER=unicorn_user
POSTGRES_PASSWORD=magical_password
POSTGRES_DB=rainbow_database
ldapsearch -x -h 193.10.199.104 -D "CN=siol0003,OU=dat,OU=INST_IV,OU=PERSONAL,OU=USERS,OU=EDU,DC=wad,DC=hv,DC=se" -W -b "DC=wad,DC=hv,DC=se" "(cn=siol0003)"
ldapsearch -x -H ldap://wad.hv.se -D "siol0003@hv.se" -W -b "DC=wad,DC=hv,DC=se" "(cn=buba0001)"
from ldap3 import Server, Connection, ALL
server = Server('wad.hv.se', get_info=ALL)
conn = Connection(server, 'USERNAME@hv.se', 'PASSWORD', auto_bind=True)
conn.search('dc=wad,dc=hv,dc=se', '(&(objectclass=person)(cn=USERNAMETOSEARCHFOR))', attributes=['sn', 'userPrincipalName', 'objectclass'])
Use ZTP to mass-config all devices in all pods, hook them all up to central switch on the same LAN as an Ansible device.
Use the Ansible device to check all flash: filesystems on every device and compare to approved file-list based on the platform criteria. Report anomalies back to the controller. Take manual action from the user based on the output and approve file wipes on the non-compliant devices.