Skip to content

Instantly share code, notes, and snippets.

View secondtruth's full-sized avatar

Christian Neff secondtruth

View GitHub Profile
@secondtruth
secondtruth / concept.md
Last active March 25, 2024 15:49
Concept for a Distributed Cloud Service

Distributed Cloud Service

Idea

The idea is to create a Distributed Cloud Service, where multiple hosts can join together to form a community-driven cloud platform. This would enable developer communities to collaboratively offer free cloud services such as APIs and hosting. Structurally simple and easy to operate, its goal is to be both secure and efficient.

Challenges and Solutions

Resource Management and Load Balancing

@secondtruth
secondtruth / searxng_weather.py
Last active March 1, 2024 01:05
Simple SearXNG weather plugin
from flask_babel import gettext
import requests
import re
name = "Weather Data Plugin"
description = gettext("Displays weather data for a given location using the Open Meteo API, with improved formatting.")
default_on = True
preference_section = 'general'
# Regular expression to match location queries (e.g., "weather in Berlin" or "weather 52.52, 13.41")
@secondtruth
secondtruth / startmin.html
Last active June 2, 2016 12:35
Startmin Template
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="">
<meta name="author" content="">
<title>Startmin - Bootstrap Admin Theme</title>
@secondtruth
secondtruth / UserAgentStringParser.php
Last active September 2, 2019 07:59
Simple User Agent string parser
<?php
class UserAgentStringParser
{
/**
* Extracts information from the user agent string.
*
* @param string $string The user agent string
* @return array Returns the user agent information.
*/
public function parse($string)
@secondtruth
secondtruth / php-fastcgi.sh
Last active September 6, 2015 18:40
This init script starts FastCGI for PHP using spawn-fcgi
#!/bin/sh
### BEGIN INIT INFO
# Provides: php-fastcgi
# Required-Start: $all
# Required-Stop: $all
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Starts FastCGI for PHP
# Description: Starts FastCGI for PHP using spawn-fcgi