[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Nextcloud 20 on F33 w/podman (Fedora Magazine)



On Tue, 2021-03-09 at 21:26 +0000, Andrew Bauer wrote:
Don't detach the container from the terminal when you run it the first time. You will then see the output from the container on the command line, which should hopefully provide useful information for troubleshooting.

Andy,

I have transcribed all of the steps in the Fedora Magazine article into a single bash shell script (below). Everything seems to run except for the last step, which is to connect to localhost:8080.  There Firefox refuses. Did they leave out a firewall check for port 8080?

Also, this appears to be a one-time script. It cannot be run two or more times without it complaining that the folder and database names already exist. Looking at the script, can you suggest where and how to restore the system to original so I can try running the script again after a change? I think I need to remove the network, volumes and containers created in the first pass of this script.

--Doc

---------

#!/bin/sh

sudo dnf install podman

# Creating a new network
podman network create nextcloud-net

# Listing all networks
podman letwork ls

# Inspecting a network
podman network inspect nextcloud-net

# Creating the volumes
podman volume create nextcloud-app
podman volume create nextcloud-data
podman volume create nextcloud-db

# Listing volumes
podman volume ls

# Inspecting volumes (this also provides the full path)
podman volume inspect nextcloud-app

# Deploy Mariadb
podman run --detach --env MYSQL_DATABASE=nextcloud --env MYSQL_USER=nextcloud --env MYSQL_PASSWORD=userpassword --env MYSQL_ROOT_PASSWORD=rootpassword --volume nextcloud-db:/var/lib/mysql --network nextcloud-net --restart on-failure --name nextcloud-db docker.io/library/mariadb:10

# Check running containers
podman container ls

# Deploy Nextcloud
podman run --env MYSQL_HOST=nextcloud-db.dns.podman --env MYSQL_DATABASE=nextcloud --env MYSQL_USER=nextcloud --env MYSQL_PASSWORD=DB_USER_PASSWORD --env NEXTCLOUD_ADMIN_USER=NC_ADMIN --env NEXTCLOUD_ADMIN_PASSWORD=NC_PASSWORD --volume nextcloud-app:/var/www/html --volume nextcloud-data:/var/www/html/data --network nextcloud-net --restart on-failure --name nextcloud --publish 8080:80 docker.io/library/nextcloud:20

# Check running containers
podman container ls

# end-of-file