- Sql Server Configuration Manager
- Sql Server Network Configuration
- Protocols for MSSQLSERVER
- TCP/IP Enabled (yes)
- Restart Sql Server
- Control Panel\System and Security\Windows Firewall > Advanced Settings
- Inbound Rules > New Rule
-- http://www.sql-server-helper.com/sql-server-2008/convert-latitude-longitude-to-geography-point.aspx | |
UPDATE [Table1] | |
SET [GeoLocation] = geography::STPointFromText('POINT(' + CAST([Longitude] AS VARCHAR(20)) + ' ' + CAST([Latitude] AS VARCHAR(20)) + ')', 4326) |
## If error installing ffmpeg = "yasm/nasm not found or too old" | |
## http://www.sthshare.com/wordpress/yasmnasm-not-found-or-too-old-on-linux-servercenots.html | |
# wget http://www.tortall.net/projects/yasm/releases/yasm-1.3.0.tar.gz | |
# tar -xvf yasm-1.3.0.tar.gz | |
# cd yasm-1.3.0 | |
# ./configure | |
# make | |
# make install | |
## http://superuser.com/questions/160443/software-to-speed-up-playback-of-mp4-files |
# cd to this directory | |
weasyprint index.html report.pdf |
from fpdf import FPDF | |
PORTRAIT_FULL_WIDTH = 190 | |
LANDSCAPE_FULL_WIDTH = 277 | |
MAX_ROWS = 57 | |
LEFT_MARGIN = 10.00125 | |
pdf = None | |
def main(): | |
global pdf |
# Tony Meyer: http://stackoverflow.com/questions/68335/how-do-i-copy-a-file-to-a-remote-server-in-python-using-scp-or-ssh | |
import os | |
import paramiko | |
ssh = paramiko.SSHClient() | |
ssh.load_host_keys(os.path.expanduser(os.path.join("~", ".ssh", "known_hosts"))) | |
ssh.connect(server, username=username, password=password) | |
sftp = ssh.open_sftp() | |
sftp.put(localpath, remotepath) |
import os | |
import glob | |
import time | |
import shutil | |
def main(): | |
appPath = '/etc/appName' | |
date = str(int(time.time())) | |
folders = glob.glob('staging/*') |
# Get time | |
timedatectl | |
# Get logs since a time | |
sudo journalctl --since 12:30 |
import os | |
def main(): | |
systemdText = """ | |
[Unit] | |
Description=API Server | |
[Service] | |
ExecStart=/usr/bin/python /etc/appName/api/apiServer.py | |
Restart=always |