Entity reference field in a block So I have a custom content type where I use an entity reference to store a node and then display it a a teaser on a page.

I now want to achieve a similar thing with a block. I've create a basic block module where it outputs HTML, but now want to allow a user to configure it in admin.

I want to create a select list in the configuration where a user can choose a node of content type 'X' and it will save this preference. Then in the block module view I want to retrieve this value.

How would I go about this?
Something along the lines of Bean or Boxes would probably be your best options (assuming one of the many Node in block modules aren't good enough).

I've got more experience with Bean, so I'll give a general idea based on that.

Both modules allow blocks to be created as fieldable entities.  You should simply be able to add an entity reference field as one of the fields on your block and set it up to display in exactly the same way as you currently do with your node/entity reference combo.

Looking through the issue queue, these modules may merge at some point, but I couldn't see anything that says which one is better.  My personal preference is Bean.