bundles/element-web: only set --openssl-legacy-provider if using nodejs >= 17
This commit is contained in:
parent
dd420c4574
commit
615f6107bc
2 changed files with 10 additions and 3 deletions
|
@ -25,11 +25,15 @@ files = {
|
|||
},
|
||||
}
|
||||
|
||||
extra_install_cmds = []
|
||||
if node.metadata.get('nodejs/version') >= 17:
|
||||
# TODO verify this is still needed when upgrading to 1.12
|
||||
extra_install_cmds.append('export NODE_OPTIONS=--openssl-legacy-provider')
|
||||
|
||||
actions = {
|
||||
'element-web_yarn': {
|
||||
'command': ' && '.join([
|
||||
# TODO verify this is still needed when upgrading to 1.12
|
||||
'export NODE_OPTIONS=--openssl-legacy-provider',
|
||||
*extra_install_cmds,
|
||||
'cd /opt/element-web',
|
||||
'yarn install --pure-lockfile --ignore-scripts',
|
||||
'yarn build',
|
||||
|
|
|
@ -9,13 +9,16 @@ defaults = {
|
|||
'nodejs': {},
|
||||
},
|
||||
},
|
||||
'nodejs': {
|
||||
'version': 18,
|
||||
},
|
||||
}
|
||||
|
||||
@metadata_reactor.provides(
|
||||
'apt/repos/nodejs/items',
|
||||
)
|
||||
def nodejs_from_version(metadata):
|
||||
version = metadata.get('nodejs/version', 18)
|
||||
version = metadata.get('nodejs/version')
|
||||
return {
|
||||
'apt': {
|
||||
'repos': {
|
||||
|
|
Loading…
Reference in a new issue