title: data directory was initialized by PostgreSQL version 13, which is not compatible with this version 14.0
body: <p>I have downloaded Portainer onto my server and created a PostgreSQL database in a container there.
  Today I could no longer get access to the database. The log shows a message that there is a version problem.</p>
  <p>I already read into some similar issues like <a href="https://stackoverflow.com/questions/44221938/postgres-container-crashes-with-database-files-are-incompatible-with-server-af">Postgres container crashes with `database files are incompatible with server` after container&#39;s image has been updated to the latest one</a> and <a href="https://stackoverflow.com/questions/44221938/postgres-container-crashes-with-database-files-are-incompatible-with-server-af">Postgres container crashes with `database files are incompatible with server` after container&#39;s image has been updated to the latest one</a></p>
  <p>and the solutions <code>brew postgresql-upgrade-database</code> did not work.</p>
  <p>What can I do?</p>
  <p>LOG</p>
  <pre><code>2021-10-03  [1] FATAL:  database files are incompatible with server
  2021-10-03  [1] DETAIL:  The data directory was initialized by PostgreSQL version 13, which is not compatible with this version 14.0 (Debian 14.0-1.pgdg110+1).
  
  PostgreSQL Database directory appears to contain a database; Skipping initialization
  </code></pre>
  <p>I also found this <a href="https://www.postgresql.org/docs/14/upgrading.html" rel="noreferrer">https://www.postgresql.org/docs/14/upgrading.html</a> but the commands didn't work. Do I need to do this in the container somehow, or what commands will work to keep it running in the container?</p>