Skip to content

Instantly share code, notes, and snippets.

@vbrinza
vbrinza / kustomization.yaml
Created March 22, 2024 15:12
Dynamic Config Map
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: dynamic-conf-map
configMapGenerator:
- name: dynamic-conf-map-values
files:
- values.yaml=my-values.yaml
configurations:
- kustomizeconfig.yaml
$ dcos marathon debug details /sign-transformer-1 --json
{
"app": {
"backoffFactor": 1.15,
"backoffSeconds": 1,
"container": {
"docker": {
"forcePullImage": true,
"image": "host/sign_transformer:1.0.1",
"parameters": [],
stderr log:
(AT BEGINNING OF FILE)
I1024 13:32:10.584918 3 exec.cpp:162] Version: 1.5.0
I1024 13:34:17.866078 11 exec.cpp:527] Agent exited ... shutting down
I1024 13:34:17.866092 12 process.cpp:2139] Failed to shutdown socket with fd 7, address 172.31.254.11:41776: Transport endpoint is not connected
I1024 13:34:17.866214 6 v0_v1executor.cpp:172] Implicitly connecting the executor to shut it down
I1024 13:34:17.866448 4 executor.cpp:171] Received SHUTDOWN event
I1024 13:34:17.866942 4 executor.cpp:748] Shutting down
I1024 13:34:17.867290 12 process.cpp:887] Failed to accept socket: future discarded
{
"id": "/testing-ground/testing-mongo",
"instances": 1,
"container": {
"type": "MESOS",
"volumes": [
{
"containerPath": "/data/db",
"hostPath": "testing-mongo",
"mode": "RW"
{
"id": "/mongodb-testing-1",
"acceptedResourceRoles":["*"],
"backoffFactor": 1.15,
"backoffSeconds": 1,
"container": {
"portMappings": [
{
"containerPort": 27017,
"hostPort": 27017,
{
"AWSTemplateFormatVersion": "2010-09-09",
"Parameters" : {
"clouderaAccessIpBlocks": {
"Description": "Comma-delimited list of three CIDR blocks",
"Type": "CommaDelimitedList",
"Default": "IP1, IP2"
}
},
"Resources": {
variable "hcloud_token" {
default = "*********"
}
provider "hcloud" {
token = "${var.hcloud_token}"
}
resource "hcloud_server" "dcos-bootstrap" {
datacenter = "nbg1-dc3"
sudo python -v
# installing zipimport hook
import zipimport # builtin
# installed zipimport hook
# /usr/lib64/python2.6/site.pyc matches /usr/lib64/python2.6/site.py
import site # precompiled from /usr/lib64/python2.6/site.pyc
# /usr/lib64/python2.6/os.pyc matches /usr/lib64/python2.6/os.py
import os # precompiled from /usr/lib64/python2.6/os.pyc
import errno # builtin
import posix # builtin
1.1.1.1 | FAILED! => {
"changed": false,
"failed": true,
"invocation": {
"module_name": "yum"
},
"module_stderr": "OpenSSH_6.2p2, OSSLShim 0.9.8r 8 Dec 2011\ndebug1: Reading configuration data /etc/ssh_config\r\ndebug1: /etc/ssh_config line 20: Applying options for *\r\ndebug1: auto-mux: Trying existing master\r\ndebug2: fd 3 setting O_NONBLOCK\r\ndebug2: mux_client_hello_exchange: master version 4\r\ndebug3: mux_client_forwards: request forwardings: 0 local, 0 remote\r\ndebug3: mux_client_request_session: entering\r\ndebug3: mux_client_request_alive: entering\r\ndebug3: mux_client_request_alive: done pid = 62780\r\ndebug3: mux_client_request_session: session request sent\r\ndebug1: mux_client_request_session: master session id: 2\r\ndebug3: mux_client_read_packet: read header failed: Broken pipe\r\ndebug2: Received exit status from master 127\r\nShared connection to 1.1.1.1 closed.\r\n",
"module_stdout": "/var/tmp/sclFSRvGo: line 8: -H: command not found\r\n",
"msg": "MODU
$ ansible -i webs webs -m shell -a "sudo touch /root/shit" --user=username --become --become-user=username --become-method=sudo -vvvv
1.1.1.1 | SUCCESS | rc=0 >>
$ ansible -i webs webs -m shell -a "touch /root/shit" --user=username --become --become-user=username --become-method=sudo -vvvv
1.1.1.1 | FAILED | rc=1 >>
touch: cannot touch `/root/shit': Permission denied