Skip to content

Instantly share code, notes, and snippets.

View skylerto's full-sized avatar

Skyler Layne skylerto

View GitHub Profile
@skylerto
skylerto / clean_docker_nexus.sh
Created January 12, 2018 20:23 — forked from matzegebbe/clean_docker_nexus.sh
Nexus Repository Manager keep the last X docker images delete all other
#!/bin/bash
REPO_URL="https://repository.xxx.net/repository/"
USER="admin"
PASSWORD="datpassword"
BUCKET="portal-docker"
KEEP_IMAGES=10
IMAGES=$(curl --silent -X GET -H 'Accept: application/vnd.docker.distribution.manifest.v2+json' -u ${USER}:${PASSWORD} "${REPO_URL}${BUCKET}/v2/_catalog" | jq .repositories | jq -r '.[]' )
@skylerto
skylerto / gist:9277afb86fa1bcf078dd0535888e8dc6
Created December 11, 2017 18:08 — forked from amokan/gist:3881064
jenkins-cli commands (v1.485)
build
Builds a job, and optionally waits until its completion.
cancel-quiet-down
Cancel the effect of the "quiet-down" command.
clear-queue
Clears the build queue
connect-node
Reconnect to a node
copy-job
Copies a job.