Skip to content

Instantly share code, notes, and snippets.

View devopsinka's full-sized avatar
🏠
Working from home

DevOps devopsinka

🏠
Working from home
View GitHub Profile
$ mkdir django && cd django
$ mkdir django-env && cd django-env
$ python3.10 -m venv env
$ source env/bin/activate
(env)$ pip install django==4.0
(env)$ django-admin.py startproject hello_django .
(env)$ python manage.py runserver
#!/bin/bash
# удаление завершенных контейнеров:
docker ps --filter status=dead --filter status=exited -aq | xargs -r docker rm -v
# удаление неиспользуемых контейнеров:
yes | docker container prune
# удаление не используемых образов:
yes | docker image prune
# удаление не используемых томов:
yes | docker volume prune
@devopsinka
devopsinka / README.md
Created March 10, 2021 14:39 — forked from danielepolencic/README.md
Create 3 nodes Kubernetes cluster locally with Vagrant

3 Virtual Machines Kubernetes cluster

Dependencies

You should install VirtualBox and Vagrant before you start.

Creating the cluster

You should create a Vagrantfile in an empty directory with the following content:

@devopsinka
devopsinka / bot.py
Created May 22, 2020 14:58
Бот регистрация заявки
import config
import telebot
from telebot import types # кнопки
from string import Template
bot = telebot.TeleBot(config.token)
user_dict = {}
class User:
@devopsinka
devopsinka / default
Created February 4, 2018 13:13 — forked from dtomasi/default
Brew Nginx PHP7
server {
listen 80;
server_name localhost;
root /Users/YOUR_USERNAME/Sites;
access_log /Library/Logs/default.access.log main;
location / {
include /usr/local/etc/nginx/conf.d/php-fpm;
}

Deploy Rails app to digitalocean with nginx, unicorn, capistrano & postgres

Create droplet of your liking (ubuntu 12.10 x32)

ssh to root in terminal with your server ip

ssh root@123.123.123.123

Add ssh fingerprint and enter password provided in email