How do you add Extra Arguments in Portainer?

    • Offizieller Beitrag

    Portainer is wonderful when setting up containers, but I cannot figure out where to add extra arguments like when building a container for letsencrypt or nextcloud. I know it is probably right under my nose but I just cannot find it. Anyone?

    System Backup Typo alert: Under the Linux section the command should be sudo umount /dev/sda1 NOT sudo unmount /dev/sda1

    Backup Data Disk to Backup Disk on Same Machine: In a Scheduled Job:rsync -av --delete /srv/dev-disk-by-uuid-f8814ed9-9a5c-4e1c-8830-426968c20ea3/ /srv/dev-disk-by-uuid-e67439d5-00a3-4942-bd5f-b84ab86aa850/ Don't forget trailing slashes, and BE CAREFUL. (HT: Getting Started with OMV5)

    Equipment - Thinkserver TS140, NanoPi M4 (v.1), Odroid XU4 (Using DietPi): PiHole

    • Offizieller Beitrag

    Command and Logging -> Command, however, this is best guess can't see anywhere else to add it

    I'll give it a try.

    • Offizieller Beitrag

    Command and Logging -> Command, however, this is best guess can't see anywhere else to add it

    The container accepted it but it didn't work...I don't think. am trying to get Nextcloud/Letsencrypt up and running and i need the extra argument --network my-net to the Nextcloud container, and --cap-add=NET_ADMIN --network my-net in the Letsencrypt container. When I called for the certification an error returned without the cert. When I went back to examine the containers the extra arguments had single quotes around them. I may have done something else to receive the cert errors, but I don't think so. I will rebuild the Letsencrypt container again and try again.

    • Offizieller Beitrag

    --network my-net

    That is set up in the video using docker network create from the command line, with portainer you don't have to do that you should just add a network under Networks, then you select that in your container.


    --cap-add=NET_ADMIN this I'm not sure of, but wasn't there something on here that this was no longer required.

    • Offizieller Beitrag

    I just discovered that has also changed in omv4. You still have to add the network via command line, but it is added to the container via the "Networks" tab in Docker. I am actually trying to install Nextcloud/Letsencrypt on an omv4 setup as well as an omv5. Not having much success with either I'm afraid.

    • Offizieller Beitrag

    Can anybody make something of this from Letsencrypt:


    HTML
    - The following errors were reported by the server:                                                                                                                               
       Domain: xxxxx.duckdns.org                                                                                                                                                     
       Type:   unauthorized                                                                                                                                                            
       Detail: Invalid response from                                                                                                                                                   
       http://xxxxx.duckdns.org/.well-known/acme-challenge/t4z5LL0ZAe9mTZOUcbmKCrxuhpo_s6SUfA-R6WkNdgM                                                                               
       [xx.xxx.xxx.xxx]: "<!DOCTYPE                                                                                                                                                    
       html>\n<html>\n\t<head>\n\t\t<title>openmediavault - HTTP 404                                                                                                                   
       error</title>\n\t\t<meta charset=\"UTF-8\">\n\t\t<meta                                                                                                                          
       http-equiv=\"X-U"

    I x'd out my subdomain, and ip address.

    • Offizieller Beitrag

    --cap-add=NET_ADMIN this I'm not sure of, but wasn't there something on here that this was no longer required.

    From the docker hub:

    Zitat

    --cap-add=NET_ADMIN is required for fail2ban to modify iptables

    • Offizieller Beitrag

    I just discovered that has also changed in omv4.

    There is a guide for Nextcloud/Letsencrypt created by @macom this is where the use of docker compose will be necessary as the only way to add options like cap add is in a docker compose file. Searching for information regarding this it has been requested that an extra args/settings option is added to Portainer. This github appears to reference that, after reading that and looking at the Portainer GUI in the add container under capabilities there is an option NET_ADMIN which is disabled, could that be the answer.


    I've just had a look at Watchtower and their documentation the --cleanup option would be placed in the Command line using the Docker plugin, but looking at the document this has now changed and been added as an environment variable.

    You still have to add the network via command line, but it is added to the container via the "Networks" tab in Docker.

    You should be able to add/create a network in Portainer under the Networks option, but with the Docker plugin it doesn't work.
    ________________________________________________________________________________________________________


    As to the duckdns, the error is related either to the set up, or at time the site was down, the two pointers being, unauthorised and http 404 error.

    • Offizieller Beitrag

    at the Portainer GUI in the add container under capabilities there is an option NET_ADMIN which is disabled, could that be the answer.

    Seems so. In the Container I created with the docker-compose file the NET_ADMIN switch is enabled when looking in Portainer.

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!