mirror of
https://github.com/rancher/os.git
synced 2025-07-01 17:21:50 +00:00
treat 404 error on datasource as unrecoverable
Signed-off-by: Sven Dowideit <SvenDowideit@home.org.au>
This commit is contained in:
parent
391082fa50
commit
78051c2814
@ -276,6 +276,7 @@ func selectDatasource(sources []datasource.Datasource) datasource.Datasource {
|
|||||||
for {
|
for {
|
||||||
log.Infof("cloud-init: Checking availability of %q\n", s.Type())
|
log.Infof("cloud-init: Checking availability of %q\n", s.Type())
|
||||||
if s.IsAvailable() {
|
if s.IsAvailable() {
|
||||||
|
log.Infof("cloud-init: Datasource GOOD: %s", s)
|
||||||
ds <- s
|
ds <- s
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -45,6 +45,11 @@ func (f *RemoteFile) String() string {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (f *RemoteFile) AvailabilityChanges() bool {
|
func (f *RemoteFile) AvailabilityChanges() bool {
|
||||||
|
if f.lastError != nil {
|
||||||
|
if _, ok := f.lastError.(pkg.ErrNotFound); ok {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
}
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user