Merge pull request #1619 from swordqiu/hotfix/qj-add-default-network-priviliges

Hotfix/qj add default network priviliges
This commit is contained in:
yunion-ci-robot
2019-07-09 17:17:57 +08:00
committed by GitHub
3 changed files with 14 additions and 1 deletions
+12
View File
@@ -206,6 +206,18 @@ var (
Action: PolicyActionGet,
Result: rbacutils.Allow,
},
{
Service: "compute",
Resource: "networks",
Action: PolicyActionGet,
Result: rbacutils.Allow,
},
{
Service: "compute",
Resource: "networks",
Action: PolicyActionList,
Result: rbacutils.Allow,
},
{
Service: "image",
Resource: "images",
+1 -1
View File
@@ -19,9 +19,9 @@ import (
"fmt"
"time"
"github.com/pkg/errors"
"yunion.io/x/jsonutils"
"yunion.io/x/log"
"yunion.io/x/pkg/errors"
api "yunion.io/x/onecloud/pkg/apis/compute"
"yunion.io/x/onecloud/pkg/cloudcommon/db"
+1
View File
@@ -105,6 +105,7 @@ func rangeObjHandler(
httperrors.GeneralServerError(w, err)
return
}
log.Debugf("%s %s", ownerId, scope)
query := getQuery(r)
hostTypes := json.GetQueryStringArray(query, "host_type")
// resourceTypes := json.GetQueryStringArray(query, "resource_type")