Questions tagged [yaml]
YaML is a human-readable data serialisation format.
91
questions
0
votes
1
answer
311
views
How can I boot using Ansible on an Dell iDRAC9 server from an iso that's located on a remote server?
I have this playbook that what I'm trying to do it's to install CentOS using Ansible and Redfish, I don't want to use any modules, I'll install the CentOS on multiple Dell iDRAC9 servers and I'm ...
0
votes
1
answer
4k
views
What's wrong in my docker file - services.db.environment must be a mapping
Here's my yml contents.
version: '2.2'
services:
# postgres
# https://hub.docker.com/_/postgres
db:
container_name: postgres
platform : linux/amd64
image: "postgres:14.6-...
0
votes
0
answers
80
views
Kubernetes auditing policy doesn't work, kubelet won't start up with the policy
im just trying to add audit logging in one of my k8s clusters, my yamls manifest are bellow: kube-api-server file from /manifests/kube-apiserver.yaml
apiVersion: v1
kind: Pod
metadata:
annotations:
...
0
votes
1
answer
892
views
How to create a "DOckerfile" to containerize a "Flutter" app to deploy it on a Kubernetes cluster?
I am just wondering to know how should I create a docker file for a Flutter app then deploy it on a Kubernetes cluster?
I found the following Dockerfile and server.sh script from this website but I ...
1
vote
1
answer
45
views
How should I replace this line "provisioner: k8s.io/minikube-hostpath" for a "Kind" statefulset.yaml file?
The following is a StatefulSet.yaml file for deploying Cassandra database on a minikube cluster. I am not sure what lines should be replaced if I want to use a Kind cluster instead of a minikube one, ...
1
vote
1
answer
889
views
replace with regular expression in azure devops
I want to take this buildVariable
Build.SourceVersion
which will equal for example:
0gc58d92d905d62415b8866g3f48f17416da426s
And replace from digit [7] till line end with empty string
0gc58d92
I ...
2
votes
1
answer
347
views
Create JSON Patch 6902 from two yaml/json files
Imagine I have a file foo.yaml and a modified version of this file called foo2.yaml.
Is there a way to create a correspondig json patch 6902?
0
votes
0
answers
70
views
Envoy proxy random load balancing option is not random
We are using the below Envoy load balancing YAML file. It is working but it is NOT randomly distributing requests across nodes 1, 2, and 3. In our use case, we have high load coming from a single ...
1
vote
1
answer
726
views
Password of new user with LXD and Cloud-init
I'm trying to create a profile to automate the creation of a container, but I'm having trouble with cloud-init. For some reason the password is not being set for the user and is also not being added ...
1
vote
1
answer
458
views
Google AppEngine - 502 Bad Gateway
I'm running a Python Flask endpoint locally and it all works fine, but when I deploy it in GCP AppEngine, I get a 502 Bad Gateway.
It seems to fail at about 200 reads of 2290 bytes each. I've ...
2
votes
1
answer
2k
views
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 ...
1
vote
1
answer
4k
views
Alertmanager telegram config chat_id and cannot unmarshal errror
I am trying to configure alertmanager to send alerts to my telegram group. Following the configuration I have:
global:
resolve_timeout: 5m
route:
group_by:
- job
group_interval: 5m
...
0
votes
1
answer
744
views
Ansible "hip-profiles unexpected here" Palo alto panos_security_rule
I'm trying to set a security policy on my Palo Alto firewalls using Ansible with the panos_security_rule module.
However, I keep running in to the same error, hip-profiles unexpected here.
I found ...
0
votes
1
answer
81
views
Automate Kubernetes Deployment using ArgoCD
We have a GitHub repo containing all the Kubernetes cluster yaml files, When we want to update a deployment we simply edit the yaml and push to GitHub.
Unfortunately, we then have to kubectl apply -f ...
0
votes
0
answers
275
views
Ansible simple inventory for dhcp hosts in yaml
Need a little hint on yaml syntax for a very simple inventory file.
I want to include dhcp range of workstations in a nice inventory file.
Regarding the official documentation this could be done but i'...
3
votes
1
answer
2k
views
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:
...
0
votes
0
answers
659
views
I m trying to use mysqldump but getting error mysqldump: Got error: 2003: Can't connect to MySQL server on host(110) when trying to connect
Here is my sam template for taking database backup
trigger:
- none
pool:
vmImage: ubuntu-latest
steps:
- script: echo Hello, world!
displayName: 'Run a one-line script'
- script:...
0
votes
1
answer
811
views
Salt state file doesn't load info from pillar
I'm getting this error when I'm trying to apply my statefile to my minion:
client.school.test:
Data failed to compile:
Rendering SLS 'base:nextcloud2' failed: Jinja variable 'list object' has no ...
0
votes
1
answer
756
views
Docker private registry as kubernetes pod - deleted images auto-recreated
I run a docker private registry v2.7.0 as a kubernetes pod with a service and a persistent volume, thanks to the Varun Kumar G tutorial, which has been the only successful method on my setup, for ...
0
votes
1
answer
19k
views
ansible - how to get over "conflicting action statements" error?
I have an Ansible playbook for creating and resizing logical Volumes
# playbook lvol.yml
- hosts: step
tasks:
- name: 'create /dev/sdb1 -> 20GB (of 35GB)'
community.general.parted:
...
3
votes
1
answer
2k
views
Cross-reference Ansible variables within the same mapping
How can I define an Ansible variable whose value is another variable in the same mapping structure?
To allow sensible namespacing of variables, I am defining mapping structures like this, where some ...
1
vote
0
answers
151
views
Multiple VM deployment via GCP Deployment Manager
What I want to achieve: I want to be able to create multiple VM instance using AWX playbook or Deployment Manager. The script will read instance configuration in a csv uploaded to gcloud or bitbucket, ...
0
votes
1
answer
142
views
Server set up using app.yaml, cron.yaml, etc. But directories aren't recognized
As the title says, the server has been configured to recognize sub directories but for whatever reason they are not being recognized when I load a web page. Is there any way to debug what is going on?
...
2
votes
1
answer
2k
views
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:...
1
vote
0
answers
6k
views
yaml.parser.ParserError: while parsing a block mapping
I followed this document while configuring patroni and I have a problem with patroni.service file like this
https://snapshooter.com/learn/postgresql/postgresql-cluster-patroni
[Unit]
Description=...
0
votes
1
answer
360
views
deploying on hosts with ansible based on yaml file
Developers are going to provide a yaml file with hosts in particular order (every deployment can differ, depend on needs) and each field in yaml file will have instructions for example install yum ...
3
votes
1
answer
1k
views
Configure AWS CloudFront to send custom query params to origin
Is it possible to configure my AWS CloudFront distribution to append to the request a custom query param (e.g a private key) before sending it to the origin?
For example, the front end is calling *....
-1
votes
1
answer
10k
views
How to combine YAMLfiles in Python?
I have some Kubernetes YAML files which need to combined.
For that I tried using Python.
Second file (sample.yaml) should be merged to the first file source.yaml
Like, the source.yaml has one section ...
0
votes
1
answer
261
views
GCP Deployment Manager: where to find a reference guide to properly create YAML config and template files?
I started working with Google Cloud Deployment Manager upon request of a client, using YAML config files, but I can't find anywhere how to map the reference shown in https://cloud.google.com/...
0
votes
1
answer
2k
views
Merge few files in Ansible lookup file
So far I use simple code to deploy Docker stacks. I don't want to use community.general.docker_stack module, due to its ridiculous requirement: the stack definition (docker compose yml file) needs to ...
1
vote
0
answers
574
views
How to monitor datadog-agent's certificates expiration?
I have an nginx-pod which redirects traffic into Kubernetes services and stores related certificates insides its volume. I want to monitor these certificates - mainly their expiration.
I found out ...
2
votes
1
answer
1k
views
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....
1
vote
1
answer
1k
views
How to convert and save raw data to PDF format using ansible
I will be getting some raw data directly from an API. I want to format this and convert into PDF file and save it. I gone through ansible modules. I am not getting any idea in this. Can someone ...
4
votes
3
answers
38k
views
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 ...
0
votes
0
answers
1k
views
How to log HTTP requests in file in Dropwizard?
I'm having issue in my Dropwizard (version 1.3.8) app logging HTTP Requests into file. I've followed Dropwizard's documentation for configuration of YAML file and my config.yml looks like this:
...
3
votes
2
answers
10k
views
How to pass a group value in inventory file to jinja2 template file in ansible
I have an inventory file named hospital.inventory and it contains following group with a single value.
[dockerSwarmManager]
hp2-3.mydomain.com
Then I have a file name security.json.j2 inside the ...
2
votes
1
answer
8k
views
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 ...
1
vote
1
answer
2k
views
When using an Ansible playbook, how do you store and use a password containing quotes or other metacharacters without them being interpereted?
My company uses Ansible (which I am a novice at) and we have a playbook and a related role for joining new Linux machines to AD. Our admin accounts have their passwords rolled three times a day, and ...
2
votes
0
answers
127
views
Puppet - Get interface name from netplan yaml config
How to get interface name which has nameservers defined?
I want to get the interface name so I can pass it to another netplan puppet module so the nameservers can be replaced. But I only want to get ...
1
vote
1
answer
774
views
Create a tree-like structure with ansible
I have to create an LDAP structure with users and groups.
The groups are a bit complex with a lot of nested groups etc. I need to create a tree like structure in my inventory, like the following:
---...
1
vote
1
answer
1k
views
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:
...
1
vote
1
answer
1k
views
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 ...
1
vote
1
answer
413
views
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:
$...
0
votes
0
answers
204
views
Using 'archive_command' directive on postgres container in kubernetes 'invalid argument: "%p"
I've got Postgres 11.5-alpine running in kubernetes in a leader-follower setup that has been working well using streaming replication for some time.
I've decided to cover my bases by writing the WAL ...
1
vote
1
answer
421
views
Install gRPC php extension in elastic-beanstack [closed]
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 ...
2
votes
1
answer
2k
views
How can I enable epel-release before installing packages with cloud-init?
I'm trying to install a few packages on CentOS 8 via cloud-init, like this:
package_upgrade: true
packages:
- firewalld
- htop
One of them one of them requires epel-release repo to be installed ...
2
votes
1
answer
14k
views
How to use Ansible modules replace or inline instead shell command with SED
i have file with string:
MYAPP.db.username.DEV=MYUSERNAME
Where:
MYAPP mean name of applications
DEV means environment
MYUSERNAME means name of user for connection to db
I need to replace these ...
1
vote
1
answer
345
views
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 ...
6
votes
1
answer
8k
views
Adding an existing security group CloudFormation EC2 template
Instead of having to set ingress and egress rules, how do I reference existing EC2 security groups in a CloudFormation Template?
Resources:
EC2Instance:
Type: AWS::EC2::Instance
...
1
vote
1
answer
127
views
"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 ...