Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
haskell-gargantext
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Christian Merten
haskell-gargantext
Commits
8f4ffdcd
Commit
8f4ffdcd
authored
Jul 15, 2024
by
Alfredo Di Napoli
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Change gargantext-settings.toml for proxy sub-section
parent
0e037e1f
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
6 deletions
+8
-6
gargantext-settings.toml
gargantext-settings.toml
+3
-3
MicroServices.hs
src/Gargantext/API/Admin/Settings/MicroServices.hs
+4
-2
TOML.hs
src/Gargantext/API/Admin/Settings/TOML.hs
+1
-1
No files found.
gargantext-settings.toml
View file @
8f4ffdcd
...
@@ -19,6 +19,6 @@ allowed-origins = [
...
@@ -19,6 +19,6 @@ allowed-origins = [
use-origins-for-hosts
=
true
use-origins-for-hosts
=
true
[microservices]
[microservices
.proxy
]
port
=
8009
proxy-port
=
8009
enabled
=
false
src/Gargantext/API/Admin/Settings/MicroServices.hs
View file @
8f4ffdcd
...
@@ -13,12 +13,14 @@ import Toml
...
@@ -13,12 +13,14 @@ import Toml
data
MicroServicesSettings
=
data
MicroServicesSettings
=
MicroServicesSettings
{
MicroServicesSettings
{
-- | The port where the microservices proxy will be listening on.
-- | The port where the microservices proxy will be listening on.
_msProxyPort
::
Int
_msProxyPort
::
!
Int
,
_msProxyEnabled
::
!
Bool
}
deriving
(
Show
,
Eq
)
}
deriving
(
Show
,
Eq
)
microServicesSettingsCodec
::
TomlCodec
MicroServicesSettings
microServicesSettingsCodec
::
TomlCodec
MicroServicesSettings
microServicesSettingsCodec
=
MicroServicesSettings
microServicesSettingsCodec
=
MicroServicesSettings
<$>
Toml
.
int
"proxy-port"
.=
_msProxyPort
<$>
Toml
.
int
"port"
.=
_msProxyPort
<*>
Toml
.
bool
"enabled"
.=
_msProxyEnabled
mkProxyUrl
::
GargConfig
->
MicroServicesSettings
->
BaseUrl
mkProxyUrl
::
GargConfig
->
MicroServicesSettings
->
BaseUrl
mkProxyUrl
GargConfig
{
..
}
MicroServicesSettings
{
..
}
=
mkProxyUrl
GargConfig
{
..
}
MicroServicesSettings
{
..
}
=
...
...
src/Gargantext/API/Admin/Settings/TOML.hs
View file @
8f4ffdcd
...
@@ -22,7 +22,7 @@ makeLenses ''GargTomlSettings
...
@@ -22,7 +22,7 @@ makeLenses ''GargTomlSettings
settingsCodec
::
TomlCodec
GargTomlSettings
settingsCodec
::
TomlCodec
GargTomlSettings
settingsCodec
=
GargTomlSettings
settingsCodec
=
GargTomlSettings
<$>
(
Toml
.
table
corsSettingsCodec
"cors"
.=
_gargCorsSettings
)
<$>
(
Toml
.
table
corsSettingsCodec
"cors"
.=
_gargCorsSettings
)
<*>
(
Toml
.
table
microServicesSettingsCodec
"microservices"
.=
_gargMicroServicesSettings
)
<*>
(
Toml
.
table
microServicesSettingsCodec
"microservices
.proxy
"
.=
_gargMicroServicesSettings
)
-- | Extends the 'allowed-origins' in the CORSettings with the URLs embellished
-- | Extends the 'allowed-origins' in the CORSettings with the URLs embellished
-- with the proxy port.
-- with the proxy port.
...
...
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