Skip to content

Instantly share code, notes, and snippets.

View ZhijieWang's full-sized avatar

Bill (Zhijie) Wang ZhijieWang

  • San Francisco
  • 12:37 (UTC -12:00)
View GitHub Profile
@tweakoz
tweakoz / gist:a68407be79e3cea85c3cb0744c9d4505
Last active June 20, 2024 14:27
Mellanox IPOIB setup Debian/Ubuntu/Netplan/Systemd
################################
# install mlnxofed driver
################################
download: https://www.mellanox.com/products/infiniband-drivers/linux/mlnx_ofed
################################
# put HCA's in IPOIB mode
################################
mst start # start mellanox software tools
@jwo
jwo / registrations_controller.rb
Created September 30, 2011 23:11
API JSON authentication with Devise
class Api::RegistrationsController < Api::BaseController
respond_to :json
def create
user = User.new(params[:user])
if user.save
render :json=> user.as_json(:auth_token=>user.authentication_token, :email=>user.email), :status=>201
return
else