Put woff, eot, svg and ttf files in app/assets/fonts
and font_name.scss in app/assets/stylesheets folder
Don't forget the .scss extension and asset_path helper
font-url( asset_path('file.woff')) format('woff')
And this in assets.rb:
Rails.application.config.assets.precompile << /\.(?:svg|eot|woff|ttf)$/
Pe-icon-7-stroke.css example:
@font-face {
font-family: 'Pe-icon-7-stroke';
src:url(asset_path('Pe-icon-7-stroke.eot?-2irksn'));
src:url( asset_path('Pe-icon-7-stroke.eot?#iefix-2irksn')) format('embedded-opentype'),
font-url( asset_path('Pe-icon-7-stroke.woff?-2irksn')) format('woff'),
font-url(asset_path('Pe-icon-7-stroke.ttf?-2irksn')) format('truetype'),
font-url(asset_path('Pe-icon-7-stroke.svg?-2irksn#Pe-icon-7-stroke')) format('svg');
font-weight: normal;
font-style: normal;
}