LoginSignup
0
0

Incus: Gentoo Linux を使う

Last updated at Posted at 2024-02-03

image を探す

incus image list images:gentoo | grep amd64

コンテナーのインストール

incus launch images:gentoo/systemd/amd64 gentoo

インストールされたことを確認

incus list gentoo
$ incus list gentoo
+--------+---------+----------------------+------+-----------+-----------+
|  NAME  |  STATE  |         IPV4         | IPV6 |   TYPE    | SNAPSHOTS |
+--------+---------+----------------------+------+-----------+-----------+
| gentoo | RUNNING | 10.56.160.170 (eth0) |      | CONTAINER | 0         |
+--------+---------+----------------------+------+-----------+-----------+

root パスワードの設定

incus exec gentoo bash
$ incus exec gentoo bash
gentoo ~ # 

login

incus console gentoo
$ incus console gentoo
To detach from the console, press: <ctrl>+a q

gentoo login:

Login 後の設定

ユーザー、パスワードの設定

useradd -u 1200 -m -G users,wheel,audio -s /bin/bash uchida
passwd uchida

sudo のインストール

emerge -avt app-admin/sudo --quiet

sshd のインストール

emerge -avt openssh --quiet
systemctl start sshd.service
systemctl enable sshd.service

vim のインストール

emerge --ask app-editors/vim

作成したユーザーでログイン

ssh 10.56.160.170

タイムゾーンの設定

sudo timedatectl set-timezone Asia/Tokyo
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0