Skip to content

This repo contains installation scripts for my personal environment (Win + Cygwin) and Ubuntu VM.

Notifications You must be signed in to change notification settings

roman-spiridonov/devops

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

91 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

About

This repo contains installation scripts for my personal VM. The initial scrips were a fork of Stanford startup-class settings (http://github.com/startup-class/setup) for Ununtu VM, but as of today they were modified significantly and morphed into my personal environment settings.

Installation

The procedure depends on the OS:

  • Ubuntu:
cd $HOME
sudo apt-get install -y git-core
git clone https://github.com/roman-spiridonov/devops
chmod +x ./devops/setup-ubuntu.sh
./devops/setup-ubuntu.sh
lynx -source rawgit.com/transcode-open/apt-cyg/master/apt-cyg > apt-cyg
install apt-cyg /bin
  1. Set up user's home: /etc/passwd > set up user's home, group and bash. Hint: Use /cygdrive/c instead of /home/.
  2. Execute ~/devops/setup-cygwin.sh to install totfiles. Note that the skeleton files reside in /etc/skel inside cygwin folder.
  3. Set up $PATH env variable to not contain spaces. Use c:\progra1 ("program files") and c:\progra2 ("program files (x86)").
  4. Make sure to include c:\cygwin64\bin in $PATH
  5. SSH
 chmod u+rwx known_hosts # for system to store identified hosts public keys
 chmod 700 ~/.ssh # .ssh settings folder
 chmod 400 key.pem # private key

Create ~/.ssh/config folder like the following:

Host awshost
HostName 54.213.193.148
User ubuntu
IdentityFile ~/.ssh/key.pem

Finally, set up SSH on Git:

  • Generate new key if necessary:
ssh-keygen -t rsa -b 4096 -C "[email protected]" # Creates a new ssh key, using the provided email as a label
  • Add the key to SSH agent:
eval $(ssh-agent -s) # launch SSH agent
ssh-add ~/.ssh/cg_aws_spiridonov.pem  # add key

dotfiles

This folder contains dotfiles (.bashrc, .nanorc, .emacs.d/init.el, etc.) for Ubuntu Linux and Cygwin.

The folder structure is as follows:

  • Common dotfiles (cross-OS) + Ubuntu: /dotfiles/*
  • Cygwin-specific dotfiles: /dotfiles/cygwin/*

Clone and run this on a new EC2 instance running Ubuntu 12.04.2 LTS to configure your the environment as follows:

cd $HOME

if [ -d .emacs.d/ ]; then
    mv .emacs.d .emacs.d~
fi

# Global
ln -sb devops/dotfiles/.nanorc .
ln -sb devops/dotfiles/dircolors.256dark ./.dircolors
ln -sb devops/dotfiles/.gitconfig .
ln -sb devops/dotfiles/.gitignore .
ln -sf devops/dotfiles/.emacs.d .

# Use for Ubuntu VM
ln -sb devops/dotfiles/.screenrc .
ln -sb devops/dotfiles/.bash_profile .
ln -sb devops/dotfiles/.bashrc .
ln -sb devops/dotfiles/.bashrc_custom .

# Use for cygwin
ln -sb devops/dotfiles/cygwin/.bash_profile .
ln -sb devops/dotfiles/cygwin/.bashrc .
ln -sb devops/dotfiles/cygwin/.minttyrc .
ln -sb devops/dotfiles/cygwin/.inputrc .
ln -sb devops/dotfiles/cygwin/.profile .

Git notes

In .gitconfig, note that the core.excludesfile refers to ~/.gitignore. This is the *nix way of defining the home directory. If you are using these dotfiles on Win system, you may need sometimes to fix this to be the following.

*nix:

git config --global core.excludesfile '~/.gitignore'

Windows:

git config --global core.excludesfile "%USERPROFILE%\.gitignore"

Emacs

Do emacs -nw hello.js and hit C-c! to launch an interactive SSJS REPL, among many other features.

Scripts

This folder contains helpful scripts.

  • colortest.sh - test color scheme after installing color packages (dircolors, solarized, etc.)

About

This repo contains installation scripts for my personal environment (Win + Cygwin) and Ubuntu VM.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •