Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
packer
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kristopher Ruzic
packer
Commits
10612b5d
Commit
10612b5d
authored
Oct 28, 2014
by
Vasiliy Tolstov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
try to avoid pagination
Signed-off-by:
Vasiliy Tolstov
<
v.tolstov@selfip.ru
>
parent
8f9e9abc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
builder/digitalocean/api_v2.go
builder/digitalocean/api_v2.go
+3
-3
No files found.
builder/digitalocean/api_v2.go
View file @
10612b5d
...
...
@@ -200,7 +200,7 @@ func (d DigitalOceanClientV2) CreateSnapshot(id uint, name string) error {
func
(
d
DigitalOceanClientV2
)
Images
()
([]
Image
,
error
)
{
res
:=
ImagesResp
{}
err
:=
NewRequestV2
(
d
,
"v2/images"
,
"GET"
,
nil
,
&
res
)
err
:=
NewRequestV2
(
d
,
"v2/images
?per_page=200
"
,
"GET"
,
nil
,
&
res
)
if
err
!=
nil
{
return
nil
,
err
}
...
...
@@ -364,7 +364,7 @@ func (d DigitalOceanClientV2) Image(slug_or_name_or_id string) (Image, error) {
// Returns all available regions.
func
(
d
DigitalOceanClientV2
)
Regions
()
([]
Region
,
error
)
{
res
:=
RegionsResp
{}
err
:=
NewRequestV2
(
d
,
"v2/regions"
,
"GET"
,
nil
,
&
res
)
err
:=
NewRequestV2
(
d
,
"v2/regions
?per_page=200
"
,
"GET"
,
nil
,
&
res
)
if
err
!=
nil
{
return
nil
,
err
}
...
...
@@ -407,7 +407,7 @@ func (d DigitalOceanClientV2) Region(slug_or_name_or_id string) (Region, error)
// Returns all available sizes.
func
(
d
DigitalOceanClientV2
)
Sizes
()
([]
Size
,
error
)
{
res
:=
SizesResp
{}
err
:=
NewRequestV2
(
d
,
"v2/sizes"
,
"GET"
,
nil
,
&
res
)
err
:=
NewRequestV2
(
d
,
"v2/sizes
?per_page=200
"
,
"GET"
,
nil
,
&
res
)
if
err
!=
nil
{
return
nil
,
err
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment