az deployment group create --resource-group ops-resource-group --template-file policy-template.json
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
| $connectTestResult = Test-NetConnection -ComputerName productteaminfrastruc458.file.core.windows.net -Port 445 | |
| if ($connectTestResult.TcpTestSucceeded) { | |
| # Save the password so the drive will persist on reboot | |
| cmd.exe /C "cmdkey /add:`"productteaminfrastruc458.file.core.windows.net`" /user:`"localhost\productteaminfrastruc458`" /pass:`"Lm9WNVgU5LVQaOqOjbN6yXN8u84okYFo9HCZU38NiExRq5JqoonM+cpMUOqVflFUycdhRATf26ghQfEivGiLAg==`"" | |
| # Mount the drive | |
| New-PSDrive -Name Z -PSProvider FileSystem -Root "\\productteaminfrastruc458.file.core.windows.net\productteaminstallers" -Persist | |
| } else { | |
| Write-Error -Message "Unable to reach the Azure storage account via port 445. Check to make sure your organization or ISP is not blocking port 445, or use Azure P2S VPN, Azure S2S VPN, or Express Route to tunnel SMB traffic over a different port." | |
| } |
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
| systemctl stop nginx |
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
| <div class="relative min-h-screen md:flex"> | |
| <!-- mobile menu bar --> | |
| <div class="bg-gray-800 text-gray-100 flex justify-between md:hidden"> | |
| <!-- logo --> | |
| <a href="#" class="block p-4 text-white font-bold">Better Dev</a> | |
| <!-- mobile menu button --> | |
| <button class="mobile-menu-button p-4 focus:outline-none focus:bg-gray-700"> | |
| <svg class="h-5 w-5" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor"> |
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
| // SQL Layer | |
| // TodayTransactions | |
| func (msl *MysqlLayer) TodayTransactions() ([]m.Product, error){ | |
| var todaysProducts []m.Product | |
| today:= time.Now() | |
| todayString:= today.Format("2006-01-02") | |
| err := msl.Session.Where("timeline >= ?", todayString).Find(&todaysProducts).Error | |
| if err != nil { | |
| return nil, err | |
| } |
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
| swagger: "2.0" | |
| info: | |
| version: "1.0.0" | |
| title: "First responder" | |
| description: "API ENDPOINT DOCUMENTTION FOR FIRST RESPONDER" | |
| termsOfService: "https://first-respond.herokuapp.com/" | |
| contact: | |
| name: "RIRST RESPONDER APP" | |
| license: | |
| name: "MIT" |
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
| package main | |
| import ( | |
| "bytes" | |
| "crypto/des" | |
| "errors" | |
| "fmt" | |
| "encoding/base64" | |
| //"golang.org/x/crypto/pbkdf2" | |
| ) |
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 React, { useState, useReducer, useEffect } from 'react'; | |
| import id from 'uuid/v4'; | |
| import Grudges from './Grudges'; | |
| import NewGrudge from './NewGrudge'; | |
| import initialState from './initialState'; | |
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
| package main | |
| import ( | |
| "fmt" | |
| "sort" | |
| ) | |
| func main() { | |
| population := map[string]int{ | |
| "Australia": 24982688, |
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
| package main | |
| import ( | |
| "fmt" | |
| "sort" | |
| ) | |
| type Pair struct { | |
| Key string | |
| Value int |
NewerOlder