[Startup Engineering] HW6-1. (1)

HW6.1

First, go through the lecture 7 notes and convert your github repository to use the dev/staging/production flow. As a very first task, update your index.html to the new version here (link); this fixes a bug with missing row-fluid classes and adds alt attributes to all image properties. See if you can do this by editing index.html in the develop git branch, merging into the staging branch, previewing, and then merging into the master branch.

현재 1번과제 진행 중...

1. 새로운 EC2 instance 생성 및 사용하던 instance terminate

2. 처음에 했던 세팅 모두 재설정: node, heroku, git, setup.sh, dotfile 등등 전부 재설치.

[sourcecode language="bash"]
# Connect AWS
[local]$chmod 400 .pem
[local]$ssh -i .pem ubuntu@publicIP //can see EC2 > instance > connect

## Execute these commands on your EC2 instance.

# Install heroku and git
[server]$ sudo apt-get install -y git-core
[server]$ wget -qO- https://toolbelt.heroku.com/install-ubuntu.sh | sh
[server]$ which git
[server]$ which heroku

# Login and set up your SSH keys
[server]$ heroku login
[server]$ ssh-keygen -t rsa
[server]$ heroku keys:add

# Clone a sample repo and push to heroku
[server]$ git clone https://github.com/heroku/node-js-sample.git
[server]$ cd node-js-sample
[server]$ heroku create
[server]$ git push heroku master

# setup.git
[server]$ sudo apt-get install -y git-core
[server]$ git clone https://github.com/startup-class/setup.git
[server]$ ./setup/setup.sh

# dotfiles.git
[server]$ git clone https://github.com/startup-class/dotfiles.git
[server]$ ln -sb dotfiles/.screenrc .
[server]$ ln -sb dotfiles/.bash_profile .
[server]$ ln -sb dotfiles/.bashrc .
[server]$ ln -sb dotfiles/.bashrc_custom .
[server]$ mv .emacs.d .emacs.d~
[server]$ ln -s dotfiles/.emacs.d .

#clone repogitory
[server]$ git clone https://github.com/minieetea/bitstarter.git //HTTPS clone URL of github repository

[/sourcecode]

3. node web.js 테스트 시 주의 : $ npm install express (posted: module.js 340 err)
[변경된 듯]

[sourcecode language="bash"]
Warning: express.createServer() is deprecated, express
applications no longer inherit from http.Server,
please use:
var express = require("express");
var app = express();
[/sourcecode]

4. 8080 port 테스트 후 index.html 파일 교체.

instance를 새로 생성해서 git push heroku master 하려고 하니, heroku app이 없고(당연함), 새로 생성하려고 하니 app 제한 있다며 리젝 -_ -

[sourcecode language="bash"]
[server:~/bitstarter]$ git add index.html
[server:~/bitstarter]$ git commit -m "new version index.html"
[server:~/bitstarter]$ git push origin master

#if you need login,
[server:~/bitstarter]$ heroku login

[server:~/bitstarter]$ git push heroku master
fatal: 'heroku' does not appear to be a git repository
fatal: The remote end hung up unexpectedly

[server:~/bitstarter]$ heroku create
! You've reached the limit of 5 apps for unverified accounts.
! Add a credit card to verify your account.

[server:~/bitstarter]$ git push heroku master
Counting objects: 440, done.
[/sourcecode]


# How to delete Heroku App

1. Login Heroku account
2. Select to delete Heroku app in list
3. Choose Settings
스크린샷 2013-08-06 오전 4.00.23
4. Click the delete app
스크린샷 2013-08-06 오전 4.00.53

5. Enter App name and Click the Delete button.

적게 일하고 많이 버는 법을 늘 고민합니다. 일이 되게 하는 것에 간혹 목숨을 겁니다. 지금은 우아한형제들과 함께 일하고 있어요.