Windows Service with Python 3.5 and pyinstaller
- Python 3.5.x
- Visual C++ Build Tools 2015
- PyInstaller 3.2
#!/bin/bash | |
CONTAINER=$1 | |
RUNNING=$(docker inspect --format="{{ .State.Running }}" $CONTAINER 2> /dev/null) | |
if [ $? -eq 1 ]; then | |
echo "'$CONTAINER' does not exist." | |
else | |
/usr/bin/docker rm --force $CONTAINER |
#!/bin/bash | |
# Author: Erik Kristensen | |
# Email: erik@erikkristensen.com | |
# License: MIT | |
# Nagios Usage: check_nrpe!check_docker_container!_container_id_ | |
# Usage: ./check_docker_container.sh _container_id_ | |
# | |
# Depending on your docker configuration, root might be required. If your nrpe user has rights | |
# to talk to the docker daemon, then root is not required. This is why root privileges are not |
#!/bin/bash | |
# get all running docker container names | |
containers=$(sudo docker ps | awk '{if(NR>1) print $NF}') | |
host=$(hostname) | |
# loop through all containers | |
for container in $containers | |
do | |
echo "Container: $container" |
Windows Service with Python 3.5 and pyinstaller
#!/usr/bin/env python | |
## Tiny Syslog Server in Python. | |
## | |
## This is a tiny syslog server that is able to receive UDP based syslog | |
## entries on a specified port and save them to a file. | |
## That's it... it does nothing else... | |
## There are a few configuration parameters. | |
LOG_FILE = 'youlogfile.log' |