If your website presents ("is stuck in") pset7 after you start apache for pset8, do a ctrl-F5 in the browser, that will reload the correct website.
(author's note: after rereading the question I realized the above may be the real problem, however since I already typed the below.....:)
There seems to be a bug in /etc/profile.d/ide50.sh that is causing this /etc/init.d/apache2: 18: /etc/profile.d/ide50.sh: [[: Permission denied
message. It is just noise. You'll have to ignore the noise until the bug is fixed. In the meantime, you need to pay attention to the lines that don't contain the error message (the signal).
Notice this line * Stopping web server apache2
. It indicates that the web server is stopped. To verify that, run apache50 status
. You will get a result like this (emphasis added).
~/workspace/pset7/ $ apache50 status
/etc/init.d/apache2: 18: /etc/profile.d/ide50.sh: [[: Permission denied
/etc/init.d/apache2: 18: /etc/profile.d/ide50.sh: [[: Permission denied
/etc/init.d/apache2: 18: /etc/profile.d/ide50.sh: [[: Permission denied
Apache is not running.
~/workspace/pset7/ $
Similarly, a start will give something like this:
~/workspace/pset7/ $ apache50 start public
/etc/init.d/apache2: 18: /etc/profile.d/ide50.sh: [[: Permission denied
/etc/init.d/apache2: 18: /etc/profile.d/ide50.sh: [[: Permission denied
/etc/init.d/apache2: 18: /etc/profile.d/ide50.sh: [[: Permission denied
Setting Apache's document root to /home/ubuntu/workspace/pset7/public ...
/etc/init.d/apache2: 18: /etc/profile.d/ide50.sh: [[: Permission denied
/etc/init.d/apache2: 18: /etc/profile.d/ide50.sh: [[: Permission denied
/etc/init.d/apache2: 18: /etc/profile.d/ide50.sh: [[: Permission denied
* Starting web server apache2
/usr/sbin/apache2ctl: 18: /etc/profile.d/ide50.sh: [[: not found
*
/etc/init.d/apache2: 18: /etc/profile.d/ide50.sh: [[: Permission denied
Apache started successfully!
Your site is now available at https://ide50-username.cs50.io
~/workspace/pset7/ $
All things being equal, you will now be able to access your web site. This is true for pset7 and pset8. The bug appears to be a result of the new help50 utility added recently.