Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

config: add standalone configuration #536

Merged
merged 1 commit into from
Mar 4, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
77 changes: 77 additions & 0 deletions examples/standalone/standalone.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
[shared]
jwt_secret = "Pive-Fumkiu4"
gatewaysvc = "localhost:19000"

[grpc]
address = "0.0.0.0:19000"

[grpc.services.gateway]
authregistrysvc = "localhost:19000"
storageregistrysvc = "localhost:19000"
preferencessvc = "localhost:19000"
userprovidersvc = "localhost:19000"
usershareprovidersvc = "localhost:19000"
publicshareprovidersvc = "localhost:19000"
ocmshareprovidersvc = "localhost:19000"
commit_share_to_storage_grant = false
datagateway = "http://localhost:19001/data"
transfer_shared_secret = "replace-me-with-a-transfer-secret" # for direct uploads
transfer_expires = 6 # give it a moment

[grpc.services.authregistry]
driver = "static"
[grpc.services.authregistry.drivers.static.rules]
basic = "localhost:19000"

[grpc.services.storageregistry]
driver = "static"
[grpc.services.storageregistry.drivers.static]
home_provider = "/"
[grpc.services.storageregistry.drivers.static.rules]
"/" = "localhost:19000"
"123e4567-e89b-12d3-a456-426655440000" = "localhost:19000"

[grpc.services.usershareprovider]
driver = "memory"

[grpc.services.publicshareprovider]
driver = "memory"

[grpc.services.storageprovider]
driver = "local"
mount_path = "/"
mount_id = "123e4567-e89b-12d3-a456-426655440000"
expose_data_server = true
data_server_url = "http://localhost:19001/data"
enable_home_creation = true

[grpc.services.storageprovider.drivers.local]
namespace = "/var/tmp/reva/"
user_layout = "{{.Username}}"
enable_home = true

[grpc.services.authprovider]
auth_manager = "json"
[grpc.services.authprovider.auth_managers.json]
users = "users.demo.json"

[grpc.services.userprovider]
driver = "json"

[grpc.services.userprovider.drivers.json]
users = "users.demo.json"

[http]
address = "0.0.0.0:19001"

[http.services.dataprovider]
driver = "local"
temp_folder = "/var/tmp/"

[http.services.dataprovider.drivers.local]
namespace = "/var/tmp/reva/"
user_layout = "{{.Username}}"
enable_home = true

#[http.services.datagateway]
#transfer_shared_secret = "replace-me-with-a-transfer-secret" # for direct uploads
35 changes: 35 additions & 0 deletions examples/standalone/users.demo.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
[
{
"id": {
"opaque_id": "4c510ada-c86b-4815-8820-42cdf82c3d51",
"idp": "http://localhost:20080"
},
"username": "einstein",
"secret": "relativity",
"mail": "[email protected]",
"display_name": "Albert Einstein",
"groups": ["sailing-lovers", "violin-haters", "physics-lovers"]
},
{
"id": {
"opaque_id": "f7fbf8c8-139b-4376-b307-cf0a8c2d0d9c",
"idp": "http://localhost:20080"
},
"username": "marie",
"secret": "radioactivity",
"mail": "[email protected]",
"display_name": "Marie Curie",
"groups": ["radium-lovers", "polonium-lovers", "physics-lovers"]
},
{
"id": {
"opaque_id": "932b4540-8d16-481e-8ef4-588e4b6b151c",
"idp": "http://localhost:20080"
},
"username": "richard",
"secret": "superfluidity",
"mail": "[email protected]",
"display_name": "Richard Feynman",
"groups": ["quantum-lovers", "philosophy-haters", "physics-lovers"]
}
]