Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
F
ffbs-gluon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
darkbit
ffbs-gluon
Commits
0db63008
Unverified
Commit
0db63008
authored
7 years ago
by
Matthias Schiffer
Browse files
Options
Downloads
Patches
Plain Diff
gluon-core: upgrade/220-interface-lan: whitespace cleanup
parent
5b09c641
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
package/gluon-core/luasrc/lib/gluon/upgrade/220-interface-lan
+23
-23
23 additions, 23 deletions
...age/gluon-core/luasrc/lib/gluon/upgrade/220-interface-lan
with
23 additions
and
23 deletions
package/gluon-core/luasrc/lib/gluon/upgrade/220-interface-lan
+
23
−
23
View file @
0db63008
...
...
@@ -7,35 +7,35 @@ local sysconfig = require 'gluon.sysconfig'
local
uci
=
require
(
'simple-uci'
).
cursor
()
if
not
sysconfig
.
lan_ifname
then
os.exit
(
0
)
os.exit
(
0
)
end
uci
:
section
(
'network'
,
'interface'
,
'mesh_lan'
,
{
ifname
=
sysconfig
.
lan_ifname
,
type
=
'bridge'
,
igmp_snooping
=
false
,
proto
=
'gluon_mesh'
,
transitive
=
true
,
fixed_mtu
=
true
,
ifname
=
sysconfig
.
lan_ifname
,
type
=
'bridge'
,
igmp_snooping
=
false
,
proto
=
'gluon_mesh'
,
transitive
=
true
,
fixed_mtu
=
true
,
})
if
uci
:
get
(
'network'
,
'mesh_lan'
,
'auto'
)
==
nil
then
local
enable
=
site
.
mesh_on_lan
if
enable
then
local
interfaces
=
uci
:
get_list
(
'network'
,
'client'
,
'ifname'
)
if
interfaces
then
for
lanif
in
sysconfig
.
lan_ifname
:
gmatch
(
'%S+'
)
do
if
util
.
contains
(
interfaces
,
lanif
)
then
enable
=
false
break
end
end
end
end
uci
:
set
(
'network'
,
'mesh_lan'
,
'auto'
,
enable
or
false
)
local
enable
=
site
.
mesh_on_lan
if
enable
then
local
interfaces
=
uci
:
get_list
(
'network'
,
'client'
,
'ifname'
)
if
interfaces
then
for
lanif
in
sysconfig
.
lan_ifname
:
gmatch
(
'%S+'
)
do
if
util
.
contains
(
interfaces
,
lanif
)
then
enable
=
false
break
end
end
end
end
uci
:
set
(
'network'
,
'mesh_lan'
,
'auto'
,
enable
or
false
)
end
uci
:
save
(
'network'
)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment