Skip to content

Instantly share code, notes, and snippets.

@lesstif
Created October 22, 2020 04:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lesstif/27be5cbe389a65ff140c98f8b7a0c3fc to your computer and use it in GitHub Desktop.
Save lesstif/27be5cbe389a65ff140c98f8b7a0c3fc to your computer and use it in GitHub Desktop.
RHEL 계열 배포판에서 yum/dnf 로 설치한 패키지 목록을 "dnf insatll " 구문을 붙여서 재출력(다른 서버에서 재활용하려고)
#!/bin/sh
PACKAG="php"
dnf list installed | grep ${PACKAG} | awk 'BEGIN {printf "dnf install -y " } {printf $1 " "}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment