Step 1 – Install & Verify Chef Workstation
Step 2 – Write a following content in hello.rb
file 'index.html' do
content "Hello everyone from DevOpsSchool"
endCode language: JavaScript (javascript)
Step 3 – Write a following content in hello.rb
$ chef-apply hello.rb
$ chef-apply hello.rb
$ chef-apply hello.rb -l debug
$ chef-apply hello.rb --why-run
Run the executable in why-run mode, which is a type of Chef Infra Client run that does everything except modify the system. Use why-run mode to understand why the Chef Infra Client makes the decisions that it makes and to learn more about the current and proposed state of the system.
I’m Rajesh Kumar, a DevOps, SRE, DevSecOps, Cloud, and Platform Engineering expert passionate about sharing practical knowledge, real-world experiences, and industry best practices. I have worked at Cotocus and regularly write about technology, travel, investing, health, product reviews, and digital marketing through my various platforms.
I publish technical articles at DevOps School, travel stories at Holiday Landmark, stock market insights at Stocks Mantra, health and fitness guidance at My Medic Plus, product reviews at TrueReviewNow, and SEO and digital marketing strategies at Wizbrand.
Find Trusted Cardiac Hospitals
Compare heart hospitals by city and services โ all in one place.
Explore Hospitals