Auto-select network name when creating a new instance

Asked by Kobi Laredo

I currently have only 1 network and when I create an instance in Horizon I always need to go to the Networking tab and select my network.
Ideally I'd like it to be auto-selected (like the default security group is). I looked in /usr/lib/python2.7/dist-packages/horizon/dashboards/nova/instances/workflows.py and noticed that the Security Group forms.MultipleChoiceField is using the "initial" attribute to auto select a security group named "default".
 I tried to apply the same logic to the SetNetworkAction workflow but it didn't work. Any suggestions why this attribute works for SetAccessControlsAction but not for SetNetworkAction?

Question information

Language:
English Edit question
Status:
Solved
For:
OpenStack Dashboard (Horizon) Edit question
Assignee:
No assignee Edit question
Solved by:
Kobi Laredo
Solved:
Last query:
Last reply:
Revision history for this message
Kobi Laredo (kobilaredo) said :
#1

I figured it out - I should have used the network ID as the initial attribute and not the netwok NAME.