Infrastructure for R peeps

Steph Locke (@SteffLocke)

2017-04-20

Poll

http://dpll.co/17175e5

Steph Locke

github.com/StephLocke | itsalocke.com | T: SteffLocke

Fundamentals

Fundamentals

Networks

  • Access
    • Names
    • IPs
    • Device addresses
    • Ports
  • Restricting access
    • Firewalls
  • Safety
    • Encryption
    • Whitelisting

Storage

  • Access
    • Persistence
    • Users
    • Metadata
  • Restricting access
    • Permissions
  • Safety
    • Role Based Access
    • Redundancy
    • Backups

OS

  • Access
    • Authentication systems
  • Restricting access
    • Permissions
  • Safety
    • User hygiene
    • Patching

PowerShell

The language for working with all things Microsoft these days.

Get-ChildItem | 
  Where Name -notlike "*.tar.gz" |
    Export-Csv "filelist.csv"

Import-Csv "filelist.csv"

Bash

The continued language of Linux

find . -maxdepth 1 ! -name '*.tar.gz' | 
  sed 's/[ \t]/,/g' > filelist.csv

cat filelist.csv

Call command line from R

Interactions are available from base package

?system  # not recommended
?system2 # works better with Windows too
?shell   # the lower level call

Windows / Linux file differences

  • Windows
  • Case insensitive
  • Permissions inherit from parent object by default
  • Linux
  • Case sensitive
  • Permisions inherit from user or one of other many overriding ways

Windows OS Variants

  • Windows 10 - not a server
  • Windows server YYYY - GUI
  • Windows Nano - Headless

Docker

Docker

  • Contained code
  • Scripted infrastructure
  • Bundled dependencies
  • Lower maintenance than VMs

Why use it?

  • Scripted installs
  • Saved from “Next, Next, Next”
  • Insanely disposable
  • Control your ops
  • Rapidly developing

Why not use it?

  • Insanely disposable
  • Control your ops
  • Rapidly developing

Why not use it? Versions

How to use it (locally)

  • Install it
  • Run the Docker Quickstart Terminal
docker run -it ubuntu /bin/bash

How to use it - demo

Docker-Machine

docker-machine is needed to run containers, work on remote machines hosting docker containers, and to work with swarm clusters

Docker plugins

Plugins allow you to extend docker capabilities. Most plugins are network and file system related.

Follow on

Next steps

Hard-won lessons

  • Do work today so tomorrow’s work is new and interesting
  • You’re only as good as your last restore
  • Use the VMs & the cloud
  • Never use sa
  • Virus scanning + database files never mixes well

Wrap up