export CHEF_DOCKER_PATH=/path/to/docker/cookbook
chef-apply docka.rb
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Configuring DNS-over-TLS on macOS | |
# Worked on macOS 10.13.4 | |
brew -v update | |
brew -v doctor | |
# Next two commands are optional | |
sudo chown -R $(whoami) $(brew --prefix)/* | |
echo 'export PATH="/usr/local/sbin:$PATH"' >> ~/.bash_profile | |
# Install DNS client | |
brew install knot-resolver | |
# Should be installed to something like: /usr/local/Cellar/knot-resolver/2.3.0/sbin/kresd |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ssh key generator data source expects the below 3 inputs, and produces 3 outputs for use: | |
# "${data.external.ssh_key_generator.result.public_key}" (contents) | |
# "${data.external.ssh_key_generator.result.private_key}" (contents) | |
# "${data.external.ssh_key_generator.result.private_key_file}" (path) | |
data "external" "ssh_key_generator" { | |
program = ["bash", "${path.root}/../ssh_key_generator.sh"] | |
query = { | |
customer_name = "${var.customer_name}" | |
customer_group = "${var.customer_group}" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Chef::Resource::DockerContainer.class_eval do | |
property :dependencies_updated, [true, false] | |
def depends_on(resource) | |
subscribes :dependencies_updated, resource, :immediately | |
subscribes :run, resource | |
end | |
action :dependencies_updated do | |
new_resource.dependencies_updated true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
driver_config: | |
digitalocean_client_id: <%= ENV['DIGITAL_OCEAN_CLIENT_ID'] %> | |
digitalocean_api_key: <%= ENV['DIGITAL_OCEAN_API_KEY'] %> | |
provisioner: | |
name: chef_zero | |
require_chef_omnibus: latest | |
platforms: |