AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / user-239624

xCovelus's questions

Martin Hope
xCovelus
Asked: 2019-03-22 02:07:26 +0800 CST

PostfixAdmin 不接受 .int 顶级域

  • 0

我被要求在 Ubuntu Server 16.04 LTS 中配置一个新的电子邮件服务器并为其提供一个管理 WebUI(我选择了PostfixAdmin)。

我们需要支持格式为 的电子邮件地址,...@<project-domain>.int比方说@projectname.int,因为开发中的内部项目(未连接到 Internet)需要它。

我配置了电子邮件,添加projectname.int到我的服务器和工作站主机文件(还没有在 DNS 中),ping 以检查,从这些其他工作站添加工作客户端。

但是在 PostfixAdmin 设置中,在创建“超级管理员帐户”的步骤中,当我使用现有的(并且经过充分测试的)后缀电子邮件admin@projectname.int时它不起作用,它说“管理员不是有效的电子邮件地址!电子邮件地址”(下面的屏幕截图)。

后来,出于测试目的,我尝试了admin@projectname.com,它可以工作,所以,我想知道是否某些顶级域名(如.int)由于某种原因是不允许的,或者是否是其他原因。

您是否知道它可能是哪个问题,或者,如果不允许,我如何允许我的 postfixadmin 使用.int?

  • Ubuntu 16.04.6 LTS
  • MySQL 14.14 发行版 5.7.25
  • 后缀 3.1.0-3
  • 鸽舍 2.2.22 (fe789d2)
  • 阿帕奇2 2.4.18
  • postfixadmin 3.2(从sourceforge下载的tar.gz)

    • 按照 INSTALL.TXT 说明中的说明进行配置

我的主机文件 /etc/hosts:

127.0.0.1 localhost.localdomain localhost
127.0.1.1 projectname.int mailsrv.projectname.int mailsrv 

# The following lines are desirable for IPv6 capable hosts
::1     localhost ip6-localhost ip6-loopback
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters

在此处输入图像描述

postfix
  • 1 个回答
  • 651 Views
Martin Hope
xCovelus
Asked: 2018-08-02 04:51:26 +0800 CST

OpenNebula:使用提供服务名称的 Curl 实例化服务模板

  • 0

在 OpenNebula 5.4 中,我可以使用 Curl 从服务模板实例化服务,但我不知道如何提供服务名称。该网站示例按预期工作:

curl http://127.0.0.1:2474/service_template/4/action -u 'oneadmin:opennebula' -v -X POST --data '{
  "action": {
    "perform":"instantiate"
  }
}'

创建与服务模板同名的服务。但是,如果我运行相同的尝试为该实例添加一个参数action(就像对给定服务执行操作时所做的那样),例如:

curl http://127.0.0.1:2474/service_template/4/action -u 'oneadmin:opennebula' -v -X POST --data '{
  "action": {
    "perform":"instantiate", 
    "params" : { 
       "name" : "new_name" 
     }
  }
}'

它忽略了该参数,导致与运行前面提到的网站示例时相同...我尝试使用'name'、'service-name'、'service_name',但结果相同...你知道怎么做吗, 请?我认为它可能受到支持(就像在他们的 Java API 中一样),但没有记录(与许多其他功能一样)。

提前,非常感谢和欢呼

curl
  • 1 个回答
  • 129 Views
Martin Hope
xCovelus
Asked: 2018-07-09 13:36:18 +0800 CST

Nginx:反向代理将客户端IP传递给服务器

  • 6

在现有的 nginx 反向代理上,我需要将客户端 IP 传递给服务器(从 nginx 到 NG-Engine 中服务的前端,然后从这个到后端),我尝试了很多站点,但服务器只是接收127.0.0.1。额外信息(在迈克尔汉普顿问题之后添加),我们的虚拟机基础设施:

  1. 客户端浏览器(另一个 VM 或远程桌面)
  2. (VM1)nginx反向代理(它可以工作,我至少添加了HTTPS层)
  3. (VM1) NgEngine 服务于自制前端
  4. (VM1) 由 Java/Spring 自制后端提供的 RESTful API(以 IntelliJ 理念运行)
  5. (VM2..x)其他服务器向后端提供数据(不可能)

我检查了文档,在这里尝试过(包括删除 X-Real-IP 标头,正如他们在其他问题中所建议的那样)。我还尝试添加:

set_real_ip_from 127.0.0.1;
real_ip_header X-Forwarded-For

我的 nginx 有 real_ip 模块(下面 nginx -V 的输出),这是我的 nginx.conf ......我做错了什么?

user www-data;
worker_processes auto;
pid /run/nginx.pid;

events {
  worker_connections 768;
  # multi_accept on;
}

http {
  sendfile on;
  tcp_nopush on;
  tcp_nodelay on;
  keepalive_timeout 65;
  types_hash_max_size 2048;
  # server_tokens off;

  server_names_hash_bucket_size 64;
  # server_name_in_redirect off;

  include /etc/nginx/mime.types;
  default_type application/octet-stream;

  ssl_protocols TLSv1 TLSv1.1 TLSv1.2; # Dropping SSLv3, ref: POODLE
  ssl_prefer_server_ciphers on;

  gzip on;
  gzip_disable "msie6";

  server {
    listen 443 ssl;
    server_name          test-server;
    ssl_certificate      /etc/nginx/ssl/nginx.crt;
    ssl_certificate_key  /etc/nginx/ssl/nginx.key;

    add_header              Strict-Transport-Security  "max-age=63072000; includeSubdomains; preload" always;
    add_header              X-Frame-Options            SAMEORIGIN;
    add_header              X-Content-Type-Options     nosniff;

    # allow nginx to start regardless of upstream endpoint state by using intermediary variable
    set                     $UPSTREAM_SERVICE          10.10.10.15:8080;

    location  / {
      proxy_pass               http://localhost:6789
      proxy_http_version       1.1;

      proxy_buffering          off;
      proxy_buffer_size        128k;
      proxy_busy_buffers_size  256k;
      proxy_buffers            4                   256k;
      proxy_set_header         Host                $host;
      proxy_set_header         X-Real-IP           $remote_addr;
      proxy_set_header         X-Forwarded-For     $proxy_add_x_forwarded_for;
      proxy_set_header         X-Forwarded-Proto   $scheme;
      proxy_set_header         Upgrade             $http_upgrade;
      proxy_set_header         Connection          $http_connection;

    }
  }
}

nginx -V 的输出:

nginx version: nginx/1.14.0 (Ubuntu)
built with OpenSSL 1.1.0g  2 Nov 2017
TLS SNI support enabled
configure arguments: --with-cc-opt='-g -O2 -fdebug-prefix-map=/build/nginx-mcUg8N/nginx-1.14.0=. -fstack-protector-strong -Wformat -Werror=format-security -fPIC -Wdate-time -D_FORTIFY_SOURCE=2' --with-ld-opt='-Wl,-Bsymbolic-functions -Wl,-z,relro -Wl,-z,now -fPIC' --prefix=/usr/share/nginx --conf-path=/etc/nginx/nginx.conf --http-log-path=/var/log/nginx/access.log --error-log-path=/var/log/nginx/error.log --lock-path=/var/lock/nginx.lock --pid-path=/run/nginx.pid --modules-path=/usr/lib/nginx/modules --http-client-body-temp-path=/var/lib/nginx/body --http-fastcgi-temp-path=/var/lib/nginx/fastcgi --http-proxy-temp-path=/var/lib/nginx/proxy --http-scgi-temp-path=/var/lib/nginx/scgi --http-uwsgi-temp-path=/var/lib/nginx/uwsgi --with-debug --with-pcre-jit --with-http_ssl_module --with-http_stub_status_module --with-http_realip_module --with-http_auth_request_module --with-http_v2_module --with-http_dav_module --with-http_slice_module --with-threads --with-http_addition_module --with-http_flv_module --with-http_geoip_module=dynamic --with-http_gunzip_module --with-http_gzip_static_module --with-http_image_filter_module=dynamic --with-http_mp4_module --with-http_perl_module=dynamic --with-http_random_index_module --with-http_secure_link_module --with-http_sub_module --with-http_xslt_module=dynamic --with-mail=dynamic --with-mail_ssl_module --with-stream=dynamic --with-stream_ssl_module --with-stream_ssl_preread_module --add-dynamic-module=/build/nginx-mcUg8N/nginx-1.14.0/debian/modules/http-headers-more-filter --add-dynamic-module=/build/nginx-mcUg8N/nginx-1.14.0/debian/modules/http-auth-pam --add-dynamic-module=/build/nginx-mcUg8N/nginx-1.14.0/debian/modules/http-cache-purge --add-dynamic-module=/build/nginx-mcUg8N/nginx-1.14.0/debian/modules/http-dav-ext --add-dynamic-module=/build/nginx-mcUg8N/nginx-1.14.0/debian/modules/http-ndk --add-dynamic-module=/build/nginx-mcUg8N/nginx-1.14.0/debian/modules/http-echo --add-dynamic-module=/build/nginx-mcUg8N/nginx-1.14.0/debian/modules/http-fancyindex --add-dynamic-module=/build/nginx-mcUg8N/nginx-1.14.0/debian/modules/nchan --add-dynamic-module=/build/nginx-mcUg8N/nginx-1.14.0/debian/modules/http-lua --add-dynamic-module=/build/nginx-mcUg8N/nginx-1.14.0/debian/modules/rtmp --add-dynamic-module=/build/nginx-mcUg8N/nginx-1.14.0/debian/modules/http-uploadprogress --add-dy
namic-module=/build/nginx-mcUg8N/nginx-1.14.0/debian/modules/http-upstream-fair --add-dynamic-module=/build/nginx-mcUg8N/nginx-1.14.0/debian/modules/http-subs-filter

非常感谢和最好的问候

nginx
  • 2 个回答
  • 38905 Views

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    新安装后 postgres 的默认超级用户用户名/密码是什么?

    • 5 个回答
  • Marko Smith

    SFTP 使用什么端口?

    • 6 个回答
  • Marko Smith

    命令行列出 Windows Active Directory 组中的用户?

    • 9 个回答
  • Marko Smith

    什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同?

    • 3 个回答
  • Marko Smith

    如何确定bash变量是否为空?

    • 15 个回答
  • Martin Hope
    Tom Feiner 如何按大小对 du -h 输出进行排序 2009-02-26 05:42:42 +0800 CST
  • Martin Hope
    Noah Goodrich 什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同? 2009-05-19 18:24:42 +0800 CST
  • Martin Hope
    Brent 如何确定bash变量是否为空? 2009-05-13 09:54:48 +0800 CST
  • Martin Hope
    cletus 您如何找到在 Windows 中打开文件的进程? 2009-05-01 16:47:16 +0800 CST

热门标签

linux nginx windows networking ubuntu domain-name-system amazon-web-services active-directory apache-2.4 ssh

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve