mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-05-12 17:04:46 +00:00
basic docs on configuraiton file
This commit is contained in:
parent
2ab4d8940f
commit
daa157ec24
@ -1,5 +1,9 @@
|
|||||||
# Alfresco Content App
|
# Alfresco Content App
|
||||||
|
|
||||||
|
## Prerequisites
|
||||||
|
|
||||||
|
- Alfresco Content Services (Community) or Alfresco Content Services 5.2.2 (Enterprise)
|
||||||
|
|
||||||
## Building and running locally
|
## Building and running locally
|
||||||
|
|
||||||
Please refer to the [developer docs](https://github.com/Alfresco/alfresco-content-app/blob/master/README.md) to get more details on building and running application on your local machine.
|
Please refer to the [developer docs](https://github.com/Alfresco/alfresco-content-app/blob/master/README.md) to get more details on building and running application on your local machine.
|
||||||
|
111
docs/configuration.md
Normal file
111
docs/configuration.md
Normal file
@ -0,0 +1,111 @@
|
|||||||
|
# Application Configuration
|
||||||
|
|
||||||
|
The Content Application provides support for a global settings file `app.config.json` that you can use to customise the behaviour of ACA and ADF components.
|
||||||
|
|
||||||
|
## Server settings
|
||||||
|
|
||||||
|
Once the Content Application starts, it needs to know where the Alfresco Content Services (either Community or Enterprise) server is.
|
||||||
|
The "ecmHost" property allows you to set the address of the server using the dynamic or static format.
|
||||||
|
|
||||||
|
### Dynamic address
|
||||||
|
|
||||||
|
The example below demonstrates the most common dynamic format for development environment:
|
||||||
|
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"ecmHost": "http://{hostname}{:port}",
|
||||||
|
...
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
The configuration above assumes you are running ACS and Content App on the same server and port
|
||||||
|
and allows deploying to different servers having the same unified configuration file.
|
||||||
|
|
||||||
|
For example, a proxy server at `localhost:3000` hosting the Content App as the root application,
|
||||||
|
and `localhost:3000/alfresco` for the ACS repository.
|
||||||
|
|
||||||
|
At runtime, the application is going to automatically substitute the "{hostname}" value with the original hostname.
|
||||||
|
Optionally it can also use the value of the original port if present, for example, "3000" at local machines, or skip the value for port 80.
|
||||||
|
|
||||||
|
### Static address
|
||||||
|
|
||||||
|
Alternatively, you can provide a static address for the ACS services if necessary:
|
||||||
|
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"ecmHost": "http://localhost:3000",
|
||||||
|
...
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
## Application settings
|
||||||
|
|
||||||
|
The are many settings you can change to alter the default behaviour of the application.
|
||||||
|
|
||||||
|
### Application Name
|
||||||
|
|
||||||
|
The following block allows you to change the name of the application.
|
||||||
|
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
...,
|
||||||
|
"application": {
|
||||||
|
"name": "Alfresco Example Content Application"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
The value of the `application.name` key gets appended to every browser tab title at runtime
|
||||||
|
with the format `[page title] - [application name]`,
|
||||||
|
for example: "Personal Files - Alfresco Example Content Application".
|
||||||
|
|
||||||
|
### Restricted content
|
||||||
|
|
||||||
|
You can restrict users from uploading certain types of files and folders by setting or extending the list of rules at the "files.excluded" path.
|
||||||
|
|
||||||
|
By default, the application ships with the following rules already predefined:
|
||||||
|
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
...,
|
||||||
|
"files": {
|
||||||
|
"excluded": [
|
||||||
|
".DS_Store",
|
||||||
|
"desktop.ini",
|
||||||
|
"thumbs.db",
|
||||||
|
".git"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
...
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
<p class="tip">
|
||||||
|
You can get more details on the supported rules in the following article: [Upload Service](https://github.com/Alfresco/alfresco-ng2-components/blob/master/docs/upload.service.md).
|
||||||
|
</p>
|
||||||
|
|
||||||
|
### Pagination settings
|
||||||
|
|
||||||
|
You can change the default settings of the pagination that gets applied to all the document lists in the application.
|
||||||
|
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
...,
|
||||||
|
"document-list": {
|
||||||
|
"supportedPageSizes": [
|
||||||
|
25,
|
||||||
|
50,
|
||||||
|
100
|
||||||
|
]
|
||||||
|
},
|
||||||
|
...
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
## Your custom settings
|
||||||
|
|
||||||
|
You can store any information in the application configuration file, and access it at runtime by utilising the `AppConfigService` service provided by the ADF framework.
|
||||||
|
|
||||||
|
<p class="tip">
|
||||||
|
Please refer to the [AppConfigService](https://github.com/Alfresco/alfresco-ng2-components/blob/master/docs/app-config.service.md) documentation to get more details on Application Configuration features and API available.
|
||||||
|
</p>
|
@ -29,6 +29,10 @@
|
|||||||
{
|
{
|
||||||
title: 'CORS',
|
title: 'CORS',
|
||||||
path: 'cors'
|
path: 'cors'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: 'Configuration',
|
||||||
|
path: 'configuration'
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"ecmHost": "http://{hostname}:{port}",
|
"ecmHost": "http://{hostname}{:port}",
|
||||||
"application": {
|
"application": {
|
||||||
"name": "Alfresco Example Content Application",
|
"name": "Alfresco Example Content Application",
|
||||||
"build": "1234"
|
"build": "1234"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user