Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix System repositories are not restored on epicli re-run (v1.3) #2897

Merged
merged 4 commits into from
Jan 19, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -56,18 +56,19 @@ echol "Docker platform: $docker_platform"

enable_system_repos_script="/var/tmp/epi-repository-setup-scripts/enable-system-repos.sh"
disable_epirepo_client_script="/var/tmp/epi-repository-setup-scripts/disable-epirepo-client.sh"
apt_sources_list="/etc/apt/sources.list"

if [[ ! -f /etc/apt/sources.list ]]; then
if [[ ! -f $apt_sources_list || ! -s $apt_sources_list ]]; then
if [[ -f /var/tmp/enabled-system-repos.tar && -f $enable_system_repos_script ]]; then
echol "OS repositories seems missing, restoring..."
$enable_system_repos_script || exit_with_error "Could not restore system repositories"
$disable_epirepo_client_script || exit_with_error "Could not disable epirepo"
else
echol "/etc/apt/sources.list seems missing, you either know what you're doing or you need to fix your repositories"
echol "$apt_sources_list seems missing or is empty, you either know what you're doing or you need to fix your repositories"
fi
fi

check_connection apt '/etc/apt/sources.list'
check_connection apt $apt_sources_list

# install prerequisites which might be missing
prerequisites=(wget gpg curl tar)
Expand Down
1 change: 1 addition & 0 deletions docs/changelogs/CHANGELOG-1.3.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
- [#2420](https://github.com/epiphany-platform/epiphany/issues/2420) - Changing Grafana admin password in the apply mode
- [#2873](https://github.com/epiphany-platform/epiphany/issues/2873) - Epicli backup fails on schema validation
- [#2886](https://github.com/epiphany-platform/epiphany/issues/2886) - [Ubuntu] [PostgreSQL] Apply command fails after upgrading from v1.0.x LTS to v1.3.0
- [#2894](https://github.com/epiphany-platform/epiphany/issues/2894) - System repositories are not restored on epicli re-run

### Updated

Expand Down