This commit is contained in:
		
						commit
						993ec547d1
					
				
					 3 changed files with 93 additions and 0 deletions
				
			
		
							
								
								
									
										17
									
								
								.drone.yml
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										17
									
								
								.drone.yml
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,17 @@
 | 
				
			||||||
 | 
					---
 | 
				
			||||||
 | 
					kind: pipeline
 | 
				
			||||||
 | 
					type: docker
 | 
				
			||||||
 | 
					name: default
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					steps:
 | 
				
			||||||
 | 
					- name: build
 | 
				
			||||||
 | 
					  image: plugins/docker
 | 
				
			||||||
 | 
					  settings:
 | 
				
			||||||
 | 
					    registry: git.kurocon.nl
 | 
				
			||||||
 | 
					    username:
 | 
				
			||||||
 | 
					      from_secret: docker_username
 | 
				
			||||||
 | 
					    password:
 | 
				
			||||||
 | 
					      from_secret: docker_password
 | 
				
			||||||
 | 
					    repo: git.kurocon.nl/kuronet/munin-docker
 | 
				
			||||||
 | 
					    tags:
 | 
				
			||||||
 | 
					    - latest
 | 
				
			||||||
							
								
								
									
										20
									
								
								Dockerfile
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										20
									
								
								Dockerfile
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,20 @@
 | 
				
			||||||
 | 
					FROM debian:12
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					LABEL org.opencontainers.image.authors="me@kurocon.nl"
 | 
				
			||||||
 | 
					LABEL org.opencontainers.image.source="https://git.kurocon.nl/KuroNET/munin-docker"
 | 
				
			||||||
 | 
					LABEL org.opencontainers.image.description="Munin image with Docker binaries"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					RUN apt-get update -qq && RUNLEVEL=1 DEBIAN_FRONTEND=noninteractive \
 | 
				
			||||||
 | 
					    apt-get install -y -qq cron munin nginx wget libcgi-fast-perl curl && \
 | 
				
			||||||
 | 
					    mkdir -p /var/run/munin && chown -R munin:munin /var/run/munin && \
 | 
				
			||||||
 | 
					    echo "includedir /etc/munin/munin-conf.d" > /etc/munin/munin.conf
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					VOLUME /var/lib/munin
 | 
				
			||||||
 | 
					VOLUME /var/log/munin
 | 
				
			||||||
 | 
					VOLUME /var/run/munin
 | 
				
			||||||
 | 
					VOLUME /var/cache/munin
 | 
				
			||||||
 | 
					VOLUME /etc/munin/munin.conf.d
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					EXPOSE 80
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					CMD ["/usr/sbin/munin-node"]
 | 
				
			||||||
							
								
								
									
										56
									
								
								README.md
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										56
									
								
								README.md
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,56 @@
 | 
				
			||||||
 | 
					# Munin (master)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					## Quickstart
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Munin stats aggregator and reporting, based on ethersys' munin container (<https://github.com/ethersys/ethersys-docker-munin>).
 | 
				
			||||||
 | 
					Base image: Debian 12
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					### Build
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					```bash
 | 
				
			||||||
 | 
					git clone https://git.kurocon.nl/KuroNET/munin-docker.git
 | 
				
			||||||
 | 
					docker build -t munin ./
 | 
				
			||||||
 | 
					docker run munin
 | 
				
			||||||
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					### Or pull
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					```bash
 | 
				
			||||||
 | 
					docker pull git.kurocon.nl/kuronet/munin-docker
 | 
				
			||||||
 | 
					docker run git.kurocon.nl/kuronet/munin-docker:latest
 | 
				
			||||||
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					## How it works
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					### Ports
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					* None
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					### Volumes
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					* `/var/lib/munin` : Databases files
 | 
				
			||||||
 | 
					* `/var/log/munin` : Logs
 | 
				
			||||||
 | 
					* `/var/run/munin` : Access to graph CGI socket
 | 
				
			||||||
 | 
					* `/var/cache/munin` : Where are generated graphs
 | 
				
			||||||
 | 
					* `/etc/munin/munin.conf.d` : Access to node configurations
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					### Environment Variables
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					* `TZ`: Customize the timezone according to your place: (i.e. `Europe/London`) (default: `Europe/Paris`)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					### Note
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Cronjobs and webserver should be setup separately (i.e. Kubernetes CronJob + sidecar nginx container)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					## Persistent example
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					```bash
 | 
				
			||||||
 | 
					docker run \
 | 
				
			||||||
 | 
					 -d \
 | 
				
			||||||
 | 
					 --name=munin \
 | 
				
			||||||
 | 
					 -e TZ="Europe/London" \
 | 
				
			||||||
 | 
					 -v /data/munin/db:/var/lib/munin \
 | 
				
			||||||
 | 
					 -v /data/munin/logs:/var/log/munin \
 | 
				
			||||||
 | 
					 -v /data/munin/cache:/var/cache/munin \
 | 
				
			||||||
 | 
					 munin
 | 
				
			||||||
 | 
					```
 | 
				
			||||||
		Reference in a new issue