Skip to content

Instantly share code, notes, and snippets.

View freeseacher's full-sized avatar
💭
(3↑↑↑↑3)+1. Yo. Not.

Aleksey Shirokih freeseacher

💭
(3↑↑↑↑3)+1. Yo. Not.
View GitHub Profile
@freeseacher
freeseacher / confluence ne boley
Last active September 11, 2021 15:38
confluence ne boley
Non for production!!!! requires heavy testing
testted on 7.13.0 with
* login
* enter space
* edit page
* upload file
* logs are written ok
* index rebuild
* backup
* restore not tested
.run_ansible:
image: ${CI_REGISTRY_IMAGE}
variables:
....
PLAYBOOK_NAME: pb.yaml
script:
- export ANSIBLE_CONFIG=./ansible.cfg
- pip3 install -r python_requirements.txt --no-cache-dir
- ansible-inventory --list --yaml -i "${INVENTORY}"
- envsubst < requirements.tmpl > requirements.yaml
@freeseacher
freeseacher / docker-compose.yml
Last active March 12, 2021 14:43
one-more-prom-slides
version: '2.3'
services:
prom:
image: prom/prometheus:v2.23.0
ports:
- 9090:9090
volumes:
- "$PWD/configs:/etc/prometheus:ro"
command:
- --config.file=/etc/prometheus/prometheus.yml
@freeseacher
freeseacher / .gitlab-ci.yml
Last active May 17, 2020 14:51
molecule setup
---
variables:
MOLECULE_VERSION: 3.0.4
LC_ALL: C.UTF-8
LANG: C.UTF-8
PY_COLORS: 1
ANSIBLE_FORCE_COLOR: "True"
stages:
- test
global:
route:
receiver: blackhole
routes:
- match:
team: sre
receiver: to_email
group_by:
- alertname
- team
{"ts":"2020-04-02T17:10:38.909Z","level":"error","caller":"net/http/server.go:3059","msg":"http: panic serving 10.101.66.5:57366: runtime error: invalid memory address or nil pointer dereference\ngoroutine 2050 [running]:\nnet/http.(*conn).serve.func1(0xc00ef22000)\n\tnet/http/server.go:1772 +0x139\npanic(0xa0fc00, 0xe91d80)\n\truntime/panic.go:973 +0x3e3\ngithub.com/VictoriaMetrics/VictoriaMetrics/lib/workingsetcache.(*Cache).UpdateStats(0x0, 0xc0000516c8)\n\tgithub.com/VictoriaMetrics/VictoriaMetrics/lib/workingsetcache/cache.go:224 +0x37\ngithub.com/VictoriaMetrics/VictoriaMetrics/lib/storage.(*indexDB).UpdateMetrics(0xc00b931d00, 0xc02c41acf8)\n\tgithub.com/VictoriaMetrics/VictoriaMetrics/lib/storage/index_db.go:258 +0x9f\ngithub.com/VictoriaMetrics/VictoriaMetrics/lib/storage.(*Storage).UpdateMetrics(0xc0000bc7e0, 0xc02c41ac00)\n\tgithub.com/VictoriaMetrics/VictoriaMetrics/lib/storage/storage.go:413 +0x4c5\nmain.registerStorageMetrics.func1(0x0)\n\tgithub.com/VictoriaMetrics/VictoriaMetrics/app/vmstorage
### Keybase proof
I hereby claim:
* I am freeseacher on github.
* I am freeseacher (https://keybase.io/freeseacher) on keybase.
* I have a public key whose fingerprint is F4A9 551B AD80 1CDE 630C 7534 3DE6 257D A886 788E
To claim this, I am signing this object:
# cat nginx1.conf
user www-data;
events {
}
http {
server {
listen 0.0.0.0:8080;
location / {
proxy_pass http://my_upsteam;
...
}
location /options {
proxy_pass http://my_upsteam;
..
vhost_traffic_status_filter_by_set_key $status journey::show_form;
...
@freeseacher
freeseacher / expected output
Created November 19, 2018 09:18
nginx vts and
% curl http://0.0.0.0:9099/metrics
# HELP nginx_vts_info Nginx info
# TYPE nginx_vts_info gauge
nginx_vts_info{hostname="bca8ca4d104a",version="1.13.1"} 1
# HELP nginx_vts_start_time_seconds Nginx start time
# TYPE nginx_vts_start_time_seconds gauge
nginx_vts_start_time_seconds 1542618835.871
# HELP nginx_vts_main_connections Nginx connections
# TYPE nginx_vts_main_connections gauge
nginx_vts_main_connections{status="accepted"} 2