a fennel wrapper for az
5dc85168 — Joaquin Iglesias Turina 11 months ago
add subscription
a92f9282 — Joaquin Iglesias Turina 11 months ago
cleanup and adapt to new situation
39bc22e0 — Joaquin Iglesias Turina a year ago
reading from config file


browse  log 



You can also use your local clone with git send-email.

#Table of Contents

  1. Azufre: A fennel wrapper for az cli.
    1. Requisites
    2. Features
    3. Usage
      1. Getting help
      2. Running commands
      3. Further Usage
    4. Known issues
    5. Credits

#Azufre: A fennel wrapper for az cli.


This library just wraps the az command line client, making direct system calls to it. In order to use it, you'll need to have properly installed and set up the az command line client. Check out the documetation.


  • While you are wrapped in azufre, you'll be:
    • Using your favorite lang
    • in a repl and data driven way
    • from the comfort of your favorite text editor.
  • It's tested!
  • There are examples!


#Getting help

Running the following should give you the az help page.

(local azufre-client (require :azufre))
(local azufre azufre-client.azufre)
(azufre [] :h)

Wondering why do we need that ugly empty list? There you fill in your az subgroups and command.

(azufre [:storage] :h)

It's not like you need to call just az often, and if asking for help you'll need to use some subgroup soon, so better put the empty list now.

#Running commands

Follow the help or documentation and fill in you subgroups and command list. Easy.

(azufre [:storage :account :list])

The az json output is returned parsed into a table.

If you need to pass parameters to your call, pass a table with {:param "value"} to azufre

(azufre [:storage :account :list]
        {:query "[].name"})

#Further Usage

Check out the examples. utlils.fnl queries storage accounts and their keys. create-containers.fnl and delete-containers.fnl use those accounts and keys to manipulate storage containers.

#Known issues

If instead of a table, :h or :help, you pass something else as last argument, you'll probably break things.

If you need to use a call with parameters that don't have an associated value, you can do this, which is clunky, but works:

(azufre [:storage :fake :subgroup] {:query "[].name" :verbose ""})

All errors are fatal. Is this a feature or a bug?


fennel Copyright © 2016-2018 Calvin Rose and contributors, distributed under the MIT/X11 License

fennel-test Copyright (c) 2021 Andrey Listopadov, distributed under the MIT/X11 License

json.lua Copyright (c) 2020 rxi, distributed under the MIT/X11 License