Skip to content

Instantly share code, notes, and snippets.

View andyshinn's full-sized avatar
🖥️
don't put computers in your mouth

Andy Shinn andyshinn

🖥️
don't put computers in your mouth
View GitHub Profile
@andyshinn
andyshinn / STEPS.md
Created April 11, 2017 21:46
Confluence in Docker

Steps

  1. Run docker-compose up to bring up the two containers (Confluence and MySQL).
  2. Navigate to http://192.168.99.100:8090/ (replace the IP with the correct IP of your Docker Machine).
  3. Choose "Production Installation" and click the Next button.
  4. Click the Next button on the Add-ons screen.
  5. Add your license key and click Next.
  6. Choose "MySQL" and then click the External Database button.
  7. Click the Direct JDBC button.
  8. Change localhost to mysql in the Database URL, set User name to confluence, Password to myconfluencepass, and click Next.
@andyshinn
andyshinn / gist:3511fbd091dc87ad78771e380fb527d4
Created September 9, 2016 20:54
Mimicking CORS preflight responses in Apache
<VirtualHost _default_:443>
ServerName yourhost
ServerAdmin someperson@yourorg.com
SSLEngine on
SSLCertificateFile /etc/ssl/private/yourorg.com.crt
SSLCertificateKeyFile /etc/ssl/private/yourorg.com.key
SSLCertificateChainFile /etc/ssl/private/chain.pem
SSLProxyEngine On
2016-09-07 17:10:25,445 [pool-3-thread-1] INFO com.sumologic.scala.collector.input.docker.DockerLogInput - Log stream for bd823e8c618fa908b395ff20e80d41781f32c6442462f22e5b5b5326315f0a23 is closed
2016-09-07 17:10:25,445 [Blade: 0000000006ED5E95 - b32a7b70-4712-4089-ac8d-e3ba7f2deeac] INFO com.sumologic.scala.collector.input.docker.DockerLogInput - Log stream for bd823e8c618fa908b395ff20e80d41781f32c6442462f22e5b5b5326315f0a23 finished running
2016-09-07 17:10:25,449 [Blade: 0000000006ED5E95 - b32a7b70-4712-4089-ac8d-e3ba7f2deeac] INFO com.sumologic.scala.collector.blade.docker.DockerLogBlade - Checking if container bd823e8c618fa908b395ff20e80d41781f32c6442462f22e5b5b5326315f0a23 is running via Docker Client com.github.dockerjava.core.DockerClientImpl@22c5c785 on attempt 1
2016-09-07 17:10:25,664 [pool-2-thread-1] ERROR com.sumologic.scala.collector.input.docker.DockerEventInput - error processing payload for 116219541 while consuming docker event message
java.lang.NullPointerException
at scala.uti
@andyshinn
andyshinn / pom.xml
Last active September 7, 2016 19:15
Basic Spring Cloud Config Server
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building configserver 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-dependency-plugin:2.10:tree (default-cli) @ configserver ---
[INFO] com.test:configserver:jar:0.0.1-SNAPSHOT
[INFO] +- org.springframework.boot:spring-boot-starter-actuator:jar:1.3.7.RELEASE:compile
[INFO] | +- org.springframework.boot:spring-boot-starter:jar:1.3.7.RELEASE:compile
---
security:
user:
password: appdefault
---
spring:
profiles: test
security:
user:
password: apptest
@andyshinn
andyshinn / docker-compose.yml
Created August 31, 2016 19:22
Cachet Rancher
nginx:
labels:
io.rancher.container.pull_image: always
image: nginx:1.9-alpine
links:
- 'cachet:'
volumes:
- cachetnginx:/etc/nginx/conf.d
- cachetwww:/var/www
volume_driver: convoy
@andyshinn
andyshinn / README.md
Created June 9, 2016 15:38
pbcopy over SSH

Install

  • Add pbcopy.plist to your ~/Library/LaunchAgents/ folder.
  • Launch the listener with launchctl load ~/Library/LaunchAgents/pbcopy.plist.
  • Add RemoteForward 2224 127.0.0.1:2224 in your ~/.ssh/config file under your Host * or specific hosts sections.
  • Add [ -n "$SSH_CLIENT" ] && alias pbcopy="nc localhost 2224" to your remote ~/.bash_profile or other shell profile.
  • Enjoy pbcopy remotely!
@andyshinn
andyshinn / APKBUILD
Created April 2, 2016 16:57
netdata Alpine Linux package
# Contributor: Andy Shinn <andys@andyshinn.as>
# Maintainer: Andy Shinn <andys@andyshinn.as>
pkgname=netdata
pkgver=1.0.1
pkgrel=0
pkgdesc="Real-time performance monitoring, done right!"
url="https://github.com/firehol/netdata"
license="GPL"
arch="all"
depends="bash nodejs"
@andyshinn
andyshinn / gist:f71b05ba59a901db78e1
Created February 24, 2016 00:51
Change Quay permissions for all repositories
for repo in $(http --session quay GET "https://quay.io/api/v1/repository?namespace=$NAMESPACE&public=false" Authorization:"Bearer $AUTH_TOKEN" | jq -r '.repositories[].name'); do http --session quay PUT "https://quay.io/api/v1/repository/$NAMESPACE/$repo/permissions/team/$TEAM" role=read; done
root 12387 0.3 0.5 1286652 43544 ? Ssl 2015 227:56 /usr/bin/docker daemon
root 14174 0.0 0.0 18184 1652 ? Ss 2015 0:00 \_ /bin/bash /run.sh run
root 20744 0.9 0.4 83764 34036 ? S 07:08 5:03 | \_ python /var/lib/cattle/pyagent/main.py
root 21070 0.0 0.0 18392 1960 ? S 07:08 0:03 | \_ /bin/bash /var/lib/cattle/pyagent/cattle/process_watcher.sh
root 6692 0.0 0.0 4340 360 ? S 16:23 0:00 | | \_ sleep 2
root 21075 0.2 0.0 18580 2084 ? S 07:08 1:08 | \_ /bin/bash /var/lib/cattle/pyagent/cattle/plugins/conntrack/conntrack.sh
root 6696 0.0 0.0 18580 1064 ? R 16:23 0:00 | | \_ /bin/bash /var/lib/cattle/pyagent/cattle/plugins/conntrack/conntrack.sh
root 21076 0.0 0.1 483228 11368 ? Sl 07:08 0:27 | \_ host-api -cadvisor-url http://127.0.0.1:9344 -logtostderr=true -ip 0.0.0.0 -port 9345 -auth=true -host-uuid b1c
root 21082