A shipping container in a remote corner of a Canadian oil field is churning out an unlikely byproduct: bitcoin.

Inside the container, high-powered computers generating new units of the cryptocurrency run with hardly any human supervision; they just need power—lots of it.

In what seems a perfect marriage of supply and demand, that power is...