<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>akira6592</author_name>
  <author_url>https://blog.hatena.ne.jp/akira6592/</author_url>
  <blog_title>てくなべ</blog_title>
  <blog_url>https://tekunabe.hatenablog.jp/</blog_url>
  <categories>
  </categories>
  <description>はじめに なにか連番を生成する際に、user1、user2・・user10 ではなく、user01、user02・・のように 特定の桁数でゼロパディングしたいことはないでしょうか。 Jinja2 の filter でフォーマットするのが便利です。 動作確認環境 Ansible 2.9.9 Jinja2 2.11.2 サンプル1: 簡単な例（単一の値） 10進数を2桁で揃えたいときは %02d です。 - hosts: localhost connection: local gather_facts: false tasks: - debug: msg: &quot;{{ 'user%02d' | for…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Ftekunabe.hatenablog.jp%2Fentry%2F2020%2F06%2F17%2Fansbile_zero_padding&quot; title=&quot; [Ansible] user01、user02・・のように数値を任意の桁数にゼロパディングする - てくなべ&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2020-06-17 23:20:38</published>
  <title> [Ansible] user01、user02・・のように数値を任意の桁数にゼロパディングする</title>
  <type>rich</type>
  <url>https://tekunabe.hatenablog.jp/entry/2020/06/17/ansbile_zero_padding</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
