I believe you want something like:
chart.colors(d3.scale.category20b());
to assign a color to each bar. If you want the color that's selected to be based of the value of the bar's data:
chart.colorAccessor(function(d, i){return i;})
These methods and more are documented here: https://github.com/dc-js/dc.js/blob/master/web/docs/api-latest.md#color-mixin