Rails build fails: schema change not deployed

The schema deploy on my Rails app is failing because the postgres uuid-ossp extension is not being included.

I have added the line to include it to my schema.rb file and committed it, but when I connect to the test machine using ssh and check the schema file, it is the previous version without the extension. This applies even after rebuilding without cache.

It is not clear to me how I can fix this.