Skip to content

Commit

Permalink
fix: domain
Browse files Browse the repository at this point in the history
  • Loading branch information
dawnwinterLiu committed Oct 18, 2023
1 parent 930dc73 commit 50bcfa5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/dgiot/src/dgiot.erl
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ domain_(#{<<"action">> := <<"setDomainSSL">>, <<"domain">> := Domain, <<"key">>
os:cmd("sed -ri 's/(ssl_certificate )[^*]*/\\1 \\/etc\\/pki\\/tls\\/certs\\/fullchain.pem;/' /data/dgiot/nginx/conf/nginx.conf"),
os:cmd("sed -ri 's/(ssl_certificate_key )[^*]*/\\1 \\/etc\\/pki\\/tls\\/certs\\/privkey.key;/' /data/dgiot/nginx/conf/nginx.conf"),
os:cmd("echo '" ++ dgiot_utils:to_list(Key) ++ "' > /etc/pki/tls/certs/fullchain.pem"),
os:cmd("echo '" ++ dgiot_utils:to_list(Csr) ++ "' > /etc/pki/tls/certs/privkey.pem"),
os:cmd("echo '" ++ dgiot_utils:to_list(Csr) ++ "' > /etc/pki/tls/certs/privkey.key"),
%% go_fastdfs
os:cmd("sed -ri 's/(\"download_domain\": \")[^\"]*/\\1" ++ dgiot_utils:to_list(Domain) ++ "/' /data/dgiot/go_fastdfs/conf/cfg.json"),
dgiot_parse:update_object(<<"Dict">>, DictId, #{<<"data">> => maps:merge(Data, maps:without([<<"action">>], Args))}),
Expand Down

0 comments on commit 50bcfa5

Please sign in to comment.