tags: cofacts, meeting note GA: UA-98468513-3 —

20211006 會議記錄

:::info

:potable_water: Release pipeline

:star: Released to production

:globe_with_meridians: Site

https://github.com/cofacts/rumors-site/releases/tag/release%2F20210930

:rocket: Staging

:robot_face: rumors-line-bot

Testing checklist

https://lin.ee/1QUzEX4nI

⛔️ Release Blockers

無

未竟項目

右上角「在真的假的開啟」 iOS 下沒有作用(production 上也是)

:globe_with_meridians: Site

Testing checklist

http://dev.cofacts.tw/

未登入下檢測:

登入自有帳號後檢測:

⛔️ Release Blockers
未竟項目

Delete reply requests

:::info 2021/12/01 Update A dedicated doc is opened to track its development - https://g0v.hackmd.io/hk1v8Ka5TCmIZinQ6zKU9Q :::

https://g0v-slack-archive.g0v.ronny.tw/index/channel/C2PPMRQGP#ts-1633251643.0785

帳號與內容

影響

處理方式

:::info 先試試看隱藏 solution

  1. user 建立黑名單
  2. 黑名單使用者的產出會被標上隱藏 state
  3. API 預設不顯示隱藏的東西;UI 會 request 隱藏的東西,並且在隱藏物的作者登入下顯示 :::

LINE bot event 送不進 Google Analytics

:::success 放個 hackmd 紀錄 incident hackmd URL 貼到每個表 :::

:::spoiler 分析細節


感謝 kevinho84 +++++

Docker host machine

$ ping www.google-analytics.com
PING www-google-analytics.l.google.com (142.251.42.142) 56(84) > bytes of data.
64 bytes from … (略) …
--- www-google-analytics.l.google.com ping statistics ---
8 packets transmitted, 8 received, 0% packet loss, time 7077ms
rtt min/avg/max/mdev = 0.540/0.597/0.644/0.041 ms
$ nslookup www.google-analytics.com
Server:		<some-ip-under-same-subnet>
Address:	<some-ip-under-same-subnet>#53

Non-authoritative answer:
www.google-analytics.com	canonical name = www-google-> analytics.l.google.com.
Name:	www-google-analytics.l.google.com
Address: 203.208.50.65

(A, B, C and D are under same subnet of my machine’s IP address)

docker@debian:~/rumors-deploy$ traceroute www.google-analytics.com
traceroute to www.google-analytics.com (142.251.42.142), 30 hops max, 60 byte packets
 1  A (A)  0.578 ms B (B)  0.709 ms  0.848 ms
 2  if-11-1-5-0.gw2.shg1.jp.linode.com (C)  0.462 ms if-0-1-5-0.gw2.shg1.jp.linode.com (D)  0.485 ms  0.458 ms
 3  72.14.196.114 (72.14.196.114)  2.102 ms 72.14.223.216 (72.14.223.216)  0.404 ms  0.408 ms
 4  108.170.242.97 (108.170.242.97)  0.552 ms  0.595 ms 108.170.242.129 (108.170.242.129)  1.615 ms
 5  108.170.236.127 (108.170.236.127)  0.542 ms  0.550 ms  0.561 ms
 6  nrt12s45-in-f14.1e100.net (142.251.42.142)  0.583 ms  0.567 ms  0.532 ms

LINE bot docker container

PING www.google-analytics.com (203.208.50.65): 56 data bytes
64 bytes from … (略) …
--- www.google-analytics.com ping statistics ---
16 packets transmitted, 4 packets received, 75% packet loss
round-trip min/avg/max = 105.746/190.202/228.356 ms
/srv/www # nslookup www.google-analytics.com
Server:		127.0.0.11
Address:	127.0.0.11:53
Non-authoritative answer:
www.google-analytics.com	canonical name = www-google-> analytics.l.google.com
Name:	www-google-analytics.l.google.com
Address: 203.208.50.65

Non-authoritative answer:
www.google-analytics.com	canonical name = www-google-analytics.l.google.com

DOCKER_GATEWAY: IP address used by docker (172.18.x.x); E and F are under same subnet of my machine’s IP address)

/srv/www # traceroute www.google-analytics.com
traceroute to www.google-analytics.com (203.208.50.65), 30 hops max, 46 byte packets
 1  DOCKER_GATEWAY (DOCKER_GATEWAY)  0.007 ms  0.006 ms  0.004 ms
 2  A (A)  0.560 ms  0.519 ms  B (B)  0.806 ms
 3  if-11-0-0-0.gw2.shg1.jp.linode.com (E)  0.471 ms  if-11-1-5-0.gw1.shg1.jp.linode.com (F)  0.638 ms  0.314 ms
 4  ae-9.a00.tokyjp05.jp.bb.gin.ntt.net (192.80.16.5)  0.833 ms  1.315 ms  1.074 ms
 5  ae-22.r02.tokyjp05.jp.bb.gin.ntt.net (129.250.4.7)  1.594 ms  1.793 ms  1.209 ms
 6  202.97.94.13 (202.97.94.13)  90.094 ms  xe-0.chinanet.tokyjp05.jp.bb.gin.ntt.net (129.250.66.10)  204.861 ms  ae-22.r02.tokyjp05.jp.bb.gin.ntt.net (129.250.4.7)  1.411 ms
 7  *  xe-3.chinanet.tokyjp05.jp.bb.gin.ntt.net (129.250.66.90)  161.073 ms  *
 8  202.97.74.2 (202.97.74.2)  80.426 ms  202.97.74.34 (202.97.74.34)  52.750 ms  202.97.91.25 (202.97.91.25)  56.915 ms
 9  202.97.62.73 (202.97.62.73)  54.355 ms  202.97.94.141 (202.97.94.141)  205.894 ms  *
10  202.97.19.53 (202.97.19.53)  90.569 ms  202.97.13.157 (202.97.13.157)  86.509 ms  *
11  101.95.88.133 (101.95.88.133)  55.874 ms  61.152.24.105 (61.152.24.105)  87.906 ms  61.152.25.109 (61.152.25.109)  95.932 ms
12  *  101.95.95.162 (101.95.95.162)  112.589 ms  101.95.116.138 (101.95.116.138)  96.343 ms
13  *  *  101.95.116.138 (101.95.116.138)  95.539 ms
14  *  203.208.62.221 (203.208.62.221)  96.958 ms  203.208.62.2 (203.208.62.2)  225.663 ms
15  203.208.62.55 (203.208.62.55)  220.407 ms  203.208.62.2 (203.208.62.2)  229.029 ms  203.208.62.16 (203.208.62.16)  224.079 ms
16  *  203.208.50.65 (203.208.50.65)  220.497 ms  203.208.62.55 (203.208.62.55)  238.744 ms

分析

我的 linode 的 network 是有開 network helper ( https://www.linode.com/docs/guides/network-helper/ ) 的。所以,Linode 會幫我管理 /etc/resolv.conf

所以我的 /etc/resolve.conf 長這樣

# Generated by Linode Network Helper
# Thu Sep 16 18:08:49 2021 UTC
#
# This file is automatically generated on each boot with your Linode's
# current network configuration. If you need to modify this file, please
# first disable the 'Auto-configure Networking' setting within your Linode's
# configuration profile:
#  - https://cloud.linode.com/linodes/2569620/advanced
#
# For more information on Network Helper:
#  - https://www.linode.com/docs/platform/network-helper
#
# A backup of the previous config is at /etc/.resolv.conf.linode-last
# A backup of the original config is at /etc/.resolv.conf.linode-orig
#
domain members.linode.com
search members.linode.com
nameserver 第一台
nameserver 第二台
nameserver 第三台
options rotate

而下面分別是我的 hostmachine 使用 8.8.8.8 以及這三台 linode name server resolve 出來的結果:

host-machine:~# nslookup www.google-analytics.com 8.8.8.8
Server:		8.8.8.8
Address:	8.8.8.8#53

Non-authoritative answer:
www.google-analytics.com	canonical name = www-google-analytics.l.google.com.
Name:	www-google-analytics.l.google.com
Address: 172.217.160.78

host-machine:~# nslookup www.google-analytics.com 第一台
Server:		第一台
Address:	第一台#53

Non-authoritative answer:
www.google-analytics.com	canonical name = www-google-analytics.l.google.com.
Name:	www-google-analytics.l.google.com
Address: 203.208.50.65

host-machine:~# nslookup www.google-analytics.com 第二台
Server:		第二台
Address:	第二台#53

Non-authoritative answer:
www.google-analytics.com	canonical name = www-google-analytics.l.google.com.
Name:	www-google-analytics.l.google.com
Address: 142.251.42.142

host-machine:~# nslookup www.google-analytics.com 第三台
Server:		第三台
Address:	第三台#53

Non-authoritative answer:
www.google-analytics.com	canonical name = www-google-analytics.l.google.com.
Name:	www-google-analytics.l.google.com
Address: 216.58.197.238

三台 name server 說的 www.google-analytics.com 位置都不同,但第一台 name server 回傳的 IP 「203.208.50.65」指向中國

然後又因為 docker container 會取用 host machine 的 /etc/resolv.conf ( https://docs.docker.com/config/containers/container-networking/#dns-services ) 所以我的 line bot docker container somehow 就把 www.google-analytics.com 解析成了 googlecn 203.208.50.65

我把 host machine 上的 /etc/resolv.conf 的第一台 name server comment 掉之後重開 line bot 的 container line bot container 就能連到 www.google-analytics.com ,資料也就能正常的送進 google analytics 了⋯⋯

:::

rumors-ai