Two definitions of morality:
– Recognition of the distinction between good and bad or between right and wrong.
– A set of social rules, customs, traditions, beliefs or practices which specify proper, acceptable forms of conduct.
For simplicity’s sake, let’s call the first definition value-based, and the second definition rule-based.
 From Wiktionary.