This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#cloud-config | |
users: | |
- name: ismail | |
groups: users, admin | |
sudo: ALL=(ALL) NOPASSWD:ALL | |
shell: /bin/bash | |
ssh_authorized_keys: | |
- ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPdJr63tCOvAaA42XTABCY1BL6jRNwq7qNF5uoNNsqoY [email protected] | |
package_update: true | |
package_upgrade: true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
ROOT_FS_USAGE=$(df -H / | grep -vE 'Filesystem' | awk '{ print $5}' | cut -d'%' -f1) | |
DISK_LIMIT=${DISK_LIMIT:-75} | |
if [ "$ROOT_FS_USAGE" -ge "$DISK_LIMIT" ]; then | |
echo "Cleaning up docker images" | |
docker system prune -af --filter="until=1h" | |
fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"version": "0.2.0", | |
"configurations": [ | |
{ | |
"type": "pwa-chrome", | |
"request": "attach", | |
"name": "Chrome debug", | |
"urlFilter": "http://localhost:8080/*", | |
"port": 9222, | |
"webRoot": "${workspaceFolder}/src", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "2.1" | |
services: | |
sonarr: | |
image: linuxserver/sonarr | |
container_name: sonarr | |
environment: | |
- PUID=1000 | |
- PGID=1000 | |
- TZ=Europe/Istanbul |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from "react"; | |
import CKEditor from "@ckeditor/ckeditor5-react"; | |
import ClassicEditor from "@ckeditor/ckeditor5-build-classic"; | |
import "@ckeditor/ckeditor5-build-classic/build/translations/tr.js"; | |
import { useMutation } from "@apollo/client"; | |
import { UPLOAD_PHOTO } from "../../gql/photo/mutation"; | |
class UploadAdapter { | |
constructor(loader, uploadPhoto) { | |
this.loader = loader; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Wallpaper.get() Get current wallpapers path. For getting as Pillow image object, use True as parameter. | |
# Wallpaper.set() Set wallpaper. Can be path of image or Pillow object. File type doesn't matter and path can be absolute or relative. | |
# Wallpaper.copy() - Copy current wallpaper. First parameter is directory and the second is file name. File extension should be JPG. Default directory is current directory and file name is 'wallpaper.jpg' | |
from os import path, getenv, getcwd | |
from ctypes import windll | |
from shutil import copyfile | |
from PIL import Image | |
from tempfile import NamedTemporaryFile |