The public IP address of an instance changes on every restart because AWS dynamically assigns them from their pool of public IP addresses. If you require a persistent public IP address, you should use an elastic IP address.
To use an elastic IP address, you must allocate it for use with the VPC, and then associate that elastic IP address with a private IP address specified by the network interface attached to the instance.