I hope everyone getting a chance to enjoy the summer and spend some time with loved once.
That said – Azure Bicep team does not seem slowing down, and I love it! New features and capabilities have been added to Azure Bicep product v0.4 version, and we will review those innovations on this post.
What is Azure Bicep?
Azure Bicep is a domain-specific language (DSL) that significantly simplifies the Azure resource authoring. It makes representation of your Azure digital estate concise with clean syntax by adding reliable type safety and code-reuse.
A typical Azure Bicep language code for an Azure storage account declaration will look as simple as the following code below – which basically explains why Bicep is called a DSL.
Why would you need it?
There are number of benefits in using Infrastructure-as-Code approach. Azure Bicep might be the right tool for you to use for Azure deployments, especially if you are trying to modernize and simplify the Azure deployment process.
Let’s look into scenarious where Bicep is the right tool to use:
✔️ Want to use language native to Azure? ✔️ Looking for fully integrated templates withing Azure platform? ✔️ Looking for fully supported product with Microsoft? ✔️ Don’t want to keep or worry about your resource state information ✔️ Looking to modernize and easy transition from JSON
Well, if your response is YES for above statements/questions then Bicep will be right tool for your solution.
New additions to Azure Bicep in version 0.4
There are numbers of enhancement and features has been added from this release. Let’s look at main Highlights of these features below:
✅ Linter MVP – The Bicep linter will inspect your code and catch a customizable set of authoring best practices. ✅ Deprecated parameter modifiers removed – Strip out deprecated parameter modifier syntax ✅ New code snippets – Suggestion with new code snippets added ✅ Bug fixes – Number of bug fixes added, thanks to community support ✅ Bicep Playground fixes – Playground doesn’t load after breaking change. ✅ Documentation and examples update ✅ Support for List method call on Azure resource references ✅ Support for JSON literal string conversion ✅ Support for using local json templates as modules ✅ Support for object body completion snippets
What is next?
There are still number of milestones in-front of Bicep team, as the versioning # of Bicep project indicates. That said, starting from Bicep version 0.3 you can get an official Microsoft support.
Below is the sneak-pick preview on what is cooking for v0.5 – which is expected to be out sometimes around August month this year.
After updating to the latest Azure CLI (2.22.0) for Windows 10, I am now seeing the same error as others have reported:
Any command such as “az bicep version” is producing the following error:
The command failed with an unexpected error. Here is the traceback and detailed error: type object 'datetime.datetime' has no attribute 'fromisoformat' Traceback (most recent call last): File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\knack/cli.py", line 231, in invoke File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/init.py", line 657, in execute File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/init.py", line 720, in _run_jobs_serially File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/init.py", line 691, in _run_job File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/init.py", line 328, in call File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/init.py", line 807, in default_command_handler File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/command_modules/resource/custom.py", line 3294, in build_bicep_file File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/command_modules/resource/_bicep.py", line 63, in run_bicep_command File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/command_modules/resource/_bicep.py", line 152, in _load_bicep_version_check_result_from_cache AttributeError: type object 'datetime.datetime' has no attribute 'fromisoformat'
Is there a temp workaround?
One of the workarounds is to uninstalled Azure CLI 2.22.0 , and then install the prior version 2.21.0. You could confirm 2.21.0 version is working for you by running the same command.
Hope this will be helpful for you, as i faced with this issue hours before my demo to #GlobalAzure 2021 😐
Hello eveyone, I am very happy to share exciting news with all of you.
Few days ago, i have receieved an email confirming acceptance of my both Azure sessions for the Global Azure 2021 event. I am truely trilled to present on April 16th and 17th following two sesions for eveyone live:
I am looking forward for your participiation, and tune in to learn about latest developments in Microsoft Azure.
In my first session i will share the following new session with you.
Abstract of the presentation as is:
Infrastructure as a Code (IaC) is important strategy to manage your digital estate in any cloud environment. Simplifying management of your infrastructure while re-using code is even better. In Microsoft Azure, we have ARM (Azure Resource Manager) templates that could declaratively define your cloud project infrastructure.
However, it is not easy to author ARM JSON templates and maintain them when your project grows and requires changes. In this demo heavy session, we will introduce the Azure Bicep language and demonstrate how it simplifies authoring ARM templates for your Azure infrastructure. We will author a manageable, readable, and modularized Azure infrastructure code, while using familiar tools.
Please let me know, what topics are you interested in?