Startup Instructions
Welcome!
Welcome to your new wiki! This is a static page with a list of items you *must* do before you can access your wiki. The last thing you will do is rename this page so you can access your actual wiki.
Fix your configuration file
If you’re seeing this page, then you have successfully launched the AMI and it’s running on your server. The wiki configuration file expects a few pieces of information that only you can give it.
You will need to log-in to the Unix command-line interface(CLI) to make these changes. When you launched your instance from the AMI, you created a key pair. You will reference this key pair when using SSH to connect.
You can find a connection guide by clicking the connect button after selecting your instance from the list on your AWS EC2 dashboard.
Once you are connected to your CLI, you will need to edit the LocalSettings.php file.
First, change directory (cd) to the web server directory:
cd /var/www/html
Now, list all the files:
ls -al
This is your wiki code, the actual information in your pages will be stored in a database, more on that later.
Open a simple text editor and tell it to open the LocalSettings.php file with this command:
sudo nano LocalSettings.php
If you have never used a simple text editor, you may want to read up on it. Just Google "unix nano".
Let's change the name of your wiki first. Look for this section near the top:
$wgSitename = "YourWikiName"; $wgMetaNamespace = "YourWikiName";
Change these to the name of your wiki.
Next, a few lines down is this:
## The protocol and server name to use in fully-qualified URLs $wgServer = "http://00.00.00.00";
This must be changed to the IP address of your server. You can find this on your Instances page in your AWS console. Click on your instance, and the info will show up below it.
You can save the file at this point by using ctrl-x and entering a "y" for yes. At this point, your wiki should load if you point your web browser to the ip address. Please note you will have to specify a plain http connection, not https. Your browser will probably warn you the connection is unsecure, it's OK we will change this later to be secure.
As long as your wiki page loads, you're good so far! But we're not out of the woods yet, all the passwords and secret stuff needs to be changed as anyone who has this snapshot knows all of your passwords(not secure!)
Securing your server
Here is a list of things to change:
- MySQL (or MariaDB):
- Root user password
- Database name
- create a new database user
- Database user password
- Grant all privileges on database to new user
- Delete wikiuser
- edit LocalSettings "#Database Settings" section to reflect these changes
- Admin user password
- Use the php script ChangePassword.php in the /maintenance directory to change the Admin password so you can log-in to the wiki.