Git 大文件存储/如何在 AWS EC2 Linux 2 上安装 git lfs /“没有可用的 git-lfs 包。”
如何在 Amazon EC2 (Amazon Linux 2) 实例上安装 git-lfs
?
基于 https://github.com/git-lfs/git -lfs/blob/main/INSTALLING.md 我尝试过吗:
sudo yum install git -y;
cd /home/ec2-user;
curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.rpm.sh | sudo bash
-> which tells me afterwards:
The repository is setup! You can now install packages.
sudo yum install git-lfs
-> gives me:
Loaded plugins: extras_suggestions, langpacks, priorities, update-motd
No package git-lfs available.
Error: Nothing to do
未来的命令(尚不可能 duo git:'lfs' 不是 git 命令。请参阅'git --help'。
之后git lfs install
)将基于https://git-lfs.github。 com/
git lfs install
...
git clone https://yourrepo.git;
Amazon Linux 2 AMI (HVM) - 内核 5.10,SSD 卷类型/Arm
How to install git-lfs
on an Amazon EC2 (Amazon Linux 2) instance?
Based on https://github.com/git-lfs/git-lfs/blob/main/INSTALLING.md did I tried:
sudo yum install git -y;
cd /home/ec2-user;
curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.rpm.sh | sudo bash
-> which tells me afterwards:
The repository is setup! You can now install packages.
sudo yum install git-lfs
-> gives me:
Loaded plugins: extras_suggestions, langpacks, priorities, update-motd
No package git-lfs available.
Error: Nothing to do
Future commands (not possible yet duo git: 'lfs' is not a git command. See 'git --help'.
after git lfs install
) would than be based on https://git-lfs.github.com/
git lfs install
...
git clone https://yourrepo.git;
Amazon Linux 2 AMI (HVM) - Kernel 5.10, SSD Volume Type / Arm
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
借助 Amazon Linux 2,您可以使用 Extras 库在实例上安装应用程序和软件更新。这些软件更新称为主题。
步骤如下:
使用 SSH 连接到您的 EC2 Linux 实例。
使用 which 命令确认 amazon-linux-extras 软件包已安装:
如果未安装 amazon-linux-extras 软件包,您可以使用 yum 进行安装:
列出可用主题,您可以使用以下命令:
git-lfs
通常作为 epel-release 的一部分提供,因此您需要首先安装适用于 Amazon Linux 的 epel 版本:对于 Amazon Linux AMI,请访问企业 Linux 的额外软件包(EPEL) 存储库已配置,但默认情况下未启用。
With Amazon Linux 2, you can use the Extras Library to install application and software updates on your instances. These software updates are known as topics.
Below are the steps:
Connect to your EC2 Linux instance using SSH.
Use the which command to confirm that the amazon-linux-extras package is installed:
If the amazon-linux-extras package isn't installed, you can use yum to install it:
To list the available topics, you can use the following command:
git-lfs
usually comes as part of the epel-release, so you need to first to install epel release for Amazon Linux:For the Amazon Linux AMI, access to the Extra Packages for Enterprise Linux (EPEL) repository is configured, but it is not enabled by default.
git-lfs
or whatever else you like from epel-release:如 packagecloud[1] 中所述,您需要运行:
来安装依赖项和存储库。或者,您可以直接从 [1] 获取脚本。然后,您可以简单地使用 yum 安装:
[1] https://packagecloud.io /github/git-lfs/install#bash-rpm
As described on packagecloud[1], you need to run:
to install the dependencies and the repos. Alternatively you can take the script from [1] directly. You can then simply install with yum:
[1] https://packagecloud.io/github/git-lfs/install#bash-rpm
您需要直接安装 ARM64 git-lfs 二进制文件:
现在,在 ARM64 上享受您的 GIT-LFS。
You need to directly install the ARM64 git-lfs binaries:
Now, enjoy your GIT-LFS on ARM64.