Section 54. Trust funds, including cemetery perpetual care funds, unless otherwise provided or directed by the donor of the funds, shall be deposited in: a trust company, co-operative bank or savings bank, if the trust company or bank is organized or exists under the laws of the commonwealth or any other state or may transact business in the commonwealth and has its main office or a branch office in the commonwealth; a national bank, federal savings bank or federal savings and loan association, if the bank or association may transact business and has its main office or a branch office in the commonwealth; provided, however, that a state-chartered or federally-chartered bank shall be insured by the Federal Deposit Insurance Corporation or its successor or invested by cities and towns in participation units in a combined investment fund under section 38A of chapter 29 or in bonds or notes which are legal investments for savings banks. Cities and towns having such funds in the custody of the treasurer in an aggregate amount in excess of two hundred and fifty thousand dollars may also invest such funds in securities, other than mortgages or collateral loans, which are legal for the investment of funds of savings banks under the laws of the commonwealth; provided, that not more than fifteen per cent of any such trust funds shall be invested in bank stocks and insurance company stocks, nor shall more than one and one-half per cent of such funds be invested in the stock of any one bank or insurance company. This section shall not apply to the city of Boston.