Goals:   Have a single nginx reverse proxy for all sub-sites (running on other ports). BLOCK all direct connections, and instead; route through nginx.   Problem(s):   502 gateway errors when trying to access https://www.example.com/site1/ (connect() failed (111: Connection refused) while connecting to upstream)   Setup:   example.com running on port 80 (nginx). site1 and site2 running on ports 8001 and 8002 respectively.   nginx config:      worker_processes 1;      events { worker_connections 1024; }      http {         sendfile on;          upstream site1 {             server 127.0.0.1:8001;         }          upstream site2 {             server 127.0.0.1:8002;         }          server {             listen 80 default_server;             server_name _;             return 301 https://$host$request_uri;         }          server {              listen 443 ssl;             listen [::]:443 ssl;             gzip on;             access_log on;             log_not_found on;             error_log  /var/log/nginx/error.log error;             server_name example.com www.example.com;             charset UTF-8;             root /var/www/html;             error_page 404 /404.html;              ssl_prefer_server_ciphers on;             ssl_certificate /etc/ssl/server.crt;             ssl_certificate_key /etc/ssl/server.key;              location /site1/ {                 proxy_set_header X-Original-Request $request_uri;                 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_pass http://site1;             }              location /site2/ {                 proxy_set_header X-Original-Request $request_uri;                 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_pass http://site2;             }         }     }   Facing a few problems regarding setting up my nginx reverse-proxy. Any help in this regard is much appreciated. Many thanks.
This is a  about Connection Refused    We see a lot of questions to the effect      When I try to connect to a system I get a message      Connection refused      Why is this ?
Changing back button in iOS 7 disables swipe to navigate back I'm trying to understand the UMP of the product functor as right adjoint to the diagonal functor but I'm having difficulties understanding the notation in Steve Awodey's . On page 210 he uses $(f_1, f_2)$, $\langle f_1, f_2 \rangle$ and $(f_1 \times f_2)$ all within one paragraph. What are those? How are these defined and how do they differ? I've noticed that in comments, when you create `code region` with backticks, the backslash will still work as an escape character within that region (but it should not, IMHO).  To clarify:   In comments, `\\` will be rendered as \, but it should be rendered as \\ In the post body itself, `\\` will be rendered as \\ (i.e., correctly)   This is especially confusing when you enter regular expressions into a comment, since backslash-escaping is very common there, and confusion increases if you are dealing with a regex that is double-escaped for representation in a string.   At some point you lose track how many backslashes you must make so the comment renders correctly, or you don't notice fast enough (or at all) and the comment contains wrong code where the same markup in a question or answer would come out as perfectly correct.   It's just that comments can't be corrected anymore after the grace period, leaving you with the choice of either deleting the comment, thus crippling the conversation, or engaging in a trial-and-error game of writing another comment with even more backslashes to explain the issue.  My question is two-fold:   Will this error be corrected? If yes, existing comments should probably be searched and "fixed" by a routine that tries to do the right thing (this is probably somewhere between hard and impossible) Or, can I rest assured that never ever the behavior of the backslash in comments is going to be changed, so I can start working around this issue by hand, knowing that they won't start displaying incorrectly at some point in the future? Winter 18  does not get values from a parent record I am testing the new  &lt;lightning:datatable&gt;, it is really good, and is a good replacement for most of my use cases which today I use a custom list component that I have developed.  I am getting data from my server through apex method, to populate it into the &lt;lightning:datatable&gt; component. I can bind the returned list directly to the data attribute and if the column names are same as the field names, all data is bound correctly.  The problem occurs when I get data from a parent record. For example - I want the Account name of my contact.  This example can show the problem:  Component Markup    &lt;aura:handler name="init" value="{!this}" action="{!c.doInit}"/&gt;  &lt;aura:attribute name="mydata" type="Object"/&gt; &lt;aura:attribute name="mycolumns" type="List"/&gt; &lt;aura:attribute name="sortedBy" type="String"/&gt; &lt;aura:attribute name="sortedDirection" type="String"/&gt;  &lt;lightning:datatable data="{! v.mydata }"                      columns="{! v.mycolumns }"                      keyField="Id"                      onrowselection="{! c.getSelectedName }"                      onsort="{!c.updateColumnSorting}"                      sortedBy="{!v.sortedBy}"                      sortedDirection="{!v.sortedDirection}"                      hideCheckboxColumn="{!false}" /&gt;        Component Controller  ({     doInit: function (component, event, helper) {         component.set('v.mycolumns', [                     {label: 'Id', fieldName: 'Id', type: 'id', sortable:"true"},                     {label: 'First Name', fieldName: 'FirstName', type: 'text', sortable:"true"},                     {label: 'Last Name', fieldName: 'LastName', type: 'text', sortable:"true"},                     {label: 'First Name Hebrew', fieldName: 'First_name_Hebrew__c', type: 'text', sortable:"true"},                     {label: 'Last Name Hebrew', fieldName: 'Last_name_Hebrew__c', type: 'text', sortable:"true"},                     {label: 'Account', fieldName: 'Account.Name', type: 'text', sortable:"true"},                     {label: 'Email', fieldName: 'Email', type: 'email', sortable:"true"},                     {label: 'Phone', fieldName: 'Phone', type: 'phone', sortable:"true"}                 ]);          var action = component.get("c.getRecordsFromDb");         action.setParams({             sObjectName: "Contact",             commaDelimitedFieldNames: "Id,FirstName,LastName,First_name_Hebrew__c,Last_name_Hebrew__c,Account.Name,Email,Phone",             filter: ""         });         action.setCallback(this, function(response){             var state = response.getState();             if (component.isValid() &amp;&amp; state === "SUCCESS") {                 var data = response.getReturnValue();                  component.set("v.mydata", data);             }         });         $A.enqueueAction(action);     } })   APEX Aura Enabled Method  @AuraEnabled public static List&lt;sObject&gt; getRecordsFromDb(String sObjectName,         String commaDelimitedFieldNames,         String filter) {      system.debug('\n\n\n\ngetRecordsFromDb sObjectName: ' + sObjectName + ', commaDelimitedFieldNames: ' + commaDelimitedFieldNames + ', filter: ' + filter + '\n\n\n\n');      // create a dynamic soql to get the value of the field     String sql = 'SELECT ' + commaDelimitedFieldNames + ' FROM ' + sObjectName;      if (!String.isBlank(filter))         sql += ' WHERE ' + filter;      system.debug('\n\n\n\ngetRecordsFromDb sql: ' + sql + '\n\n\n\n');     List&lt;sObject&gt; records = Database.query(sql);     system.debug('\n\n\n\ngetRecordsFromDb: ' + records + '\n\n\n\n');      return records; }   The problem is with the Account.Name field - the &lt;lightning:datatable&gt; component does not display the column data.   I know that the data is returned ok, and I know that in the object that is returned, the Account is contained like an object (probably this is the problem):    Is there a good way to show parent record data with this component? What is the advantage on saving the money for the overlord when you have 9 drones, and not filling your supply first and then getting the overlord?  In my theory, in the first case you get to wait the saving time with 9 drones, and get to wait almost the same time with 10 drones in the second case. Second case should be better, since 10 drones mine faster than 9? So why does everybody go with the first case?  All this is assuming you go 12 pool or something like that, where you will get more drones after the overlord. 6- and 8-pools are obviously different. How do I make Div Container 100% width only on homepage of site? So I'm working on this class that's supposed to request help documentation from a vendor through a web service. I try to name it DocumentRetriever, VendorDocRequester, DocGetter, but they just don't sound right. I ended up browsing through  for half an hour trying to come up with an adequate word.   Start programming with bad names is like having a very bad hair day in the morning, the rest of the day goes downhill from there. Feel me? I was having a look at an old question of mine when I browsed the  from the timeline. I scrolled downwards and realized the Review completed panel comes along for the ride. While that might be , tags flowing over top of it as pictured below probably isn't.  Here's a .gif of the Question and Duplicate tabs flowing over it as well. Note that the timeline button also flows over. If vote buttons are present, they will also flow over it.  Reproduced on Chrome and Microsoft Edge. Update Per  by Tiago Martins Peres, this issue also happens in other Review types, namely Late Answers, First Posts and Low Quality Posts. In addition to that, it is causing the action buttons on reviews to become unclickable if you scroll low enough.  As a temporary workaround, you can use 's , which  this issue. Multiple Author and email with location? I am trying to add multiple Author with their email and location but not working.  I am trying to get something like this     first_person^1 , second person^2, third_person^3            {1^mail, 2^mail, 3^mail}@gmail.com                   institution name                      location Setting Blend Width on Mosaic Dataset using ArcMap Worf was seen still wearing the red colours on Star Trek Nemesis. Was he still a strategic operations officer, or did he become tactical officer again despite wearing red colours? Do I need to have antivirus software installed? I thought that there was no need to scan for viruses either in Ubuntu or any Linux distros until I found virus scanner packages clamtk and klamav in Ubuntu software center yesterday.  This leads to the following questions:   How do viruses differ between Linux and Windows? How do the strategies for protection differ between Linux and Windows? Should a virus scanner package be installed on my system? If so, which would be a better option? How to synchronize clocks for computers that are not online? I was about to add an extra signal handler to an app we have here and I noticed that the author had used sigaction() to set up the other signal handlers. I was going to use signal(). To follow convention I should use sigaction() but if I was writing from scratch, which should I choose? can u suggest me any short trick of solving these kind of problems. How to find last four digits of any number raised to some power ? Why is it that Blender will only allow me to render with a CPU (GPU choice is unavailable)? Or is it until I acquire a graphics card that is specially built for such a task?  The images below show a Dell System Diagnostics (Video calibration) and GPU-Z results.      Platform: Dell Inspiron 3521 notebook with Core&nbsp;i3 Intel HD Graphics 4000 Let $q_1,q_2,q_3,q_4$ be orthonormal vectors in $\mathbb{R}^4$,$z_1,z_2,...,z_6$ orthonormal vectors in $\mathbb{R}^6$ and $A=z_1q_1^T + z_2q_2^T$. Let $q_1,q_2,q_3,q_4$ be orthonormal vectors in $\mathbb{R}^4$,$z_1,z_2,...,z_6$ orthonormal vectors in $\mathbb{R}^6$ and $A=z_1q_1^T + z_2q_2^T$.  a) Find the base and dimension of fundamental subspaces of matrix A  b) Using the results given by a) find the general solution for $Ax - z_1$.  Any hint would be appreciated. $\mathbb{F}_p[X]/(X^2+X+1)$ is a field iff $p \equiv 2 \bmod 3$ Let $p$ be a prime. Prove that $\mathbb{F}_p[X]/(X^2+X+1)$ is a field iff $p \equiv 2\bmod3$.    So:   If $p \equiv 2 $ mod $ 3$, I have to show that every element of $\mathbb{F}_p[X]/(X^2+X+1)$ has an inverse.  If $\mathbb{F}_p[X]/(X^2+X+1)$ is a field I have to show $p \equiv 2 $ mod $ 3$. Retaining all fishnet grid squares within boundary of polygon from another feature class? I have created a fishnet grid (3km x 3km) over a vector polygon.   I now want to clip the fishnet over the vector polygon retaining all grid squares within the boundary of the polygon.   Therefore I want all squares that would typically be clipped into partial squares to remain as whole squares.   Does anybody know how to do this? converting date string to date format