# Avatar not found after updating to 1.4 beta because of port in URL

**URL:** https://meta.discourse.org/t/avatar-not-found-after-updating-to-1-4-beta-because-of-port-in-url/29632
**Category:** Bug
**Created:** [4 juni 2015 om 01:43 UTC](https://meta.discourse.org/t/avatar-not-found-after-updating-to-1-4-beta-because-of-port-in-url/29632 "2015-06-04T01:43:18Z")
**Posts on this page:** 11
**Page:** 1

<div class="post-metadata">

### Author: ![wil93](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/wil93/32/121264_2.png) [@wil93](https://meta.discourse.org/u/wil93)
#### Post date: [4 juni 2015 om 01:43 UTC](https://meta.discourse.org/t/avatar-not-found-after-updating-to-1-4-beta-because-of-port-in-url/29632/1 "2015-06-04T01:43:18Z")

</div>

As you can see [here](http://cms.di.unipi.it:8000/) avatars are not loading after upgrading to 1.4 beta.

![](https://global.discourse-cdn.com/meta/original/3X/1/0/10c805c80f26f78a335d22143fed378bcf8dac51.png)

The avatar src seems to be: `"/user_avatar/cms.di.unipi.it:8000/wil93/120/6_1.png"`, and it looks wrong (the domain is repeated).

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [4 juni 2015 om 01:47 UTC](https://meta.discourse.org/t/avatar-not-found-after-updating-to-1-4-beta-because-of-port-in-url/29632/2 "2015-06-04T01:47:19Z")

</div>

Do you have a developer only port setting in your site settings?

---

<div class="post-metadata">

### Author: ![wil93](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/wil93/32/121264_2.png) [@wil93](https://meta.discourse.org/u/wil93)
#### Post date: [4 juni 2015 om 08:47 UTC](https://meta.discourse.org/t/avatar-not-found-after-updating-to-1-4-beta-because-of-port-in-url/29632/3 "2015-06-04T08:47:10Z")

</div>

I think not… I can’t find a “developer only port” in the settings, however (I searched for “port”).

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [4 juni 2015 om 08:49 UTC](https://meta.discourse.org/t/avatar-not-found-after-updating-to-1-4-beta-because-of-port-in-url/29632/4 "2015-06-04T08:49:04Z")

</div>

It was removed as a visible setting in most Discourse instances because it causes problems (as per above..).

If you set it in previous, older versions of Discourse it will still be present. That’s the only reason I could ever think a port would show up there.

---

<div class="post-metadata">

### Author: ![wil93](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/wil93/32/121264_2.png) [@wil93](https://meta.discourse.org/u/wil93)
#### Post date: [4 juni 2015 om 09:46 UTC](https://meta.discourse.org/t/avatar-not-found-after-updating-to-1-4-beta-because-of-port-in-url/29632/5 "2015-06-04T09:46:28Z")

</div>

Oh sorry, that is normal: we decided to set up that port because we weren’t allowed to add a subdomain and because we read that discourse had issues when served on a prefix (like `example.com/forum`). The port was also there in the previous version. However, in the previous version the avatars were visible 😄

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [4 juni 2015 om 09:51 UTC](https://meta.discourse.org/t/avatar-not-found-after-updating-to-1-4-beta-because-of-port-in-url/29632/6 "2015-06-04T09:51:00Z")

</div>

If that setting exists you will have problems. It is marked as a developer only setting, and hidden in recent versions of Discourse, for a reason..

---

<div class="post-metadata">

### Author: ![riking](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/riking/32/170938_2.png) [@riking](https://meta.discourse.org/u/riking)
#### Post date: [4 juni 2015 om 10:00 UTC](https://meta.discourse.org/t/avatar-not-found-after-updating-to-1-4-beta-because-of-port-in-url/29632/7 "2015-06-04T10:00:16Z")

</div>

To kill the setting, enter a SQL console and:

```
DELETE FROM site_settings WHERE name = 'port';

```

---

<div class="post-metadata">

### Author: ![Stephen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/stephen/32/95011_2.png) [@Stephen](https://meta.discourse.org/u/Stephen)
#### Post date: [4 juni 2015 om 14:22 UTC](https://meta.discourse.org/t/avatar-not-found-after-updating-to-1-4-beta-because-of-port-in-url/29632/8 "2015-06-04T14:22:05Z")

</div>

but if he does that with another site on port 80 Discourse will become inaccessible?

---

<div class="post-metadata">

### Author: ![wil93](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/wil93/32/121264_2.png) [@wil93](https://meta.discourse.org/u/wil93)
#### Post date: [4 juni 2015 om 15:03 UTC](https://meta.discourse.org/t/avatar-not-found-after-updating-to-1-4-beta-because-of-port-in-url/29632/9 "2015-06-04T15:03:33Z")

</div>

I don’t have that entry:

```
discourse=> select * from site_settings where name = 'port';
 id | name | data_type | value | created_at | updated_at 
----+------+-----------+-------+------------+------------
(0 rows)

```

The port is configured on a higher level, using docker:

```
ioi@cms:~$ docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
6a661b7761f9 local_discourse/discourse_allenamenti:latest "/sbin/boot" 13 hours ago Up 13 hours 0.0.0.0:2299->22/tcp, 0.0.0.0:8000->80/tcp discourse_allenamenti                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    

```

So, the URL is correct (we want it to have a port).

The problem is: it worked before the update 😄

---

<div class="post-metadata">

### Author: ![wil93](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/wil93/32/121264_2.png) [@wil93](https://meta.discourse.org/u/wil93)
#### Post date: [1 november 2015 om 19:09 UTC](https://meta.discourse.org/t/avatar-not-found-after-updating-to-1-4-beta-because-of-port-in-url/29632/10 "2015-11-01T19:09:54Z")

</div>

After a long search, I ultimately solved this issue.

The problem was that (in my YAML config file) I had:

```
DISCOURSE_HOSTNAME: 'cms.di.unipi.it:8000'

```

I just had to change it to:

```
DISCOURSE_HOSTNAME: 'cms.di.unipi.it'

```

And then run the usual rebuild command. Now the forum is still reachable at the `:8000` port, which I want, but it finally shows the avatars 🎉 🎊

---

<div class="post-metadata">

### Author: ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)
#### Post date: [2 november 2015 om 08:48 UTC](https://meta.discourse.org/t/avatar-not-found-after-updating-to-1-4-beta-because-of-port-in-url/29632/11 "2015-11-02T08:48:03Z")

</div>


