Peel and cut the pineapple and ginger into pieces. Place it together with water and sugar in a food processor and mix until smooth. Pour it into a sauce pan and boil it over medium heat for about 45 minutes, until you get a syrupy consistency. Sieve and discard the pulp. Let it cool completely in the fridge.