matoken

@matoken@snac.matoken.org


Sitehttps://matoken.org/
Bloghttps://matoken.org/blog/
GPG Key572E532C

Location: 31.2,130.8

0 ★ 0 ↺

[?]matoken » 🌐
@matoken@snac.matoken.org

今日打ち上げ
後ろに10分ずれてる?

JAXA | H3ロケット8号機による「みちびき5号機」の打上げ時刻及び打上げ時間帯[再設定] https://www.jaxa.jp/press/2025/12/20251215-1_j.html

0 ★ 0 ↺

[?]matoken » 🌐
@matoken@snac.matoken.org

室温2℃寒い

matoken boosted

[?]matoken » 🌐
@matoken@matoken.org

DuckDuckGoのイースターエッグ

tumblrで見かけたのですが,検索エンジンのDuckDuckGoのイースターエッグを1つ知りました. […] [SENSITIVE CONTENT]

tumblrで見かけたのですが,検索エンジンのDuckDuckGoのイースターエッグを1つ知りました.

DuckDuckGoで「linux」と検索すると検索文字列の左のアヒルアイコンがペンギンになるというもの.

https://www.tumblr.com/matoken/802369996450906112/httpsduckduckgocomdistlogosdynamiclinuxpn

自分でも試してみるとたしかにペンギンに.

こちらのURL でいつでも確認できます.

ただし,いつも使っているJavaScript の必要ないhtml版( https://html.duckduckgo.com/html/ )だと変わりませんでした.

「BSD」だと特に何も変わらず.
tootしたところ,「FreeBSD」だとデーモンくんになると教えてもらいました.
その他「OpenBSD」もありました.



NetBSDは無さそう.旗はアイコンにしづらかった?

一部のボーカロイドもあるようです.
探せば他にもあるかもしれませんね.

0 ★ 0 ↺

[?]matoken » 🌐
@matoken@snac.matoken.org

ドロップキャッチ困る
ドメイン同じなのでパスワードマネージャが自動入力しちゃうか……証明書をパスワードマネージャに入れて変更があったら警告出すとか?

「関係者は誰も関与してません」往年の迷サイト『スラッシュドット・ジャパン』の偽サイトが登場し「詐欺サイトの可能性があります。絶対ログイン禁止」 - Togetter https://togetter.com/li/2639361

matoken boosted

[?]matoken » 🌐
@matoken@matoken.org

snacのWelcome pageを設定ファイルでカスタマイズ

さくらのナレッジに軽量ActivityPub Server のsnac についての記事を寄稿しました. さくらインターネットのさくらのナレッジにsnacの記事を寄稿 – matoken’s blog ここに書かなかったsnac のことをいくつか書いていこうと思います. 今日はsnac でのWelcome pageのカスタマイズについてその2. 以前のカスタマイズではhtml ファイルの書き換えを行いましたが今回は設定ファイルでの書き換えです. snacのWelcome pageのhtmlファイルカスタマイズ – matoken’s blog […] [SENSITIVE CONTENT]

さくらのナレッジに軽量ActivityPub Server のsnac についての記事を寄稿しました.

ここに書かなかったsnac のことをいくつか書いていこうと思います.
今日はsnac でのWelcome pageのカスタマイズについてその2.
以前のカスタマイズではhtml ファイルの書き換えを行いましたが今回は設定ファイルでの書き換えです.

snac のtop page は以下のような挨拶ページが表示されます. greeting.html ファイルを書き換えることでこのページをカスタマイズ出来ますが,他にもサーバー設定ファイルの server.json でもカスタマイズ項目があります.

$ w3m -dump https://snac.kagolug.org/snac.kagolug.org is a Fediverse instance that uses the ActivityPub protocol. Inother words, users at this host can communicate with people that use softwarelike Mastodon, Pleroma, Friendica, etc. all around the world.This server runs the snac software and there is no automatic sign-up process.The following users are part of this community:    @info@snac.kagolug.org (info)    @matoken@snac.kagolug.org (matoken)This site is powered by snac.

show_instance_timeline これを true に設定するとWelcome page に最新のユーザーが投稿したタイムラインが表示されるようになります.
また,以下の設定項目が設定されていた場合それも表示されます.

admin_email
インスタンス管理者の電子メールアドレス

admin_account
インスタンス管理者のアカウント

title
インスタンスのタイトル

short_description
インスタンスに対する短い説明

short_description_raw
short_description を生の文字列として解釈するか,HTML に変換するか

例えばこの様に設定すると,

$ grep -A5 show_instance_timeline snac-data/server.json    "show_instance_timeline": true,    "admin_email": "",    "admin_account": "matoken",    "title": "🐈🐈🐈",    "short_description": "matokenの個人ActivityPub インスタンスです.",    "short_description_raw": false,

こんな感じになりました.

注意点として,show_instance_timelinetrue にすると greeting.html は無視されるようです.用途や好みに合わせてどちらかを利用する感じでしょうか.

0 ★ 0 ↺

[?]matoken » 🌐
@matoken@snac.matoken.org

INIU のモバイルバッテリーでリコール
US 向けのようだけど日本語ページがある
少し前に(今回の対象とは違う)INIU のバッテリー買ったので少し心配

INIU | BI-B41-recall https://iniushop.com/ja-jp/pages/recall-b41

0 ★ 0 ↺

[?]matoken » 🌐
@matoken@snac.matoken.org

「なんか
殴れる棒
探してきます」

放課後ていぼう日誌・第88話 | ヤンチャンWeb(ヤングチャンピオン)
https://youngchampion.jp/episodes/75c27cf3ba7b2

0 ★ 0 ↺

[?]matoken » 🌐
@matoken@snac.matoken.org

閉じればカバー必要ないとかこういうの好き
ESP32S3を使っているよ
これ以前は単体での技適はなかったけど今どうだろう?

Diptyx E-reader | Hackaday.io https://share.google/ZWWLdMAvux7nuBKZH

...
0 ★ 0 ↺

[?]matoken » 🌐
@matoken@snac.matoken.org

写真見たら大きいESP32でこれなら大丈夫そう
小さな以前技適なかったM5StickC Plus2のはESP32-PICO-V3-02か
似たのが秋月にあるな

Wi-Fiモジュール ESP32-PICO-V3-ZERO: 半導体 秋月電子通商-電子部品・ネット通販 https://akizukidenshi.com/catalog/g/g116823/

    0 ★ 0 ↺

    [?]matoken » 🌐
    @matoken@snac.matoken.org

    良さそう
    グリルパン欲しくなった

    魚焼きグリルで鶏肉とイモをグリルしろ|マシーナリーとも子 https://note.com/mahinari_tomoko/n/na3cfbe9b23ed

    0 ★ 0 ↺

    [?]matoken » 🌐
    @matoken@snac.matoken.org

    RaspberryPi3BでのNitter のbuild 時にswap を増やし忘れてssh 切断されてしまう
    多分コケるまで帰ってこないなこれ……

    matoken boosted

    [?]matoken » 🌐
    @matoken@matoken.org

    snacでのSPAM対策

    さくらのナレッジに軽量ActivityPub Server のsnac についての記事を寄稿しました. さくらインターネットのさくらのナレッジにsnacの記事を寄稿 – matoken’s blog ここに書かなかったsnac のことをいくつか書いていこうと思います. 今日はsnac でのSPAM 対策について. […] [SENSITIVE CONTENT]

    さくらのナレッジに軽量ActivityPub Server のsnac についての記事を寄稿しました.

    ここに書かなかったsnac のことをいくつか書いていこうと思います.
    今日はsnac でのSPAM 対策について.

    SPAM が来ないに越したことはありませんがActivityPub でも偶に見かけます.もしSPAM が来るときのことを考えて対策を確認しておきます.
    snac では2つの対策があるようです.

    SPAM Mitigation    There have been some SPAM attacks on the Fediverse and, as too many instances and server implementations out there still allow automatic account creation, it will only get worse.  snac includes some (not very strong) tools for try‐    ing to survive the SPAM flood that will eventually happen.

    The  min_account_age field in the main configuration file allows setting a minimum age (in seconds) to consider too recently created accounts suspicious of being a potential source of SPAM. This is a naïve assumption, because spam‐mers can create accounts, let them dormant for a while and then start to use them. Also, some ActivityPub implementations don't even bother to return a creation date for their accounts, so this is not very useful.

    From version 2.50, post content can be filtered out by regular expressions.  These weapons of mass destruction can be written into the filter_reject.txt file in the server base directory, one per line;  if  this  file  exists,  allposts'  content  will  be  matched (after being stripped of HTML tags) against these regexes, one by one, and any match will make the post to be rejected. Use lower case, the regex will be case insensitive by default.  If you don'tknow about regular expressions, don't use this option (or learn about them inw some tutorial, there are gazillions of them out there), as you and your users may start missing posts. Also, given that every regular expression  imple‐mentation supports a different set of features, consider reading the documentation about the one implemented in your system.

    — snac(8) より

    アカウント作成から日の浅いアカウントを拒否

    1つ目はメイン設定ファイルの server.json で設定できる min_account_age で,投稿を受け付けるアカウントが作成されてからの時間が設定できます.
    ただし,SPAM アカウントを作成して寝かせてから運用したり,アカウントの作成日を返さない実装もあるらしいのであまり役に立たないようです.
    既定値は 0 になっています.

    $ jq .min_account_age server.json0

    投稿内容を正規表現でフィルタリング

    2つめは投稿内容を正規表現でフィルタリングできるようです.snac データディレクトリに filter_reject.txt を用意してこのファイル中に1行ずつ記述できるようです.これにより全ての投稿をHTML タグを取り除いた後正規表現と1つずつ照合され一致する投稿は拒否されます.
    正規表現なのでテストを十分して設定したほうが良さそうです.

    Reverse proxy やFirewall などsnac の外で対策も考えられます.その他以下のようなものもあるようです.e-mail もこんな感じで多段にしたりしますね.そうなるとReceived のようなものが見たいなと思ったりも.

    0 ★ 0 ↺

    [?]matoken » 🌐
    @matoken@snac.matoken.org

    ThinkPad L13 にUSB HUB 経由で給電すると65W 必要になり既定値の45W じゃ起動時に警告が出る
    角ACアダプタ90W はあるのでこういうの使う手も?

    Amazon.co.jp: アイネックス USB-C電源変換アダプタ PD100W対応 Lenovo/NEC用 DCC-SQREP10 : パソコン・周辺機器 https://www.amazon.co.jp/dp/B0DLGNYJT9

    0 ★ 0 ↺

    [?]matoken » 🌐
    @matoken@snac.matoken.org

    2000円ちょいの掛け布団どうだろう?
    洗濯できるのは良さそう

    Amazon|fuwawa 掛け布団 シングル 冬用 暖かい かけ布団 冬 掛けふとん 抗菌防臭・防カビ・防ダニ 帝人マイティトップⅡECO使用 SEK認証 ボリューム ふとん 軽量 柔らかな肌触り 洗える 布団 ピーチスキン加工 充填量1.5kg (150x210 ダークグレー)|掛けふとん オンライン通販 https://www.amazon.co.jp/dp/B0C7Z7WR35

    0 ★ 0 ↺

    [?]matoken » 🌐
    @matoken@snac.matoken.org

    sun の起動時のframebuffer ロゴ集

    mdehling/sun-fb-logos: A collection of Sun framebuffer logos for your viewing pleasure. https://github.com/mdehling/sun-fb-logos?tab=readme-ov-file

    0 ★ 0 ↺

    [?]matoken » 🌐
    @matoken@snac.matoken.org

    猫のおなかで冷たい手を温めようとして逃げられる🐈

    matoken boosted

    [?]matoken » 🌐
    @matoken@matoken.org

    snacのrobots.txt

    さくらのナレッジに軽量ActivityPub Server のsnac についての記事を寄稿しました. さくらインターネットのさくらのナレッジにsnacの記事を寄稿 – matoken’s blog ここに書かなかったsnac のことをいくつか書いていこうと思います. 今日はsnac でのrobots.txt について. […] [SENSITIVE CONTENT]

    さくらのナレッジに軽量ActivityPub Server のsnac についての記事を寄稿しました.

    ここに書かなかったsnac のことをいくつか書いていこうと思います.
    今日はsnac でのrobots.txt について.

    検索エンジンで「site:snac.kagolug.org」のように検索してみると何も出てきません.運用開始からそう時間が経っていないからかな?と思いつつ念の為 robots.txt を確認するとこんな感じで全て拒否るすようになっていました.

    $ w3m -dump https://snac.kagolug.org/robots.txtUser-agent: *Disallow: /

    source を確認すると httpd.c の中でハードコーディングされているようです.

    $ grep -n -A5 robots.txt httpd.c321:    if (strcmp(q_path, "/robots.txt") == 0) {322-        status = HTTP_STATUS_OK;323-        *ctype = "text/plain";324-        *body  = xs_str_new("User-agent: *\n"325-                            "Disallow: /\n");326-    }

    snac の設定でどうにかできればいいですが恐らく無理.ISSUE を探すと以下のものが.404エラーが邪魔なので用意しているだけでカスタマイズしたい人は前段のhttp proxy でルールを追加する感じのようです.

    ISSUE を立てた方はnginx でカスタムrobots.txt を返すようにしているようです.

    Actually, I am able to work around this by returning a custom robots.txt with nginx:

    location = /robots.txt {return 200 'User-agent: FediFetcher\nAllow: /\nUser-agent: *\nDisallow: /\n';}

    自分の環境はApache2 httpd ですが同じような設定はできるので設定してみます.

    Apache2 httpd のAlias でrobots.txt を設定

    以前Nitter を公開していたときにもやっていたのでこれを参考に設定します.

    Apache2 httpd のsnac 部分の設定を以下のように修正しました.これでLinux ファイルシステム内の /var/lib/snac2/robots.txt/robots.txt になるはずです.

    $ sudo git diff /etc/apache2/sites-available/011-snac.kagolug.org.confdiff --git a/apache2/sites-available/011-snac.kagolug.org.conf b/apache2/sites-available/011-snac.kagolug.org.confindex f5b5c7f..7bb72c1 100644--- a/apache2/sites-available/011-snac.kagolug.org.conf+++ b/apache2/sites-available/011-snac.kagolug.org.conf@@ -58,6 +58,11 @@        </Location>        Alias /static /var/www/static+       Alias /robots.txt /var/lib/snac2/robots.txt+       <Location "/robots.txt">+               ProxyPass !+               Require all granted+       </Location>        # Possible values include: debug, info, notice, warn, error, crit,        # alert, emerg.

    設定を確認してから反映します.

    $ sudo apache2ctl configtest$ sudo systemctl reload apache2

    このファイルが,

    $ sudo -u www-data cat /var/lib/snac2/robots.txtUser-agent: *Allow: /

    /robots.txt に反映されました.

    $ w3m -dump https://snac.kagolug.org/robots.txtUser-agent: *Allow: /

    これで各種bot からのアクセスが許可されました.

    source 書き換え

    source からbuild している環境ではsource 書き換えでもrobots.txt をカスタマイズできました.でもアップデートのたびにパッチを当てるのは面倒なのでやはりproxy で設定するほうが良さそうです.

    robots.txt を無くす(404 エラーがたくさんなのであまり良く無さそう)

    $ git diff httpd.cdiff --git a/httpd.c b/httpd.cindex a8cd849..976fdd6 100644--- a/httpd.c+++ b/httpd.c@@ -318,13 +318,6 @@ int server_get_handler(xs_dict *req, const char *q_path,         *body  = xs_json_dumps(j, 4);     }     else-    if (strcmp(q_path, "/robots.txt") == 0) {-        status = HTTP_STATUS_OK;-        *ctype = "text/plain";-        *body  = xs_str_new("User-agent: *\n"-                            "Disallow: /\n");-    }-    else     if (strcmp(q_path, "/style.css") == 0) {         FILE *f;         xs *css_fn = xs_fmt("%s/style.css", srv_basedir);

    $ w3m -dump https://snac.matoken.org/robots.txt404 Not Found (snac/2.85)

    全て許可に書き換え

    $ git diff httpd.cdiff --git a/httpd.c b/httpd.cindex a8cd849..c0bcaef 100644--- a/httpd.c+++ b/httpd.c@@ -322,7 +322,7 @@ int server_get_handler(xs_dict *req, const char *q_path,         status = HTTP_STATUS_OK;         *ctype = "text/plain";         *body  = xs_str_new("User-agent: *\n"-                            "Disallow: /\n");+                            "Allow: /\n");     }     else     if (strcmp(q_path, "/style.css") == 0) {

    $ w3m -dump https://snac.matoken.org/robots.txtUser-agent: *Allow: /

    0 ★ 0 ↺

    [?]matoken » 🌐
    @matoken@snac.matoken.org

    今日は温かいけど風が強い
    道路は葉っぱや枯れ枝でいっぱいでした🍂

    ...
    0 ★ 0 ↺

    [?]matoken » 🌐
    @matoken@snac.matoken.org

    思ったより雨は振らなかった

      0 ★ 0 ↺

      [?]matoken » 🌐
      @matoken@snac.matoken.org

      ねむーい

      1 ★ 0 ↺

      [?]matoken » 🌐
      @matoken@snac.matoken.org

      -5 の打ち上げ再設定されていた
      12/17 11:00(水)

      JAXA | H3ロケット8号機による「みちびき5号機」の打上げ[再設定] https://www.jaxa.jp/press/2025/12/20251213-1_j.html

        0 ★ 0 ↺

        [?]matoken » 🌐
        @matoken@snac.matoken.org

        snacでのSPAM対策ネタ書こうとしてたんだけどlocal でsnac 起動してip address でmention とか送れなそうでテストうまく行かないので後回しに
        てことで robots.txt の記事を先に書いた

        ...
        0 ★ 0 ↺

        [?]matoken » 🌐
        @matoken@snac.matoken.org

        robots.txt 反映されないな?で昔の自分に助けられた

        Nitterにrobots.txtを設定(Apache httpdのreverse proxy環境でAlias設定) – matoken's blog https://matoken.org/blog/2021/05/31/set-robots-txt-in-nitter-alias-setting-in-reverse-proxy-environment-of-apache-httpd/

          0 ★ 0 ↺

          [?]matoken » 🌐
          @matoken@snac.matoken.org

          しとしと雨☂
          傘持っていくか

          0 ★ 0 ↺

          [?]matoken » 🌐
          @matoken@snac.matoken.org

          今週のEpic無料ゲムもらおうと思ったら
          https://store.epicgames.com/ja/p/hogwarts-legacy -> 404 になってしまうな?

          Epic Games Store | PCゲーム、MOD、DLCなどをダウンロード&プレイ – Epic Games https://store.epicgames.com/ja/

          ...
          0 ★ 0 ↺

          [?]matoken » 🌐
          @matoken@snac.matoken.org

          今試すとOK

            matoken boosted

            [?]matoken » 🌐
            @matoken@matoken.org

            snacのWelcome pageのカスタマイズ

            さくらのナレッジに軽量ActivityPub Server のsnac についての記事を寄稿しました. さくらインターネットのさくらのナレッジにsnacの記事を寄稿 – matoken’s blog ここに書かなかったsnac のことをいくつか書いていこうと思います. 今日はsnac でのWelcome pageのカスタマイズについて. […] [SENSITIVE CONTENT]

            さくらのナレッジに軽量ActivityPub Server のsnac についての記事を寄稿しました.

            ここに書かなかったsnac のことをいくつか書いていこうと思います.
            今日はsnac でのWelcome pageのカスタマイズについて.

            snac のtop page は以下のような挨拶ページが表示されます.このページをカスタマイズしてみます.

            $ w3m -dump https://snac.kagolug.org/snac.kagolug.org is a Fediverse instance that uses the ActivityPub protocol. Inother words, users at this host can communicate with people that use softwarelike Mastodon, Pleroma, Friendica, etc. all around the world.This server runs the snac software and there is no automatic sign-up process.The following users are part of this community:    @info@snac.kagolug.org (info)    @matoken@snac.kagolug.org (matoken)This site is powered by snac.

            このページは greeting.html を読み込んでいるようです.

            greeting.html

            <!DOCTYPE html><html><head><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="icon" type="image/x-icon" href="https://%host%/favicon.ico"/><style>*{color-scheme:light dark}body{margin:auto;max-width:50em}</style><title>Welcome to %host%</title></head><body><p><b>%host%</b> is a <a href="https://en.wikipedia.org/wiki/Fediverse">Fediverse</a> instance that uses the <a href="https://en.wikipedia.org/wiki/ActivityPub">ActivityPub</a> protocol. In other words, users at this host can communicate with people that use software like Mastodon, Pleroma, Friendica, etc. all around the world.</p><p>This server runs the <a href="https://comam.es/what-is-snac">snac</a> software and there is no automatic sign-up process.</p><p>The following users are part of this community:</p>%userlist%<p>This site is powered by <abbr title="Social Networks Are Crap">snac</abbr>.</p></body></html>

            例えば日本語にしたり,ユーザーリストを隠したりといったカスタマイズが出来ます.このhtml ファイルを保存した時点で反映されます.

            $ w3m -dump https://snac.kagolug.org/snac.kagolug.orgはActivityPubプロトコルを利用したFediverseインスタンスです.このホストのユーザーは世界中のMastodon, Pleroma, Friendica, などのソフトウェアを利用している人々とコミニュケーションを取ることが出来ます.このサーバーはsnac ソフトウェアを利用しています.自動登録プロセスはありません.以下のユーザーがこのコミュニティに参加しています:    @info@snac.kagolug.org (info)    @matoken@snac.kagolug.org (matoken)This site is powered by snac.

            今回とりあえず日本語にしましたが,LUG の説明なども入れたいところです.

            0 ★ 0 ↺

            [?]matoken » 🌐
            @matoken@snac.matoken.org

            新しい方かな?
            新しい方は見てないので見たいところ……いまdisk full なので何か消さないとだな

            TRIGUN STAMPEDE | TVer https://tver.jp/series/srtq04wjf2

            0 ★ 0 ↺

            [?]matoken » 🌐
            @matoken@snac.matoken.org

            わかりやすい獣道

            土手にあった獣道

            Alt...土手にあった獣道

            0 ★ 0 ↺

            [?]matoken » 🌐
            @matoken@snac.matoken.org

            KartaView に写真Up したいけどアプリからは駄目
            てことでVPS 二一旦置いてからにするかと
            retry 繰り返すと進んでいくけども遅い……

            2025_11_21_15_55_15_326_+0900/Mapillary-11.21.15.55.15/2025_11_21_16_08_49_485_+0900.jpg
            712,854 100% 10.31kB/s 0:01:07 (xfr, to-chk=84/788)
            2025_11_21_15_55_15_326_+0900/Mapillary-11.21.15.55.15/2025_11_21_16_08_51_543_+0900.jpg
            687,780 100% 5.98kB/s 0:01:52 (xfr, to-chk=83/788)
            2025_11_21_15_55_15_326_+0900/Mapillary-11.21.15.55.15/2025_11_21_16_08_53_232_+0900.jpg
            868,834 100% 5.48kB/s 0:02:29 (xfr, to-chk=82/788)

              ...
              1 ★ 0 ↺

              [?]matoken » 🌐
              @matoken@snac.matoken.org

              プチプチ切れるね
              パスフレーズなし鍵交換してloop させる?
              rsync: [sender] write error: Broken pipe (32)

                matoken boosted

                [?]matoken » 🌐
                @matoken@matoken.org

                月の満ち欠けをTUIで表示するASCII Moon

                asciimoon.com という月の満ち欠けがasciiart で表現されたサイトがあります.ただしJavaScriptが無いと満ち欠けは分からずw3m などでは今ひとつな感じでした. ASCII Moon はそのsiteにインスパイアされた月の満ち欠けをTUI で表示するコマンドです. rockydd/ascii_moon: A TUI (Terminal User Interface) application written in Rust that displays the moon phase in ASCII art. […] [SENSITIVE CONTENT]

                asciimoon.com という月の満ち欠けがasciiart で表現されたサイトがあります.ただしJavaScriptが無いと満ち欠けは分からずw3m などでは今ひとつな感じでした.

                ASCII Moon はそのsiteにインスパイアされた月の満ち欠けをTUI で表示するコマンドです.

                ASCII Moon はReleases page にLinux/macOS/Windows のamd64 版のバイナリが置いてあります.
                Linux armhf ではどうだろうと今回はsource からbuild しました.

                $ git clone https://github.com/rockydd/ascii_moon.git$ cd ascii_moon$ cargo build --release$ ./target/release/ascii_moon$ ./target/release/ascii_moon --helpA TUI to show the moon phaseUsage: ascii_moon [OPTIONS]Options:  -d, --date <DATE>    Date in YYYY-MM-DD format (defaults to today)      --lines <LINES>  Render the moon to a specific number of lines (non-interactive)  -h, --help           Print help  -V, --version        Print version$ ./target/release/ascii_moon --versionascii_moon 0.2.0

                オプション無しでインタラクティブモード.
                -d, --date <日付(YYY-MM-DD)> で特定の日付で起動.
                --lines <行数> はscript やMOTD など向けで指定した行数で月のAsciiArt を出力します.
                -d, --date--lines は一緒に指定できます.

                インタラクティブモードではカーソル左右で1日単位で日付を操作できます.l key で地名のラベルのon/off,L key でラベルの言語変更,i key で下部の情報のon/off ができます.
                インタラクティブモードの動作の状態は以下のasciinema で確認できます.

                TUI でもこのAscii Moon, astroterm, tracker など面白い天文アプリが増えている感じがします.

                環境

                $ ./target/release/ascii_moon --versionascii_moon 0.2.0$ cargo versionwarning: `/home/matoken/.cargo/config` is deprecated in favor of `config.toml`  |  = help: if you need to support cargo 1.38 or earlier, you can symlink `config` to `config.toml`cargo 1.92.0 (344c4567c 2025-10-21)$ cargo build --release$ lsb_release -drNo LSB modules are available.Description:    Raspbian GNU/Linux 12 (bookworm)Release:        12$ archarmv7l$ cat /sys/firmware/devicetree/base/modelRaspberry Pi 3 Model B Rev 1.2

                Post by @matoken

                View on Mastodon

                0 ★ 0 ↺

                [?]matoken » 🌐
                @matoken@snac.matoken.org

                そろそろ新作きます
                楽しみ

                妖しいね☆わたしの弟ギョーメイくん なんかの絵3 / 丸尾ろこミ https://manga.nicovideo.jp/watch/mg987428

                  0 ★ 0 ↺

                  [?]matoken » 🌐
                  @matoken@snac.matoken.org

                  聖女破城槌!?

                  「念願の悪役令嬢(ラスボス)の身体を手に入れたぞ!/【第78話】灼熱の突貫!」マガポケ https://s.magazinepocket.com/ldg?t=2328&d=1&e=428458

                  0 ★ 0 ↺

                  [?]matoken » 🌐
                  @matoken@snac.matoken.org

                  運転中に蚊に噛まれる>

                  0 ★ 0 ↺

                  [?]matoken » 🌐
                  @matoken@snac.matoken.org

                  洗濯物の乾きが悪いので扇風機をonにして仕事へ

                  0 ★ 0 ↺

                  [?]matoken » 🌐
                  @matoken@snac.matoken.org

                  snacで投稿した以下のtoot がmastodon client のtoot で表示が変
                  toot 側のbug?
                  https://snac.matoken.org/matoken/p/1765446248.960004

                  snac表示

                  Alt...snac表示

                  toot表示

                  Alt...toot表示

                  mastodon表示

                  Alt...mastodon表示

                  0 ★ 0 ↺

                  [?]matoken » 🌐
                  @matoken@snac.matoken.org

                  予約済み
                  WordPress で更新できなかったときのための予約済み投稿を用意しているのだけど毎日これを後ろにずらすのがめんどくさいな

                  matoken boosted

                  [?]matoken » 🌐
                  @matoken@matoken.org

                  Debian 13 trixieでbackportsを使い最新のsnacを利用

                  さくらのナレッジに軽量ActivityPub Server のsnac についての記事を寄稿しました. さくらインターネットのさくらのナレッジにsnacの記事を寄稿 – matoken’s blog ここに書かなかったsnac のことをいくつか書いていこうと思います. 今日はDebian trixie backports のsnac パッケージを使うよう設定してみます. […] [SENSITIVE CONTENT]

                  さくらのナレッジに軽量ActivityPub Server のsnac についての記事を寄稿しました.

                  ここに書かなかったsnac のことをいくつか書いていこうと思います.
                  今日はDebian trixie backports のsnac パッケージを使うよう設定してみます.

                  Debian でのsnac2 パッケージのバージョン

                  snac2 はDebian パッケージになっています.しかし,stable のDebian 13 trixie のsnac2 パッケージのバージョンは 2.75-2 で少し古いバージョンです.
                  stable-backports のパッケージのバージョンは現在の上流の最新と同じ 2.85 なのでこれを利用してみます.

                  $ rmadison snac2| grep -v debugsnac2      | 2.75-2~bpo12+1 | oldstable-backports       | source, amd64, arm64, armel, armhf, i386, mips64el, mipsel, ppc64el, s390xsnac2      | 2.75-2         | stable                    | source, amd64, arm64, armel, armhf, i386, ppc64el, riscv64, s390xsnac2      | 2.84-3~bpo13+1 | stable-backports          | source, riscv64snac2      | 2.85-1~bpo13+1 | stable-backports          | source, amd64, arm64, armel, armhf, i386, ppc64el, s390xsnac2      | 2.85-1         | testing                   | source, amd64, arm64, armhf, i386, ppc64el, riscv64, s390xsnac2      | 2.85-1         | unstable                  | source, amd64, arm64, armhf, i386, ppc64el, riscv64, s390x

                  Debian 13 trixie に backports を設定

                  Debian backports はDebian stable で一部のtesting パッケージを利用できるよう調整されたもので対応したパッケージであればstable より新しいバージョンが利用できます.

                  これを利用するためにはbackports 情報を sources.list に追加する必要があります.
                  ここでは公式ドキュメントと同じ /etc/apt/sources.list.d/debian-backports.sources としてファイルを作成しました.

                  /etc/apt/sources.list.d/debian-backports.sources を作成

                  Types: deb deb-srcURIs: http://deb.debian.org/debianSuites: trixie-backportsComponents: mainEnabled: yesSigned-By: /usr/share/keyrings/debian-archive-keyring.gpg

                  続いてパッケージ情報をbackports を含む最新状態にします.

                  パッケージ情報更新

                  $ sudo apt update

                  backports の snac を導入

                  backpots のパッケージは通常のインストールでは導入されません.backports のパッケージを導入するにはパッケージ名に /trixie-backports を付けて導入します.

                  $ sudo apt install snac2/trixie-backports

                  もしくは -t trixie-backports を付けて導入すると不足した依存関係も導入されるようです.

                  $ sudo apt install -t trixie-backports snac2

                  $ dpkg-query -W snac2snac2   2.85-1~bpo13+1$ snac versionsnac 2.85 - A simple, minimalistic ActivityPub instanceCopyright (c) 2022 - 2025 grunfink et al. / MIT licenseupgrade {basedir}                    Upgrade to a new version

                  導入されたbackports パッケージは通常と同じ優先度100に固定されるので導入後はいつもの apt upgrade でbackports パッケージも更新されます.つまり通常の運用で大丈夫です.

                  snac アップグレード操作

                  snac のバージョンアップ時にディスク構成が変わることがあり,その場合snac が起動しないようです.その場合snac の upgrade コマンドを実行する必要があるようです.
                  自分は念の為毎回実行しています.

                  snac(8)より

                  Upgrading to a new version    Sometimes, the data storage disk layout changes between versions. If there is such a change, snac will refuse to run and require an upgrade. Do this by running

                  snac upgrade $HOME/snac-data

                  Take special care to execute this upgrade operation without any snac processes serving on the same folder. You can break everything. I know this because Tyler knows this.

                  $ snac | grep upgradeupgrade {basedir}                    Upgrade to a new version

                  upgrade コマンドはデーモンが起動していない状態で実行する必要があるので一旦snac を停止してから実行,その後snac を起動します.

                  $ sudo service snac2 stop (1)$ sudo -u debian-snac snac upgrade /var/lib/snac2/ (2)19:45:50 Linux sandbox not compiled in19:45:50 OK$ sudo service snac2 start (3)$ w3m -dump https://snac.kagolug.org/info | tail -1 (4)about this site - powered by snac/2.83

                  1. snac 停止

                  2. snac upgrade

                  3. snac 起動

                  4. バージョン確認

                  という感じでDebian stable でも最新のsnac が利用できています.一旦設定すると通常のDebian パッケージ更新操作で追従してくれるので運用もいつもと変わりません.更新タイミングも公式と見比べると結構すぐ対応してくれているようです.

                  0 ★ 0 ↺

                  [?]matoken » 🌐
                  @matoken@snac.matoken.org

                  小雨☂

                  0 ★ 0 ↺

                  [?]matoken » 🌐
                  @matoken@snac.matoken.org

                  2026-01-07のレグルス食は起こらない地域だった

                  レグルス食(2026年1月) | 国立天文台(NAOJ) https://share.google/9hUk60EGjW6u2M1Aa

                  0 ★ 0 ↺

                  [?]matoken » 🌐
                  @matoken@snac.matoken.org

                  サントリーの自販機決済アプリのジハンピ
                  今なら3本無料につられて入れたけど40km程北上しないと対象自販機が無さそうという感じで結局クーポンは先月失効
                  さっき確認したら行動圏内の20km程先にできていた
                  とりあえず一応徒歩圏内にあるcoke on 使いますね……

                  0 ★ 0 ↺

                  [?]matoken » 🌐
                  @matoken@snac.matoken.org

                  0 ★ 0 ↺

                  [?]matoken » 🌐
                  @matoken@snac.matoken.org

                  使うかわかんないけど「パケット放題 1Mbps」を追加した
                  以前1.5Mbps使ってたけどマンガなんかは辛かった
                  いつもmineoサービスをご利用いただき、誠にありがとうございます。

                  以下のオプションの変更が完了しましたので、お知らせいたします。

                  ≪お申し込み内容≫
                  ■オプション申し込み
                   ■追加
                   ・パケット放題 1Mbps

                  matoken boosted

                  [?]matoken » 🌐
                  @matoken@matoken.org

                  snac でカスタム絵文字を利用

                  さくらのナレッジに軽量ActivityPub Server のsnac についての記事を寄稿しました. さくらインターネットのさくらのナレッジにsnacの記事を寄稿 – matoken’s blog ここに書かなかったsnac のことをいくつか書いていこうと思います. 今日はカスタム絵文字について. […] [SENSITIVE CONTENT]

                  さくらのナレッジに軽量ActivityPub Server のsnac についての記事を寄稿しました.

                  ここに書かなかったsnac のことをいくつか書いていこうと思います.
                  今日はカスタム絵文字について.

                  ActivityPub 各インスタンスでよく使われているカスタム絵文字というものがあります.misskey.io なんかでは特に多用されているようです.
                  snac もカスタム絵文字に対応しています.

                  既定値で設定されているものとして例えばtoot 本文中に :-) と入力することで「🙂」が, :beer: と入力することで「🍺」が表示されます.他に :shrug2: で「¯\_(ツ)_/¯」なんでものも.でもこのあたりのUnicode絵文字などは日本語入力環境があるとあまり有り難みは感じなそうです.でも画像ファイルも利用できます.

                  自分で用意した絵文字を追加してみましょう.

                  カスタム絵文字を追加するにはsnac のデータディレクトリにある emojis.json を編集することでカスタマイズできます.

                  emojis.json の既定値はこんな感じです.
                  toot 本文中に記述するkey と,実際に評される値の組み合わせです.key は保管性を保つために : で囲むことが推奨されています.値は以下では数値文字参照及び文字列ですが,URL を指定することも出来ます.

                  {    ":-)": "&#128578;",    ":-D": "&#128512;",    "X-D": "&#128518;",    ";-)": "&#128521;",    "B-)": "&#128526;",    ">:-(": "&#128545;",    ":-(": "&#128542;",    ":-*": "&#128536;",    ":-/": "&#128533;",    "8-o": "&#128562;",    "%-)": "&#129322;",    ":_(": "&#128546;",    ":-|": "&#128528;",    "<3": "&#10084;&#65039;",    ":facepalm:": "&#129318;",    ":shrug:": "&#129335;",    ":shrug2:": "&#175;\\_(&#12484;)_/&#175;",    ":eyeroll:": "&#128580;",    ":beer:": "&#127866;",    ":beers:": "&#127867;",    ":munch:": "&#128561;",    ":thumb:": "&#128077;"}

                  ここにsnac デフォルトアイコンを追加してみます.snac のベースurl の下の /susie.png (kagolug では https://snac.kagolug.org/susie.png )にアクセスするとsnac デフォルトアイコンのsusie が表示されます.これを利用してみます.

                  emojis.json を以下のように書き換えます.

                       ":beer:": "&#127866;",     ":beers:": "&#127867;",     ":munch:": "&#128561;",-    ":thumb:": "&#128077;"+    ":thumb:": "&#128077;",+    ":susie:": "https://snac.kagolug.org/susie.png" }

                  Tip

                  emojis.json は保存した時点で内容が反映されます.中途半端な状態で保存すると全てのカスタム絵文字が利用できなくなったりするので注意しましょう.

                  これで :susie: と入力することで が表示されるようになります.

                  更にペンギンのTux とタスマニアデビルのTuz を追加してみます.
                  アイコンの画像ファイルを用意し,静的環境に設置,そのurl をemojis.json ファイルに記述します.
                  今回以下のようになりました.

                       ":beer:": "&#127866;",     ":beers:": "&#127867;",     ":munch:": "&#128561;",-    ":thumb:": "&#128077;"+    ":thumb:": "&#128077;",+    ":susie:": "https://snac.kagolug.org/susie.png",+    ":tux:": "https://www.kagolug.org/snac-emoji/Tux.png",+    ":tuz:": "https://www.kagolug.org/snac-emoji/Tuz.png" }

                  これで :susie:, :tux:, :tuz: の3つの絵文字が利用できるようになりました.
                  toot して確認できます.
                  もしくは以下のようなサイトでMastodon カスタム絵文字API経由で絵文字一覧を確認することも出来ます.

                  ]

                  snac のカスタム絵文字についての詳細はsnac(8) を参照してください.

                  Custom Emojis    From version 2.51, support for customized Emojis in posts is available (previously, they were hardcoded). Emojis are read from the emojis.json file in the instance base directory, as a JSON object of key / value pairs (if this file    does not exist, it will be created with the predefined set). Each key in the object contains the text to be found (e.g., the :-) for a smiling face), and its associated value, the text string that will replace it (in  this  example    case, the HTML entity for the Unicode codepoint for the smiley or the Emoji itself as text).

                  Emoji values can also be URLs to image files; in this case, they will not be substituted in the post content, but added to the 'tag' array as an ActivityPub standard 'Emoji' object (it's recommendable that the Emoji key be enclosedin colons for maximum compatibility with other ActivityPub implementations, like e.g. :happydoggo:). These images can be served from an external source or from the static directory of the instance admin.

                  If you want to disable any Emoji substitution, change the file to contain just an empty JSON object ({}).

                  matoken boosted

                  [?]info » 🌐
                  @info@snac.kagolug.org

                  さくらのナレッジでActivityPub サーバーのsnac についての記事が公開されました.
                  主にここのインスタンスを立ち上げたときの記録です.

                  さくらのVPSで試す、軽量ActivityPub実装「snac」によるセルフホストSNS構築 | さくらのナレッジ https://knowledge.sakura.ad.jp/48228/

                    3 ★ 3 ↺

                    [?]matoken » 🌐
                    @matoken@snac.matoken.org

                    DuckDuckGo で「Linux」と検索すると左上のアヒルがペンギンに🐧
                    https://www.tumblr.com/virologistandpotato/801981939975372800/not-sure-if-anyone-has-done-this-but-i-wanted-to?source=share
                    試してみると確かに.BSD検索してもデーモンくんは現れなかった
                    ペンギン直リンク

                    ...
                    matoken boosted

                    [?]m-ushi :vivaldi_blue: » 🌐
                    @mushi@social.vivaldi.net

                    @matoken@snac.matoken.org @matoken@inari.opencocon.org 横からすみません。FreeBSDと検索すればデーモンくんになりますね

                      ...
                      3 ★ 3 ↺

                      [?]matoken » 🌐
                      @matoken@snac.matoken.org

                      お,本当ですね👿

                      openbsdもありました🐡


                      CC: @matoken@inari.opencocon.org

                        0 ★ 0 ↺

                        [?]matoken » 🌐
                        @matoken@snac.matoken.org

                        ポタってこようと思ったらパンクしていたのでザクザクと少しウォーキング
                        スマートウォッチで4.1km
                        スマホgpsで3.5km
                        多分後者が正しい

                        道路に積もった枯れ葉

                        Alt...道路に積もった枯れ葉

                        History

                        Back to top - More...