DataBase/PostgreSQL (2) 썸네일형 리스트형 PostgreSQL 도커로 실행하기 docker run --name postgreDb -d -p 5432:5432 -e POSTGRES_USER=test -e POSTGRES_PASSWORD=1234 postgres --name: 컨테이너 이름 -d: 컨테이너 백그라운드 실행 및 실행 후 컨테이너 아이디 출력 -p: 포트 포워딩 -e: 환경 변수 postgres: pull 받을 이미지명(tag가 없으면 자동으로 latest pull) docker exec -it CONTAINER_ID /bin/bash psql -U YOUR_USER_NAME(default: postgres) PostgreSQL 15 설치 및 연결(CentOS) 개발 환경 - OS: GCP CentOS 7 - 설치할 PostgreSQL: 15.1 1. RPM 레파지토리에 postgresql 추가 yum install -y https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm yum -y repolist 2. 시스템 업데이트 yum -y update 3. 종속성 레파지토리 추가 yum -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm 4. PostgreSQL 15 설치 yum -y install postgresql15-server psql -.. 이전 1 다음