summaryrefslogtreecommitdiff
path: root/src/rest
diff options
context:
space:
mode:
authorSchanzenbach, Martin <mschanzenbach@posteo.de>2019-04-29 17:44:10 +0200
committerSchanzenbach, Martin <mschanzenbach@posteo.de>2019-04-29 17:44:10 +0200
commita3392854e21b10b84e5f1d81db41c929a031ab39 (patch)
treed668ab05d1548c0f572b67d8dc4cb4e1f5097876 /src/rest
parent1894c4186101db00fabd0d780edf7eb5a122b07b (diff)
downloadgnunet-a3392854e21b10b84e5f1d81db41c929a031ab39.tar.gz
gnunet-a3392854e21b10b84e5f1d81db41c929a031ab39.zip
REST: fallback to default port
Diffstat (limited to 'src/rest')
-rw-r--r--src/rest/gnunet-rest-server.c7
-rw-r--r--src/rest/rest.conf1
2 files changed, 4 insertions, 4 deletions
diff --git a/src/rest/gnunet-rest-server.c b/src/rest/gnunet-rest-server.c
index 813525404..ba1d595fd 100644
--- a/src/rest/gnunet-rest-server.c
+++ b/src/rest/gnunet-rest-server.c
@@ -824,14 +824,13 @@ run (void *cls,
824 824
825 /* Get port to bind to */ 825 /* Get port to bind to */
826 if (GNUNET_OK != GNUNET_CONFIGURATION_get_value_number (cfg, "rest", 826 if (GNUNET_OK != GNUNET_CONFIGURATION_get_value_number (cfg, "rest",
827 "PORT", 827 "HTTP_PORT",
828 &port)) 828 &port))
829 { 829 {
830 //No address specified 830 //No address specified
831 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, 831 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
832 "Don't know what port to use...\n"); 832 "Using default port...\n");
833 GNUNET_SCHEDULER_shutdown (); 833 port = GNUNET_REST_SERVICE_PORT;
834 return;
835 } 834 }
836 835
837 /* Get address to bind to */ 836 /* Get address to bind to */
diff --git a/src/rest/rest.conf b/src/rest/rest.conf
index dfeedd26c..71fef8aa1 100644
--- a/src/rest/rest.conf
+++ b/src/rest/rest.conf
@@ -2,6 +2,7 @@
2UNIXPATH = $GNUNET_USER_RUNTIME_DIR/gnunet-service-rest.sock 2UNIXPATH = $GNUNET_USER_RUNTIME_DIR/gnunet-service-rest.sock
3BINARY=gnunet-rest-server 3BINARY=gnunet-rest-server
4IMMEDIATE_START=YES 4IMMEDIATE_START=YES
5HTTP_PORT=7776
5BIND_TO=127.0.0.1 6BIND_TO=127.0.0.1
6BIND_TO6=::1 7BIND_TO6=::1
7REST_ALLOW_HEADERS=Authorization,Accept,Content-Type 8REST_ALLOW_HEADERS=Authorization,Accept,Content-Type