Skip to content

Instantly share code, notes, and snippets.

View sumitsaiwal's full-sized avatar

Sumit Kumar sumitsaiwal

View GitHub Profile
@sumitsaiwal
sumitsaiwal / aws_ebs_volume_k8s
Created July 28, 2018 17:59
AWS EBS Volumes in Kubernetes
containers:
- name: APP_NAME
image: "DOCKER_IMAGE_NAME"
ports:
- name: http
containerPort: 3000
volumeMounts:
- name: share
mountPath: /var/lib/
volumes:
Driver Support Required:
1. Display
2. 3D hardware acceleration support
3. Audio
4. Webcam
5. Video-game controller
http://somatorio.org/en/post/running-gui-apps-with-docker/
https://blog.qmo.io/the-perfect-media-server-with-docker-plex-and-automatic-bittorrent/
@sumitsaiwal
sumitsaiwal / vsts_build_retain
Last active August 16, 2018 10:35
Retain VSTS build indefinitely
#import-module "Microsoft.TeamFoundation.DistributedTask.Task.Common"
$uri = "$($env:SYSTEM_TEAMFOUNDATIONCOLLECTIONURI)$env:SYSTEM_TEAMPROJECT/_apis/build/builds/$($env:BUILD_BUILDID)?api-version=2.0"
Write-Verbose "URI: $uri"
$body = "{keepForever:true}"
$result = Invoke-RestMethod -Uri $uri -Method Patch -ContentType "application/json" -Headers @{Authorization = "Bearer $env:SYSTEM_ACCESSTOKEN"} -Body $body
Write-Output "RESULT: $result"
@sumitsaiwal
sumitsaiwal / tennis.py
Created June 17, 2020 07:45
Tennis Scoreboard Problem in Python.
input_list = []
while True:
input_str = input()
if input_str == "":
break
else:
input_list.append(input_str)
#print(input_list)