From b6c8bf1813c28524e3e3d420f5c0bd34ab5d1a6d Mon Sep 17 00:00:00 2001 From: SafeEHA Date: Thu, 18 Jan 2024 14:20:33 +0100 Subject: [PATCH 1/2] Article on How to run Metal3 website locally with Jekyll Signed-off-by: SafeEHA Article on How to run Metal3 website locally with Jekyll Signed-off-by: SafeEHA Article on How to run Metal3 website locally with Jekyll Signed-off-by: SafeEHA precommit fixes Signed-off-by: SafeEHA precommit fixes Signed-off-by: SafeEHA precommit fixes Signed-off-by: SafeEHA --- ..._run_Metal3_website_locally_with_Jekyll.md | 75 +++++++++++++++++++ 1 file changed, 75 insertions(+) create mode 100644 _posts/2024-01-18-How_to_run_Metal3_website_locally_with_Jekyll.md diff --git a/_posts/2024-01-18-How_to_run_Metal3_website_locally_with_Jekyll.md b/_posts/2024-01-18-How_to_run_Metal3_website_locally_with_Jekyll.md new file mode 100644 index 000000000..9b52039c1 --- /dev/null +++ b/_posts/2024-01-18-How_to_run_Metal3_website_locally_with_Jekyll.md @@ -0,0 +1,75 @@ +--- +title: "How to run Metal3 website locally with Jekyll" +date: 2024-01-18 +draft: false +categories: + ["metal3", "baremetal", "metal3-dev-env", "documentation", "development"] +author: Salima Rabiu +--- + +## Introduction + +If you’re a developer or contributor to the Metal3 project, you may need to run the Metal3 +website locally to test changes and ensure everything looks as expected before deploying +them. In this guide, we’ll walk you through the process of setting up and running Metal3’s +website locally on your machine using Jekyll. + +## Prerequisites + +Before we begin, make sure you have the following prerequisites installed on your system: + +- Ruby: Jekyll, the static site generator used by Metal3, is built with Ruby. Install Ruby + and its development tools by running the following command in your terminal: + +```bash +sudo apt install ruby-full +``` + +## Setting up Metal3’s Website + +Once Ruby is installed, we can proceed to set up Metal3’s website and its dependencies. +Follow these steps: + +- Clone the Metal3 website repository from GitHub. Open your terminal and navigate to the + directory where you want to clone the repository, then run the following command: + +```bash +git clone https://github.com/metal3-io/metal3-io.github.io.git +``` + +- Change to the cloned directory: + +```bash +cd metal3-io.github.io +``` + +- Install the required gems and dependencies using Bundler. Run the following command: + +```bash +bundle install +``` + +## Running the Metal3 Website Locally + +With Metal3’s website and its dependencies installed, you can now start the local +development server to view and test the website. In the terminal, navigate to the +project’s root directory (`metal3-io.github.io`) and run the following command: + +```bash +bundle exec jekyll serve +``` + +This command tells Jekyll to build the website and start a local server. Once the server +is running, you’ll see output indicating the local address where the Metal3 website is +being served, typically [http://localhost:4000](http://localhost:4000). + +Open your web browser and enter the provided address. Congratulations! You should now see +the Metal3 website running locally, allowing you to preview your changes and ensure +everything is working as expected. + +## Conclusion + +Running Metal3’s website locally using Jekyll is a great way to test changes and ensure +the site functions properly before deploying them. By following the steps outlined in +this guide, you’ve successfully set up and run Metal3’s website locally. Feel free to +explore the Metal3 documentation and contribute to the project further. From b44dc793c30181e280aa226ca1beb8bd2a9d0beb Mon Sep 17 00:00:00 2001 From: Tuomo Tanskanen Date: Mon, 22 Jan 2024 14:31:07 +0200 Subject: [PATCH 2/2] add Salima's blog post on Jekyll Signed-off-by: Tuomo Tanskanen --- ..._run_Metal3_website_locally_with_Jekyll.md | 75 ++++++++++--------- 1 file changed, 41 insertions(+), 34 deletions(-) diff --git a/_posts/2024-01-18-How_to_run_Metal3_website_locally_with_Jekyll.md b/_posts/2024-01-18-How_to_run_Metal3_website_locally_with_Jekyll.md index 9b52039c1..be58cbb46 100644 --- a/_posts/2024-01-18-How_to_run_Metal3_website_locally_with_Jekyll.md +++ b/_posts/2024-01-18-How_to_run_Metal3_website_locally_with_Jekyll.md @@ -9,45 +9,50 @@ author: Salima Rabiu ## Introduction -If you’re a developer or contributor to the Metal3 project, you may need to run the Metal3 -website locally to test changes and ensure everything looks as expected before deploying -them. In this guide, we’ll walk you through the process of setting up and running Metal3’s -website locally on your machine using Jekyll. +If you’re a developer or contributor to the Metal3 project, you may need +to run the Metal3 website locally to test changes and ensure everything +looks as expected before deploying them. In this guide, we’ll walk you +through the process of setting up and running Metal3’s website locally +on your machine using Jekyll. ## Prerequisites -Before we begin, make sure you have the following prerequisites installed on your system: +Before we begin, make sure you have the following prerequisites +installed on your system: -- Ruby: Jekyll, the static site generator used by Metal3, is built with Ruby. Install Ruby - and its development tools by running the following command in your terminal: +- Ruby: Jekyll, the static site generator used by Metal3, is built with + Ruby. Install Ruby and its development tools by running the following + command in your terminal: -```bash -sudo apt install ruby-full -``` + ```bash + sudo apt install ruby-full + ``` ## Setting up Metal3’s Website -Once Ruby is installed, we can proceed to set up Metal3’s website and its dependencies. -Follow these steps: +Once Ruby is installed, we can proceed to set up Metal3’s website and +its dependencies. Follow these steps: -- Clone the Metal3 website repository from GitHub. Open your terminal and navigate to the - directory where you want to clone the repository, then run the following command: +- Clone the Metal3 website repository from GitHub. Open your terminal + and navigate to the directory where you want to clone the repository, + then run the following command: -```bash -git clone https://github.com/metal3-io/metal3-io.github.io.git -``` + ```bash + git clone https://github.com/metal3-io/metal3-io.github.io.git + ``` - Change to the cloned directory: -```bash -cd metal3-io.github.io -``` + ```bash + cd metal3-io.github.io + ``` -- Install the required gems and dependencies using Bundler. Run the following command: +- Install the required gems and dependencies using Bundler. Run the + following command: -```bash -bundle install -``` + ```bash + bundle install + ``` ## Running the Metal3 Website Locally @@ -59,17 +64,19 @@ project’s root directory (`metal3-io.github.io`) and run the following command bundle exec jekyll serve ``` -This command tells Jekyll to build the website and start a local server. Once the server -is running, you’ll see output indicating the local address where the Metal3 website is -being served, typically [http://localhost:4000](http://localhost:4000). +This command tells Jekyll to build the website and start a local server. +Once the server is running, you’ll see output indicating the local +address where the Metal3 website is being served, typically +[http://localhost:4000](http://localhost:4000). -Open your web browser and enter the provided address. Congratulations! You should now see -the Metal3 website running locally, allowing you to preview your changes and ensure -everything is working as expected. +Open your web browser and enter the provided address. Congratulations! +You should now see the Metal3 website running locally, allowing you to +preview your changes and ensure everything is working as expected. ## Conclusion -Running Metal3’s website locally using Jekyll is a great way to test changes and ensure -the site functions properly before deploying them. By following the steps outlined in -this guide, you’ve successfully set up and run Metal3’s website locally. Feel free to -explore the Metal3 documentation and contribute to the project further. +Running Metal3’s website locally using Jekyll is a great way to test +changes and ensure the site functions properly before deploying them. By +following the steps outlined in this guide, you’ve successfully set up +and run Metal3’s website locally. Feel free to explore the Metal3 +documentation and contribute to the project further.