Skip to content

Commit

Permalink
Merge tag 'rt-5gms-application-function-v1.2.0-rc1'
Browse files Browse the repository at this point in the history
  • Loading branch information
davidjwbbc committed Mar 31, 2023
2 parents 9d13481 + 20686e5 commit c9f2a23
Show file tree
Hide file tree
Showing 60 changed files with 9,589 additions and 1,697 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
__pycache__
*.pyc
build
install
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ This AF uses the [Open5GS](https://open5gs.org/) framework to implement the netw

## Specifications

A list of specification related to this repository is available [here](https://github.com/5G-MAG/Standards/wiki/5G-Media-Streaming-Architecture-(5GMS):-Relevant-Specifications).
A list of specification related to this repository is available [here](https://github.com/5G-MAG/Standards/wiki/5G-Media-Streaming-Architecture-(5GMS\):-Relevant-Specifications).

## Install dependencies

Expand Down Expand Up @@ -77,6 +77,8 @@ specify an alternative configuration file. For example:

The source example configuration file can be found in `~/rt-5gms-application-function/src/5gmsaf/msaf.yaml`.

Also see the [Configuring the Application Function](https://github.com/5G-MAG/rt-5gms-application-function/wiki/Configuring-the-Application-Function) wiki page for details on configuration.

## Testing

See the section on [Testing](https://github.com/5G-MAG/rt-5gms-application-function/wiki/Developing-and-Contributing#testing) in the wiki.
Expand Down
3 changes: 0 additions & 3 deletions examples/Certificates.json

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"distributionConfigurations": [
{},
{
"certificateId": "testcert1"
"certificateId": "@certificate-id@"
}
]
}

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@
"baseURL": "https://ftp.itec.aau.at/datasets/DASHDataset2014/BigBuckBunny/4sec/"
},
"distributionConfigurations": [
{"domainNameAlias": "media.example.com"}
{ "certificateId": "@certificate-id@" }
]
}
54 changes: 6 additions & 48 deletions examples/README.md
Original file line number Diff line number Diff line change
@@ -1,21 +1,6 @@
# 5G-MAG Reference Tools: 5GMS Application Function Example Configurations

This directory contains examples of configuration files for the 5GMS Application Function.

## `Certificates.json`

This file contains a mapping from certificate ID to certificate filename. The
certificate IDs in this file are used to find the matching certificate file
(containing a public certificate, private key and any intermediate CA
certificates) when referenced from a ContentHostingConfiguration file.

The `subprojects/rt-common-shared/5gms/scripts/make_self_signed_certs.py` script can be used, passing a 5GMS Application Function YAML configuration file as a parameter, to create suitable self-signed certificate files for testing purposes.

For example:
```bash
cd ~/rt-5gms-application-function
subprojects/rt-common-shared/5gms/scripts/make_self_signed_certs.py --af-conf=examples/Test_https_canonical-msaf.yaml
```
This directory contains examples of configurations for the 5GMS Application Function.

## `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest.json`

Expand All @@ -25,38 +10,11 @@ It contains a ContentHostingConfiguration, based on 3GPP TS 26.512 Release 17.3.

The distribution side of the configurations tells the rt-5gms-application-function to configure a 5GMS Application Server to reverse proxy the media on its localhost (127.0.0.1) loopback interface. The distribution configuration object is left empty as this is a simple distribution where all fields are generated by the 5GMS Application Function. Note that there needs to be at least one entry in `distributionConfigurations`, even if it is an empty object.

## `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest_http_and_https.json`

This file is an alternative to `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest.json` (see above) and can be used along with the `Certificates.json` file to configure a rt-5gms-application-function to provision a 5GMS Application Server which will provide both HTTP and HTTPS distribution points.

## `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest_https.json`

This file is an alternative to `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest.json` (see above) and can be used along with the `Certificates.json` file to run a rt-5gms-application-function to provision a 5GMS Application Server which will provide an HTTPS distribution point only.

## `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest_domain-name_http.json`

This file is the same as `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest.json` except that the distribution configuration also has "media.example.com" as a domain name alias. This file is included for testing the portions of the Application Function that should prefer the use of the domain name alias over the canonical name or vice-versa.

## `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest_domain-name_http_and_https.json`

This file is the same as `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest_http_and_https.json` except that the distribution configuration also has "media.example.com" as a domain name alias. This file is included for testing the portions of the Application Function that should prefer the use of the domain name alias over the canonical name or vice-versa.

## `Test_http_canonical-msaf.yaml`

This is a 5GMS Application Function YAML configuration file used for testing. This configuration uses the `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest.json` ContentHostingConfiguration to test http protocol distribution using `localhost` as the canonical domain name of the Application Server.

## `Test_http_domain_alias-msaf.yaml`

This is a 5GMS Application Function YAML configuration file used for testing. This configuration uses the `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest_domain-name_http.json` ContentHostingConfiguration to test http protocol distribution using `localhost` as the canonical domain name of the Application Server and `media.example.com` as a domain name alias for the distribution configuration.

## `Test_https_canonical-msaf.yaml`

This is a 5GMS Application Function YAML configuration file used for testing. This configuration uses the `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest_http_and_https.json` ContentHostingConfiguration and the `Certificates.json` certificates index file to test https protocol distribution using `localhost` as the canonical domain name of the Application Server.

Generate the certificates before using the configuration file. See [`Certificates.json`](#certificatesjson) for more information.
## `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest_http_and_https.json.tmpl`

## `Test_https_domain_alias-msaf.yaml`
This template file is an alternative to `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest.json` (see above) and can be used to configure a rt-5gms-application-function to provision a 5GMS Application Server which will provide both HTTP and HTTPS distribution points. Before the contents of this file can be used as a configuration `@certificate-id@` must be substituted for a valid certificate id for the provisioning session you wish to add the configuration to.

This is a 5GMS Application Function YAML configuration file used for testing. This configuration uses the `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest_domain-name_http_and_https.json` ContentHostingConfiguration and the `Certificates.json` certificates index file to test https protocol distribution using `localhost` as the canonical domain name of the Application Server and `media.example.com` as a domain name alias for the distribution configurations.
## `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest_https.json.tmpl`

Generate the certificates before using the configuration file. See [`Certificates.json`](#certificatesjson) for more information.
This template file is an alternative to `ContentHostingConfiguration_Big-Buck-Bunny_pull-ingest.json` (see above) and can be used to configure a rt-5gms-application-function to provision a 5GMS Application Server which will provide an HTTPS distribution point only. Before the contents of this file can be used as a configuration `@certificate-id@` must be substituted for a valid certific
ate id for the provisioning session you wish to add the configuration to.
28 changes: 0 additions & 28 deletions examples/Test_http_canonical-msaf.yaml

This file was deleted.

28 changes: 0 additions & 28 deletions examples/Test_http_domain_alias-msaf.yaml

This file was deleted.

28 changes: 0 additions & 28 deletions examples/Test_https_canonical-msaf.yaml

This file was deleted.

28 changes: 0 additions & 28 deletions examples/Test_https_domain_alias-msaf.yaml

This file was deleted.

12 changes: 9 additions & 3 deletions meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,21 @@
# program. If this file is missing then the license can be retrieved from
# https://drive.google.com/file/d/1cinCiA778IErENZ3JN52VFW-1ffHpx7Z/view

project('rt-5gms-af', 'c',
version : '1.1.0',
# Meson module fs and its functions like fs.hash_file require atleast meson 0.59.0

project('rt-5gms-application-function', 'c',
version : '1.2.0',
license : '5G-MAG Public',
meson_version : '>= 0.47.0',
meson_version : '>= 0.59.0',
default_options : [
'c_std=gnu89',
],
)

fiveg_api_release = '17'

sh_cmd = find_program('sh')
patch_open5gs_result = run_command([sh_cmd, '-c', '"$MESON_SOURCE_ROOT/subprojects/patch_open5gs.sh" open5gs'], check: true, capture: false)
open5gs_project=subproject('open5gs',required:true)
subdir('tools')
subdir('src')
8 changes: 8 additions & 0 deletions src/5gmsaf/ContentProtocolsDiscovery_body.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"downlinkIngestProtocols": [
{
"termIdentifier": "urn:3gpp:5gms:content-protocol:http-pull-ingest",
"descriptionLocator": "https://www.etsi.org/deliver/etsi_ts/126500_126599/126512/17.03.00_60/ts_126512v170300p.pdf#page=67"
}
]
}
9 changes: 9 additions & 0 deletions src/5gmsaf/api-info-head.mustache
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#ifndef _{{#lambda.uppercase}}{{projectName}}{{/lambda.uppercase}}_API_H
#define _{{#lambda.uppercase}}{{projectName}}{{/lambda.uppercase}}_API_H

#define {{#lambda.uppercase}}{{projectName}}{{/lambda.uppercase}}_BASE_PATH "{{basePath}}"
#define {{#lambda.uppercase}}{{projectName}}{{/lambda.uppercase}}_API_NAME "{{appName}}"
#define {{#lambda.uppercase}}{{projectName}}{{/lambda.uppercase}}_API_VERSION "{{appVersion}}"
#define {{#lambda.uppercase}}{{projectName}}{{/lambda.uppercase}}_API_DESCRIPTION "{{appDescription}}"

#endif /* _{{#lambda.uppercase}}{{projectName}}{{/lambda.uppercase}}_API_H */
Loading

0 comments on commit c9f2a23

Please sign in to comment.