Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
# to generate your dhparam.pem file, run in the terminal | |
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048 |
#!groovy | |
# Best of Jenkinsfile | |
# `Jenkinsfile` is a groovy script DSL for defining CI/CD workflows for Jenkins | |
node { | |
} |
" Statusline (requires Powerline font) | |
set statusline= | |
set statusline+=%(%{&buflisted?bufnr('%'):''}\ \ %) | |
set statusline+=%< " Truncate line here | |
set statusline+=%f\ " File path, as typed or relative to current directory | |
set statusline+=%{&modified?'+\ ':''} | |
set statusline+=%{&readonly?'\ ':''} | |
set statusline+=%= " Separation point between left and right aligned items | |
set statusline+=\ %{&filetype!=#''?&filetype:'none'} | |
set statusline+=%(\ %{(&bomb\|\|&fileencoding!~#'^$\\\|utf-8'?'\ '.&fileencoding.(&bomb?'-bom':''):'') |
# import config. | |
# You can change the default config with `make cnf="config_special.env" build` | |
cnf ?= config.env | |
include $(cnf) | |
export $(shell sed 's/=.*//' $(cnf)) | |
# import deploy config | |
# You can change the default deploy config with `make cnf="deploy_special.env" release` | |
dpl ?= deploy.env | |
include $(dpl) |
When you're decomissioning a machine that has been managed by Puppet you may want to programatically clean up the node. There are two parts to this:
The following should work for Puppet 4.x and Puppet DB 4.x (including Puppet Enterprise 2016.4.x, 2017.1.x, 2017.2.x).
I've used certificate based auth, and the examples are being run from the puppet master so make use of existing certificates for authentication. When run remotely the cacert, certificate and corresponding private key for authentication will need to be present.
#!/bin/bash | |
# | |
# https://support.1password.com/command-line-getting-started/ | |
# | |
# Full docs: https://support.1password.com/command-line/ | |
# | |
# gpg --receive-keys 3FEF9748469ADBE15DA7CA80AC2D62742012EA22 | |
# gpg --verify op.sig op | |
# |
This script will read your secret file and set each line as an env variable in your container.
I' assuming that you already has a entrypoint file in your Dockerfile. So now, you need to copy and paste the contents of set_env_secrets.sh to your entrypoint(you don't need the first line).
Now, you need to create a secret, the name could be whatever you like. I'm using the name of my application as a pattern for my secrets name. For this example, my secret name will be super-project and the content will be.
hass:account | |
hass:alert | |
hass:alert-circle | |
hass:altimeter | |
hass:apple-safari | |
hass:apps | |
hass:arrow-bottom-left | |
hass:arrow-down | |
hass:arrow-left | |
hass:arrow-right |