Last active
November 20, 2022 08:21
-
-
Save ctd/9fbd0ed5b7d9be1aa532d11a0701bae1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Install and Enable the EPEL Repository for yum | |
amazon-linux-extras install -y epel | |
## Install packages generally required for building RPM packages | |
yum install -y yum-utils rpm-build redhat-rpm-config make | |
## Install build dependencies for mosh | |
yum-builddep -y mosh | |
## Download the source RPM for mosh | |
yumdownloader --source mosh-1.3.2-1.el7 | |
## Rebuild the RPM package locally | |
rpmbuild --rebuild mosh-1.3.2-1.el7.src.rpm | |
## The resulting RPM files will now be located in ~/rpmbuild/RPMS/ | |
## You can install these using `yum install $PATH_TO_RPM_FILE` | |
## e.g. `yum install ~/rpmbuild/RPMS/x86_64/mosh-1.3.2-1.amzn2.x86_64.rpm` | |
## The RPM file can be installed on any other Amazon Linux 2 machines of the same machine architecture without rebuilding it on each machine. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment