Questions tagged [yaml]

YaML is a human-readable data serialisation format.

YAML is a data serialisation format designed to be written and read by humans. Modern YAML is a superset of JSON, meaning that YAML parsers can consume any valid JSON as well as the richer and more human-friendly long form.

For more information refer to the YAML Wikipedia page or the YAML homepage.

86 questions
2
votes
2 answers

SaltStack: found conflicting ID

My sls file: /etc/sudoers.d/foo: file.managed: - contents: | foo ALL = NOPASSWD: /usr/bin/systemctl restart minio_storage-foo.service foo ALL = NOPASSWD: /bin/systemctl restart minio_storage-foo.service - template: jinja -…
guettli
  • 3,113
  • 14
  • 59
  • 110
2
votes
1 answer

Ansible error: The tasks/main.yml file for role 'common' must contain a list of tasks

I inherited this ansible git from my predecessor. I can't get it to work though and I guess it's something basic that I'm missing. It keeps giving me this lovely error: ERROR! The tasks/main.yml file for role 'common' must contain a list of…
2
votes
1 answer

Unable to delete daemonSet in k8s

I've created a daemonSet in k8s under the namespace kube-system. While trying to delete the deamonSet it got stuck (also when I force it) I've already tried to set a updateStrategy: RollingUpdate To the Yaml and kubectl apply reports that:…
2
votes
1 answer

How to validate variables contents in Ansible?

ansible-lint only checks the tasks/handlers and doesn't iterate over the variables (e.g. if you're using with_items, it won't iterate over all the items) and yamllint only checks cosmetic issues and is hard to customized with custom rules. Is there…
Giovanni Tirloni
  • 5,693
  • 3
  • 24
  • 49
2
votes
1 answer

Contents in Kubernetes pod gets empty when persistent volume is mounted

persistent volume claim and persistent volume yaml file apiVersion: v1 kind: PersistentVolume metadata: name: my-volume labels: type: local spec: storageClassName: manual capacity: storage: 5Gi accessModes: - ReadWriteOnce …
aks
  • 37
  • 1
  • 6
2
votes
1 answer

patroni.exceptions.PatroniFatalException: 'Failed to bootstrap cluster'

I have a problem with patroni right here [postgres@localhost ~]$ patroni /etc/patroni.yml 2021-05-25 11:39:56,767 INFO: Selected new etcd server http://10.102.196.138:2379 2021-05-25 11:39:56,772 INFO: No PostgreSQL configuration items changed,…
2
votes
1 answer

AWS CloudFormation - Creating Layer Version and Function that uses layer

I have a Cloudformation template that currently looks roughly like the following. Resources: MyLayer: Type: AWS::Lambda::LayerVersion Properties: CompatibleRuntimes: - nodejs12.x - nodejs10.x Content:…
2
votes
3 answers

Ansible check if variable exists in attribute list

I have a variable containing details of host machines on my network (called 'hostlist' - I believe you call this a dictionary, but I'm not sure of the terminology. The variable is defined in a file in group_vars/all, so it's available in all…
Mike Williams
  • 23
  • 1
  • 1
  • 3
2
votes
1 answer

Use lookup/dynamic variable names in Ansible jinja2 template

The playbook below should generate a file with the content: a,b ssh_host_key ssh_rsa_host_key However, the way I construct the variable names results in either syntax/templating errors or 'variable name does not exists': --- - hosts: localhost …
Willem
  • 157
  • 4
  • 13
1
vote
1 answer

pod's name from an environment variables defined in yaml

how can I create a yaml file for pod that get its name from a environment variables defined in yaml file. I have tried this but it is not allowed. metadata: generateName: $(HOSTNAME) . . . env: - name: HOSTNAME valueFrom: …
esxzawq
  • 121
  • 1
  • 10
1
vote
1 answer

Templated dict keys in ansible YAML

I am trying to use a dict in an Ansible task, which is defined like this: in vars/main.yml file: username: user1 userpass: pass1 users: "{{ username }}": pass: "{{ userpass }}" This doesn't work in Ansible 2.9: Ansible seems to not…
1
vote
1 answer

Puppet parse hiera in inline_template

I have got some .yaml hiera file with: iptables::test: ip: 1.1.1.1 : 'adm-1' 2.2.2.2 : 'adm-2' 3.3.3.3 : 'adm-3' And i want to parse this file in inline_template. I write: $variable1 = hiera('iptables::test.ip') $variable2 =…
perrfect
  • 45
  • 1
  • 6
1
vote
1 answer

Install gRPC php extension in elastic-beanstack

I need to install gRPC php extension elastic-beanstack. The way i found is to write a config file inside ".ebextensions" in order to automatically install the extension. For that I need to create yaml or json file. I need to add the following…
Maverick
  • 11
  • 2
1
vote
0 answers

Gitlab CI/CD with conditional scripts

Here is what I wish to do in GitLab CI/CD: Whenever something is pushed into a specific branch I wish to have multiple scrips and CI/CD should decide which script should be run based on the pushed files list. For example: IF anything changed in…
Bert
  • 984
  • 1
  • 11
  • 29
1
vote
1 answer

"Report-To" HTTP header implementation for GAE Standard

I'm attempting to add a "Report-To:" HTTP header to our App Engine's app.yaml configuration file for integration with https://report-uri.com (based on the Reporting API here, here, and here) but when I push the changes to the repository, Cloud Build…