Skip to content

Commit

Permalink
Merge pull request #361 from cradle8810/326_ntp
Browse files Browse the repository at this point in the history
Add ntp configuration
  • Loading branch information
cradle8810 authored Nov 2, 2024
2 parents 864620d + 0d05fee commit af7e278
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 0 deletions.
4 changes: 4 additions & 0 deletions inventories/group_vars/all.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,7 @@ all:
62663735663834613033633032613763376462346333343165653538383038633762636337316361
3738663863333931390a623839383165643363393537306635343237656337356534623036616465
6532
ntp_servers:
- "ntp1.jst.mfeed.ad.jp"
- "ntp2.jst.mfeed.ad.jp"
- "ntp3.jst.mfeed.ad.jp"
1 change: 1 addition & 0 deletions requirements.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ roles:
- name: compscidr.gpg
- name: geerlingguy.docker
- name: geerlingguy.jenkins
- name: geerlingguy.ntp
- name: mrlesmithjr.netplan
src: https://github.com/mrlesmithjr/ansible-netplan
version: 'f0167f5'
Expand Down
6 changes: 6 additions & 0 deletions tasks/all/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,12 @@
ansible.builtin.import_tasks:
file: tasks/all/set-locale.yml

- name: "Common / Set NTP"
ansible.builtin.import_tasks:
file: tasks/all/ntp.yml
tags:
- ntp

- name: "Common / Put authorized Key for hayato"
ansible.builtin.import_tasks:
file: tasks/all/authorized_keys.yml
Expand Down
10 changes: 10 additions & 0 deletions tasks/all/ntp.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
- name: "Common / NTP Setting"
ansible.builtin.import_role:
name: geerlingguy.ntp
vars:
ntp_enabled: true
ntp_timezone: "Asia/Tokyo"
ntp_servers: "{{ all.vars.ntp_servers }}"
ntp_tinker_panic: true
ntp_manage_config: true

0 comments on commit af7e278

Please sign in to comment.