This guide has moved to a GitHub repository to enable collaboration and community input via pull-requests.
https://github.com/alexellis/k8s-on-raspbian
Alex
// Types for the result object with discriminated union | |
type Success<T> = { | |
data: T; | |
error: null; | |
}; | |
type Failure<E> = { | |
data: null; | |
error: E; | |
}; |
// Types for the result object with discriminated union | |
type Success<T> = { | |
data: T; | |
error: null; | |
}; | |
type Failure<E> = { | |
data: null; | |
error: E; | |
}; |
using System; | |
using System.Threading.Tasks; | |
namespace System.Collections.Concurrent | |
{ | |
public static class ConcurrentDictionaryExtensions | |
{ | |
/// <summary> | |
/// Provides an alternative to <see cref="ConcurrentDictionary{TKey, TValue}.GetOrAdd(TKey, Func{TKey, TValue})"/> that disposes values that implement <see cref="IDisposable"/>. | |
/// </summary> |
const API = Cypress.env('API'); | |
const headers = { | |
Authorization: '', | |
}; | |
Cypress.Commands.add('loginUser', () => { | |
return cy.readFile('aad-tokens.json') | |
.then(creds => { | |
// set auth headers so test setup calls are authorized |
function getAadToken(user, password, identifier) { | |
return puppeteer.launch({ headless: true }).then(async browser => { | |
try { | |
const page = await browser.newPage(); | |
await page.goto("SITEURL"); | |
await page.click( | |
"LOGINBUTTON" | |
); |
--- | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: aspnetcoreapp | |
labels: | |
app: aspnetcoreapp | |
spec: | |
type: NodePort | |
ports: |
FROM microsoft/dotnet:2.0-sdk as builder | |
RUN mkdir -p /root/src/app/aspnetcoreapp | |
WORKDIR /root/src/app/aspnetcoreapp | |
#copy just the project file over | |
# this prevents additional extraneous restores | |
# and allows us to resuse the intermediate layer | |
# This only happens again if we change the csproj. | |
# This means WAY faster builds! |
using Org.BouncyCastle.Crypto; | |
using Org.BouncyCastle.Crypto.Parameters; | |
using Org.BouncyCastle.OpenSsl; | |
using Org.BouncyCastle.Security; | |
using System; | |
using System.IO; | |
using System.Security.Cryptography; | |
namespace MyProject.Data.Encryption | |
{ |
This guide has moved to a GitHub repository to enable collaboration and community input via pull-requests.
https://github.com/alexellis/k8s-on-raspbian
Alex
using ProjectTest.MyModels; | |
using SQLite.Net; | |
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
using Xamarin.Forms; | |
namespace ProjectTest.Database |