Skip to content

Commit

Permalink
fix: configure and enable systemd-timesyncd (#12262)
Browse files Browse the repository at this point in the history
Signed-off-by: Oriol Batalla <obatalla@fb.com>
  • Loading branch information
uri200 authored and tmdzk committed Mar 24, 2022
1 parent 73e6114 commit 7d82fd0
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lte/gateway/deploy/agw_install_ubuntu.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ DEPLOY_PATH="/home/$MAGMA_USER/magma/lte/gateway/deploy"
SUCCESS_MESSAGE="ok"
NEED_REBOOT=0
WHOAMI=$(whoami)
MAGMA_VERSION="${MAGMA_VERSION:-v1.6}"
MAGMA_VERSION="${MAGMA_VERSION:-v1.7}"
CLOUD_INSTALL="cloud"
GIT_URL="${GIT_URL:-https://github.com/magma/magma.git}"
INTERFACE_DIR="/etc/network/interfaces.d"
Expand Down
19 changes: 19 additions & 0 deletions lte/gateway/deploy/roles/dev_common/files/timesyncd.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# This file is part of systemd.
#
# systemd is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2.1 of the License, or
# (at your option) any later version.
#
# Entries in this file show the compile time defaults.
# You can change settings by editing this file.
# Defaults can be restored by simply deleting this file.
#
# See timesyncd.conf(5) for details.

[Time]
NTP=0.pool.ntp.org 1.pool.ntp.org 2.pool.ntp.org 3.pool.ntp.org
#FallbackNTP=ntp.ubuntu.com
#RootDistanceMaxSec=5
#PollIntervalMinSec=32
#PollIntervalMaxSec=2048
11 changes: 11 additions & 0 deletions lte/gateway/deploy/roles/dev_common/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,17 @@
- ansible
retries: 5

- name: Copy over the timesyncd config
become: yes
copy:
src: timesyncd.conf
dest: /etc/systemd/timesyncd.conf

- name: Make sure timesyncd is started
systemd:
name: systemd-timesyncd.service
state: started

- name: Copy ssh keepAlive configs
copy: src={{ item.src }} dest={{ item.dest }}
become: yes
Expand Down
2 changes: 1 addition & 1 deletion lte/gateway/deploy/roles/magma_deploy/vars/all.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
magma_pkgrepo_proto: https
magma_pkgrepo_host: artifactory.magmacore.org/artifactory/debian
magma_pkgrepo_path: ""
magma_pkgrepo_dist: focal-1.6.1
magma_pkgrepo_dist: focal-1.7.0
magma_pkgrepo_component: main
magma_pkgrepo_name: "magma"

Expand Down
2 changes: 1 addition & 1 deletion lte/gateway/release/upgrade_magma.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash

WHOAMI=$(whoami)
MAGMA_VERSION="1.6.1"
MAGMA_VERSION="1.7.0"
# Default is focal
OS_VERSION="focal"

Expand Down

0 comments on commit 7d82fd0

Please sign in to comment.