LogoLogo
  • FAC Curriculum
  • archive
    • Node & npm introduction
    • developer
      • Programming Paradigms
    • handbook
      • Asking for help
      • Coaching groups
      • Code review
      • Course rules
      • Debugging
      • Employment schedule and material delivered in FAC20
      • GitHub Workflow
      • Glossary or terms
      • Presentation Guidance
      • Equality, Diversity and Inclusion
      • Installation guide
      • Learning circles
      • Mentoring guidance
      • What to expect from your mentors
      • One-day projects
      • Pair programming
      • Portfolio
      • Questions for problem solving
      • Progress Logs
      • Final project report
      • Managing software projects
      • Project Presentations
      • Project roles
      • Projects
      • Retrospectives
      • Role Circles
      • Safeguarding policy
      • Technical Spikes
      • System requirements
      • Tech for Better
      • User Manuals
      • Wellbeing Support
      • project-docs
        • What makes a mentor?
        • Product Handover
        • Sprint Planning
        • Tech for Better Presentations
        • User Research & Usability Testing
    • foundation
      • full-stack
        • Learning Outcomes
        • project
      • testing
        • project
        • spikes
  • docs
    • Contributing to the curriculum
    • Curriculum intent
    • Curriculum process
  • src
    • About our curriculum
    • course
      • Code of Conduct
      • Docker
      • .NET and Umbraco
      • Getting started
      • Founders and Coders coursebook
      • KSB's
      • Mini projects
      • Revision checklist
      • Svelte
      • TypeScript
      • handbook
        • Software Developer Handbook
        • Software Foundation Handbook
      • precourse
        • Before you start the course
        • Installation List
      • syllabus
        • developer
          • app
            • learning-outcomes
            • project
            • schedule
            • spikes
          • introduction
            • learning-outcomes
            • project
            • resources
            • schedule
          • week00-pre-course
            • We'd like you to spend some time before starting the course working on useful fundamentals.
            • spikes
          • week01-project01-basics
            • Employability introduction
            • Homework
            • learning-outcomes
            • Week of September 9th
            • project
            • resources
            • schedule
            • spikes
          • week02-project02-chatbot
            • employability
            • Homework
            • learning-outcomes
            • Week of September 16th
            • project
            • resources
            • schedule
            • spikes
          • week03-project03-server
            • Learning Outcomes
            • Week of September 23th
            • The Amazin' Quizzer API Backend
            • resources
            • schedule
          • week04-project03-frontend
            • learning-outcomes
            • Week of September 30th
            • UI for Quizzer App
            • resources
            • schedule
          • week05-project03-test-deploy
            • Testing and deployment
            • Week of October 7th
            • project
            • resources
            • schedule
          • week06-project04-databases
            • learning-outcomes
            • Week of October 14th
            • project
            • Databases
            • schedule
          • week07-project04-authentication
            • Learning Outcomes
            • Week of October 21st
            • project
            • resources
            • schedule
          • week08-project04-test-deploy
            • Learning Outcomes
            • Week of October 28th
            • project
            • resources
            • schedule
          • week09-reading-week
            • Learning Outcomes
            • overview
            • Project
            • Resources
            • schedule
          • week10-project05-DOTNET-intro
            • Learning Outcomes
            • overview
            • project
            • Resources
            • schedule
          • week11-project05-DOTNET-testing
            • Testing and deployment
            • Week of November 18th
            • project
            • Resources
            • schedule
          • week12-project05-DOTNET-deploy
            • Learning Outcomes
            • Week of November 25th
            • project
            • Resources
            • schedule
            • Spikes
          • week13-TFB-design
            • Learning Outcomes
            • overview
            • Project
            • Resources
            • schedule
            • Design Week Spikes
          • week14-TFB-build
            • Learning Outcomes
            • overview
            • Project
            • DevOps Resources
            • schedule
            • Spikes
          • week15-TFB-build
            • Learning Outcomes
            • overview
            • Project
            • Resources
            • schedule
            • Spikes
          • projects
            • in-house-design
              • Learning Outcomes
              • Project
              • Resources
              • schedule
              • Design Week Spikes
        • foundation
          • Obsolete-full-stack
            • project
          • post-course
            • Homework
            • schedule
        • portfolio
          • fruit-shop
            • learning-outcomes
            • project
            • resources
          • game
            • learning-outcomes
            • project
            • resources
          • hobby-page
            • learning-outcomes
            • project
            • resources
          • movie-data
            • learning-outcomes
            • project
            • resources
          • project-gallery
            • learning-outcomes
            • project
            • resources
          • website
            • learning-outcomes
            • project
            • JavaScript
        • tfb
          • week 1
            • Introduction (45 minutes)
            • Further reading
          • week 10
            • content
            • resources
          • week 11
            • What will we be doing this week?
            • resources
          • week 12
            • What will we be doing this week?
            • Further reading
          • week 2
            • Discover (90 minutes)
            • resources
          • week 3
            • content
            • resources
          • week 4
            • Mapping the user journey (90 minutes)
            • resources
          • week 5
            • Figma Workshop 1 (90 minutes)
            • Further reading
          • week 6
            • Figma Workshop 2 (90 minutes)
            • resources
          • week 7
            • Product pitches & Selection (90 minutes)
            • resources
          • week 8
            • content
            • resources
          • week 9
            • content
            • resources
    • learn
      • DOTNET
        • Introduction to .NET
      • auth
        • Authenticating web apps
      • database
        • Persisting data with SQLite and Node
      • dotnet-two
        • Dependency injections and interfaces in .NET
      • form-validation
        • Form validation
      • react
        • Building client-side apps with React
      • server
        • HTTP servers with Node & Express
      • typescript
        • TypeScript
    • mentoring
      • design-week
        • Analysis Workshop
        • Code planning
        • Definition Workshop
        • Discovery Workshop
        • Figma introduction
        • Usability testing
        • User Research
    • resources
      • http
        • introduction
    • workshops
      • cookie-auth
        • index
      • creating-promises
        • index
      • css-layout
        • index
      • cypress-testing
        • index
      • database-testing
        • index
      • dev-tooling
        • Developer tooling
      • dom-challenge
        • index
      • dom-rendering
        • index
      • es-modules
        • index
      • express-middleware
        • Express middleware
      • first-class-functions
        • index
      • form-validation
        • index
      • functions-callbacks-async
        • Functions, callbacks, & async JavaScript
      • git-intro
        • Introduction to Git
      • git-terminal
        • Using Git in the terminal
      • git-workflow
        • Git workflow
      • github-projects
        • GitHub Projects Workflow Workshop
      • heroku-sql-challenge
        • index
      • html-forms
        • index
      • learn-a11y
        • index
        • starter-files
          • solution
            • Accessibility solution explanation
      • learn-fetch
        • index
      • learn-integration-testing
        • index
      • learn-testing
        • Learn testing in JavaScript
      • learn-unit-testing
        • index
      • node-error-handling
        • Node error-handling
      • node-express-server
        • Node and Express HTTP server
      • node-npm-intro
        • Node & npm introduction
      • node-postgres
        • Learn Postgres with Node
      • node-scripting-challenge
        • index
      • password-security
        • index
      • promise-practice
        • index
      • react-components
        • React components
      • react-fetch
        • index
      • react-forms
        • React forms
      • react-refactor-classes
        • index
      • react-state-effects
        • React state & effects
      • real-world-fetch
        • index
      • scope-challenge
        • Scope debugging challenge
      • semantic-html
        • index
      • server-side-forms
        • Server-side forms
      • session-auth
        • Session authentication
      • sql-intro
        • index
      • tdd-array-methods
        • index
Powered by GitBook
On this page
  • .NET
  • Spike
  • Acceptance Criteria
  • PHP
Export as PDF
  1. src
  2. course
  3. syllabus
  4. developer
  5. week12-project05-DOTNET-deploy

project

.NET

Your task this week is to deploy and test the library app you have completed in the previous two weeks.

Spike

Before you start you need to create a testing and deployment plan. We would like you to plan a testing strategy that will have broad coverage of your project. The tools we would like you to use to achieve this can include Cypress, Postman and the Node built in testing library.

We would also like you to deploy this project using an EC2 instance for you server and a S3 bucket to serve your static files using CloudFront. You should also utilise Github actions to allow you to automatically deploy changes on merges to your main branch.

Questions to consider

  • What parts of the application logic are the most critical to cover with unit tests?

  • How will you mock external dependencies (like databases or APIs) during unit testing?

  • What are the key user journeys and flows within the application that must be covered by end-to-end tests?

  • Where will the code that represents your infrastructure live and how will it be organised?

  • How will you manage configuration variables for different environments (development, staging, production)?

  • What are the different AWS products you will need to configure to make your deployment successful?

Acceptance Criteria

Stretch


PHP

Deployment and Advanced Topics

Monday: Exploring Deployment Options

  • Objectives:

    • Learn about standard WordPress hosting solutions.

    • Compare AWS with managed WordPress hosting providers.

  • Activities:

    1. Research Hosting Providers:

      • Managed WordPress Hosts:

        • SiteGround:

          • Note features like WordPress-specific optimizations, staging environments, and support.

        • Bluehost:

          • Check for one-click WordPress installs, free domain, and SSL certificate.

        • WP Engine:

          • Explore managed hosting features like advanced security, global CDN, and development environments.

      • Features to Consider:

        • Performance Optimization:

          • Server configurations.

          • Use of caching technologies.

          • CDN availability.

        • Security Features:

          • SSL certificates.

          • Malware scanning.

          • Firewall protection.

        • Customer Support:

          • Availability of 24/7 support.

          • Support channels (chat, phone, email).

        • Pricing Plans:

          • Monthly vs. annual pricing.

          • Introductory offers and renewal rates.

    2. Understand Benefits of Managed Hosting:

      • Ease of Use:

        • Simplified setup processes.

        • Pre-configured WordPress environments.

      • Performance:

        • Servers optimized specifically for WordPress.

        • Built-in caching and performance enhancements.

      • Security:

        • Regular security updates.

        • Proactive monitoring for vulnerabilities.

    3. Compare with AWS:

      • AWS Flexibility:

        • Ability to customize server environments.

        • Scalability options.

      • Complexity:

        • Requires knowledge of server management.

        • Setup can be more time-consuming.

      • Cost Considerations:

        • Potentially lower costs at scale.

        • Pay-as-you-go pricing model.

    4. Decide on Hosting Solution:

      • Factors to Consider:

        • Learning Objectives:

          • Do you want to learn server management alongside WordPress?

        • Budget Constraints:

          • What is the acceptable cost per month/year?

        • Time Available for Setup:

          • Is there time to manage servers, or is a managed solution preferable?

      • Make a Decision:

        • Choose the hosting provider that best fits your project needs.

  • Resources:


Tuesday: Preparing for Deployment

  • Objectives:

    • Set up the chosen hosting environment.

    • Migrate the local WordPress site to the hosting server.

  • Activities:

    1. Set Up Hosting Environment:

      • Sign Up for Hosting:

        • Follow the sign-up process for your chosen hosting provider.

        • Note down important details like login credentials, server IP, and nameservers.

      • Set Up Domain (if applicable):

        • Register a Domain:

        • Update Nameservers:

          • Point your domain to your hosting provider's nameservers.

    2. Export Local Database:

      • Use phpMyAdmin:

        • Access phpMyAdmin via http://localhost/phpmyadmin/.

        • Select your WordPress database (e.g., wordpress_db).

        • Click on the Export tab.

        • Choose the Quick export method and format as SQL.

        • Click Go to download the database export file.

    3. Import Database to Server:

      • Access Server's phpMyAdmin:

        • Log in to your hosting account's control panel (e.g., cPanel).

        • Open phpMyAdmin from the control panel.

        • Create a new database (e.g., yourusername_wpdb).

        • Create a new database user and assign it to the database with all privileges.

        • Select the new database.

        • Click on the Import tab.

        • Choose the SQL file exported earlier and click Go to import.

    4. Upload WordPress Files:

      • Use FTP Client (e.g., FileZilla):

        • Connect to the Server:

          • Host: Your domain or server IP.

          • Username: Your FTP username.

          • Password: Your FTP password.

          • Port: Usually 21.

        • Upload Files:

          • Navigate to the public_html or www directory on the server.

          • Upload all files and folders from your local WordPress directory.

    5. Configure wp-config.php:

      • Update Database Credentials:

        • Open wp-config.php in a text editor.

        • Update the following lines with your server database credentials:

          define('DB_NAME', 'yourusername_wpdb');
          define('DB_USER', 'your_db_username');
          define('DB_PASSWORD', 'your_db_password');
          define('DB_HOST', 'localhost'); // Often 'localhost', check with your host
      • Update Site URLs:

        • Add the following lines to temporarily define site URLs:

          define('WP_HOME','http://yourdomain.com');
          define('WP_SITEURL','http://yourdomain.com');
    6. Test the Site:

      • Access the Site via Browser:

        • Navigate to http://yourdomain.com.

        • Check if the site loads correctly.

      • Troubleshoot Issues:

        • Common Issues:

          • Database connection errors.

          • Missing files or permissions errors.

        • Solutions:

          • Double-check database credentials in wp-config.php.

          • Ensure all files are uploaded.

          • Check file permissions (usually folders 755, files 644).

  • Resources:


Wednesday: Securing and Optimizing the Site

  • Objectives:

    • Implement security best practices.

    • Optimize the site's performance.

  • Activities:

    1. Install SSL Certificate:

      • Use Let's Encrypt (if supported):

        • Access Control Panel:

          • Go to your hosting control panel.

        • Find SSL/TLS Settings:

          • Locate the SSL/TLS or Let's Encrypt option.

        • Install SSL Certificate:

          • Follow the prompts to install a free SSL certificate for your domain.

      • Force HTTPS:

        • Update .htaccess File:

          • Add the following code at the top of your .htaccess file to redirect all traffic to HTTPS:

            RewriteEngine On
            RewriteCond %{SERVER_PORT} 80
            RewriteRule ^(.*)$ https://www.yourdomain.com/$1 [R,L]
        • Update WordPress Settings:

          • In the WordPress admin dashboard, go to Settings > General.

          • Update WordPress Address (URL) and Site Address (URL) to use https://.

    2. Set Up Security Plugins:

      • Install Wordfence Security Plugin:

        • In the WordPress admin dashboard, go to Plugins > Add New.

        • Search for "Wordfence Security".

        • Install and activate the plugin.

      • Configure Wordfence:

        • Follow the setup wizard.

        • Enable firewall and scan options.

        • Configure login security settings.

    3. Implement Caching for Performance:

      • Install WP Super Cache Plugin:

        • Go to Plugins > Add New.

        • Search for "WP Super Cache".

        • Install and activate the plugin.

      • Configure Caching Options:

        • Go to Settings > WP Super Cache.

        • Enable Caching.

        • Choose Simple caching method.

      • Advanced Settings (Optional):

        • Configure CDN support if using a CDN.

        • Enable compression.

    4. Optimize Images and Assets:

      • Install Smush Image Compression Plugin:

        • Go to Plugins > Add New.

        • Search for "Smush".

        • Install and activate the plugin.

      • Bulk Optimize Images:

        • Go to Media > Bulk Smush.

        • Optimize existing images.

      • Enable Automatic Optimization:

        • Configure settings to automatically optimize images on upload.

      • Minify CSS and JavaScript with Autoptimize:

        • Install and activate the "Autoptimize" plugin.

        • Go to Settings > Autoptimize.

        • Enable options to optimize HTML, JavaScript, and CSS.

    5. Check Site Performance:

      • Use GTmetrix:

        • Enter your site URL and analyze.

      • Use Google PageSpeed Insights:

        • Enter your site URL and analyze.

      • Review Recommendations:

        • Identify areas for improvement.

        • Implement suggestions as feasible.

  • Resources:


Thursday: Final Adjustments and Presentation

  • Objectives:

    • Finalize the deployment of the WordPress site.

    • Prepare and deliver the final 20-minute presentation.

    • Allocate time for presentation preparation.

    • Engage in normal development activities.

  • Activities:

    1. Morning Development:

      • Finalize Deployment:

        • Double-Check Functionality:

          • Test all site features, including custom theme and plugin functionalities.

        • Fix Any Remaining Issues:

          • Address any bugs or errors found during testing.

      • Perform Final Testing:

        • Cross-Browser Testing:

          • Test the site on multiple browsers (Chrome, Firefox, Edge, Safari).

        • Mobile Responsiveness:

          • Test the site on mobile devices or use browser developer tools.

    2. Presentation Preparation (1 hour):

      • Summarize Project Journey:

        • Outline the project's objectives, progress, and outcomes.

      • Prepare Presentation Materials:

        • Create slides highlighting key features.

        • Include screenshots and code snippets where appropriate.

        • Prepare a live demo of the deployed site.

      • Rehearse:

        • Practice the presentation to ensure it fits within the 20-minute time limit.

    3. Deliver the Presentation (20 minutes):

      • Presentation Structure:

        • Introduction:

          • Briefly introduce yourself and the project.

        • Project Overview:

          • Discuss the project's goals and scope.

        • Demonstration:

          • Showcase the live site.

          • Navigate through key features.

          • Highlight custom theme and plugin functionalities.

        • Technical Deep-Dive:

          • Explain complex components.

          • Show relevant code snippets.

          • Discuss challenges and how you overcame them.

        • Conclusion:

          • Summarize accomplishments.

          • Mention possible future improvements.

      • Engage with the Audience:

        • Invite questions and feedback.

    4. Afternoon Development:

      • Implement Feedback:

        • Address any immediate feedback from the presentation.

      • Begin Project Documentation:

        • Start compiling user guides and technical documentation.

  • Resources:


Additional Learning Opportunities and Resources

  • Advanced PHP Concepts:

    1. Learn Object-Oriented Programming (OOP):

      • Implement Classes and Objects in Your Plugin:

        • Refactor parts of your plugin to use classes.

        • Example Class Structure:

          <?php
          class Event_Manager {
            public function __construct() {
              add_action( 'init', array( $this, 'register_custom_post_type' ) );
            }
          
            public function register_custom_post_type() {
              // Registration code here
            }
          
            // Additional methods
          }
          
          $event_manager = new Event_Manager();
          ?>
      • Benefits of OOP:

        • Encapsulation of functionality.

        • Easier maintenance and scalability.

      • Resources:

    2. Use Namespaces and Autoloading:

      • Organize Code Using Namespaces:

        • Add namespaces to your classes.

          <?php
          namespace MyPlugin;
          
          class Event_Manager {
            // Class code
          }
          ?>
      • Implement PSR-4 Autoloading:

        • Use Composer for autoloading classes.

          • Install Composer:

          • Create composer.json:

            {
              "autoload": {
                "psr-4": {
                  "MyPlugin\\": "src/"
                }
              }
            }
          • Run Composer Dump-Autoload:

            composer dump-autoload
          • Include Autoloader in Plugin:

            require_once plugin_dir_path( __FILE__ ) . 'vendor/autoload.php';
      • Resources:

  • Security Best Practices:

    • Deep Dive into WordPress Security:

      • Further Hardening WordPress:

        • Change default table prefixes.

        • Disable file editing from the admin dashboard.

          // Add to wp-config.php
          define('DISALLOW_FILE_EDIT', true);
        • Limit login attempts.

      • Stay Updated:

        • Regularly update WordPress core, themes, and plugins.

      • Resources:

PreviousWeek of November 25thNextResources

Last updated 6 months ago

Visit .

Visit .

Visit .

If you need a new domain, register one through your hosting provider or a domain registrar like .

Install FileZilla: If not already installed, download from .

Visit .

Visit .

Download from .

SiteGround WordPress Hosting
Bluehost WordPress Hosting
WP Engine
WordPress Hosting Options (WPBeginner)
Deploying WordPress on AWS (AWS Docs)
Best Managed WordPress Hosting Providers
Namecheap
FileZilla
Migrating WordPress Sites (Official Docs)
File Transfer via FTP (FileZilla Guide)
Editing wp-config.php (Official Docs)
GTmetrix
PageSpeed Insights
WordPress Security Guide (Wordfence Blog)
SSL for WordPress (Let’s Encrypt Guide)
Caching and Performance (Official Docs)
Tips for Effective Technical Presentations
Live Demo Best Practices
PHP OOP Concepts
getcomposer.org
Composer Autoloading
Namespaces in PHP
Hardening WordPress (Official Docs)
WordPress Security Whitepaper