My DEVOPS Journey -  YAML

My DEVOPS Journey - YAML

2nd Blog

ยท

3 min read

๐Ÿ‘‹Hi folks, I'm back with an interesting markup language that I have learnt in the course of Devops. That's nothing but YAML. Well, this week in addition to YAML I also worked on linux administration commands and also commands that are used for DevOps. But, I will give a detailed explanation about that in my next blog. For now, I'll explain what I learned about YAML.

What is YAML?

-YAML actually stands for Yet another markup language. But, later it was changed to YAML ain't markup language

  • YAML is a data serialization language used to write configuration files (Docker, Kubernetes, etc).

  • It is used in applications where data is being stored or transmitted.

Now a lot of us will have doubts concerning Data Serialization.

What is Data Serialization?

As far as I have learnt, to define it in my own words, It is a process of converting data objects in a complex data structure into a stream of storage(bytes) that can be transfered to any form of files like YAML files, database, memory, Web-Development files, Mobile application files, etc.

  • Data serialization languages are YAML, JSON, XML.

DataSerialization.jpeg

How's Data stored in YAML?

In YAML, data is stored in the form of:

1. Key-Value pairs:

Represented like a HashMap

 "YAML" : "A markup language"
 2001 : "Initial release year"

 # also represented as ๐Ÿ‘‡
 {YAML : "A markup language", 2001 : "Initial release year"}

2. Lists:

- YAML
- XML
- JSON
- yMAL
# the last one is not same as the first one. Because YAML is a case sensitive language.

3. Block Style:

Stores data in blocks with a block name.

Data Serialization Languages:
 - YAML
 - XML
 - JSON

# also represented as ๐Ÿ‘‡
Data Serialization Languages: [YAML, XML, JSON]
# we use the above format to avoid indentation error
  • There are also many advanced data types like sequences, nested sequences, maps, dictionaries, etc which were fun to learn and practice.
  • I also learnt to store data in XML and JSON files to actually know what is the difference between them and YAML. From my observation, I can tell that YAML is a proper human-readable language unlike XML and JSON which were not human-readable when large data is stored.

  • YAML also has a code validator which we will be using in upcoming projects when working with kubernetes stuff I believe. Code Validator

  • We can also transform YAML code to JSON and vice versa using some online tools. Code Translator

To learn more about YAML, please visit ๐Ÿ‘‰ YAML Tutorial - The Complete Guide

I'm Following kunal kushwaha's YAML full course

Finally, thanks to Kunal Kushwaha for his amazing contribution to society via communities and transforming many student's lives.

That's it for this blog guys. I hope you learnt something useful from this blog. Thank you for reading. Have a great day!๐Ÿ˜„

ย