modules/ipfs: switch to firewall-safe port
This commit is contained in:
parent
b06fa54537
commit
6f3e1e18d7
1 changed files with 4 additions and 3 deletions
|
@ -5,6 +5,7 @@ let
|
||||||
apiAddress = "/unix/run/ipfs/ipfs-api.sock";
|
apiAddress = "/unix/run/ipfs/ipfs-api.sock";
|
||||||
ipfsApi = pkgs.writeTextDir "api" apiAddress;
|
ipfsApi = pkgs.writeTextDir "api" apiAddress;
|
||||||
gw = config.links.ipfsGateway;
|
gw = config.links.ipfsGateway;
|
||||||
|
ipfsPort = 110;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
age.secrets.ipfs-swarm-key = {
|
age.secrets.ipfs-swarm-key = {
|
||||||
|
@ -17,8 +18,8 @@ in
|
||||||
links.ipfsGateway.protocol = "http";
|
links.ipfsGateway.protocol = "http";
|
||||||
|
|
||||||
networking.firewall = {
|
networking.firewall = {
|
||||||
allowedTCPPorts = [ 4001 ];
|
allowedTCPPorts = [ ipfsPort ];
|
||||||
allowedUDPPorts = [ 4001 ];
|
allowedUDPPorts = [ ipfsPort ];
|
||||||
};
|
};
|
||||||
|
|
||||||
services.ipfs = {
|
services.ipfs = {
|
||||||
|
@ -39,7 +40,7 @@ in
|
||||||
"/ip4/168.235.67.108/tcp/4001/p2p/QmRMA5pWXtfuW1y5w2t9gYxrDDD6bPRLKdWAYnHTeCxZMm"
|
"/ip4/168.235.67.108/tcp/4001/p2p/QmRMA5pWXtfuW1y5w2t9gYxrDDD6bPRLKdWAYnHTeCxZMm"
|
||||||
"/ip4/51.38.87.150/tcp/4001/p2p/12D3KooWDUgNsoLVauCDpRAo54mc4whoBudgeXQnZZK2iVYhBLCN"
|
"/ip4/51.38.87.150/tcp/4001/p2p/12D3KooWDUgNsoLVauCDpRAo54mc4whoBudgeXQnZZK2iVYhBLCN"
|
||||||
"/ip4/77.54.95.19/tcp/12104/p2p/12D3KooWC1RZxLvAeEFNTZWk1FWc1sZZ3yemF4FNNRYa3X854KJ8"
|
"/ip4/77.54.95.19/tcp/12104/p2p/12D3KooWC1RZxLvAeEFNTZWk1FWc1sZZ3yemF4FNNRYa3X854KJ8"
|
||||||
"/ip4/95.216.8.12/tcp/4001/p2p/Qmd7QHZU8UjfYdwmjmq1SBh9pvER9AwHpfwQvnvNo3HBBo"
|
"/ip4/95.216.8.12/tcp/${toString ipfsPort}/p2p/Qmd7QHZU8UjfYdwmjmq1SBh9pvER9AwHpfwQvnvNo3HBBo"
|
||||||
];
|
];
|
||||||
AutoNAT.ServiceMode = "enabled";
|
AutoNAT.ServiceMode = "enabled";
|
||||||
API.HTTPHeaders = {
|
API.HTTPHeaders = {
|
||||||
|
|
Loading…
Reference in a new issue