Prerequisites: Kubernetes cluster and local kubectl configuration
- Look for which service account you want to use
$ kubectl -n kube-system get serviceaccount
- Retrieve the token name
1. Generate the certificate locally | |
openssl req -x509 -nodes -days 365 -newkey rsa:1024 -keyout azurecert.pem -out azurecert.pem -subj "/CN=My Azure Cert" | |
openssl x509 -inform pem -in azurecert.pem -outform der -out azurecert.cer | |
2. Navigate to https://manage.windowsazure.com | |
3. Click on Settings from the Menu | |
4. Select Management Certificates | |
5. Upload the cer file |
{ | |
"handler": "Microsoft.Compute.MultiVm", | |
"version": "0.0.1-preview", | |
"parameters": { | |
"basics": [ | |
{ | |
"name": "puppetMasterVmName", | |
"type": "Microsoft.Common.TextBox", | |
"label": "Puppet Enterprise Master VM Name", | |
"defaultValue": "puppetmaster", |
azure_vm { 'sample': | |
location => 'eastus', | |
image => 'linux:http://puppetimages.blob.core.windows.net/azure/PuppetEnterpriseMaster-2016_1_2-amd64-server-20160708-en-us-30GB.vhd', | |
# Possible implementation | |
# user_image_type => 'linux', | |
# user_image_uri => 'http://puppetimages.blob.core.windows.net/azure/PuppetEnterpriseMaster-2016_1_2-amd64-server-20160708-en-us-30GB.vhd' | |
user => 'azureuser', | |
password => 'Password', | |
size => 'Standard_A0', | |
resource_group => 'testresacc01', |
1. Run 'git rev-parse HEAD' # gets the current commit hash | |
2. Append the first 7 chars to the version in the metadata.json | |
3. Run `COPYFILE DISABLE=1 puppet module build` | |
4. puppet module install $pathto.tar.gz —-force —-ignore-dependencies | |
# --------------------------------------------------------------------------- | |
# | |
# Description: This file holds all my BASH configurations and aliases | |
# | |
# Sections: | |
# 1. Environment Configuration | |
# 2. Make Terminal Better (remapping defaults and adding functionality) | |
# 3. File and Folder Management | |
# 4. Searching | |
# 5. Process Management |
{ | |
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#", | |
"contentVersion": "1.0.0.0", | |
"parameters": { | |
"newStorageAccountName": { | |
"type": "string", | |
"metadata": { | |
"description": "Unique DNS Name for the Storage Account where the Virtual Machine's disks will be placed." | |
} | |
}, |
There are two API responses associated with an Azure VM: model view and instance view. | |
Documentation | |
https://docs.microsoft.com/en-us/rest/api/compute/virtualmachines/virtualmachines-get | |
Model view example: | |
{ | |
"id":"/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.Compute/virtualMachines/myVM", | |
"vmId": "{vm-id}", | |
"name":"virtualMachineName”, |
endpoint: https://tickets.puppetlabs.com | |
user: kenaz | |
project: DI | |
editor: vim | |
custom-commands: | |
- name: env | |
help: print the JIRA environment variables available to custom commands | |
script: | | |
env | grep JIRA |
endpoint: https://tickets.puppetlabs.com | |
user: kenaz | |
project: DI | |
editor: vim | |
custom-commands: | |
- name: env | |
help: print the JIRA environment variables available to custom commands | |
script: | | |
env | grep JIRA |