Docker 6

Docker로 프로젝트(Springboot), DB(Postgres), 캐시(Redis) 연동하기

취미생활로 프로젝트를 하나 시작했다. 아직 github에 push 하진 않았지만 시작 중 방법을 올려보려고 한다. # Use postgres/example user/password credentials version: '3' services: goose-auth-api: image: gudrb963/goose-auth-api:latest container_name: goose-auth-api build: context: . ports: - 8080:8080 depends_on: - postgres environment: - SPRING_DATASOURCE_URL=jdbc:postgresql://postgres:5432/gooseauth - SPRING_DATASOURCE_USERNAME=gooseauth..

Docker 2022.07.15

docker 삭제, docker reinstall, docker uninstall

OS : Windows 10 64bit Docker Desktop 사용 중 이와 같은 창에서 프로그래스 바가 넘어가지 않아 docker를 실행 할 수도 삭제 할 수도 없는 상황에 처했다. registry를 삭제 후 삭제하면 깔끔하게 삭제가 된다. 입력 후 레지스트리 창을 켠다. HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Docker Desktop Docker Desktop registry key를 삭제한다. 그 후 다시 프로그램 추가제거에서 docker desktop 삭제를 시도하면 정상적으로 삭제가 되는 것을 확인 할 수 있다. 출처 https://github.com/docker/for-win/issues/7489 Un..

Docker 2021.11.05

docker 이미지 생성, docker hub 업로드, docker springboot mysql 연동

application.yml 혹은 application.properties 파일 수정 ​ 우선 local에서 작업한 springboot 프로젝트를 docker 이미지로 뽑아내기 위해 application.yml 혹은 application.properties 파일을 수정해야한다. //application.properties spring.datasource.url=jdbc:mysql://my_mysql:3306/mydatabase?useSSL=false&useUnicode=true&serverTimezone=Asia/Seoul&allowPublicKeyRetrieval=true application.properties 내용에 위 내용 말고도 다른 내용이 많을 것으로 예상된다. localhost 혹은 127...

Docker 2021.10.22

Docker 설치 mysql 설치 및 실행하기 Ubuntu 18.04

현재 서버에는 mysql 없음 ko@ko-MS-16F1:~$ mysql Command 'mysql' not found, but can be installed with: sudo apt install mysql-client-core-5.7 sudo apt install mariadb-client-core-10.1 설치 시작 ​ ​ Docker 저장소 설정 sudo apt-get update # 패키지 다운로드 sudo apt-get install apt-transport-https ca-certificates curl gnupg-agent software-properties-common # Docker GPG 키 추가 sudo curl -fsSL https://download.docker.com/linux..

Docker 2021.10.22

docker mysql Unknown or incorrect time zone : 'Asia/Seoul'

docker mysql에서 time_zone 설정 중 ​ Unknown or incorrect time zone : 'Asia/Seoul' 오류가 나왔다. docker mysql /bin/bash 접속 root@05bcc7dfec1c:/# mysql_tzinfo_to_sql /usr/share/zoneinfo | mysql -u root -p mysql Enter password: Warning: Unable to load '/usr/share/zoneinfo/iso3166.tab' as time zone. Skipping it. Warning: Unable to load '/usr/share/zoneinfo/leap-seconds.list' as time zone. Skipping it. Warning..

Docker 2021.10.22

docker tomcat HTTP 상태 404 – 찾을 수 없음

synology nas를 사용했다 ​ 최신버전 다운받고 ​ 기본 설정 (포트번호 8080)으로 바로 실행 후 켜보니 404 오류가 나왔다. ​ GUI에서 안되길래 답답해서 ssh 환경에서 진행했다. ​ 아래처럼 해결했다. ~$ docker run -d --name myTomcat -p 8080:8080 tomcat:latest ~$ docker exec -it myTomcat /bin/bash ~$ mv webapps webapps2 ~$ mv webapps.dist/ webapps ~$ exit IT WORKS ​ https://forums.docker.com/t/tomcat-give-error-404/95130 Tomcat give error 404 Hi guys, After running tomca..

Docker 2021.10.22