Nginx cache directory error

I just want to write down an error that I came through the other day, I could say this is one of that kind, stupid errors, however here we go:

I setted up while ago a ngixn web site, everything works perfectly at that moment, however month after I decide to do a small change:

Rewrite the URL to remove the date params

And when I restarted the server I found out it won't came alive again because the following error:

2014/11/24 14:24:38 [emerg] 14869#0: mkdir() "/var/cache/nginx" failed (2: No such file or directory)  

For some reason my cache configuration was trying to write info on a directory that doesn't exist.

##
# Cache Proxy
##
proxy_cache_path /var/cache/nginx levels=1:2 keys_zone=STATIC:10m inactive=24h max_size=512m;  
proxy_temp_path /var/tmp;