AWS

環境
AWS EC2
AWS VPC Endpoint

操作方法
1.EC2 Instance Connect Endpoint用のセキュリティグループの作成
1).VPCコンソール画面に移 ...

AWS

環境
AWS S3
AWS EC2

操作方法
1.mountpoint-s3のインストール

$ wget sudo yum install ./mount-s3.rpm

2.Amazon ...

Ansible

環境
Red Hat Enterprise Linux release 9.2 (Plow)
Ansible 2.14.2
Python 3.11.2

概要
changed_when: re ...

Red Hat Enterprise Linux

環境
RHEL8.6

書式
curl -O
-Oオプション をつけてローカルにダウンロードします。

操作例
1.-Oオプション をつけずに実行する

$ curl html ...

Ansible

環境
Red Hat Enterprise Linux release 9.2 (Plow)
Ansible 2.14.2
Python 3.11.2

操作方法
1.作業ディレクトリを作成す ...

Ansible

環境

Red Hat Enterprise Linux release 9.2 (Plow)Ansible 2.14.2Python 3.11.2

実行コマンド
ansible $ansible-playbook - ...

Linux

概要
sshコマンド実行前にsshpassでパスワードを指定する
$ sshpass -p パスワード ssh ホスト名 -l ユーザ名

ファイルからパスワードを取得させる
$ sshpass -f ...

Ansible

環境
RHEL8.6

概要

- lineinfile:   path:対象のファイル名のパス名を指定   state: absent    regexp: '^%wheel'

‘^%wheel ...

Ansible

環境
RHEL8.6

概要

- lineinfile:   path:対象のファイル名のパス名を指定 regexp:編集対象とする行を示す正規表現を指定 line:挿入/置換する行を指定

操作例

- ...

Ansible

環境
AlmaLinux release 9.2 (Turquoise Kodkod)
構文
template: src=xxxx.j2 dest=/xxxx
templateモジュール自体はファイルコ ...

Ansible

環境
AlmaLinux release 9.2 (Turquoise Kodkod)

書式
ansible-playbook -i hosts チェック対象.yml –syntax-check ...

AlmaLinux 9

環境
AlmaLinux release 9.2 (Turquoise Kodkod)

操作方法
1.オプション指定なしでResponseBodyのみ出力
$ curl

結果 Hello,Li ...

Ansible

環境
RHEL8.6

概要
ansible.builtin.fail:
when: inventory_hostname == “ホスト名”
必ず 1 つのタスクをす ...

Ansible

環境
RHEL8.6

概要
playbook 実行するプレイブックファイルを指定する
-i インベントリーファイルを指定する
–list-tasks プレイブックを実行せず、実行 ...

AWS

環境
AWS VPC トラフィックミラーリング
AWS EC2 RHEL8.6

操作方法
1.EC2のインスタンスを作成する
セキュリティグループにインスタンスからUDP/4789の通信受信 ...

AWS

環境
AWS EC2 RHEL8.6
AWS Systems Manager

概要
セッションマネージャーを使用したローカルポートとリモートポート間のトラフィックの転送が可能になります。

AW ...

AWS

環境
AWS Systems Manager
AWS EC2 RHEL8.6

操作方法
1.SSMの設定でRun As supportを有効にする
1).AWS Systems Manage ...

Serverspec

環境
Red Hat Enterprise Linux release 9.2 (Plow)

操作方法
1.rubyのインストール
# dnf install ruby

略インストール済み: ...