mirror of
https://github.com/aljazceru/cyphernode.git
synced 2025-12-26 09:05:13 +01:00
config tool now uses user which it runs under as default user for cyphernode, when run_as_user is not selected
This commit is contained in:
1
dist/setup.sh
vendored
1
dist/setup.sh
vendored
@@ -181,6 +181,7 @@ configure() {
|
||||
|
||||
# configure features of cyphernode
|
||||
docker run -v $current_path:/data \
|
||||
-e DEFAULT_USER=$USER \
|
||||
--log-driver=none$pw_env \
|
||||
--rm$interactive cyphernodeconf:latest $(id -u):$(id -g) yo --no-insight cyphernode$gen_options $recreate
|
||||
}
|
||||
|
||||
@@ -327,6 +327,7 @@ module.exports = class extends Generator {
|
||||
lightning_nodename: '',
|
||||
lightning_nodecolor: ''
|
||||
}, this.props );
|
||||
this.props.default_username = process.env.DEFAULT_USER || '';
|
||||
}
|
||||
|
||||
_isChecked( name, value ) {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/bin/sh
|
||||
|
||||
# run as user <%= username %>
|
||||
export USER=$(id -u <%= run_as_different_user?username:'' %>):$(id -g <%= run_as_different_user?username:'' %>)
|
||||
export USER=$(id -u <%= run_as_different_user?username:default_username %>):$(id -g <%= run_as_different_user?username:default_username %>)
|
||||
export ARCH=$(uname -m)
|
||||
|
||||
<% if (docker_mode == 'swarm') { %>
|
||||
|
||||
Reference in New Issue
Block a user