Skip to content

Instantly share code, notes, and snippets.

View fluential's full-sized avatar
💭
¯\_(ツ)_/¯

Mike fluential

💭
¯\_(ツ)_/¯
  • Earth
View GitHub Profile
@fluential
fluential / Dockerfile
Created April 4, 2024 16:06 — forked from stackcoder/Dockerfile
Dockerfile for fawkes
FROM python:3.6-slim
RUN apt-get update && apt-get install --no-install-recommends -y \
libgl1 \
libglib2.0-0 \
curl
RUN extractor='extractor_2.h5' \
&& extractor_sha256='cdda15f239331b9535d80a94b4d75889ccb3b61d7b030c921bd2bfd7862b0adc' \
&& extractor_path='/usr/local/lib/python3.6/site-packages/fawkes/model' \
@fluential
fluential / 01_longhorn_bestpractices.md
Created December 15, 2022 02:05 — forked from ifeulner/01_longhorn_bestpractices.md
Longhorn hcloud best practices

Longhorn best practices

The following settings are provided as an example how longhorn should be configured in a production cluster, especially if it is deployed on Hetzner Cloud infrastructure.

Hetzner server nodes provide local storage and allow up to five attached volumes (with a size of up to 10TiB each) Local storage is provided by NVMe storage and therefore is much faster than the attached volumes, but limited in size (max 300GiB usable).

Initial configuration

Also you want to control the nodes that are used for storage. So it is suggested to set the option Create default disk only on labeled node to true

@fluential
fluential / check_hash.py
Created October 17, 2022 18:04 — forked from JrooTJunior/check_hash.py
telegram site auth
# implementation of Telegram site authorization checking algorithm
# for more information https://core.telegram.org/widgets/login#checking-authorization
import collections
import hmac
import hashlib
def check_string(data, token):
secret = hashlib.sha256()
secret.update(token.encode('utf-8'))
@fluential
fluential / 1.md
Created July 11, 2022 15:45 — forked from CustomIcon/1.md
start(), idle() and stop() multiple Pyrogram Clients at once.

UPDATED

Updated to Pyrogram v1.

If you know what you're doing, feel free to use these as a guide.

For any questions, head to @PyrogramLounge.

# Bazarr downloads subtitles
version: "3.4"
services:
bazarr:
image: linuxserver/bazarr:1.0.5-development
container_name: bazarr
restart: unless-stopped
environment:
- TZ=Europe/London
@fluential
fluential / gitlab-runner-rootless.sh
Created June 26, 2022 17:21 — forked from Jamesits/gitlab-runner-rootless.sh
Run GitLab CI runner from non-root user account without it complaining for the "user mode" thing
cat > /etc/systemd/system/gitlab-runner.service.d/override.conf <<EOF
[Service]
User=gitlab-runner
Group=gitlab-runner
ExecStartPre=+ln -sf /var/run/podman/podman.sock /var/run/docker.sock
ExecStart=
ExecStart=strace -e getuid,getgid -e inject=getuid:retval=0 -e inject=getgid:retval=0 -- /usr/bin/gitlab-runner run --working-directory /home/gitlab-runner --config /etc/gitlab-runner/config.toml --service gitlab-runner --user gitlab-runner
EOF

Remove snaps

sudo snap remove --purge firefox
sudo snap remove --purge snap-store
sudo snap remove --purge snapd-desktop-integration
sudo snap remove --purge gtk-common-themes
sudo snap remove --purge gnome-3-38-2004
sudo snap remove --purge core20
sudo snap remove --purge bare
sudo snap remove --purge snapd
@fluential
fluential / secret_detection.yml
Created April 5, 2022 22:51 — forked from halloei/secret_detection.yml
GitLab Secret Detection which fails when vulnerabilities were found
# This job overrides the default secret detection job from GitLab
# (https://gitlab.com/gitlab-org/gitlab/-/blob/master/lib/gitlab/ci/templates/Jobs/Secret-Detection.gitlab-ci.yml)
# and fails if vulnerabilities were found. The exit code represents the number of vulnerabilities.
#
# Requirements:
# - Stage "test"
include:
- template: Security/Secret-Detection.gitlab-ci.yml
@fluential
fluential / debian-install-megacli.md
Created October 3, 2021 19:10 — forked from fxkraus/debian-install-megacli.md
Install LSI MegaCli .deb package on Debian/Ubuntu

download

wget https://docs.broadcom.com/docs-and-downloads/raid-controllers/raid-controllers-common-files/8-07-14_MegaCLI.zip

unzip

unzip 8-07-14_MegaCLI.zip
@fluential
fluential / open_source_licenses.md
Created September 22, 2021 10:31 — forked from nicolasdao/open_source_licenses.md
What you need to know to choose an open source license.