Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
mastodon
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
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
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Pierre Boudes
mastodon
Commits
1af48265
Unverified
Commit
1af48265
authored
2 years ago
by
Arthur Isac
Committed by
GitHub
2 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Copied Spaces support from packer .rake (#20573)
parent
cf36ee99
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
lib/tasks/mastodon.rake
+34
-1
34 additions, 1 deletion
lib/tasks/mastodon.rake
with
34 additions
and
1 deletion
lib/tasks/mastodon.rake
+
34
−
1
View file @
1af48265
...
...
@@ -142,7 +142,40 @@ namespace :mastodon do
prompt
.
say
"
\n
"
if
prompt
.
yes?
(
'Do you want to store uploaded files on the cloud?'
,
default:
false
)
case
prompt
.
select
(
'Provider'
,
[
'Amazon S3'
,
'Wasabi'
,
'Minio'
,
'Google Cloud Storage'
])
case
prompt
.
select
(
'Provider'
,
[
'DigitalOcean Spaces'
,
'Amazon S3'
,
'Wasabi'
,
'Minio'
,
'Google Cloud Storage'
])
when
'DigitalOcean Spaces'
env
[
'S3_ENABLED'
]
=
'true'
env
[
'S3_PROTOCOL'
]
=
'https'
env
[
'S3_BUCKET'
]
=
prompt
.
ask
(
'Space name:'
)
do
|
q
|
q
.
required
true
q
.
default
"files.
#{
env
[
'LOCAL_DOMAIN'
]
}
"
q
.
modify
:strip
end
env
[
'S3_REGION'
]
=
prompt
.
ask
(
'Space region:'
)
do
|
q
|
q
.
required
true
q
.
default
'nyc3'
q
.
modify
:strip
end
env
[
'S3_HOSTNAME'
]
=
prompt
.
ask
(
'Space endpoint:'
)
do
|
q
|
q
.
required
true
q
.
default
'nyc3.digitaloceanspaces.com'
q
.
modify
:strip
end
env
[
'S3_ENDPOINT'
]
=
"https://
#{
env
[
'S3_HOSTNAME'
]
}
"
env
[
'AWS_ACCESS_KEY_ID'
]
=
prompt
.
ask
(
'Space access key:'
)
do
|
q
|
q
.
required
true
q
.
modify
:strip
end
env
[
'AWS_SECRET_ACCESS_KEY'
]
=
prompt
.
ask
(
'Space secret key:'
)
do
|
q
|
q
.
required
true
q
.
modify
:strip
end
when
'Amazon S3'
env
[
'S3_ENABLED'
]
=
'true'
env
[
'S3_PROTOCOL'
]
=
'https'
...
...
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