TOP > ライフ > FS Technology道場 > ネタ

道場TOP ネタ一覧 FS Technology道場

How to install Mealie on Raspberry Pi

◇評価 0ポイント
◇閲覧回数 619
◇登録日
2023年12月6日

Check

前のネタへ

Mealie is an open-source, self-hosted recipe management application. Its aim is to assist users in effortlessly organizing, searching, and sharing recipes. The application provides a user-friendly interface that allows you to add, edit, and manage recipes, including information about cooking time, meal types, and more. In this tutorial, we'll guide you on how to install and run Mealie on your Raspberry Pi.

Step 1: Prepare the Environment for Mealie on Raspberry Pi

Before installing Mealie, we need to perform some actions on the Raspberry Pi.

The first step is to update the package lists and upgrade any outdated packages with the following two commands:

sudo apt update
sudo apt upgrade -y

Next, install Docker on the Raspberry Pi by following our provided guide. This guide sets up all the necessary components correctly for the subsequent steps to proceed smoothly.

Once Docker installation is complete, let's create a directory to store the Docker Compose file for Mealie.

Use the following command in the terminal to create this directory:

mkdir ~/meilie

After creating the new directory, switch to it using the cd command. The next few steps will assume that you are currently in this directory.

cd ~/meilie

Step 2: Configure Mealie Docker Compose File on Raspberry Pi

To install Mealie on Raspberry Pi, we need to create a Docker Compose file.

Use the following command to start editing this file. We have chosen the Nano text editor as it is one of the simplest editors to use in the command line.

nano docker-compose.yml

In the opened file, you need to input the following content. Note that you will need to make some changes in this file to fit your setup, but we will detail those changes in the next step.

yaml

version: "3.7"
services:
mealie:
image: ghcr.io/mealie-recipes/mealie:v1.0.0-RC1.1
container_name: mealie
ports:
- "9925:9000"
deploy:
resources:
limits:
memory: 1000M
depends_on:
- postgres
volumes:
- mealie-data:/app/data/
environment:
# Set Backend ENV Variables Here
- ALLOW_SIGNUP=true
- PUID=1000
- PGID=1000
- TZ=<YOURTIMEZONE>
- MAX_WORKERS=1
- WEB_CONCURRENCY=1
- BASE_URL=<BASEURL>

# Database Settings
- DB_ENGINE=postgres
- POSTGRES_USER=mealie
- POSTGRES_PASSWORD=<POSTGRESPASSWORD>
- POSTGRES_SERVER=postgres
- POSTGRES_PORT=5432
- POSTGRES_DB=mealie
restart: always
postgres:
container_name: postgres
image: postgres:15
restart: always
volumes:
- ./mealie-pgdata:/var/lib/postgresql/data
environment:
POSTGRES_PASSWORD: <POSTGRESPASSWORD>
POSTGRES_USER: mealie

volumes:
mealie-data:
driver: local
mealie-pgdata:
driver: local

In this Docker Compose file, you'll notice that we've left some placeholders. Here's a detailed explanation of the placeholders you need to replace:

<POSTGREPASSWORD> &ndash; This placeholder appears twice. Replace them with a secure password of your choice, it can be a completely random string. This password is used for the interaction between Mealie and the Postgres database server.

<BASEURL> &ndash; The base URL for accessing Mealie. Replace it with your domain or static IP address, for example, "http://192.168.0.1:9000".

<YOURTIMEZONE> &ndash; Replace this value with your timezone, using the tz database identifier, for example, "America/New_York".

After filling in all the details, press CTRL + X to save and exit, then press Y to confirm the save, and finally, press ENTER.

Step 3: Start Mealie with Docker

After writing the Docker Compose file, you can easily start Mealie on your Raspberry Pi.

When you are in the directory created earlier, launch Mealie by running the following command:

docker-compose up -d

The startup process might take a few minutes as Docker downloads Mealie from the repository to your Raspberry Pi and then launches it.

By using the -d option, we instruct Docker to detach Mealie from the current terminal session and continue running it in the background.

Step 4: Access the Mealie Web Interface

Now, you can easily access the Mealie web interface. If you are remotely connected to the Raspberry Pi, you need to know its IP address.

You can quickly retrieve the IP address of the Raspberry Pi using one of the following commands:

hostname -I

Once you have the IP address, open the following page in your preferred web browser.

Make sure to replace <IPADDRESS> with the IP address of your Raspberry Pi.

URL:

http://<IPADDRESS>:9925

Upon entering the page, you will see the login screen for Mealie.

Log into the web interface using the default credentials, which are the email "changeme@example.com" and the password "MyPassword." We will show you how to change these credentials later.

Refine the language for clarity and coherence. Translate the content into

Step 5: Change Your Username and Password

When using Mealie on your Raspberry Pi, the first task is to change the default username and password.

To initiate this process, click on the profile icon in the top left corner of the page, where the text "Change Me" is initially displayed.

Next, scroll down until you find the "Personal" section under the "User Settings" heading, then click the "Manage User Profile" link.

Now you're in the right place. Scroll down until you see the "Change Password" button and fields for changing your name, username, and email.

Start by clicking the "Change Password" button to input a new password for the Mealie administrator.

Enter the new password for the Mealie administrator in the pop-up dialog (1).

After filling in the new password, click the "Update" button to complete the change (2).

You can also modify the full name and email of the administrator account (1). Fill in these fields with the details you want for the account.

Once satisfied with the changes made, click the "Update" button (2).

With this, you have successfully installed and set up Mealie on your Raspberry Pi.

You can begin adding and creating recipes by clicking the "+" button in the sidebar.

More Raspberry Pi related projects:

Raspberry Pi Infant Monitoring System with Splunk

UTILISER UN RASPBERRY PI POUR CR&Eacute;ER UN MICROPHONE SANS FIL &Agrave; FR&Eacute;QUENCE RADIO

【このネタに対するあなたの評価は?】
☆☆☆☆☆ ☆☆☆ ☆
【キーワード】

ブログ? そんなの必要ありません! 今日から、いきなりアフィリエイトスタート!

【まにあ道アフィリエイト】まにあ道ならAmazonアソシエイトIDを利用してネタを書くだけで、お気軽に始めていただけます。

新着クイズ

もっと見る

新着掲示板

もっと見る