diff --git a/rh199_(rapid)/labs_solutions.md b/rh199_(rapid)/labs_solutions.md index b16aab5..bc0a74a 100644 --- a/rh199_(rapid)/labs_solutions.md +++ b/rh199_(rapid)/labs_solutions.md @@ -2,18 +2,59 @@ *** + +**Для выполнения лабораторных работ потребуется настроить 2 виртуальных хоста** + +server1 - 192.168.10.10 +user: student +password: student +root password: redhat + +server2 - 192.168.10.11 +user: student +password: student +root password: redhat + +Дополнительно необходимо: +*SERVER1* +1. Установить httpd +```bash +[student@server2 ~]$ sudo -i +[sudo] пароль для student: +[root@server2 ~]# yum install httpd -y +[root@server2 ~]# systemctl enable --now httpd +Created symlink /etc/systemd/system/multi-user.target.wants/httpd.service → /usr/lib/systemd/system/httpd.service. +[root@server2 ~]# echo "This is SERVER2 WEB-SERVER" > /var/www/html/index.html +[root@server2 ~]# firewall-cmd --add-service=http +success +[root@server2 ~]# firewall-cmd --add-service=http --permanent +success +[root@server2 ~]# mkdir /test +[root@server2 ~]# echo "This is the html file for the SELinux final lab on SERVER2." > /test/lab.html +[root@server2 ~]# mv /test/lab.html /var/www/html/ +[root@server2 ~]# ls -lZ /var/www/html/ +итого 8 +-rw-r--r--. 1 root root unconfined_u:object_r:httpd_sys_content_t:s0 27 окт 9 16:03 index.html +-rw-r--r--. 1 root root unconfined_u:object_r:default_t:s0 60 окт 9 16:07 lab.html +[root@server2 ~]# rmdir /test/ +[root@server2 ~]# curl http://server2/index.html +This is SERVER2 WEB-SERVER +[root@server2 ~]# curl http://server2/lab.html + + +403 Forbidden + +

Forbidden

+

You don't have permission to access this resource.

+ +``` + +*** + ###### top *лабораторные работы начинаются в 3-й главы* -***server1 - 192.168.10.10 -user: student -password: student -root password: redhat*** - -***server2 - 192.168.10.11 -user: student -password: student -root password: redhat*** +*** 3. [Управление локальными пользователями и группами.](#chapter3) 4. [Управление доступом к файлам.](#chapter4) diff --git a/rh199_(rapid)/untitled.md b/rh199_(rapid)/untitled.md deleted file mode 100644 index 96cd086..0000000 --- a/rh199_(rapid)/untitled.md +++ /dev/null @@ -1,4 +0,0 @@ -some *This is Blue italic.* text - -some **This is Red Bold.** text -