20th Pluralsight Course Published – “Getting Started with Drupal”

Last week I published a new course on Pluralsight. This one is a milestone as it marks my 20th course! This course is titled “Getting Started with Drupal“. Startups, enterprises and more continue to adopt content management systems at a fast rate with Drupal being one of the top Content Management Systems used.

Drupal is one of the top choices for startups and enterprises. It is used for many uses from web apps, marketing tools, e-commerce, and even a company’s main website.

I have been working with Drupal and other content management systems in various aspects for over sixteen years. I have used Drupal for my own websites, hosted it for businesses, administered Drupal sites for customers, Drupal development for customers, and even managed the development of Drupal modules. With all of my history with Drupal, I was excited when the opportunity came up to build a course about it.

This course is ideal for bloggers, entrepreneurs, Product Managers, Marketing managers, Marketing executives, Marketing consultants, Marketing employees, web developers, project managers, business analysts, web designers, graphic designers, UX/UI, designers, and anyone interested in content management systems specifically Drupal.

This course will take you from little to no knowledge of Drupal to a place where you can be confident enough to get started. Whether you want to create a personal blog, a business website, or an online store, Drupal is a skill you should have and this course has you covered.

In this course, Getting Started with Drupal, you’ll learn its many uses, features, tech stack, and you’ll also explore hosting it. Next, you’ll learn how to install it. Finally, you’ll discover its user interface and general configuration.

Some of the major topics that are covered in this course include:

  1. Core Drupal knowledge.
  2. About its tech stack such as web servers like Apache, language PHP, Composer, Drush, & databases like MySQL & how these work with Drupal.
  3. How to acquire a domain & hosting for Drupal.
  4. & Finally, how to install and configure Drupal.

By the end of this course, you will have a better understanding of content management systems, & Drupal itself, its uses, features, & tech stack. As well as knowledge of how to get a domain name, hosting, and install Drupal along with a tour of its interface and general configuration.

This course is the 1st in a Drupal Path named “Drupal Fundamentals” on Pluralsight. The 2nd course in the path is “Drupal 10 Site Administration”. You can check out the full path here:

https://www.pluralsight.com/paths/drupal-fundamentals

Check out the “Getting Started with Drupal“ course here:

https://www.pluralsight.com/courses/drupal-getting-started

I hope you find value in this new Getting Started with Drupal course. Be sure to follow my profile on Pluralsight so you will be notified as I release new courses

Here is the link to my Pluralsight profile to follow me:

https://www.pluralsight.com/authors/steve-buchanan

Read more

16th Pluralsight course – “Laravel The Big Picture” a web framework for modern PHP based web apps

I am excited to announce that I published a Laravel course on Pluralsight! This course is titled “Laravel 9: The Big Picture“. This is my 16th course with Pluralsight. I have been working with PHP based websites, Content Management Systems, Frameworks, and the language off and on for many years. When the opportunity came to author a course on Laravel I jumped on it.

Laravel is a full-stack web framework for modern PHP based web applications. PHP is a language that has been around for a long time used to power most of the web site and web apps on the internet today. And some of the best web development teams in the world build their products with Laravel.

Many don’t know this but Laravel can be used for front-end and back-end development, as well as developing a REST API. Some of the largest companies and most popular websites have been built using Laravel such as Disney, Apple, Pfizer, BBC, Twitch, Mastercard, and more.

In this course, Laravel 9: The Big Picture, you’ll learn about the Laravel full-stack framework. First, you’ll explore Laravel’s core components such as: routing, middleware, controllers, requests, responses, views, blade templates, and more. Next, you’ll discover how to install Laravel, configure it, how it handles security, works with databases, about its APIs and more. Finally, you’ll learn what it is like to develop, build, and deploy an app with Laravel.

When you’re finished with this course, you’ll have the skills and knowledge of Laravel needed to decide if it is the right PHP web framework for you and where to go next on your journey with Laravel.

Check out the new Laravel course here: https://app.pluralsight.com/library/courses/laravel-9-big-picture

I hope you find value in this new Laravel 9: The Big Picture course. Be sure to follow my profile on Pluralsight so you will be notified as I release new courses

Here is the link to my Pluralsight profile to follow mehttps://app.pluralsight.com/profile/author/steve-buchanan

Read more

Build & release a Container Image from Azure DevOps to Azure Web App for Containers

I recently published a blog post on 4sysops.com about Web App for Containers on Azure here: https://4sysops.com/archives/web-app-for-containers-on-azure. That blog post is about the often-overlooked service in Azure that can be used to host a container/s on a web app in Azure App service.

This is a great service if you just need to run a single container or even a couple of containers that you have in Docker Compose. This service is PaaS and abstracts away an orchestration system like Kubernetes. If you need insight into the Azure App Service Web App for Containers service check out the blog post on 4sysops.

In this long blog post I am going to take things a step further and walk-through the build & release of a Container from Azure DevOps to Azure Web App for Containers. The overall goal of this post is to help someone else out if they want to setup a build and release pipeline for building and deploying a container to Azure App Service. We will use a very simple PHP web app I built that will run in the container.

Here are the components that are involved in this scenario:

  • Azure Container Registry (ACR): We will use this to store our container image. We will be pushing up the container image and pull it back down from the registry as a part of the build and release process.
  • Azure DevOps (ADO): This is the DevOps tooling we will use to build our container, push it up to ACR, pull it down into our release pipeline and then deploy to our Azure App Service.
  • App Service Web App for Containers: This is the web server service on Azure that will be used to host our container. Under the hood this will be a container that is running Linux and Apache to host the PHP web app.

Here is the data Flow for our containerized web app:

  1. Deploy the Azure App Service Web App for Containers instance
  2. Deploy the Azure Container Registry
  3. Deploy the Azure DevOps organization and project, create repository to host the code, clone repository in VS Code (Not shown in this blog post. Assume you know how to this up.)
  4. Update the application code (PHP code and Docker image) in Visual Studio code
  5. Commit application code from Visual Studio code to the Azure DevOps repo (Not shown in this blog post. Assume you know how to this up.)
  6. Setup build and then run container build and push the container image to ACR
  7.  Setup release pipeline and then kick off the release pipeline pulling down the container image from ACR and deploys the container to the App Service Web App for Containers instance.

Here is a diagram detailing out the build and release process we will be using:

Click to enlarge

Note that all code used in this blog post is hosted on my GitHub here: https://github.com/Buchatech/EOTD-PHP-APP-DOCKER-CONTAINER

Ok. Let’s get into the setup of core components of the solution and the various parts of the build and release pipeline.

For starters this solution will need a project in Azure DevOps with a repo. Create a project in Azure DevOps and a repo based on Git. Name the repo exerciseoftheday. Next up let’s create the core framework we need in Azure.

Deploy Azure App Service Web App for Containers

Let’s create the Azure App Service Web App for Containers that will be needed. We will need a resource group, an app service plan and then we can setup the app service. The PHP app we will be running is named Exercise Of The Day (EOTD) for short so our resources will use EOTD. Use the following steps to set all of this up.

We will do everything via Azure Cloud Shell. Go to https://shell.azure.com/ or launch Cloud Shell within VS Code.

Run the following Syntax:

# Create a resource group

az group create –name EOTDWebAppRG –location centralus

# Create an Azure App Service plan

az appservice plan create –name EOTDAppServicePlan –resource-group EOTDWebAppRG –sku S1 –is-linux

# Create an Azure App Service Web App for Containers

az webapp create –resource-group EOTDWebAppRG –plan EOTDAppServicePlan –name EOTD –deployment-container-image-name alpine

# Create a deployment slot for the Azure App Service Web App for Containers

az webapp deployment slot create –name EOTD –resource-group EOTDWebAppRG –slot dev –configuration-source EOTD

Deploy Azure Container Registry

Now let’s create the Azure Container Registry. Again, this is where we will store the container image. Run the following Syntax:

# Create Azure Container Registry

az acr create –resource-group EOTDWebAppRG –name eotdacr –sku Basic –admin-enabled false –location centralus

Note the loginServer from the output. This is the FQDN of the registry. Normally we would need this, admin enabled, and the password to log into the registry. In this scenario we won’t need admin enabled or the password because we will be adding a connection to Azure DevOps and the pipelines will handle pushing to and pulling the image from the registry.

When it’s all done you should see the following resources in the new resource group:

Next, we will need to build an application and a container image.

Read more

Composer in a Docker Image

This will be a short post and this one is mostly for me so I can easily find this information in the future when I need it again. 🙂

Recently I was containerizing some PHP websites that use Composer. If you are not familiar with Composer but you are working with PHP, you will run across it at some point. Composer is a dependency package manager for PHP. Composer manages (install/update) any required libraries and dependencies needed for your PHP site.

To use Composer you must first declare the libraries and dependencies in a composer.json file in your site directory and then you would run Composer and it will do its magic. For more information on Composer visit: https://getcomposer.org/doc/00-intro.md

Back to my task, I needed to install Composer in the containers I was building and run it to install all the dependencies. I needed these actions in the Dockerfile so it would all happen during the container build. After some research on Composer I was able to pull something together. Here is the syntax that I ended up putting in the Dockerfile:

# Install Composer
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer

# Set working directory for composer (Contains the composer.json file)
WORKDIR /var/www/html/sitename

# Run Composer
RUN composer install

Note: I placed the above code at the end of the Dockerfile ensuring Apache, PHP etc was all in place first.

Thanks for reading and happy Containerizing!

Read more