https://gist.github.com/willurd/5720255 글에  정적 웹서버를 실행하는 한줄짜리 명령어 모음이 정리되었다.

Docker의 시대를 살고 있는 우리는 손쉽게 nginX나 Apache Httpd를 로컬에 격리된 공간에서 실행할 수 있지만, 간단한 정적 파일 서빙 테스트에는 부담스러운 옵션이긴 하다.

그래서 각 언어들이 제공하는 HTTPD 모듈을 통해 정적 웹서버를 흉내내 볼 수 있다.

 

나는 파이썬을 좋아하므로 다음 명령을 가장 많이 사용한다.

 

$ python -m http.server 8000

혹시나 하는 마음에   node를 실행할 경우에는 다음 두가지 방식을 사용하면 된다.

$ npm install -g http-server   # 의존패키지 설치
$ http-server -p 8000
$ npm install -g node-static   # 의존 패키지 설치
$ static -p 8000
반응형

felipecsl.com/2021/04/26/nobody-cares-about-your-beautiful-code.html 글에서 뽑아본 마음에 드는 영어 문장

 

Harsh truth is that "Users couldn't care less about the programming language you used or how beautiful, clean, modular and maintainable your code is. In face, they dont't give a crap about it"

가혹한 현실은 "사용자들은 당신이 어떤 프로그래밍 언어를 사용하는지, 코드가 얼마나 아름답고, 깔끔하고 유지보수가 가능한 수준인지에 대해 신경을 쓰지 않는다. 실제는 아예 그에 대한 관심이 없다."

 

Truth is, companies need to make a tradeoff between "move fast and break things" or grow in a steady, sustainable and healthy pace and be eaten up by competition. In the end, its' all about which startup is able to move faster and adapt quicker until they finally achieve enough traction to then take a step back and reevaluate early technical decisions

사실, 기업은 "빨리 움직여서 무언가를 혁신하여 깨부수거나" 꾸준히 지속가능한 건강한 페이스를 만들어 성장하지 않으면 경쟁자들에게 먹혀버린다. 결국 스타트업들은 충분한 추진력을 얻을때까지 빨리 움직이고 빨리 적응해야지만 한발  물러서서 초기 의사결정을 재평가할 수 있게 된다.

 

Often I see developers that seems to care more about wrting clean and beautiful code just for the sake of it. completely forgetting the bigger picture, why they are doing.  Still, wring highly clean, resusable and maintainable code is usually not a priority for companies in this category, It's just about shipping, getting the feature in front of users, A/B testing which flow works best, rip apart the failed experiments,rinse and repeat.

깨끗하고 아름다운 코드를 만드는데만 온통 신경을 쓰고, 정작 왜 그 일을 하고 있는지 큰 그림을 잊어버리는 개발자들을 많이 본다. 스타트업같은 기업들에게 깔끔한, 재사용가능한, 관리할 수 있는 코드를 작성하는 것은 우선순위가 아니다. 배포하고, 사용자들에게 새로운 기능을 제공하고, 어떤 동선이 최선인지 A/B테스트를 하고, 실패한 것에서 뭔가 수정해 보고 다시 내놓고 이 과정을 반복하는 것 뿐이다.

 

Ultimate, there is no right or wrong approach, it's mostly just the cost of doing business.

결국 옳고 그른 접근 방식은 없다. 이건 사업을 하는 비용일 뿐이다.

 

 

반응형

+ Recent posts