- collections.deque:
- double linked list
- bad with random insert
- list:
- bad with pop, push to top
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
{"lastUpload":"2019-10-13T19:11:22.092Z","extensionVersion":"v3.4.3"} |
This file contains 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
const express = require('express') | |
const vm = require('vm') | |
let app = express() | |
app.use(function(req, res, next) { | |
req.body = '' | |
req.setEncoding('utf8'); | |
- Dockerizing your own personal infrastructure (Docker Swarm, RexRay, Traefik, Let’s Encrypt, DigitalOcean, Jenkins, Ansible)
- https://tech.feedyourhead.at/content/testing-ansible-roles-automatically-on-every-git-push
- https://github.com/debops
- https://github.com/SiriusRed/gitlab-ci-deploy-ansible/tree/master/roles/deploy-container/tasks
- https://habr.com/ru/company/southbridge/blog/310278/
- https://habr.com/ru/company/alfa/blog/359030/
- https://subscription.packtpub.com/book/application_development/9781785289194/14/ch14lvl1sec37/automating-deployment-with-docker-swarm-and-ansible
- https://medium.com/@adrian.gheorghe.dev/docker-swarm-ci-deployment-using-ansible-and-jenkins-ddfc99296db8
-
apt install qemu-kvm qemu-system-x86 qemu-utils libvirt-daemon-system libvirt-clients virtinst virt-manager virt-viewer adduser koi8-r libvirt adduser koi8-r libvirt-qemu adduser koi8-r kvm adduser koi8-r qemu virt-install --virt-type kvm --name buster --memory 512 --location http://httpredir.debian.org/debian/dists/buster/main/installer-amd64/ --disk size=4 --os-variant debiantesting --extra-args "console=ttyS0"
-
This file contains 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
# udevadm info --path=/class/net/wlxe894f61788fc --attribute-walk --query env | |
# udevadm control --reload-rules | |
# udevadm trigger | |
# udevadm monitor --subsystem=net | |
# udevadm test --action=add /class/net/wlxe894f61788fc | |
SUBSYSTEM=="net", SUBSYSTEMS=="usb", ACTION=="add", DRIVERS=="?*", ATTRS{product}=="*", ATTR{type}=="1", KERNEL=="wlan*", NAME="%k%n" |
- https://linux-notes.org/rabota-s-tomami-volumes-v-docker/
- https://stackoverflow.com/questions/41935435/understanding-volume-instruction-in-dockerfile
- https://linuxhint.com/dockerfile_volumes/
- http://containertutorials.com/volumes/volume_from_image.html
- https://stackoverflow.com/questions/34809646/what-is-the-purpose-of-volume-in-dockerfile
- https://stackoverflow.com/questions/49633701/docker-volume-empty-after-its-created
- http://jpetazzo.github.io/2015/01/19/dockerfile-and-data-in-volumes/
- https://ru.stackoverflow.com/questions/771085/%D0%A7%D1%82%D0%BE-%D0%B4%D0%B5%D0%BB%D0%B0%D0%B5%D1%82-%D0%B8%D0%BD%D1%81%D1%82%D1%80%D1%83%D0%BA%D1%86%D0%B8%D1%8F-volume-%D0%B2-dockerfile
- docker/compose#3211
- https://stackoverflow.com/questions/29924843/how-do-i-set-hostname-in-docker-compose
This file contains 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
from __future__ import annotations | |
import typing as ty | |
import abc | |
class ModelMeta(abc.ABCMeta): | |
def __new__(msc, name, bases, ns): | |
cls = super().__new__(msc, name, bases, ns) | |
try: | |
# We do not need something like To's id here |
This file contains 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 heapq | |
import asyncio | |
class EventSimulator(asyncio.AbstractEventLoop): | |
'''A simple event-driven simulator, using async/await''' | |
def __init__(self): | |
self._time = 0 | |
self._running = False | |
self._immediate = [] |