In the Parasha Vayekhi (ויחי – and he lived), the last parasha of the book of Genesis (47:28-50:26), and in the corresponding haftarah (Kings I 2:1-12), Yaakov and King David, before their death, give instructions for the future and bless their sons. Yaakov transfers his authority to Yehouda and David transfers it to Chlomo. They both promise the deliverance of the people of Israel.
In the first book of Kings, chapter 2, verse 3, David says to Chlomo:
אִם-יִשְׁמְרוּ בָנֶיךָ אֶת-דַּרְכָּם לָלֶכֶת לְפָנַי בֶּאֱמֶת, בְּכָל-לְבָבָם וּבְכָל-נַפְשָׁם: לֵאמֹר–לֹא-יִכָּרֵת לְךָ אִישׁ, מֵעַל כִּסֵּא יִשְׂרָאֵל.
If your sons are attentive to their way, walking before me with truth, with all their heart and with all their soul: saying–no man shall be cut off from you, from the throne of Israel.
The Tomb of David, located on Mount Zion behind the walls of the old city of Jerusalem, is in the ground floor room in a building built by the Crusaders on an ancient synagogue from the Roman era. As mentioned in the first book of Kings (2:10)
וַיִּשְׁכַּב דָּוִד, עִם-אֲבֹתָיו; וַיִּקָּבֵר, בְּעִיר דָּוִד. {פ}
David slept with his fathers, and he was buried in the city of David.