From patchwork Tue Jun 9 16:40:29 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sandeep Gundlupet Raju X-Patchwork-Id: 89598 X-Patchwork-Delegate: ticotimo@gmail.com Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0535CCD8CB9 for ; Tue, 9 Jun 2026 16:40:35 +0000 (UTC) Received: from BL2PR02CU003.outbound.protection.outlook.com (BL2PR02CU003.outbound.protection.outlook.com [52.101.52.39]) by mx.groups.io with SMTP id smtpd.msgproc01-g2.40.1781023227462145729 for ; Tue, 09 Jun 2026 09:40:27 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="dkim: body hash did not verify" header.i=@amd.com header.s=selector1 header.b=TX4jVNkZ; spf=permerror, err=parse error for token &{10 18 %{i}._ip.%{h}._ehlo.%{d}._spf.vali.email}: invalid domain name (domain: amd.com, ip: 52.101.52.39, mailfrom: sandeep.gundlupet-raju@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=KQTWaN1v00cxfVUCr6PPKefJmuNZ2OQiLntnUyC2t5qUFOIx0Ux4eD0fvOPulnsnHE/+6QQsAsug/50U6mq0jSg2lpoPeSpK1D5b1CSPxQrfiK+rytYL3ZMyKg52yi3BBECQ5kCQ7a2QmrjB8TYdkm51obsF96II8J4MJgKjNGYii3a4pn/Dgp19XOqiCmsvvr0jcCkHKoUhNd0Mm7KSI26jbGMDUqG3hGLhUJjjRacdC/9NPSHOU5eRoI4XDPk4ZT0YSL7/oee9WPUTybhf7NaIU5wl7SaUPCdxga+TDUzooBdnQfGJPeuBTq9uqctU00gZ9jJEisRIJE/sZLJkXA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=qewx22CpLYAaxWxojY+46kZgDqrjcJ8Bh7jqwh8zk2E=; b=P7SYe4qb2Te3Zq+CRjXNaIlaDWlIPDXXCtdDNVfs20ILjWxQaDQpJnM2Iepu/htXkAWGxjUQVRyf7EoNREfHlEgRqOuooBzgxtmc+ZXCN+V8OQN5VIhbG6j8sTNi2HOTIfeffDEaUBMr6HoKd3YWe4kX9KT65pw7P2SVWZ0RAGOBSfz7ReIUo1nSKbwomRgzLwUpX6y9nkPeaqnp7tKyhZjjC7NnpuaVW/m8tTuxkWJ8I4eaXBEMe/Ob979EVFjuk3ZMmyHWhvZvZfHKGn6d7JyMTfbr5UlcYgNWLUFe405YFkl+S8F40GuHza1ZgCYL3ybJVAMBNwHK3HTVW8L5Sg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=lists.yoctoproject.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=qewx22CpLYAaxWxojY+46kZgDqrjcJ8Bh7jqwh8zk2E=; b=TX4jVNkZr1ho1OpB3PwjdubaCzqnJ2Cv6uGkCOcadGwR6xKj1KiT5TlvagtLJM4Qmu8rhvZdrSiMy1UAy7wsl2cF+4oLOtFNewX8CxV3O1y1MATh37BRES8Q48H3WTilT3ASUN2duMRzu+tX0vdo5xoW1SsgCiInVGQaWupDhOI= Received: from SJ0PR13CA0178.namprd13.prod.outlook.com (2603:10b6:a03:2c7::33) by PH7PR12MB7819.namprd12.prod.outlook.com (2603:10b6:510:27f::5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.92.12; Tue, 9 Jun 2026 16:40:21 +0000 Received: from BY1PEPF0001AE19.namprd04.prod.outlook.com (2603:10b6:a03:2c7:cafe::ac) by SJ0PR13CA0178.outlook.office365.com (2603:10b6:a03:2c7::33) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.21.113.9 via Frontend Transport; Tue, 9 Jun 2026 16:40:19 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=satlexmb08.amd.com; pr=C Received: from satlexmb08.amd.com (165.204.84.17) by BY1PEPF0001AE19.mail.protection.outlook.com (10.167.242.101) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.113.7 via Frontend Transport; Tue, 9 Jun 2026 16:40:19 +0000 Received: from satlexmb10.amd.com (10.181.42.219) by satlexmb08.amd.com (10.181.42.217) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.41; Tue, 9 Jun 2026 11:40:19 -0500 Received: from satlexmb08.amd.com (10.181.42.217) by satlexmb10.amd.com (10.181.42.219) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.41; Tue, 9 Jun 2026 11:40:19 -0500 Received: from xcosantraju40.xilinx.com (10.180.168.240) by satlexmb08.amd.com (10.181.42.217) with Microsoft SMTP Server id 15.2.2562.41 via Frontend Transport; Tue, 9 Jun 2026 11:40:18 -0500 From: Sandeep Gundlupet Raju To: , CC: , Subject: [yocto-patches] [layerindex-web][PATCH v3 1/4] layerindex: Add app dir support for configurable container Date: Tue, 9 Jun 2026 10:40:29 -0600 Message-ID: <20260609164032.1415124-2-sandeep.gundlupet-raju@amd.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260609164032.1415124-1-sandeep.gundlupet-raju@amd.com> References: <20260609164032.1415124-1-sandeep.gundlupet-raju@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BY1PEPF0001AE19:EE_|PH7PR12MB7819:EE_ X-MS-Office365-Filtering-Correlation-Id: 411cffe6-8217-4b0d-4835-08dec645cb26 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|1800799024|82310400026|36860700016|376014|18002099003|22082099003|3023799007|6133799003|11063799006|56012099006; X-Microsoft-Antispam-Message-Info: T7nCexYC17u+GqRZGW4GNljUy0j8qmWKSiq53x7AIHKwtbk4MIpqCk5uBqShyBoQnygLe+NFY97kyCX1dtDLLILjWJH2nCB40hP+Jg9kOviSuldQTyEFFlSkBFh9JX7XEGutSvZQvOeGvoOITeKcHiPMtLNbFqo8AScpPcFuj4RjAHdv2BnckG4JGJqGt/g1h/fdtAz5c0lXXmmjqIgwk6bvhFwJ6HYAwAUCKwGlY20vOzspb5EPSrB/Qr3FyNw2TR89Ol+aF4+zk/U6WR7MKP7arTvYjM16Bn8I0ddtrLSMDB6deCCcLw0CquT33aJGlKic9eR+2ixhRky7AoXIbDoxk+/Z2GMGu8vdVObiDMd9GEv3snUPReNvvHQwoVmmucL57mbOF5Q6ydMhqjmoKj+nis2v7wsfRUf8qe0THVR7CmPe0GoQy/iklIexwHl0L27uiLoAR/0daoPjmKEQlGseg9u8YAhTw3AAjJnDv3PTtLlYK7RR6F5dMJvpeicKTie8HEAItyA9930VWUWbjXEhHrD5DZU1/qMR4g5iEFxll5rqDfZ3JLOPaC6f5mgEx3mOde7q978TI2mv9V8g8dgXj6itemC5qAuj2xJdqqneShLIiKBfDW2dT/zekr77vYYelgZXhFXs3iakgxwnwE6AL1DWZiTn8nw6g/Njp5+1PsO7LOw/XBHbJVtbk4LCowUT+SBWhRFT9FCScDc0TVP/y/w3F/YOmxq25YLVSZI= X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:satlexmb08.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230040)(1800799024)(82310400026)(36860700016)(376014)(18002099003)(22082099003)(3023799007)(6133799003)(11063799006)(56012099006);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: FKNdFhXyyhHEsZE4wIopxcAwFW3Q1rnGXO1hkbnQMMyKjmUdp+9OMzgyFXFNOLLk62m5fPka3LHoi6pUYe1/2BG313couzTPcI7dtgshpww754R72Er4De7VkY/9oInK+MVUzEJH72bnjtEzW2c6gfCcRNlKFU4F7WC8ui10nhFwAu3xZED7sDWwKOy9AttOYetm0T4q3np6OVd56wQLWJ3BMAFMOkGRy688c8yQm3Uwer4+aj2c4z2g0J7f2/QXogG7zDEVcUPKugsKRjYAUwEmA7rYJK6nsemKWkj2iXvupI00igCyTypCjtQ7e50HGBhSNy7UcjDnJ35l4FBlWwweRvKA08P0eokGxCrSBQxDIRbJSwDULtzzol/tPrrNdYBPs+PWYPottbfQN/oEKtoIWHFG03Q1TlsUJH21o7+Aae4AV6qK2nDYPx0jFg+4 X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2026 16:40:19.5422 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 411cffe6-8217-4b0d-4835-08dec645cb26 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[satlexmb08.amd.com] X-MS-Exchange-CrossTenant-AuthSource: BY1PEPF0001AE19.namprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH7PR12MB7819 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Tue, 09 Jun 2026 16:40:35 -0000 X-Groupsio-URL: https://lists.yoctoproject.org/g/yocto-patches/message/4189 Add a new --app-dir command-line argument (default: /opt) to allow the base directory used inside the containers to be configurable instead of being hardcoded to /opt. Changes: - dockersetup.py: add --app-dir argument; write APP_DIR to .env file via new write_env_file() so docker-compose passes it as a build arg; update edit_dockercompose() to expand build: block and inject APP_DIR build arg reference, and rewrite volume mounts and celery --workdir accordingly; propagate app_dir through setup_https(), check_connectivity(), and all direct docker-compose run call sites - Dockerfile: add ARG APP_DIR=/opt + ENV APP_DIR=${APP_DIR}; replace all hardcoded /opt paths with ${APP_DIR} in COPY, RUN and CMD instructions - docker/migrate.sh: replace /opt with ${APP_DIR:-/opt} - docker/refreshlayers.sh: replace /opt with ${APP_DIR:-/opt} - docker/updatelayers.sh: replace /opt with ${APP_DIR:-/opt} - Pass app_dir to edit_settings_py() and replace the hardcoded LAYER_FETCH_DIR = "/opt/workdir" with app_dir + "/workdir", so the fetch directory respects the --app-dir option. AI-Generated: GitHub Copilot (Claude Sonnet 4.6) Signed-off-by: Sandeep Gundlupet Raju --- Dockerfile | 24 ++++++------ docker/migrate.sh | 2 +- docker/refreshlayers.sh | 2 +- docker/updatelayers.sh | 2 +- dockersetup.py | 86 +++++++++++++++++++++++++++++++++-------- 5 files changed, 85 insertions(+), 31 deletions(-) diff --git a/Dockerfile b/Dockerfile index 72f57d2..8e6e508 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,6 +3,8 @@ FROM ubuntu:jammy LABEL maintainer="Michael Halstead " +ARG APP_DIR=/opt +ENV APP_DIR=${APP_DIR} ENV PYTHONUNBUFFERED=1 \ LANGUAGE=en_US \ LANG=en_US.UTF-8 \ @@ -55,22 +57,22 @@ RUN DEBIAN_FRONTEND=noninteractive apt-get update \ && rm -rf /var/lib/apt/lists/* \ && apt-get clean -COPY . /opt/layerindex -RUN rm -rf /opt/layerindex/docker -COPY docker/settings.py /opt/layerindex/settings.py -COPY docker/refreshlayers.sh /opt/refreshlayers.sh -COPY docker/updatelayers.sh /opt/updatelayers.sh -COPY docker/migrate.sh /opt/migrate.sh -COPY docker/connectivity_check.sh /opt/connectivity_check.sh +COPY . ${APP_DIR}/layerindex +RUN rm -rf ${APP_DIR}/layerindex/docker +COPY docker/settings.py ${APP_DIR}/layerindex/settings.py +COPY docker/refreshlayers.sh ${APP_DIR}/refreshlayers.sh +COPY docker/updatelayers.sh ${APP_DIR}/updatelayers.sh +COPY docker/migrate.sh ${APP_DIR}/migrate.sh +COPY docker/connectivity_check.sh ${APP_DIR}/connectivity_check.sh -RUN mkdir /opt/workdir \ +RUN mkdir ${APP_DIR}/workdir \ && adduser --system --uid=500 layers \ - && chown -R layers /opt/workdir + && chown -R layers ${APP_DIR}/workdir USER layers # Always copy in .gitconfig and proxy helper script (they need editing to be active) COPY docker/.gitconfig /home/layers/.gitconfig -COPY docker/git-proxy /opt/bin/git-proxy +COPY docker/git-proxy ${APP_DIR}/bin/git-proxy # Start Gunicorn -CMD ["/usr/local/bin/gunicorn", "wsgi:application", "--workers=4", "--bind=:5000", "--timeout=60", "--log-level=debug", "--chdir=/opt/layerindex"] +CMD ["/bin/sh", "-c", "/usr/local/bin/gunicorn wsgi:application --workers=4 --bind=:5000 --timeout=60 --log-level=debug --chdir=${APP_DIR}/layerindex"] diff --git a/docker/migrate.sh b/docker/migrate.sh index ca15368..bb9f646 100755 --- a/docker/migrate.sh +++ b/docker/migrate.sh @@ -1,2 +1,2 @@ #!/bin/bash -python3 /opt/layerindex/manage.py migrate "$@" +python3 ${APP_DIR:-/opt}/layerindex/manage.py migrate "$@" diff --git a/docker/refreshlayers.sh b/docker/refreshlayers.sh index 0c550bd..5adaf86 100755 --- a/docker/refreshlayers.sh +++ b/docker/refreshlayers.sh @@ -1,3 +1,3 @@ #!/bin/bash -update=/opt/layerindex/layerindex/update.py +update=${APP_DIR:-/opt}/layerindex/layerindex/update.py $update -q -r diff --git a/docker/updatelayers.sh b/docker/updatelayers.sh index 21640ba..6f0e8f0 100755 --- a/docker/updatelayers.sh +++ b/docker/updatelayers.sh @@ -1,3 +1,3 @@ #!/bin/bash -update=/opt/layerindex/layerindex/update.py +update=${APP_DIR:-/opt}/layerindex/layerindex/update.py $update -q diff --git a/dockersetup.py b/dockersetup.py index bc7478c..3a74eb3 100755 --- a/dockersetup.py +++ b/dockersetup.py @@ -70,6 +70,7 @@ def get_args(): parser.add_argument('--no-migrate', action="store_true", default=False, help='Skip running database migrations') parser.add_argument('--no-admin-user', action="store_true", default=False, help='Skip adding admin user') parser.add_argument('--no-connectivity', action="store_true", default=False, help='Skip checking external network connectivity') + parser.add_argument('--app-dir', type=str, help='Base directory inside the container for application files. Default is %(default)s', required=False, default='/opt') args = parser.parse_args() @@ -253,14 +254,16 @@ def yaml_comment(line): # Add hostname, secret key, db info, and email host in docker-compose.yml -def edit_dockercompose(hostname, dbpassword, dbapassword, secretkey, rmqpassword, portmapping, letsencrypt, email_host, email_port, email_user, email_password, email_ssl, email_tls): +def edit_dockercompose(hostname, dbpassword, dbapassword, secretkey, rmqpassword, portmapping, letsencrypt, email_host, email_port, email_user, email_password, email_ssl, email_tls, app_dir='/opt'): + + in_layersapp_build = False def adjust_cert_mount_line(ln): linesplit = ln.split(':') if letsencrypt: linesplit[1] = '/etc/letsencrypt' else: - linesplit[1] = '/opt/cert' + linesplit[1] = app_dir + '/cert' # This allows us to handle if there is a ":ro" or similar on the end return ':'.join(linesplit) @@ -305,6 +308,33 @@ def edit_dockercompose(hostname, dbpassword, dbapassword, secretkey, rmqpassword newlines.append(ucline + '\n') else: newlines.append(yaml_comment(line) + '\n') + elif re.match(r'^\s+build:\s+\.$', line): + # Convert inline 'build: .' to block form so we can pass APP_DIR as a build arg + indent = line[:len(line) - len(line.lstrip())] + newlines.append(indent + 'build:\n') + newlines.append(indent + ' context: .\n') + newlines.append(indent + ' args:\n') + newlines.append(indent + ' - APP_DIR=${APP_DIR}\n') + in_layersapp_build = True + continue + elif '- APP_DIR=' in line: + # Keep APP_DIR referencing the .env file (do not embed value here) + format = line[:line.find('- APP_DIR=')].replace('#', '') + newlines.append(format + '- APP_DIR=${APP_DIR}\n') + continue + elif re.match(r'^\s+context:\s+\.$', line) and in_layersapp_build: + in_layersapp_build = False + newlines.append(line + '\n') + continue + elif ':/opt/workdir' in line: + newlines.append(line.replace(':/opt/workdir', ':' + app_dir + '/workdir') + '\n') + continue + elif ':/opt/layerindex-task-logs' in line: + newlines.append(line.replace(':/opt/layerindex-task-logs', ':' + app_dir + '/layerindex-task-logs') + '\n') + continue + elif '--workdir=/opt/layerindex' in line: + newlines.append(line.replace('--workdir=/opt/layerindex', '--workdir=' + app_dir + '/layerindex') + '\n') + continue elif "layersweb:" in line: in_layersweb = True newlines.append(line + "\n") @@ -426,7 +456,7 @@ def edit_nginx_ssl_conf(hostname, https_port, certdir, certfile, keyfile): writefile("docker/nginx-ssl-edited.conf", ''.join(newlines)) -def edit_settings_py(emailaddr): +def edit_settings_py(emailaddr, app_dir='/opt'): filedata = readfile('docker/settings.py') newlines = [] lines = filedata.splitlines() @@ -444,6 +474,9 @@ def edit_settings_py(emailaddr): newlines.append(" ('Admin', '%s'),\n" % emailaddr) newlines.append(")\n") continue + elif line.lstrip().startswith('LAYER_FETCH_DIR'): + newlines.append("LAYER_FETCH_DIR = \"%s/workdir\"\n" % app_dir) + continue newlines.append(line + "\n") writefile("docker/settings.py", ''.join(newlines)) @@ -474,9 +507,9 @@ def edit_dockerfile_web(hostname, no_https): writefile("Dockerfile.web", ''.join(newlines)) -def setup_https(hostname, http_port, https_port, letsencrypt, letsencrypt_production, cert, cert_key, emailaddr): +def setup_https(hostname, http_port, https_port, letsencrypt, letsencrypt_production, cert, cert_key, emailaddr, app_dir='/opt'): local_cert_dir = os.path.abspath('docker/certs') - container_cert_dir = '/opt/cert' + container_cert_dir = app_dir + '/cert' if letsencrypt: # Create dummy cert container_cert_dir = '/etc/letsencrypt' @@ -578,8 +611,26 @@ def edit_options_file(project_name): f.write('project_name=%s\n' % project_name) -def check_connectivity(): - return_code = subprocess.call(['docker-compose', 'run', '--rm', 'layersapp', '/opt/connectivity_check.sh'], shell=False) +def write_env_file(app_dir): + """Write APP_DIR to .env so docker-compose passes it as a build arg.""" + env_vars = {} + try: + with open('.env', 'r') as f: + for line in f: + line = line.strip() + if '=' in line and not line.startswith('#'): + k, v = line.split('=', 1) + env_vars[k.strip()] = v.strip() + except FileNotFoundError: + pass + env_vars['APP_DIR'] = app_dir + with open('.env', 'w') as f: + for k, v in env_vars.items(): + f.write('%s=%s\n' % (k, v)) + + +def check_connectivity(app_dir='/opt'): + return_code = subprocess.call(['docker-compose', 'run', '--rm', 'layersapp', app_dir + '/connectivity_check.sh'], shell=False) if return_code != 0: print("Connectivity check failed - if you are behind a proxy, please check that you have correctly specified the proxy settings on the command line (see --help for details)") sys.exit(1) @@ -741,24 +792,25 @@ if args.uninstall: if args.update: args.no_https = read_dockerfile_web() if not args.no_https: - container_cert_dir = '/opt/cert' + container_cert_dir = args.app_dir + '/cert' args.hostname, https_port, certdir, certfile, keyfile = read_nginx_ssl_conf(container_cert_dir) edit_nginx_ssl_conf(args.hostname, https_port, certdir, certfile, keyfile) else: # Always edit these in case we switch from proxy to no proxy edit_gitproxy(socks_proxy_host, socks_proxy_port, args.no_proxy) edit_dockerfile(args.http_proxy, args.https_proxy, args.no_proxy) + write_env_file(args.app_dir) - edit_dockercompose(args.hostname, dbpassword, dbapassword, secretkey, rmqpassword, args.portmapping, args.letsencrypt, email_host, email_port, args.email_user, args.email_password, args.email_ssl, args.email_tls) + edit_dockercompose(args.hostname, dbpassword, dbapassword, secretkey, rmqpassword, args.portmapping, args.letsencrypt, email_host, email_port, args.email_user, args.email_password, args.email_ssl, args.email_tls, args.app_dir) edit_dockerfile_web(args.hostname, args.no_https) - edit_settings_py(emailaddr) + edit_settings_py(emailaddr, args.app_dir) edit_options_file(args.project_name) if not args.no_https: - setup_https(args.hostname, http_port, https_port, args.letsencrypt, args.letsencrypt_production, args.cert, args.cert_key, emailaddr) + setup_https(args.hostname, http_port, https_port, args.letsencrypt, args.letsencrypt_production, args.cert, args.cert_key, emailaddr, args.app_dir) ## Start up containers return_code = subprocess.call(['docker-compose', 'up', '-d', '--build'], shell=False) @@ -768,7 +820,7 @@ if return_code != 0: if not (args.update or args.no_connectivity): ## Run connectivity check - check_connectivity() + check_connectivity(args.app_dir) # Get real project name (if only there were a reasonable way to do this... ugh) real_project_name = '' @@ -830,7 +882,7 @@ if not args.no_migrate: env = os.environ.copy() env['DATABASE_USER'] = 'root' env['DATABASE_PASSWORD'] = dbapassword - return_code = subprocess.call(['docker-compose', 'run', '--rm', '-e', 'DATABASE_USER', '-e', 'DATABASE_PASSWORD', 'layersapp', '/opt/migrate.sh'], shell=False, env=env) + return_code = subprocess.call(['docker-compose', 'run', '--rm', '-e', 'DATABASE_USER', '-e', 'DATABASE_PASSWORD', 'layersapp', args.app_dir + '/migrate.sh'], shell=False, env=env) if return_code != 0: print("Applying migrations failed") sys.exit(1) @@ -864,13 +916,13 @@ if not args.update: break for volume in volumes: volname = '%s_%s' % (real_project_name, volume) - return_code = subprocess.call(['docker', 'run', '--rm', '-v', '%s:/opt/mount' % volname, 'debian:stretch', 'chown', '500', '/opt/mount'], shell=False) + return_code = subprocess.call(['docker', 'run', '--rm', '-v', '%s:%s/mount' % (volname, args.app_dir), 'debian:stretch', 'chown', '500', args.app_dir + '/mount'], shell=False) if return_code != 0: print("Setting volume permissions for volume %s failed" % volume) sys.exit(1) ## Generate static assets. Run this command again to regenerate at any time (when static assets in the code are updated) -return_code = subprocess.call("docker-compose run --rm -e STATIC_ROOT=/usr/share/nginx/html -v %s_layersstatic:/usr/share/nginx/html layersapp /opt/layerindex/manage.py collectstatic --noinput" % quote(real_project_name), shell = True) +return_code = subprocess.call("docker-compose run --rm -e STATIC_ROOT=/usr/share/nginx/html -v %s_layersstatic:/usr/share/nginx/html layersapp %s/layerindex/manage.py collectstatic --noinput" % (quote(real_project_name), args.app_dir), shell = True) if return_code != 0: print("Collecting static files failed") sys.exit(1) @@ -891,12 +943,12 @@ else: if not args.update: if not args.databasefile: ## Set site name - return_code = subprocess.call(['docker-compose', 'run', '--rm', 'layersapp', '/opt/layerindex/layerindex/tools/site_name.py', host, 'OpenEmbedded Layer Index'], shell=False) + return_code = subprocess.call(['docker-compose', 'run', '--rm', 'layersapp', args.app_dir + '/layerindex/layerindex/tools/site_name.py', host, 'OpenEmbedded Layer Index'], shell=False) if not args.no_admin_user: ## For a fresh database, create an admin account print("Creating database superuser. Input user name and password when prompted.") - return_code = subprocess.call(['docker-compose', 'run', '--rm', 'layersapp', '/opt/layerindex/manage.py', 'createsuperuser', '--email', emailaddr], shell=False) + return_code = subprocess.call(['docker-compose', 'run', '--rm', 'layersapp', args.app_dir + '/layerindex/manage.py', 'createsuperuser', '--email', emailaddr], shell=False) if return_code != 0: print("Creating superuser failed") sys.exit(1) From patchwork Tue Jun 9 16:40:30 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sandeep Gundlupet Raju X-Patchwork-Id: 89596 X-Patchwork-Delegate: ticotimo@gmail.com Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1147DCD8CB2 for ; Tue, 9 Jun 2026 16:40:25 +0000 (UTC) Received: from PH7PR06CU001.outbound.protection.outlook.com (PH7PR06CU001.outbound.protection.outlook.com [52.101.201.3]) by mx.groups.io with SMTP id smtpd.msgproc01-g2.38.1781023223424940523 for ; Tue, 09 Jun 2026 09:40:23 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="dkim: body hash did not verify" header.i=@amd.com header.s=selector1 header.b=UzuzOMr5; spf=permerror, err=parse error for token &{10 18 %{i}._ip.%{h}._ehlo.%{d}._spf.vali.email}: invalid domain name (domain: amd.com, ip: 52.101.201.3, mailfrom: sandeep.gundlupet-raju@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=hGGeoOqSBTKHTQb9izVfHnvL/qMxxDOcGSWdvVm+d5SGzx/kQk58/IV/KWZ9ncsgLkZubFIJU2DjiwTNHqlXjZm7NOZEk9IxDOP2ABADnHV3CWJ29rj0zC0GRNCsQpqzNr/ReL49PL46AtvtobWi92i+sPhiSUzKSEfSfwiUlMaFrt3iAdc0nLT4qFfZ1b8PW1Q9AgN0YbiRLyf3O7BZyIMXRJkTRYnfI253rxxSqVNk2TiNK6E6jUz8s04SZnhv1cEaOZpnDkhjSyldssYlidRX02wlv2UAf6vqprnKR2/tj7nW6t3NOu9kT0ao2szh/jEO8p/Pn/kuuEfebvdLcg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=tgj//8poQzg+Mmj4LhL9s4hoS2qf+CedcRw5qSs83jc=; b=VWhkcwVLT3Mg4zpA1Cv9RCi7aWJGKv5Bxn65gSgFMi6nXh8g0hVOICVOmd3209jpJLHgxUFc3PceYxFfNLHY2oPlI60GV31V2fJixkEPxZf8r/ilsuwM+vCQPSq7l4Jw0vA4+HvB2OL9ewVBK1dfQ7E5gvbTwRJqmLL3kPYLhP4h5I4fccUHP6t7+ZnnrtpHJ9S5Y+/0WJA7AqTmj1QsMYAJiAnCGDKI5/Q+8FfMAGK1R+B+KiyVRc5aRCXuhnys7FM+9sS7yXAiqzxUuiajdLjv0XCYQey65T0NfJxE9+Go9nbQ3lBkI9+Sh4hUMEmCQSIIcgrPgtkJx8FS0KBPEA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=lists.yoctoproject.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=tgj//8poQzg+Mmj4LhL9s4hoS2qf+CedcRw5qSs83jc=; b=UzuzOMr5l39MGjx2vU0u9pFfvZjNYRqrh4s9BDG64EqR06uqKYmJh1Em1yDG4EPNDwnQGCO8hA3T+0Z3Kogm1nxPEMJJEU7G5zOIcukzINcPqH3QsQi2iB+YWQuZCze6Tn7ka73drI9fErBEyWX8EP0VsDfyuhEPwXRLC8lKzTw= Received: from SJ0PR03CA0282.namprd03.prod.outlook.com (2603:10b6:a03:39e::17) by PH7PR12MB5901.namprd12.prod.outlook.com (2603:10b6:510:1d5::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.92.13; Tue, 9 Jun 2026 16:40:20 +0000 Received: from BY1PEPF0001AE1D.namprd04.prod.outlook.com (2603:10b6:a03:39e:cafe::49) by SJ0PR03CA0282.outlook.office365.com (2603:10b6:a03:39e::17) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.21.113.10 via Frontend Transport; Tue, 9 Jun 2026 16:40:20 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=satlexmb08.amd.com; pr=C Received: from satlexmb08.amd.com (165.204.84.17) by BY1PEPF0001AE1D.mail.protection.outlook.com (10.167.242.106) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.113.7 via Frontend Transport; Tue, 9 Jun 2026 16:40:19 +0000 Received: from satlexmb10.amd.com (10.181.42.219) by satlexmb08.amd.com (10.181.42.217) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.41; Tue, 9 Jun 2026 11:40:19 -0500 Received: from satlexmb08.amd.com (10.181.42.217) by satlexmb10.amd.com (10.181.42.219) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.41; Tue, 9 Jun 2026 11:40:19 -0500 Received: from xcosantraju40.xilinx.com (10.180.168.240) by satlexmb08.amd.com (10.181.42.217) with Microsoft SMTP Server id 15.2.2562.41 via Frontend Transport; Tue, 9 Jun 2026 11:40:19 -0500 From: Sandeep Gundlupet Raju To: , CC: , Subject: [yocto-patches] [layerindex-web][PATCH v3 2/4] connectivity_check.sh: Use yoctoproject.org for HTTPS check Date: Tue, 9 Jun 2026 10:40:30 -0600 Message-ID: <20260609164032.1415124-3-sandeep.gundlupet-raju@amd.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260609164032.1415124-1-sandeep.gundlupet-raju@amd.com> References: <20260609164032.1415124-1-sandeep.gundlupet-raju@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BY1PEPF0001AE1D:EE_|PH7PR12MB5901:EE_ X-MS-Office365-Filtering-Correlation-Id: 46b9f139-7514-4c70-a8a9-08dec645cb4f X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|1800799024|82310400026|376014|36860700016|22082099003|18002099003|11063799006|56012099006; X-Microsoft-Antispam-Message-Info: qntZz7oyYlj4cR9PtRCUI4sBLgttonCsek+mu8h5goQbSMHmoWRirQqp4GSAqpYS+1Cj6uzG2WFj6jw47OJOMBx59wS0zrMjJ0NBj3P6dTaIXXd9vHoVeLR9DxspFwCSHR4ZOAOU4Ae30hLENwKkltPp4b6dEGaXuQyB6UvaOoMhmyvzkMn/E80j++oggIyANN1vI7IFt04+VoXcgFGrYl2DUTqVKIAs4Tfi6bwNSt7Hp0A3EzYEQeoj3du2O/g+mEYEeJAGixLCUGneV69GMluRfRhLDsOpm9mqPZyjSaJzSU7VDl7JTNmIS6AiMUcWGDXnYkbtkqcjPfrW7bIPbo/SB20LPjfKCpHrv543eooe1oyU2IGZYmAh+uilX3w6zxKiq6tLHF+JAJgBjDX1Qvo4aVgRj2LS9sp5LwTPF8DRZyTZuKBiBL+KQs1pt5ANfz6YyXZ6Y/uDK39T/ThqKVZMVnsEjoFMGQPkqIuNOPyisCMmqCW+J3Ab9Uvlj90meI0Df5EEytVaq7/79j1ZqWgxgYBVU4/xrd673Wy3e80jHOlMWKpMnET3zkQgqFLyI3D3PELANycdJ+O6V9Tvt8GlW/VET92DIjs2nDbIC1e/OHuYzb9Cxyf44zzx1Whw36GPLZSQZyAPOV8bEf0+7jIK/sV4fpW6lynUNl5S744= X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:satlexmb08.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230040)(1800799024)(82310400026)(376014)(36860700016)(22082099003)(18002099003)(11063799006)(56012099006);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: maZHND0fQpfV/2oZTVDNdsYvnTAaGT6PjnG9Lwhfgbd3DkcGmJLxa7nxdwc3bZgMn5HYB/MzF9I2EbRnCxH8BBryvHMXboWUalOGT5IWVRvTLT3ckIqwYkIJBgSWTgkWrQ5Om6xNtirlN4gVrLFMPydWrID03BqitR/BnTWczleRROoZMkLsN/v1haugO6muK56TrM0CP4hPh4lUyraAYUg7QOetJLplMD9hyY0yDSTODlse/M9OYLKcubMfeEDT+Wc8VEI2qOEhMCNTicGSuRYIuBuPwPxy6dSiH55wX2IrXoCANj85TXakHupPzMbQFDPPWGry9C99AiyGAXvu/VSDdPrvnw+BDC0Ol6QaCr+ofUm5laEF6TdfjPgkH2qLig6YTnaPSxwIoiOJINOfUEl5nb+uMzn0wHb2SP4ZMWk6iNElUxfCxnZQPfQWRT4O X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2026 16:40:19.8536 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 46b9f139-7514-4c70-a8a9-08dec645cb4f X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[satlexmb08.amd.com] X-MS-Exchange-CrossTenant-AuthSource: BY1PEPF0001AE1D.namprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH7PR12MB5901 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Tue, 09 Jun 2026 16:40:25 -0000 X-Groupsio-URL: https://lists.yoctoproject.org/g/yocto-patches/message/4187 Replace google.com with yoctoproject.org as the HTTPS test URL. google.com may be blocked or considered unsafe on some Linux host environments, while yoctoproject.org is a more appropriate and reliable choice for a Yocto/OE layer index deployment. AI-Generated: GitHub Copilot (Claude Sonnet 4.6) Signed-off-by: Sandeep Gundlupet Raju --- docker/connectivity_check.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/connectivity_check.sh b/docker/connectivity_check.sh index 2e46ce4..630d0dc 100755 --- a/docker/connectivity_check.sh +++ b/docker/connectivity_check.sh @@ -18,7 +18,7 @@ if ! wget -q $HTTP_TEST_URL ; then exit 1 fi -HTTPS_TEST_URL="https://google.com" +HTTPS_TEST_URL="https://yoctoproject.org" if ! wget -q $HTTPS_TEST_URL ; then echo "ERROR: failed to fetch $HTTPS_TEST_URL" cleanup_tmp From patchwork Tue Jun 9 16:40:31 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sandeep Gundlupet Raju X-Patchwork-Id: 89595 X-Patchwork-Delegate: ticotimo@gmail.com Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id DB1BDCD98C8 for ; Tue, 9 Jun 2026 16:40:24 +0000 (UTC) Received: from SN4PR0501CU005.outbound.protection.outlook.com (SN4PR0501CU005.outbound.protection.outlook.com [40.93.194.23]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.50.1781023223872731779 for ; Tue, 09 Jun 2026 09:40:24 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="dkim: body hash did not verify" header.i=@amd.com header.s=selector1 header.b=5lR7GTmZ; spf=permerror, err=parse error for token &{10 18 %{i}._ip.%{h}._ehlo.%{d}._spf.vali.email}: invalid domain name (domain: amd.com, ip: 40.93.194.23, mailfrom: sandeep.gundlupet-raju@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=KJEGzVWvk9SEz8+X8iiw8ckJeaXJXQgX621fQk36IfoPKt/zgVakUMCgjT4NOylylqc/m5uy+4lv1TCl2pI8WiY9NsHA2zJUX9o+k/vMgDZlu6UAfmek4DSJxqjt9sgnYcVxO2DaUZkhxFoQBLFBzT8mKhK3N2P7nRAJyFhikJ68YiQb1MRT724o+c/yEQugXECAz3E5lLaZsVHqWz8xqc0wQqft0GhicGelV9xnPE/RlK6LE1UJzPX1rVqnkr6D419sXvUlBPhfqnA8P11WGDfVLMpcyKW8E8wwu56Pz3jBKxqiHGIGY/cTXonJ1CVzu/9jduia2RF76MPNUlvGgg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=GFw0FQscymf7MOR2UdasgOgSvcyMXv06v6zH6ZSyrxs=; b=F6rKm39A5KnPISUh8oVqM2+0NqrCyPsvXwjZS7HtBVfebZbOmly9FDtvbXMH81B+PoR7iM2/3HqWf5PqmHGlac0wEQ7g/M+JcpwktAqif2WzedcYYVv6+5Bo7RW8HjoVVDJxtQk02VxKpx4D9QkeVek0SEww9Udmp7tbJXzShgoXoFt3drQ+bJpIUupF8mc0yRRkPeAM+B2tuyOOFB3eF23atH0dWVzdN9RLW4W9mM0HTgG94fE0j2+pKEC2XYeJ+/4C0hSr7rXOplBlFByMcfxx/1UqfxaEBTULC6gel2Cjy+Y413wC2nB/FuwO7ZA6t8DNMvlcfbMnKiG2U/LSQA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=lists.yoctoproject.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=GFw0FQscymf7MOR2UdasgOgSvcyMXv06v6zH6ZSyrxs=; b=5lR7GTmZ1ViS9WKZtI7R0HnwSy8uJ/5BToJB4bekTzRdlNQEafw/bzGnitWjE4QuuNvqVP3Ru5/mf4gRqFUbpxD1FLkIB8BhOFOSuIqlxzgo5/4cagcYzqdn1W5y+ZLGS/+Bpm3Ph49urHdgBjcfu8egpG7+fKG2eHU0eMci6Ks= Received: from SJ0PR03CA0164.namprd03.prod.outlook.com (2603:10b6:a03:338::19) by DM6PR12MB4185.namprd12.prod.outlook.com (2603:10b6:5:216::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.92.13; Tue, 9 Jun 2026 16:40:20 +0000 Received: from BY1PEPF0001AE17.namprd04.prod.outlook.com (2603:10b6:a03:338:cafe::87) by SJ0PR03CA0164.outlook.office365.com (2603:10b6:a03:338::19) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.21.113.10 via Frontend Transport; Tue, 9 Jun 2026 16:40:20 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=satlexmb08.amd.com; pr=C Received: from satlexmb08.amd.com (165.204.84.17) by BY1PEPF0001AE17.mail.protection.outlook.com (10.167.242.107) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.113.7 via Frontend Transport; Tue, 9 Jun 2026 16:40:20 +0000 Received: from satlexmb10.amd.com (10.181.42.219) by satlexmb08.amd.com (10.181.42.217) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.41; Tue, 9 Jun 2026 11:40:19 -0500 Received: from satlexmb08.amd.com (10.181.42.217) by satlexmb10.amd.com (10.181.42.219) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.41; Tue, 9 Jun 2026 11:40:19 -0500 Received: from xcosantraju40.xilinx.com (10.180.168.240) by satlexmb08.amd.com (10.181.42.217) with Microsoft SMTP Server id 15.2.2562.41 via Frontend Transport; Tue, 9 Jun 2026 11:40:19 -0500 From: Sandeep Gundlupet Raju To: , CC: , Subject: [yocto-patches] [layerindex-web][PATCH v3 3/4] README.devel: Replace deprecated libmariadb package Date: Tue, 9 Jun 2026 10:40:31 -0600 Message-ID: <20260609164032.1415124-4-sandeep.gundlupet-raju@amd.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260609164032.1415124-1-sandeep.gundlupet-raju@amd.com> References: <20260609164032.1415124-1-sandeep.gundlupet-raju@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BY1PEPF0001AE17:EE_|DM6PR12MB4185:EE_ X-MS-Office365-Filtering-Correlation-Id: 8958cc57-c063-4e95-2324-08dec645cb7c X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|1800799024|36860700016|376014|82310400026|22082099003|18002099003|11063799006|56012099006|3023799007; X-Microsoft-Antispam-Message-Info: pFKDWoDj9NR2eWzURp4wg0yhjQC/q+C3tL/e6WPKIPtOkFZmf6CNKYXDsWA9rmZ856S5Fx0Ow+cS42tM0o8IBi+A7B91ddUq7cDOEWazVcpUNKTE+k8LOxSByyaT3AcDrQudwyoGV5hp5YZsiIDAx1OxTBb7XTq55TjHvfADS/ycItjSS3TfLkv+7aNn0KfRntfsjP8RyczYfYWr4x1TGGGnYOopwj/Xzzt4VsJWkf5DwsDTIkJhw69lROhNndDkApZ2htaH/lb6izEYW/QQNQfXcxNNvt6WeCxDdj0+PkSDjxyBcRdUJKByx2XN+0CJxDWD07ycI9xV7al9qgsxdMrabkUTABzztBmtC3nAJQlNYzgBeRBM7eF0PB+vs+hUoA8qyPTS6zbgGy2usRvw+FYCehzs7QwEmwQAVmVLJaWdg4gIzE1lqk8jp09Hopp4wWPO1on1kJ0L4WoX3kUtK3kBQpfI0SwSp9nBF+LhyGgzgP/VYYzADDi7TibWhkRVHr5wwtN4bgluDvtUOsI39qnvu/DnNlryaLG9rOIKvwVDhYBwukG7PlfKVnAGXa5S9LRiBt7gMOaIVZF5w8ME9dUS7Kqao5zjDQ0d57v4Vj9MCgUkteiLl+nl59w1OyJenhPYtxIbSYo9DIJh+nx0a083fAPrlS2maRXyZm9fsTLXl3xC1xy7xmMhBqG7GEFh0EZtCVfagM2qXCiScpS7XYZuzNe6n/9eywizKmLsiSg= X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:satlexmb08.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230040)(1800799024)(36860700016)(376014)(82310400026)(22082099003)(18002099003)(11063799006)(56012099006)(3023799007);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: IdtBZU1llF7m+cwKC+XKqhprlT8NE0cd628Sk8cyAHXTSBeOkgYDyEOJkYSWdi8Mx08x2i1UykgWP7bKwnX94LOaFe7MY1UNJrjF3+jclY1pD+ZSa+z5YPVcK/9bCjzldApWyWCQa0PQb8itASg/9htTZSCSD0QYDAag/2Jf/eIwSCmkaXVzOOFlOk4supty6WTUdvrLDxtdwx/t6rlvCJ/ei+6sFxKOgep+ojmKMHbyQXL58lTG5wHK+rr0oYz84MT/T1mTJe0iDMOZoKyAH62n5LUmAQWnVGCQmQH5Ed+D6WqzB2ALTkTVIOXuTPKapK5hKgmo6Ss7L0LCSbgQ+pekcP74FgHuB7/qD81ep30HSiLZ31YSVkaMwsPxPtw9+e+nRPn1ZzjCyVrjBDJuWx2Y9Jqrhjy+BSQlx3QfL070n7crEdViYZTqglWgiugw X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2026 16:40:20.1048 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 8958cc57-c063-4e95-2324-08dec645cb7c X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[satlexmb08.amd.com] X-MS-Exchange-CrossTenant-AuthSource: BY1PEPF0001AE17.namprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB4185 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Tue, 09 Jun 2026 16:40:24 -0000 X-Groupsio-URL: https://lists.yoctoproject.org/g/yocto-patches/message/4188 Replace deprecated libmariadb-client-lgpl-dev with libmariadb-dev package in README.devel instructions. AI-Generated: GitHub Copilot (Claude Sonnet 4.6) Signed-off-by: Sandeep Gundlupet Raju --- README.devel | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.devel b/README.devel index 78fbfbb..de370e5 100644 --- a/README.devel +++ b/README.devel @@ -40,7 +40,7 @@ distros). the database backend): sudo apt-get update - sudo apt-get install python3-venv libmariadb-client-lgpl-dev build-essential python3-dev libjpeg-dev libz-dev libfreetype6-dev libssl-dev mariadb-server rabbitmq-server + sudo apt-get install python3-venv libmariadb-dev build-essential python3-dev libjpeg-dev libz-dev libfreetype6-dev libssl-dev mariadb-server rabbitmq-server 2. Work around path issues (you may not need this): From patchwork Tue Jun 9 16:40:32 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sandeep Gundlupet Raju X-Patchwork-Id: 89597 X-Patchwork-Delegate: ticotimo@gmail.com Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 14B26CD8CB2 for ; Tue, 9 Jun 2026 16:40:35 +0000 (UTC) Received: from CH5PR02CU005.outbound.protection.outlook.com (CH5PR02CU005.outbound.protection.outlook.com [40.107.200.47]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.52.1781023228074318782 for ; Tue, 09 Jun 2026 09:40:28 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="dkim: body hash did not verify" header.i=@amd.com header.s=selector1 header.b=Tg580MoY; spf=permerror, err=parse error for token &{10 18 %{i}._ip.%{h}._ehlo.%{d}._spf.vali.email}: invalid domain name (domain: amd.com, ip: 40.107.200.47, mailfrom: sandeep.gundlupet-raju@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=OcyG/tk3PgCoKQF/Xs1wu7flfuOlzTvlp1GFdU5RZ5TTqwe8+CYNwaHWySSE+gIh++9sicLRupMycFcGfEsI/YTuEUsv6JzXLB6A0QXRgJSAj0DVI2pMZoCIeRxId1yFD6hzp1OopEmoJbxxQPeTiOAP1dSD82eDVgmaLFsMyEkPDDf7bYPpt5slBaxp5jz99oBFbqp/n2RLcGu8uiiFnL+6b7pEfFcOw2dy3j+7jyN0xGlZwCbCiylNWQRpVifYc7k4rFYOq69Vsfvj+ps4wvribqtqYulKQrZekVVamNfj9aikFL0421mBH9NY3MsTYusBBmfluEiylBUHBBMyMA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=AlL5tIPGV0t1/3l8xhkBzH1IbSBMH5BagQQWth+bdgQ=; b=FaKVCy/WfacDVhHWkXtuxqdduaMioiF8FIAsJ93sOvm9Tbsieeo2to7qqxJqaNGmlzNLBMjNRCMwhTEpEWdjwUxzFZvZxz9GmtYs3qaXfk4FR4rlbpiAxYP9cHJBRueyicof9LW+sZDG/1eo0aEsoGjfyi6yqx4dLHeo0fKMEAwYy/AOZXY97ESz/zzBhhm8k8oRgkysuaenuBHDYekcaqUiWEA4xeWngtB3inVU7Q94wNcvnirlDYTU4OXM/Q0ggJIuIzEAgx2Px++dcxxdwIkhl9xRbRKYDsTE/cGv4+6KljsF7C1EQ7jhaWr32KxnQPbwIfyhlzlgw4ONGGVD+w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=lists.yoctoproject.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=AlL5tIPGV0t1/3l8xhkBzH1IbSBMH5BagQQWth+bdgQ=; b=Tg580MoY5KIZ/UbOHZvhD0eOS/1w7GMVuAawYp+HKkSolK1dl8egHmhmWVWiHW6qDkox+DP5Iaw1to6PI/nWM8nxNUr40KAgZcSze8vtdSlob4ILR3Q5KsiVAtRLFp7QodYgkspabqyTbUBBNb5nAyn81vB5PL5ewh33Me81oFM= Received: from SJ0PR13CA0177.namprd13.prod.outlook.com (2603:10b6:a03:2c7::32) by SJ2PR12MB8925.namprd12.prod.outlook.com (2603:10b6:a03:542::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.92.12; Tue, 9 Jun 2026 16:40:20 +0000 Received: from BY1PEPF0001AE19.namprd04.prod.outlook.com (2603:10b6:a03:2c7:cafe::98) by SJ0PR13CA0177.outlook.office365.com (2603:10b6:a03:2c7::32) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.21.113.10 via Frontend Transport; Tue, 9 Jun 2026 16:40:20 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=satlexmb08.amd.com; pr=C Received: from satlexmb08.amd.com (165.204.84.17) by BY1PEPF0001AE19.mail.protection.outlook.com (10.167.242.101) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.113.7 via Frontend Transport; Tue, 9 Jun 2026 16:40:20 +0000 Received: from satlexmb10.amd.com (10.181.42.219) by satlexmb08.amd.com (10.181.42.217) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.41; Tue, 9 Jun 2026 11:40:20 -0500 Received: from satlexmb08.amd.com (10.181.42.217) by satlexmb10.amd.com (10.181.42.219) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.41; Tue, 9 Jun 2026 11:40:20 -0500 Received: from xcosantraju40.xilinx.com (10.180.168.240) by satlexmb08.amd.com (10.181.42.217) with Microsoft SMTP Server id 15.2.2562.41 via Frontend Transport; Tue, 9 Jun 2026 11:40:19 -0500 From: Sandeep Gundlupet Raju To: , CC: , Subject: [yocto-patches] [layerindex-web][PATCH v3 4/4] README: Document --app-dir option usage Date: Tue, 9 Jun 2026 10:40:32 -0600 Message-ID: <20260609164032.1415124-5-sandeep.gundlupet-raju@amd.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260609164032.1415124-1-sandeep.gundlupet-raju@amd.com> References: <20260609164032.1415124-1-sandeep.gundlupet-raju@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BY1PEPF0001AE19:EE_|SJ2PR12MB8925:EE_ X-MS-Office365-Filtering-Correlation-Id: 35e52008-72ad-4905-cb91-08dec645cbc3 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|376014|36860700016|1800799024|82310400026|3023799007|56012099006|6133799003|11063799006|18002099003|13003099007|22082099003; X-Microsoft-Antispam-Message-Info: NtDb/SIfHcoDILgURHMtSW7U3D0W7b1gWuX2vgI5kyZaaLtuM0+3pIutL5BqN0sfnSYNYUKj6zrVKwRmvNrSrRZ0ZRM9NT5sbIZrVu90BJYVayAdEXJLu/EggUuexeGglme9Fu8rtYEnctJpW3Nm14VvSQJJGAKeAB5TvVI+CdyDnIaujmx63RGs1YqtqEPA39Q/NW7idsBJFQG06zNJftMV4Mur9DJ92jk6pk+wi9uW5P0kMDWG5pjZV3FUuFeGHPwAJKcVzMdc2HnL/Reezbbj0OC+4SghjDWHPK3JfNnXwfAoErWdykdzFg1Dv0vn8kWJd3l0NJgj7IlPgLm5Y1tllHxePIGL0cHr7z5/PPWxRUuAx5LitiLSnEGdmAAUdnvVpLHLdH9gZ7l5jMdkeiF5IiBg3Vk2QXs5CP5FfXGxSXPgPDGDc8LXL1cz7tkFXu7eows1A8uSfQL3hbFvMwY1nOOQ10ou+ME1OjFDLnyYBS+XV6JLd8v9vgkasklTndg2zDjl/DRxReigTvxkUbnnxtmqm6kqdByAScrq9aK+J+tu48nF0kGgBVX+yZXT1Wmt7yI9biIFYXSZuTxCjkcrKR0aeNeAUXkxRZXwLFL7VK5j4K8S/d6o5NNyARGhe9QWl07GFu8DlqpcZwA6y65YmzPVzgRXA2ui3YHUSoc= X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:satlexmb08.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230040)(376014)(36860700016)(1800799024)(82310400026)(3023799007)(56012099006)(6133799003)(11063799006)(18002099003)(13003099007)(22082099003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 18Rqi8qFlvGFJBZ+PMbcrCq4028pb4LEuua7xIzGTxRYq/RmVD/tpYPrwQVGa5Ea6vbRgeBSN183GGZLTAJ5kKaowT6R9fV1PTZsv74z8nZud2n2OHYDyWRIJozMP8kvbjW/tBcKenROmr6FTPUpJOrik2LBtK9Mqga0llLkNkN2HauPGCQiDMobbf6A4NeSxPJtjdEX4PAqhH8JFXPuHtgNEaSz4mCOAXFBgth8cuodSFMg9MOL/6D7BUiHI1v/4vIP78bMUNza5tRGL2wm+tXwz7VLdv+IerghXubjvVT81BQnhUusDIWywOsDuS9+iRQ1ssxmTFskqx1HpthIAA/M6bwcJOaq/Hf2UgYES0QOSQvdVrG10FeeK4oVdIGuavn0IE0VmCyYMLXqbzNicX8SakSBreufGMAnmvPVswaMw0oJZr+GEg5qdOnMVwRy X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2026 16:40:20.5740 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 35e52008-72ad-4905-cb91-08dec645cbc3 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[satlexmb08.amd.com] X-MS-Exchange-CrossTenant-AuthSource: BY1PEPF0001AE19.namprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SJ2PR12MB8925 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Tue, 09 Jun 2026 16:40:35 -0000 X-Groupsio-URL: https://lists.yoctoproject.org/g/yocto-patches/message/4190 Update README to reflect the new --app-dir support added to dockersetup.py: - Step 2: Add a note explaining that the default installation base directory inside the containers is /opt (requiring the repo to be cloned at /opt/layerindex), and document the --app-dir option for using a custom directory (e.g. when the repo is cloned to a non-default path) - Database Setup: add note to replace /opt with --app-dir value if used - Updating OE data: add same note - Security section: add reminder to substitute --app-dir value in the changepassword and axes_reset commands AI-Generated: GitHub Copilot (Claude Sonnet 4.6) Signed-off-by: Sandeep Gundlupet Raju --- README | 39 +++++++++++++++++++++++++++++++-------- 1 file changed, 31 insertions(+), 8 deletions(-) diff --git a/README b/README index 96c2ddd..a292cc5 100644 --- a/README +++ b/README @@ -49,6 +49,19 @@ instructions will walk you through the setup. ./dockersetup.py -d ~/databasedump.sql -p http://: + NOTE: By default, the application is installed inside the containers under + /opt (e.g. /opt/layerindex, /opt/migrate.sh). This means you should clone + this repository into /opt/layerindex on the host before running the script, + or alternatively use the --app-dir option to specify a different base + directory inside the container: + + ./dockersetup.py --app-dir /path/to/appdir + + For example, if you have cloned the repository to + /scratch2/myuser/layerindex-web, you would run: + + ./dockersetup.py --app-dir /scratch2/myuser/layerindex-web + NOTE: If you want email sending to work (required for user registration and password resets), you should use the -e/--email-host option to specify your outgoing email server. @@ -99,11 +112,14 @@ Database Setup Once the application is running you'll need to do a bit of further setup within it: +NOTE: The following commands use /opt as the default base directory. If you +ran dockersetup.py with --app-dir, replace /opt with the value you specified. + 1. For a fresh database (without importing any database dump) you will need layer data. To import the full set for the master branch from the public instance at layers.openembedded.org you can run the following: - docker-compose run --rm layersapp /opt/layerindex/layerindex/tools/import_layers.py https://layers.openembedded.org + docker-compose -f docker-compose.yml run --rm layersapp /opt/layerindex/layerindex/tools/import_layers.py https://layers.openembedded.org Alternatively, you can populate the database manually - you'll need to add at least the openembedded-core layer to the @@ -169,19 +185,22 @@ You will likely want to update the OpenEmbedded layer information on a regular basis. To do that by fetching and parsing all layer repositories, run the following: +NOTE: The following commands use /opt as the default base directory. If you +ran dockersetup.py with --app-dir, replace /opt with the value you specified. + Incremental update: - docker-compose run --rm layersapp /opt/layerindex/layerindex/update.py + docker-compose -f docker-compose.yml run --rm layersapp /opt/layerindex/layerindex/update.py Reload all data (should only be needed if the database structure has changed as part of an upgrade of the application code): - docker-compose run --rm layersapp /opt/layerindex/layerindex/update.py -r + docker-compose -f docker-compose.yml run --rm layersapp /opt/layerindex/layerindex/update.py -r Alternatively, you can update the data from an existing layer index instance (as per above during setup): - docker-compose run --rm layersapp /opt/layerindex/layerindex/tools/import_layers.py https://layers.openembedded.org + docker-compose -f docker-compose.yml run --rm layersapp /opt/layerindex/layerindex/tools/import_layers.py https://layers.openembedded.org @@ -356,7 +375,9 @@ REGISTRATION_OPEN = False reset function ( /accounts/password_reset/ ) or alternatively from the backend you can run the following command: - docker-compose exec layersapp /opt/layerindex/manage.py changepassword + docker-compose -f docker-compose.yml exec layersapp /opt/layerindex/manage.py changepassword + + (Replace /opt with your --app-dir value if you used a custom directory.) * The web-based password reset function will ask the user answers to security questions they selected and answered when they created the @@ -387,7 +408,9 @@ REGISTRATION_OPEN = False (default 4, resets after an hour). The lockout can be removed immediately using the following command: - docker-compose exec layersapp /opt/layerindex/manage.py axes_reset + docker-compose -f docker-compose.yml exec layersapp /opt/layerindex/manage.py axes_reset + + (Replace /opt with your --app-dir value if you used a custom directory.) If you wish to disable this, remove or comment out "axes" in INSTALLED_APPS. For more information on configuring axes, see: @@ -412,12 +435,12 @@ To back up the database within the docker-based setup, you can run the following command (no need to substitute ${MYSQL_ROOT_PASSWORD}, it's already present within the container environment): -docker-compose exec layersdb /bin/sh -c '/usr/bin/mariadb-dump -u root --password=${MYSQL_ROOT_PASSWORD} --max_allowed_packet=512M layersdb' | gzip > backup-`date +%Y_%m_%d_%H%M`.sql.gz +docker-compose -f docker-compose.yml exec layersdb /bin/sh -c '/usr/bin/mariadb-dump -u root --password=${MYSQL_ROOT_PASSWORD} --max_allowed_packet=512M layersdb' | gzip > backup-`date +%Y_%m_%d_%H%M`.sql.gz To restore one of these backups you would run the following command (take care, this will overwrite the data immediately without prompting!): -zcat backupfile.sql.gz | docker-compose exec -T layersdb /bin/sh -c '/usr/bin/mariadb -u root --password=${MYSQL_ROOT_PASSWORD} layersdb' +zcat backupfile.sql.gz | docker-compose -f docker-compose.yml exec -T layersdb /bin/sh -c '/usr/bin/mariadb -u root --password=${MYSQL_ROOT_PASSWORD} layersdb'