Skip to content


Subversion checkout URL

You can clone with
Download ZIP
A leaderboard and chat sample that demonstrates how you can combine ASP.NET and Node.js in the same web application running on Windows Azure Web Sites.
JavaScript C# CSS
Branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.

Tankster Command: Leaderboard & Chat Sample

The leaderboard and chat sample demonstrates how you can combine ASP.NET and Node.js in the same web application. The application consists of the following components.

  • An ASP.NET MVC 4 leaderbaord application using Entity Framework Code First.
  • A Node.js server that leverages Socket.IO to handle real-time communication between chat users.
  • A Redis store to persist Socket.IO connections and messages, permitting to scale out the chat services.


Running the Sample Locally

  1. Open the TanksterCommand.sln solution.
  2. Compile the solution. The NuGet packages dependencies will be automatically downloaded and installed.
  3. Create a Facebook Application and set the FacebookAppId and FacebookAppSecret in the web.config file. You must also set the Facebook Site Url for you Facebook application to the URL where your site will run locally, for example http://localhost:23595. See this post or Facebook's article for more details on setting up a Facebook app.

    <add key="FacebookAppId" value="..." />
    <add key="FacebookAppSecret" value="..." />
  4. Press F5 to run the sample. Log in and try the Chat view.

Deploying the Application to Windows Azure

  1. Create a Windows Azure Web Site with a Database and download the publish profile. See this tutorial for more details.
  2. After you have downloaded the publish profile open the project in Visual Studio. Right-click on the TanksterCommand project and click publish.
  3. Import your publish profile and click publish.
  4. Be sure to enable code first migrations in order to setup your database after you deploy.

    Enable Migrations

  5. Click publish and wait for the application to deploy.
  6. After the applciation is published it will open in the browser. You can now login and test the chat.
Something went wrong with that request. Please try again.