CS Web Installer Sucks!, but I fixed it.
However cool Community Server is, it's Web Installer until 3 hours ago
was my model for the way I wanted to make Rainbow's Web Installer.
Now I may be a little pissed because I spent 3 hours on a very stupid little issue.
When using the Community Server Web Installer, in the 3rd step, it asks the user for
the database server, username, password, windows auth or sql.
In the 4th step, if the information from the previous step is correct,
the user is asked to select a databae from a dropdown list.
I noticed that the dropdown list was being populated, but when I clicked next, the installer gave me a message:
Number:18456:logon failed for user 'sa'.
I googled this and found out on Community Server's site that the way to
"fix" this is to give Network Service and ASPNET pemissions as DBO to
the database. WHAT?!
Why should I have to do that? I don't want to give a remote machine's
network service account access to a database serving many users.
The reason that network service needs access is because at the
SelectDB stage, db_password.Text is empty as a string. ( in
Installer/Default.aspx )
I was playing around with
Default.aspx to see if I can learn how they made the web based installer
and no matter what I tried, it still gave me that horrible, stupid
error.
I asked myself, how the heck is this code
connecting to the database server, enumerating a list of available
databases upon connecting and NOT connect to the database afterward.
When I tried to print the assembled connection string in the
errorMessage Literal, it would have ALL of the values (db server,
db username, database) except for db password.
I don't know if this
is an ASP.NET bug, but to fix the problem, I made db_password a regular
textbox ( with no password mode) and all of a sudden the application
was working.
I am continuing to make a Rainbow Web Installer
that WONT require network service or ASPNET to access the database. I
really don't care if the user will see the DB password in the web
browser. The user experience of someone being able to install an
application without doing anything except putting in DB details over
the web is more important to me.