https://www.railstutorial.org/book/beginning#sec-rails_server
I have reached this step, and I\'m using the cloud9 environment. When I run the server as per Listing 1.7 o
$ rails server -b $IP -p $PORT
Cloud9 uses the special environment variables $IP and $PORT to assign the IP address and port number dynamically. If you want to see the values of these variables, type echo $IP or echo $PORT at the command line.
It's likely that if you wait a few minutes (not more than 2), your OS will free up the port. If not, use a random port number over about 5,000 every time you run rails server, e.g.
$ rails server -b $IP -p 6789
Or, because your IDE is so sucky, you might consider using a different IDE.