官术网_书友最值得收藏!

Creating a sample HTML web page

We will start creating our Docker image by creating a minimalistic HTML "Hello World!" web page. This step mimics implementing an application without any containerization and is a common scenario in application development: you are running a non-containerized application and then you move it to a Docker container.

You can also use the files from this book's GitHub repository to do this, available from:  https://github.com/PacktPublishing/Hands-On-Kubernetes-on-Windows/tree/master/Chapter01/01_docker-helloworld-iis.

Add a new file in Visual Studio Code in your workspace using the Ctrl + N shortcut or by navigating to File > New File. Use the following sample HTML code in the new file:

<!DOCTYPE html>
<html>
<head>
<title>Hello World!</title>
</head>
<body>
<h1>Hello World from Windows container!</h1>
</body>
</html>

Save the file (using Ctrl + S) as index.html in your workspace.

Let's proceed with creating the Dockerfile itself.

主站蜘蛛池模板: 余姚市| 五常市| 甘洛县| 利津县| 吴堡县| 玛沁县| 敖汉旗| 竹山县| 南郑县| 泰州市| 湘潭市| 三原县| 崇文区| 兴仁县| 呼和浩特市| 正阳县| 河曲县| 大埔县| 边坝县| 阿图什市| 汝城县| 天全县| 林口县| 太保市| 林芝县| 荔浦县| 维西| 陵川县| 柘荣县| 丹东市| 九寨沟县| 时尚| 丹巴县| 大宁县| 天柱县| 林西县| 南阳市| 涞源县| 永州市| 雅安市| 修水县|