# 7.5 समान step 3: files copy आणि permissions

Source: https://ravindrabagale.com/mr/aws/ch07-static-website-hosting-3-oses-2-web-servers/7-5-step-3-common-copy-files-and-set-permissions.html
Language: mr (Marathi with English technical terms)

Home मधल्या files web root मध्ये आणू. Folders 755, files 644:

sudo mkdir -p /var/www/mysite
sudo cp -r ~/mysite/* /var/www/mysite/
sudo find /var/www/mysite -type d -exec chmod 755 {} \;
sudo find /var/www/mysite -type f -exec chmod 644 {} \;
ls -la /var/www/mysite

या sample मध्ये hidden files नाहीत. ~/mysite/* hidden files copy करत नाही; स्वतःच्या project मध्ये कोणत्या dotfiles public करायच्या हे निवडूनच deploy करा.

आता तुमच्या OS/server चा पुढचा lesson निवडा.

Lab

ls -la मध्ये folders drwxr-xr-x आणि files -rw-r--r-- पाहा. namei -l /var/www/mysite/index.html ने पूर्ण path चे permissions तपासा.

रवींद्र बागले यांची tip

आधी localhost वर योग्य Host header सह curl करा. आतूनही error असेल तर config/service/logs; आत चालतं पण बाहेर नाही तर network/firewall/IP तपासा.
