Skip to content

Instantly share code, notes, and snippets.

View shirhatti's full-sized avatar

Sourabh Shirhatti shirhatti

View GitHub Profile
# Copyright (c) .NET Foundation
# Licensed under the MIT License
author "Sourabh Shirhatti"
start on runlevel [2345]
stop on runlevel [016]
script
exec start-stop-daemon --start --make-pidfile --pidfile /var/run/aspnet5webserver.pid --chuid aspnet --exec /home/shirhatti/.dnx/runtimes/dnx-mono.1.0.0-beta6/bin/dnx /home/shirhatti/output/approot/src/WebApplicationBasic/ kestrel >> /var/log/aspnet5webserver.sys.log 2>&1
end script
server {
listen 80;
location / {
proxy_pass http://127.0.0.1:5000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
events {
worker_connections 768;
# multi_accept on;
}
http {
##
# Basic Settings
##
➜ vagrant vagrant up --provider=azure
/Users/shirhatti/.vagrant.d/gems/gems/vagrant-azure-1.2.0/lib/vagrant-azure/config.rb:106:in `finalize!': undefined method `random_string' for Azure::Core::Utility:Module (NoMethodError)
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/plugins/kernel_v2/config/vm.rb:475:in `block in finalize!'
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/plugins/kernel_v2/config/vm.rb:440:in `each'
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/plugins/kernel_v2/config/vm.rb:440:in `finalize!'
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/lib/vagrant/config/v2/root.rb:50:in `block in finalize!'
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/lib/vagrant/config/v2/root.rb:49:in `each'
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/lib/vagrant/config/v2/root.rb:49:in `finalize!'
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/lib/vagrant/config/v2/loader.rb:21:in `finalize'
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/lib/vagrant/config/loader.rb:1
@shirhatti
shirhatti / stacktrace
Created August 13, 2015 17:08
Stacktrace
/Users/sourabhshirhatti/.vagrant.d/gems/gems/vagrant-azure-1.1.1/lib/vagrant-azure/config.rb:106:in `finalize!': undefined method `random_string' for Azure::Core::Utility:Module (NoMethodError)
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/plugins/kernel_v2/config/vm.rb:475:in `block in finalize!'
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/plugins/kernel_v2/config/vm.rb:440:in `each'
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/plugins/kernel_v2/config/vm.rb:440:in `finalize!'
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/lib/vagrant/config/v2/root.rb:50:in `block in finalize!'
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/lib/vagrant/config/v2/root.rb:49:in `each'
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/lib/vagrant/config/v2/root.rb:49:in `finalize!'
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/lib/vagrant/config/v2/loader.rb:21:in `finalize'
from /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/lib/vagrant/config/loader.rb:158:in `load'
from /opt/vagrant/e
@shirhatti
shirhatti / Notes.md
Last active August 29, 2015 14:10
382V Notes for November 11

#EE382V/379K: Multicore Computing

##Agenda 0. Communicating Sequencer Processes 0. Temporal Logic

##Backus-Naur Form

  • Developed to describe the Syntax of ALGOL
  • Context-free grammar used describe the syntax of programming langauages.
azureuser@shirhatti:~$ mcs -r System.Net.Http.dll test.cs
warning CS8029: Compatibility: Use -r:LIBRARY instead of -r library
azureuser@shirhatti:~$ mono test.exe
Unhandled Exception:
System.AggregateException: One or more errors occurred ---> System.Net.WebException: Error: SendFailure (Error writing headers) ---> System.Net.WebException: Error writing headers ---> System.IO.IOException: The authentication or decryption has failed. ---> Mono.Security.Protocol.Tls.TlsException: Invalid certificate received from server. Error code: 0xffffffff800b010a
at Mono.Security.Protocol.Tls.Handshake.Client.TlsServerCertificate.RemoteValidation (Mono.Security.Protocol.Tls.ClientContext context, AlertDescription description) [0x00000] in <filename unknown>:0
at Mono.Security.Protocol.Tls.Handshake.Client.TlsServerCertificate.validateCertificates (Mono.Security.X509.X509CertificateCollection certificates) [0x00000] in <filename unknown>:0
at Mono.Security.Protocol.Tls.Handshake.Client.TlsServerCertificate.Proces
@shirhatti
shirhatti / error.log
Created August 14, 2014 23:47
KPM restore fails
azureuser@shirhatti:~/tmp/MvcApplication1$ kpm restore
Restoring packages for /home/azureuser/tmp/MvcApplication1/project.json
Attempting to resolve dependency MvcApplication1 >= 0.1-alpha-SNAPSHOT
Attempting to resolve dependency Microsoft.AspNet.Diagnostics >= 1.0.0
Attempting to resolve dependency Microsoft.AspNet.Hosting >= 1.0.0
Attempting to resolve dependency Microsoft.AspNet.Mvc >= 6.0.0
Attempting to resolve dependency Microsoft.AspNet.Server.WebListener >= 1.0.0
Attempting to resolve dependency Kestrel >= 1.0.0
Attempting to resolve dependency mscorlib >=
Attempting to resolve dependency System >=
@shirhatti
shirhatti / gist:24b8a0910e003c73d20a
Created August 8, 2014 18:41
Launch Sublime from Powershell
Set-Alias sublime 'C:\Program Files\Sublime Text 3\sublime_text.exe'
{
"ProjectName": "DesignTimeHostDemo",
"Configurations": [
{
"FrameworkName": "net45",
"LongFrameworkName": ".NETFramework,Version=v4.5",
"FriendlyFrameworkName": ".NET Framework 4.5",
"CompilationSettings": {
"LanguageVersion": 6,
"Defines": [