workbench icon indicating copy to clipboard operation
workbench copied to clipboard

replace the domain?

Open swissdaytrader opened this issue 4 years ago • 1 comments

I follow this instruction https://github.com/rubykube/workbench/wiki/DigitalOcean-Installation

And i can not find the place to add my domain ;)

i need to add my domain to all this files ? "compose/proxy.yaml" "compose/backend.yaml" "compose/app.yaml" "config/trading-ui.env" "compose/cryptonodes.yaml" "config/integration/fixtures/barong.json" "config/integration/fixtures/peatio.json" "config/peatio.env" "config/barong.env" "config/barong/seeds.yml" "config/toolbox.yaml" ?

Replace domain

Set $new_domain variable equal to your domain and run bash script:

#!/bin/bash

old_domain="wb.local" new_domain="your.domain"

files=( "compose/proxy.yaml" "compose/backend.yaml" "compose/app.yaml" "config/trading-ui.env" "compose/cryptonodes.yaml" "config/integration/fixtures/barong.json" "config/integration/fixtures/peatio.json" "config/peatio.env" "config/barong.env" "config/barong/seeds.yml" "config/toolbox.yaml" )

for file in ${files[@]}; do sed -i "s/${old_domain}/${new_domain}/g" ${file} done

Thanks for your help

swissdaytrader avatar Sep 11 '19 07:09 swissdaytrader

@swissdaytrader you should use nano or vim to create a bash file name change.sh at /home/workbench/workbench then paste below script to it

#!/bin/bash

old_domain="wb.local"
new_domain="your.domain"

files=(
"compose/proxy.yaml"
"compose/backend.yaml"
"compose/app.yaml"
"config/trading-ui.env"
"compose/cryptonodes.yaml"
"config/integration/fixtures/barong.json"
"config/integration/fixtures/peatio.json"
"config/peatio.env"
"config/barong.env"
"config/barong/seeds.yml"
"config/toolbox.yaml"
)

for file in ${files[@]}; do
sed -i "s/${old_domain}/${new_domain}/g" ${file}
done

then chmod +x change.sh and run it ./change.sh

phuongdev89 avatar Dec 23 '19 15:12 phuongdev89