It happens that there are many standards for storing cryptography materials (key, certificate, ...) and it isn't always obvious to know which standard is used by just looking at file name extension or file content. There are bunch of questions on stackoverflow asking about how to convert from PEM to PKCS#8 or PKCS#12, while many tried to answer the questions, those answers may not help because the correct answer depends on the content inside the PEM file. That is, a PEM file can contain many different things, such as an X509 certificate, a PKCS#1 or PKCS#8 private key. The worst-case scenario is that someone just store a non-PEM content in "something.pem" file.
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
| # Scheduling the above script hourly. Ensure you're properly authenticated via aws configure. | |
| #!/bin/bash | |
| zip ebs-backup-worker.zip .schedule-ebs-snapshot-backups.py | |
| aws lambda create-function --function-name ebs-backup-worker \ | |
| --runtime python2.7 \ | |
| --role "arn for your lambda user's role" \ | |
| --handler lambda_handler \ | |
| --zip-file fileb:///ebs-backup-worker.zip |
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
| variable "region" {} | |
| variable "access_key" {} | |
| variable "secret_key" {} | |
| provider "aws" { | |
| version = "~> 1.25" | |
| region = "${var.region}" | |
| access_key = "${var.access_key}" | |
| secret_key = "${var.secret_key}"} |
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
| #r "Newtonsoft.Json" | |
| using System.Net; | |
| using Microsoft.AspNetCore.Mvc; | |
| using Microsoft.Extensions.Primitives; | |
| using Newtonsoft.Json; | |
| using System.Net.Http.Headers; | |
| public static async Task<IActionResult> Run(HttpRequest req, ILogger log) | |
| { |
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
| Download the CLI Version of NuGet | |
| https://dist.nuget.org/win-x86-commandline/latest/nuget.exe | |
| --Create Work Paths | |
| md c:\nuget | |
| md c:\nuget\source | |
| md c:\nuget\publish | |
| -- One-Time - Create local NuGet Repo/feed using a local drive path | |
| cd c:\nuget |
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
| import org.apache.hadoop.util.ShutdownHookManager | |
| import org.apache.spark.sql.streaming.StreamingQueryListener | |
| import org.apache.spark.sql.streaming.StreamingQueryManager | |
| import org.slf4j.LoggerFactory | |
| import java.util.UUID | |
| import java.util.concurrent.ConcurrentHashMap | |
| import java.util.concurrent.SynchronousQueue | |
| import java.util.concurrent.TimeUnit |
OlderNewer