Skip to content

Instantly share code, notes, and snippets.

  • вводим сайт
  • скролим вниз
  • скачиваем .xls
  • перезаписываем в CSV из OpenOffice или чего попало

Результат: site.csv

вытягиваем список IP

@droopy4096
droopy4096 / bombard_gosuslugi.sh
Created March 1, 2022 01:14
Bombardier helper
sh ./bombarder.sh $(curl -s https://raw.githubusercontent.com/droopy4096/stoppropaganda/external-json/data/ru_gosuslugi.json | jq -r '. | keys[]')
@droopy4096
droopy4096 / _accessor.tpl
Last active June 8, 2021 19:36
Helm execute a template in a subchart's scope
# idea from https://github.com/helm/helm/issues/4535#issuecomment-477778391
{{- define "call-nested" }}
{{- $dot := index . 0 }}
{{- $subchart := index . 1 | splitList "." }}
{{- $template := index . 2 }}
{{- $values := $dot.Values }}
{{- range $subchart }}
{{- $values = index $values . }}
{{- end }}
#!/bin/sh
set -e
# MY_JOBS=$(mktemp containers.XXXX)
# ALL_RUNS=$(mktemp runs.XXXX)
MY_JOBS=$(mktemp jobs.XXXXXX)
cleanup(){
[ -n "${DEBUG}" ] && echo ${MY_JOBS}
rm ${MY_JOBS}
}
# Generated by Powerlevel10k configuration wizard on 2020-09-25 at 12:05 MDT.
# Based on romkatv/powerlevel10k/config/p10k-classic.zsh, checksum 49789.
# Wizard options: powerline, classic, unicode, dark, 24h time, angled separators,
# blurred heads, flat tails, 2 lines, disconnected, left frame, compact, concise,
# transient_prompt, instant_prompt=verbose.
# Type `p10k configure` to generate another config.
#
# Config for Powerlevel10k with classic powerline prompt style. Type `p10k configure` to generate
# your own config based on it.
#
--langdef=Puppet
--langmap=Puppet:.pp
--regex-Puppet=/^class[ \t]*([:a-zA-Z0-9_\-]+)[ \t]*/\1/c,class/
--regex-Puppet=/^node[ \t]*([a-zA-Z0-9_"'\.\-]+)[ \t]*/\1/n,node/
--regex-Puppet=/^site[ \t]*([a-zA-Z0-9_"'\.\-]+)[ \t]*/\1/s,site/
--regex-Puppet=/^define[ \t]*([:a-zA-Z0-9_\-]+)[ \t]*/\1/d,definition/
--regex-Puppet=/^ *([a-zA-Z:_]+) *\{ *(.*) *:/\1[\2]/r,resource/
--regex-Puppet=/^ *(@[a-zA-Z:_]+) *\{ *(.*) *:/\1[\2]/v,virtual_resource/
--regex-Puppet=/^ *([A-Z][a-zA-Z0-9_:]+) *\{/\1/f,default/
- hosts: puppetmaster
tasks:
- name: stop master puppet
service: name=httpd state=stopped
tags:
- master
- service
- stop
- name: kill remaining httpd process
@droopy4096
droopy4096 / compose_setup.pp
Created February 9, 2018 23:05
docker compose wrapper with vcsrepo
define compose_setup(
$compose_source_repo,
$compose_source_revision,
$compose_deploy_dir,
$compose_ensure='present',
$compose_file='docker-compose.yml',
$compose_identity=undef,
$compose_stage_dir=undef,
$compose_source_repo_force=false,
$compose_ensure='latest',
Jan 10 16:25:39 2018 (92) Connection to HyperKitty failed: ("Connection broken: ConnectionResetError(104, 'Connection reset by peer')", ConnectionResetError(104, 'Connection reset by peer'))
Jan 10 16:25:39 2018 (92) Exception in the HyperKitty archiver: ("Connection broken: ConnectionResetError(104, 'Connection reset by peer')", ConnectionResetError(104, 'Connection reset by peer'))
Jan 10 16:25:39 2018 (92) Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/urllib3/response.py", line 302, in _error_catcher
yield
File "/usr/local/lib/python3.6/site-packages/urllib3/response.py", line 384, in read
data = self._fp.read(amt)
File "/usr/local/lib/python3.6/http/client.py", line 449, in read
n = self.readinto(b)
File "/usr/local/lib/python3.6/http/client.py", line 493, in readinto
@droopy4096
droopy4096 / docker-compose.yaml
Created October 6, 2017 00:34
Mailman-core configs
# docker-compose -f compose-file config:
mailman-core:
container_name: mailman-core
depends_on:
- database
environment:
DATABASE_CLASS: mailman.database.postgresql.PostgreSQLDatabase
DATABASE_TYPE: postgres
DATABASE_URL: postgres://mailman:mailmanpass@database/mailmandb
DB_NAME: mailmandb