ARCHIVED: Migrate your IU Web Framework site to Sitehost
On this page:
- Overview
- 1. Create a new Sitehost account
- 2. Update Webserve paths in code chunks
- 3. Update code managed in the WCMS
- 4. Update Transports
- 5. Update Destinations
- 6. Update the Settings block
- 7. Run the IU Web Framework setup script on Sitehost-test and Sitehost
- 8. Publish your site to Sitehost's test server and verify it works
- 9. Publish your site to Sitehost's production server and verify it works
- 10. Request a virtual host transfer
Overview
Follow the steps outlined below to migrate your IU Web Framework site from Webserve to the Sitehost service.
The following is not intended for IU Web Framework sites that have been customized, integrated with applications outside the WCMS, protected with custom .htaccess
files, or had scheduled tasks (cron jobs) set up. To determine if your site has been customized and to migrate a site with customizations, see ARCHIVED: Migrate your customized IU Web Framework site to Sitehost.
If your site doesn't use the IU Web Framework, follow the ARCHIVED: Sitehost migration guide instead.
1. Create a new Sitehost account
Verify that Two-Step Login (Duo) is enabled for the group account for which you want to request Sitehost; see Use Two-Step Login (Duo) with a group account.
- Go to Enterprise Web Technical Services and click .
If prompted, log in with your IU username and passphrase.
- You will see a list of group accounts that you own. Click .
- Read the User Agreement, provide the information requested at the end, and then click . The request will be sent to Web Services Support for approval. You will receive email confirmation that the account was created.
2. Update Webserve paths in code chunks
A code chunk is used by an IU Web Framework site to output code such as PHP, JavaScript, or HTML.
If any of your site's code chunks contain hard-coded paths to other files on Webserve, you'll need to update these code chunks to reflect the new file paths used by Sitehost. Replace <account>
with your group account name when performing the steps below:
- Replace
/ip/<account>/www
and/ip/<account>/wwws
with/groups/<account>/web
- Replace
/ip/<account>/
with/groups/<account>/
- Replace
www
andwwws
withweb
If you have a MachForm installation on your Webserve account, see MachForm migration instructions on GitHub.
3. Update code managed in the WCMS
In the _php
folder, edit the .htaccess
file and delete the Satisfy Any
and Allow from all
directives, as they are not used in Apache 2.4.
4. Update Transports
Each of your site's Transports must be updated using the WCMS Manager Tools to reflect new Transport names, host names, and server directories.
- Log into the WCMS Manager Tools.
- Go to .
- Expand the accordion for the site you are migrating to show its Transports.
- Click the pencil icon on the upper right of a Transport to edit it using the steps below:
For the Transport labeled "TEST":
- Set "Transport Name" to
Sitehost – Test
. - Set "Host Name" to
ssh.sitehost-test.iu.edu
. - Set "Server Directory" to
/groups/<account>/
.
For the Transport labeled "LIVE" or "PRODUCTION":
- Set "Transport Name" to
Sitehost – Production
. - Set "Host Name" to
ssh.sitehost.iu.edu
. - Set "Server Directory" to
/groups/<account>/
. - Click to save your changes.
- Set "Transport Name" to
5. Update Destinations
Each of your site's Destinations must be updated in the WCMS to reflect the new directory paths in Sitehost. You should update current Destinations. Creating new Destinations will require updating Content Types. Update each Content Type by adding any new Destinations to the Content Type's Publishable Options.
- Log into your site in the WCMS.
- Go to .
- Click
For the Destination labeled "TEST":
- Right-click the and click .
- Set "Directory" to
web
. - Click to save your changes.
- Right-click the and click .
- Set "New Destination Name" to
Sitehost - Test
. - Click to save your changes.
For the Destination labeled "LIVE" or "PRODUCTION":
- Right-click the and click .
- Set "Directory" to
web
. - Click to save your changes.
- Right-click the and click .
- Set "New Destination Name" to
Sitehost - Production
. - Click to save your changes.
in the left sidebar.
6. Update the Settings block
You'll need to update the staging URL in your site's Settings block in the WCMS. The Settings block is located toward the bottom of your site's root folder.
- Log into your site in the WCMS if you're not already logged in.
- Go to .
- Right-click the block in the left-hand file explorer and click .
- Set "Staging URL" to
<account>.sitehost-test.iu.edu
. - Click to save your changes.
7. Run the IU Web Framework setup script on Sitehost-test and Sitehost
The IU Web Framework setup script prepares your Sitehost-test and Sitehost account to serve your IU Web Framework website. Follow the directions below to run the setup script.
For your test Sitehost account:
- Log into IU's VPN if you're off campus.
- SSH into your site using the command line or a tool like PuTTY, replacing
<username>
with your personal IU username (not the group account name):ssh <username>@ssh.sitehost-test.iu.edu
. - Enter your personal passphrase (not the passphrase for the group account).
- Confirm your attempt to log in with Duo.
- Run the following command, replacing
<account>
with the group account name:become <account>
. - Enter your IU passphrase when prompted.
cd
into the web directory.- Run the following command:
/groups/iuframe/bin/setup_framework
. - When prompted, enter your test site's virtual host URL, replacing <account> with the group account name:
<account>.sitehost-test.iu.edu
. - Run the following command to list all files and directories:
ls -a
. - Verify the setup script created the following files and directories:
gwassets/
.htaccess
.user.ini
robots.txt
For your production Sitehost account, follow the steps above, replacing instances of sitehost-test
in URLs with sitehost
. In step 9, replace the URL <account>.sitehost-test.iu.edu
with your virtual URL (for example, iuframe.iu.edu
). If your site does not have a virtual host, enter the following URL, replacing <account>
with the group account name: <account>.sitehost.iu.edu
.
8. Publish your site to Sitehost's test server and verify it works
Publish your site to Sitehost's test server to confirm your site is working as expected before publishing to Sitehost's public-facing production server.
- Log into your site in the WCMS if you're not already logged in.
- Go to .
- Right-click the root folder of your site in the left-hand file explorer and click .
- Check the box labeled "Sitehost - Test".
- Uncheck the box labeled "Sitehost - Production".
- Click .
- Visit
<account>.sitehost-test.iu.edu
to verify your site is working as expected. Contact Web Services Support if you're unable to get your site to work on Sitehost's test server.
9. Publish your site to Sitehost's production server and verify it works
To publish your site to Sitehost's production server, follow the steps below:
- Log into your site in the WCMS if you're not already logged in.
- Go to .
- Right click on the root folder of your site and click .
- Uncheck the box labeled "Sitehost - Test".
- Check the box labeled "Sitehost - Production".
- Click .
Testing your site on the Sitehost production server requires adding your virtual host to Sitehost without requesting a DNS change. If you are not using a virtual host, then you can view your site on Sitehost by going to <account>.sitehost.iu.edu
.
Make a virtual host request
- Go to Enterprise Web Technical Services and click .
If prompted, log in with your IU username and passphrase.
- After logging in, you will see a list of group accounts you own. Click for the group account for which you want to request a virtual host.
- Click on the left menu.
- Click .
- Complete the form. Check the box labeled "This currently points to another server" if your virtual host is currently pointing to another server such as Webserve. If you check this box, the DNS change will not take place until you contact Web Services Support to request a virtual host DNS transfer.
- Click .
You will receive a confirmation email when your virtual host request is approved. Allow up to 30 minutes from receiving the confirmation email for the virtual host to be installed on Sitehost.
Visit your site using a test URL
- In a web browser, go to
https://<website_url>/sitehostmigrationtest
, replacing<website_url>
with your site's virtual host URL (for example,iuframe.iu.edu
). - You will see an intermediate page that says you are about to view your site on the Sitehost production server. Click the virtual host link to proceed.
You will now see your site as rendered by the Sitehost servers. The site title will begin with "Testing - ". Repeat the two steps listed above if clicking the link on the intermediate page does not take you to your site as rendered by the Sitehost servers.
10. Request a virtual host transfer
When you have finished the above steps:
- Log into Enterprise Web Technical Services with your personal IU username and passphrase.
- Click .
- Find the account associated with the virtual host, and then click the link for the virtual host.
- At the bottom, click .
Also, you may contact Tier 2 to send the account names and site URLs that you migrated.
Site migrations require a DNS change, which will take effect by 8am on the following business day after you receive confirmation of the request.
When the DNS changes take effect, Webserve administrators will lock your Webserve account. If you need your account unlocked, contact Tier 2.
This is document ayxs in the Knowledge Base.
Last modified on 2023-05-08 15:54:21.