docker

https://0422.tistory.com/294 Docker compose로 테스트 코드 환경 구성하기(express + TypeORM) - typeORM, Jest 설정 컨테이너 설정은 다했으니 TypeORM과 Jest의 설정을 해보자. Data-Source.ts 일단 나는 DataSource방식으로DAO코드를 작성했다. https://orkhan.gitbook.io/typeorm/docs/data-source Working with DataSource - typeorm Generally, you ca 0422.tistory.com 위 글에서 이어진다. 문제 현재 유닛 테스트, 통합테스트는 로컬 환경에서만 가능하다. 이걸 배포시에 자동으로 테스트한뒤 배포해보자(배포구성은 이미 되어있음) 유닛테스트,..
컨테이너 설정은 다했으니 TypeORM과 Jest의 설정을 해보자. Data-Source.ts 일단 나는 DataSource방식으로DAO코드를 작성했다. https://orkhan.gitbook.io/typeorm/docs/data-source Working with DataSource - typeorm Generally, you call initialize method of the DataSource instance on application bootstrap, and destroy it after you completely finished working with the database. In practice, if you are building a backend for your site and you..
드디어 도커 컨테이너를 활용해서 테스트코드를 작성해보자. 로컬에서 db를 비우고, 테스트하고, 다시 비우면 너무 일이 많으므로, test시도시에 컨테이너를 띄우고, 모든 테스트를 완료한 후에 컨테이너를 내리는 식으로 테스트를 진행할 것이다. 일단 docker-compose.yml을 작성해서 mySQL 컨테이너를 하나 띄워주자 version: '3' services: mySQLContainer: image: mysql container_name: mySQLContainer command: - --default-authentication-plugin=mysql_native_password - --character-set-server=utf8 - --collation-server=utf8_general_ci ..
_0422
'docker' 태그의 글 목록