This file contains 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
Write-Host "Installing Yarn..." -ForegroundColor Cyan | |
Write-Host "Downloading..." | |
$msiPath = "$env:TEMP\yarn.msi" | |
(New-Object Net.WebClient).DownloadFile('https://yarnpkg.com/latest.msi', $msiPath) | |
Write-Host "Installing..." | |
cmd /c start /wait msiexec /i "$msiPath" /quiet | |
Write-Host "Yarn installed" -ForegroundColor Green |
This file contains 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
version: '2.2' | |
services: | |
es01: | |
image: docker.elastic.co/elasticsearch/elasticsearch:7.8.0 | |
container_name: es01 | |
environment: | |
- node.name=es01 | |
- cluster.name=es-docker-cluster | |
- discovery.seed_hosts=es02,es03 | |
- cluster.initial_master_nodes=es01 |
This file contains 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
docker stop $(docker ps -aq) | |
docker rm $(docker ps -aq) | |
docker rmi $(docker images -q) |
This file contains 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
Set-NetConnectionProfile -interfacealias "vEthernet (DockerNAT)" -NetworkCategory Private |
This file contains 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
# [<tag>] (If applied, this commit will...) <subject> (Max 72 char) | |
# |<---- Preferably using up to 50 chars --->|<------------------->| | |
# Example: | |
# [feat] Implement automated commit messages | |
# (Optional) Explain why this change is being made | |
# |<---- Try To Limit Each Line to a Maximum Of 72 Characters ---->| | |
# (Optional) Provide links or keys to any relevant tickets, articles or other resources | |
# Example: Github issue #23 |
This file contains 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
Write-Host "Removing remote branches from origin that were merged to develop" | |
git branch -r --merged | Where { $_ -NotMatch "(^\*|master|develop|help|remote)" } | %{ git push origin --delete $_.Trim().replace('origin/', '')} |
This file contains 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
Write-Host "Removing local branches that were merged to develop" | |
git branch --merged | Where { $_ -NotMatch "(^\*|master|develop|help|remote)" } | %{git branch -d $_.Trim()} |
This file contains 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
# Switch HyperV off | |
bcdedit /set hypervisorlaunchtype off | |
#Switch HyperV on | |
bcdedit /set hypervisorlaunchtype auto | |
#Above require system reboot but allow quick toggle so switch from HyperV to VirtualBox can be done painless |
This file contains 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
FROM node:10.6.0-alpine AS build | |
WORKDIR /src | |
COPY ${PROJECT_NAME}/package*.json ./ | |
RUN npm install | |
COPY ${PROJECT_NAME}/ . | |
RUN npm run build | |
FROM nginx:alpine | |
EXPOSE 80 | |
COPY ${PROJECT_NAME}/nginx.conf /etc/nginx/nginx.conf |
This file contains 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
using System; | |
using System.Runtime.InteropServices; | |
namespace ItWorks.Api.Infrastructure | |
{ | |
public static class UUId | |
{ | |
/// <summary> | |
/// This method can be used to retrieve well formed universally unique id. The advantage is, it has no vulnerability what GUID v1 and has good distribution so won't overload SQL Server | |
/// </summary> |
NewerOlder