본문 바로가기

리눅스 헛다리/Ubuntu

(15)
우분투24데스크탑 - 유튜브 다운로드 우분투24데스크탑 - 유튜브 다운로드​​터미널 열기 = 알트 + 컨트롤 + t ​#> sudo apt update​#> sudo apt install pipxpipx ensurepath​#> pipx install yt-dlp​#> sudo apt install ffmpeg​mp3 다운#> pipx run yt-dlp -x --audio-format mp3 https://www.youtube.com/watch?v=gNLW1wdIoCA​영상다운 mp4#> pipx run yt-dlp -f "bestvideo[ext=mp4]+bestaudio[ext=m4a]/mp4" https://www.youtube.com/watch?v=6ZUIwj3FgUY​​위에꺼 안돼는 경우#> pipx run yt-dlp -f "b..
우분투24 데스크탑 설치후 할일 우분투24 데스크탑 설치후 할일​1. sudo apt update​​​2. vim 설치 - vi는 방향키 오류 있을수 있음.#> sudo apt install vim​vi 실행시 vim 으로 실행#> sudo update-alternatives --config editor root@jhun-RF511:/etc/apt/sources.list.d# sudo update-alternatives --config editor대체 항목 editor에 대해 (/usr/bin/editor 제공) 4개 선택이 있습니다. 선택 경로 우선순� 상태------------------------------------------------------------* 0 /bin/..
우분투 systemd 데몬 사용 - 일정시간마다 동작처리 vi /etc/systemd/system/[서비스명].service​[Unit]Description=[서비스] Schedule TaskAfter=network.target​[Service]ExecStart=/usr/bin/php /home/[프로젝트]/spark schedule:your_schedule Restart=always ##RestartSec=3 ##User=[사용자]WorkingDirectory=/home/[프로젝트]StandardOutput=append:/var/log/[서비스명].logStandardError=append:/var/log/[서비스명].log----------------------------------------------------------------------------..
우분투 systemd 데몬 사용 - sh 파일 실행하기 (여기서는 특정시간에 동작 설정) vi /etc/systemd/system/bakup_sh.service[Unit]Description=설명 db를 백업할거야....After=network.targetRequires=network-online.target[Service]Type=oneshotUser=rootWorkingDirectory=/home/backup ExecStart=/home/backup/backup.sh   vi /etc/systemd/system/bakup_sh.timer[Unit]Description=설명 .....[Timer]OnCalendar=*-*-* 03:00:00   # systemd 새로고침sudo systemctl daemon-reload​#시스템 시작시 등록되었는지 확인systemctl i..
[ubuntu server 24.04] git설치및 git pull [ubuntu server 24.04] git설치및 git pull​​위 구조에서 운영서버 git pull 작업 ....​​- git 설치sudo apt install git​- 프로젝트 이동cd /프로젝트​​- 초기화git init​- user 등록git config --global user.email "이메일"git config --global user.name "이름"​​- 저장소 등록git remote add origin 저장소경로​- 저장소 등록시 에러문 발생할 경우에러메시지 :fatal: detected dubious ownership in repository at '경로'To add an exception for this directory, call: (안전한 디렉토리가 아니라고 경고) 아래..
우분투24.04 ftp 설정 apt install vsftpd​​​vi /etc/vsftpd.conf# Example config file /etc/vsftpd.conf## The default compiled in settings are fairly paranoid. This sample file# loosens things up a bit, to make the ftp daemon more usable.# Please see vsftpd.conf.5 for all compiled in defaults.## READ THIS: This example file is NOT an exhaustive list of vsftpd options.# Please read the vsftpd.conf.5 manual page to get a ..
우분투 sftp 권한 처리(nginx 루트경로를 /var/www/html/ 인경우 ) 우분투 sftp 권한 처리(nginx 루트경로를 /var/www/html/ 인경우 )​​nginx 웹 루트 경로를 /var/www/html/ 하위로 사용할 경우​sftp로 파일 및 폴더를 올리려면 권한이 필요하다.​chown www-data , chmod 를 했어도 권한이 없어서 폴더가 생성이 되지 않는다.​sftp 설정에서 권한을 줘야 한다.​vi /etc/ssh/sshd_config​ 그룹으로 주던가Match Group www-data ChrootDirectory / ForceCommand internal-sftp 유저명으로 주던가 Match User user001 ChrootDirectory /user001 ForceCommand internal-sftp 그룹으로 하던 유저로 ..
우분투24.04서버 nginx설치03 [vhost설정] 1. nginx.conf 확인sudo vi /etc/nginx/nginx.conf​include /etc/nginx/sites-enabled/*; 있는지 확인​2. vhost 설정 폴더 확인​/etc/nginx 에 sites-available sites-available 폴더 확인​​sudo vi /etc/nginx/sites-available/lore2.vm-ubuntu.com​server {listen 80;server_name lore2.vm-ubuntu.com;​root /home/lore2/public_html;index index.html index.htm index.php;​location / {try_files $uri $uri/ =404;}​error_page 404 /404.html;​..