Skip to content

Instantly share code, notes, and snippets.

@virtualdreams
virtualdreams / .vimrc
Last active October 7, 2021 14:27
Standard .vimrc
" set nocompatible
set nocompatible
" enable syntax highligting
syntax on
" suppress welcome screen
set shortmess+=I
" some useful options
# Variables
setenv FOO bar
# Settings
startup_message off
shell zsh
vbell off
defutf8 on
defscrollback 10000
autodetach on
@virtualdreams
virtualdreams / .zshrc
Last active August 9, 2018 18:29
Simple zsh configuration
# init
autoload -U colors && colors
alias ls='ls --color=auto'
alias rm='rm -i'
setopt nobeep # avoid beep
setopt noglobdots # * shouldn't match dotfiles
setopt no_auto_remove_slash
setopt hash_list_all
@virtualdreams
virtualdreams / mono-server4.service
Created May 5, 2015 06:02
systemd mono-server4 unit script
[Unit]
Description=FastCGI mono server 4
After=network.target
[Service]
Environment=MONO_IOMAP=all
EnvironmentFile=
Type=simple
ExecStart=/usr/bin/fastcgi-mono-server4 /applications=*:/:/srv/www/mvc/ /socket=tcp:127.0.0.1:9000
User=www-data
@virtualdreams
virtualdreams / uwsgi-emperor.service
Created August 20, 2016 10:21
systemd service for uwsgi emperor
[Unit]
Description=uWSGI Emperor
After=syslog.target
[Service]
ExecStart=/usr/bin/uwsgi --json /etc/uwsgi/emperor.json
# Requires systemd version 211 or newer
RuntimeDirectory=uwsgi
Restart=always
KillSignal=SIGQUIT
@virtualdreams
virtualdreams / mongod.service
Last active March 16, 2019 06:38
MongoDB systemd service file
[Unit]
Description=MongoDB Database Server
After=network.target
[Service]
User=mongodb
Group=mongodb
ExecStart=/usr/bin/mongod --config /etc/mongod.conf
PIDFile=/var/run/mongodb/mongod.pid
@virtualdreams
virtualdreams / NuGet.config
Created March 23, 2017 06:40
Sample configuration for nuget/vscode to move that big and fat .nuget folder from c directory.
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageRestore>
<add key="enabled" value="True" />
<add key="automatic" value="True" />
</packageRestore>
<config>
<add key="https_proxy" value="http://127.0.0.1:3128/" />
<add key="http_proxy" value="http://127.0.0.1:3128/" />
<add key="globalPackagesFolder" value="e:\Entwicklung\.nuget" />
@virtualdreams
virtualdreams / gogs.service
Created April 4, 2017 15:10
Gogs systemd service
[Unit]
Description=Gogs
After=syslog.target
After=network.target
#After=mysqld.service
#After=postgresql.service
#After=memcached.service
#After=redis.service
[Service]
@virtualdreams
virtualdreams / dotnet.service
Created April 4, 2017 15:14
dotnet systemd service
[Unit]
Description=dotnet <your service name>
After=network.target
[Service]
Environment=ASPNETCORE_URLS=http://127.0.0.1:5000/
EnvironmentFile=
;Restart=always
;RestartSec=10
Type=simple
@virtualdreams
virtualdreams / goaccess.service
Created April 4, 2017 15:16
goaccess systemd service
[Unit]
Description=Goaccess Web log report.
After=network.target
[Service]
Type=simple
User=root
Group=root
Restart=always
ExecStart=/usr/local/bin/goaccess -a -g -f /var/log/nginx/access.log -o /srv/www/goaccess/index.html --real-time-html --ws-url <your url>