-
python setup.py test
(is it necessary now if we reject Travis-CI?) -
getopts
insetup.sh
- using Vagrant to set up & compile wheel dependencies of GWM (at least provide some shell script to do it, Vagrantfiles aren't necessary)
- installing dependencies &
ganeti_webmgr
from OSUOSL FTP mirrors -
--upgrade
option forsetup.sh
(or something clever like recognizing existing virtual environments) - GWM tools package & default configuration
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 os | |
import random | |
import string | |
from django.core.exceptions import ImproperlyConfigured | |
def random_secret(n=20): | |
"Create randomly selected character sequence." | |
return "".join(random.sample(string.digits + string.printable, n)) |
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
lsb_release='/usr/bin/lsb_release' | |
architecture=`uname -i` | |
os='unknown' | |
if [ -x $lsb_release ]; then | |
# we pull in default values, should work for both Debian and Ubuntu | |
os=`$lsb_release -s -i | tr "[:upper:]" "[:lower:]"` | |
if [ "$OS" == "centos" ]; then | |
os_codename=`$lsb_release -s -r | sed -e 's/\..*//'` |
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
Show hidden characters
{ | |
"always_show_minimap_viewport": true, | |
"bold_folder_labels": true, | |
"caret_style": "solid", | |
"color_scheme": "Packages/Monokai Extended/Monokai Extended.tmTheme", | |
"draw_minimap_border": true, | |
"enable_telemetry": false, | |
"ensure_newline_at_eof_on_save": true, | |
"folder_exclude_patterns": | |
[ |
(You can watch the progress here.)
Proposed setup.sh
installation script for GWM would:
- detect user's operating system (Debian or CentOS)
- install system dependencies (Python,
python-virtualenv
) via user's OS default package managers (apt
oryum
) [this will requiresudo
] - create virtual environment in local directory (or in directory specified by user)
During Ganeti Web Manager refactoring one huge application (ganeti_web
) was
turned into many smaller applications (actual list: authentication
,
clusters
, django_test_tools
, ganeti_web
, jobs
, muddle
,
muddle_users
, nodes
, utils
, virtualmachines
, vm_templates
).
However, over 19 migrations are still placed in ganeti_web
application.
How to make them work? My idea is as follows:
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
$ sudo /bin/false | |
[sudo] password for piotr: | |
There must be cure for it! | |
[sudo] password for piotr: | |
And with that remarks folks, the case of the Crown vs yourself was proven. | |
[sudo] password for piotr: | |
Where did you learn to type? | |
sudo: 3 błędne próby wprowadzenia hasła |
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
#!/usr/bin/env python | |
# coding: utf-8 | |
import os | |
import datetime | |
import time | |
import pynotify | |
MAX_UPTIME = 60 * 60 # in seconds: 1 hour | |
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
#!/usr/bin/env python | |
import requests | |
from datetime import date | |
import re | |
def main(): | |
url1 = "http://corporate.visa.com/pd/consumer_services/consumer_ex_rates.jsp" | |
url2 = "http://corporate.visa.com/pd/consumer_services/consumer_ex_results.jsp" |