树莓派部署harbor_arm64
文章目录
- 树莓派4b部署Harbor-arm64版本
- docker-compose维护命令
- 访问harbor 192.168.1.111认用户名密码admin/Harbor12345
树莓派4b部署Harbor-arm64版本
harbor-arm版本
部署:参考
wget https://github.com/hzliangbin/harbor-arm64/releases/download/v1.9.3/harbor-offline-installer-v1.9.3.tgz
tar -xf harbor-offline-installer-v1.9.3.tgz -C /opt/
cp /opt/harbor/harbor.yml.tmpl /opt/harbor/harbor.yml
修改/opt/harbor/harbor.yml中的hostname字段为实际ip地址或者域名
注释掉https related config模块(本地环境可以直接使用http)
docker load -i /opt/harbor/harbor.v1.9.3.tar.gz
bash /opt/harbor/prepare
bash /opt/harbor/install.sh
docker-compose维护命令
cd /opt/harbor/
启动harbor: docker-compose up -d
停止harbor: docker-compose stop
重启harbor: docker-compose restart
查看harbor状态: docker-compose ps
异常:
docker-compose harbor harbor-log 报错:Authentication token manipulation error启动报错现象
docker-copmose up -d 后 harbor-log 无限重启
查看 harbor-log日志
docker logs -f harbor-logsudo: unable to change expired password: Authentication token manipulation error
sudo: Account or password is expired, reset your password and try again
sudo: a terminal is required to read the password; either use the -S option to read from standard input or configure an askpass helper
Changing password for root.
解决方法:
1.以tar形式导出容器
mkdir -p /tmp/harbor-log
cd /tmp/harbor-log
docker export harbor-log -o harbor-log.tar
2.解压tar包,修改shadow中的权限(有想深入了解的可以百度“关于/etc/shadow 文件”)
# 解压tar包
tar xvfp harbor-log.tar# 修改shadow文件的值
sed -i 's/:90:/:99999:/g' /tmp/harbor-log/etc/shadow
3.将修改后的shadow文件挂载到harbor-log容器内
mkdir /root/data/harbor/harbor-log-etccp /tmp/harbor-log/etc/shadow /root/data/harbor/harbor-log-etc/shadow
4.修改docker-compose.yml中harbor-log容器volumes配置,增加如下内容
- type: bindsource: ./harbor-log-etc/shadowtarget: /etc/shadow
5.重新启动harbor
docker-compose down
docker-compose up -d
#1 外置数据库部署访问(本次部署仅测试使用,生产环境建议高可用方式部署)
192.168.1.111: redis、postgresql
#redis
mkdir -p /opt/redis/conf/
cat << EOF > /opt/redis/conf/redis.conf
#bind 127.0.0.1
protected-mode no appendonly yes
requirepass duan@1994
EOFdocker run -itd --restart=always -p 6379:6379 --name redis-server -v /opt/redis/conf:/usr/local/etc/redis -v /data/redis/data:/data -d redis:6.0.10 redis-server /usr/local/etc/redis/redis.conf#postgresql
docker run -itd --restart=always -p 5432:5432 --name postgresql -v /data/postgresql/data:/var/lib/postgresql/data -e POSTGRES_PASSWORD=duan@1994 postgres:13.1登录pgsql创建用户和数据库
docker exec -it postgresql bash
create user harbor with password 'harborDB';
create database harbor;
create database harbor_clair;
create database harbor_notary_server;
create database harbor_notary_signer;
GRANT ALL PRIVILEGES ON DATABASE harbor to harbor;
GRANT ALL PRIVILEGES ON DATABASE harbor_clair to harbor;
GRANT ALL PRIVILEGES ON DATABASE harbor_notary_server to harbor;
GRANT ALL PRIVILEGES ON DATABASE harbor_notary_signer to harbor;
#2 部署minio(本次部署仅测试使用,生产环境建议高可用方式部署)
sudo docker run -d -p 11000:9000 -p 11001:9090 --net=host --name minio -e "MINIO_ACCESS_KEY=minioadmin" -e "MINIO_SECRET_KEY=minioadmin@131008" -v /media/pi/Elements/minio/data:/data -v /media/pi/Elements/minio/config:/root/.minio minio/minio server /data --console-address ":11001" -address ":11000"
#3 配置harbor.yaml
# Configuration file of Harbor# The IP address or hostname to access admin UI and registry service.
# DO NOT use localhost or 127.0.0.1, because Harbor needs to be accessed by external clients.
hostname: 192.168.86.5# http related config
http:# port for http, default is 80. If https enabled, this port will redirect to https portport: 80# https related config
#https:
# # https port for harbor, default is 443
# port: 443
# # The path of cert and key files for nginx
# certificate: /your/certificate/path
# private_key: /your/private/key/path# # Uncomment following will enable tls communication between all harbor components
# internal_tls:
# # set enabled to true means internal tls is enabled
# enabled: true
# # put your cert and key files on dir
# dir: /etc/harbor/tls/internal# Uncomment external_url if you want to enable external proxy
# And when it enabled the hostname will no longer used
# external_url: https://reg.mydomain.com:8433# The initial password of Harbor admin
# It only works in first time to install harbor
# Remember Change the admin password from UI after launching Harbor.
harbor_admin_password: Harbor12345# Harbor DB configuration
database:# The password for the root user of Harbor DB. Change this before any production use.password: root123# The maximum number of connections in the idle connection pool. If it <=0, no idle connections are retained.max_idle_conns: 50# The maximum number of open connections to the database. If it <= 0, then there is no limit on the number of open connections.# Note: the default number of connections is 1024 for postgres of harbor.max_open_conns: 1000# The default data volume
data_volume: /data# Harbor Storage settings by default is using /data dir on local filesystem
# Uncomment storage_service setting If you want to using external storage
# storage_service:
# # ca_bundle is the path to the custom root ca certificate, which will be injected into the truststore
# # of registry's and chart repository's containers. This is usually needed when the user hosts a internal storage with self signed certificate.
# ca_bundle:# # storage backend, default is filesystem, options include filesystem, azure, gcs, s3, swift and oss
# # for more info about this configuration please refer https://docs.docker.com/registry/configuration/
# filesystem:
# maxthreads: 100
# # set disable to true when you want to disable registry redirect
# redirect:
# disabled: false
storage_service:s3:accesskey: adminsecretkey: admin123456region: us-east-1regionendpoint: http://192.168.86.6:9000(新版本用9001)bucket: harbor-registryencrypt: falsesecure: falsev4auth: truechunksize: 5242880rootdirectory: /# Clair configuration
clair:# The interval of clair updaters, the unit is hour, set to 0 to disable the updaters.updaters_interval: 12# Trivy configuration
#
# Trivy DB contains vulnerability information from NVD, Red Hat, and many other upstream vulnerability databases.
# It is downloaded by Trivy from the GitHub release page https://github.com/aquasecurity/trivy-db/releases and cached
# in the local file system. In addition, the database contains the update timestamp so Trivy can detect whether it
# should download a newer version from the Internet or use the cached one. Currently, the database is updated every
# 12 hours and published as a new release to GitHub.
trivy:# ignoreUnfixed The flag to display only fixed vulnerabilitiesignore_unfixed: false# skipUpdate The flag to enable or disable Trivy DB downloads from GitHub## You might want to enable this flag in test or CI/CD environments to avoid GitHub rate limiting issues.# If the flag is enabled you have to download the `trivy-offline.tar.gz` archive manually, extract `trivy.db` and# `metadata.json` files and mount them in the `/home/scanner/.cache/trivy/db` path.skip_update: false## insecure The flag to skip verifying registry certificateinsecure: false# github_token The GitHub access token to download Trivy DB## Anonymous downloads from GitHub are subject to the limit of 60 requests per hour. Normally such rate limit is enough# for production operations. If, for any reason, it's not enough, you could increase the rate limit to 5000# requests per hour by specifying the GitHub access token. For more details on GitHub rate limiting please consult# https://developer.github.com/v3/#rate-limiting## You can create a GitHub token by following the instructions in# https://help.github.com/en/github/authenticating-to-github/creating-a-personal-access-token-for-the-command-line## github_token: xxxjobservice:# Maximum number of job workers in job servicemax_job_workers: 10notification:# Maximum retry count for webhook jobwebhook_job_max_retry: 10chart:# Change the value of absolute_url to enabled can enable absolute url in chartabsolute_url: disabled# Log configurations
log:# options are debug, info, warning, error, fatallevel: info# configs for logs in local storagelocal:# Log files are rotated log_rotate_count times before being removed. If count is 0, old versions are removed rather than rotated.rotate_count: 50# Log files are rotated only if they grow bigger than log_rotate_size bytes. If size is followed by k, the size is assumed to be in kilobytes.# If the M is used, the size is in megabytes, and if G is used, the size is in gigabytes. So size 100, size 100k, size 100M and size 100G# are all valid.rotate_size: 200M# The directory on your host that store loglocation: /var/log/harbor# Uncomment following lines to enable external syslog endpoint.# external_endpoint:# # protocol used to transmit log to external endpoint, options is tcp or udp# protocol: tcp# # The host of external endpoint# host: localhost# # Port of external endpoint# port: 5140#This attribute is for migrator to detect the version of the .cfg file, DO NOT MODIFY!
_version: 2.0.0# Uncomment external_database if using external database.
external_database:harbor:host: 192.168.1.111port: 5432db_name: harborusername: harborpassword: harborDBssl_mode: disablemax_idle_conns: 2max_open_conns: 0clair:host: 192.168.1.111port: 5432db_name: clairusername: harborpassword: harborDBssl_mode: disablenotary_signer:host: 192.168.1.111port: 5432db_name: notary_signerusername: harborpassword: harborDBssl_mode: disablenotary_server:host: 192.168.1.111port: 5432db_name: notary_serverusername: harborpassword: harborDBssl_mode: disable# Uncomment external_redis if using external Redis server
external_redis:# support redis, redis+sentinel# host for redis: <host_redis>:<port_redis># host for redis+sentinel:# <host_sentinel1>:<port_sentinel1>,<host_sentinel2>:<port_sentinel2>,<host_sentinel3>:<port_sentinel3>host: 192.168.1.111:6379password: duan@1994# sentinel_master_set must be set to support redis+sentinel#sentinel_master_set:# db_index 0 is for core, it's unchangeableregistry_db_index: 1jobservice_db_index: 2chartmuseum_db_index: 3clair_db_index: 4trivy_db_index: 5idle_timeout_seconds: 30# Uncomment uaa for trusting the certificate of uaa instance that is hosted via self-signed cert.
# uaa:
# ca_file: /path/to/ca# Global proxy
# Config http proxy for components, e.g. http://my.proxy.com:3128
# Components doesn't need to connect to each others via http proxy.
# Remove component from `components` array if want disable proxy
# for it. If you want use proxy for replication, MUST enable proxy
# for core and jobservice, and set `http_proxy` and `https_proxy`.
# Add domain to the `no_proxy` field, when you want disable proxy
# for some special registry.
proxy:http_proxy:https_proxy:no_proxy:components:- core- jobservice- clair- trivy
访问harbor 192.168.1.111认用户名密码admin/Harbor12345
docker push 异常:
docker 在push镜像到本地registry出现的500 Internal Server Error
原因一:
镜像目录不符合要求:应该是两级目录以上才可以的, 如:
192.168.1.111:5000/postgres:latest 不符合要求
192.168.1.111:5000/lvyuanj/postgres:latest 符合要求
Docker push时报错:Docker denied: requested access to the resource is denied的解决办法
请遵循这两种解决方法
(1)解决方案 1:
首先,检查您的 docker hub 凭据是否输入了正确的凭据。
如果您输入的密码正确,则此错误仍然存在,请尝试注销并使用您的凭据重新登录。
对于注销使用,
docker logout
再次登录使用,
docker login
在某些情况下,此解决方案可能有效。
解决方案 2:
如果仍然如此,您在尝试解决方案 1 后仍收到此错误,您必须按照此解决方案来清除错误。
YOUR_DOCKERHUB_NAME 必须是自己harbor域名或者ip:port 例:自己私有harbor 192.168.1.111:5000
首先,登录后你必须在推送之前标记你的图像:
docker tag image_name YOUR_DOCKERHUB_NAME/image_name
然后,你必须推动它。
docker push YOUR_DOCKERHUB_NAME/image_name
完成此操作后,您将能够将 docker 镜像推送到您的存储库中,错误将消失。
再次登录使用,
docker login
在某些情况下,此解决方案可能有效。
解决方案 2:
如果仍然如此,您在尝试解决方案 1 后仍收到此错误,您必须按照此解决方案来清除错误。
YOUR_DOCKERHUB_NAME 必须是自己harbor域名或者ip:port 例:自己私有harbor 192.168.1.111:5000
首先,登录后你必须在推送之前标记你的图像:
docker tag image_name YOUR_DOCKERHUB_NAME/image_name
然后,你必须推动它。
docker push YOUR_DOCKERHUB_NAME/image_name
完成此操作后,您将能够将 docker 镜像推送到您的存储库中,错误将消失。
相关文章:

树莓派部署harbor_arm64
文章目录 树莓派4b部署Harbor-arm64版本docker-compose维护命令访问harbor 192.168.1.111认用户名密码admin/Harbor12345 树莓派4b部署Harbor-arm64版本 harbor-arm版本 部署:参考 wget https://github.com/hzliangbin/harbor-arm64/releases/download/v1.9.3/ha…...

Typora图床配置优化(PicGo-Core(command line) 插件 + gitee)
Typora图床配置优化(PicGo-Core(command line) 插件 gitee) 前言 在日常使用Typora编写markdown笔记时,经常需要插入图片来帮助理解和整理逻辑。然而,由于图片保存在本地,上传到网上时经常出现图片不见或错误警告的…...

开放式耳机推荐品牌:五款品质超凡机型必须选购
在这个快节奏的生活中,我们每个人都渴望在忙碌之余找到一片属于自己的宁静。音乐,作为连接心灵的桥梁,无疑是最为直接和有效的途径。而一款优秀的开放式耳机,不仅能让我们沉浸在美妙的旋律中,还能在保持对外界环境感知…...
【大数据面试题】31 Flink 有哪些重启方法
一步一个脚印,一天一道面试题 Flink 提供了几种不同的重启方法: 异常自动从 Checkpoint 重启: Checkpoint是Flink的另一种状态快照机制,它比Savepoint更为频繁,提供了细粒度的状态恢复点。通过配置Checkpoint,Flink会…...

【IDEA】Redis可视化神器
在开发过程中,为了方便地管理 Redis 数据库,我们可能会使用一些数据库可视化插件。这些插件通常可以帮助你在 IDE 中直观地查看和管理 Redis 数据库,包括查看键值对、执行命令、监视数据库活动等。 IDEA作为IDE界的Jenkins,本身自…...

深入分析 Android Activity (十一)
文章目录 深入分析 Android Activity (十一)1. Activity 的内存管理和优化1.1 内存泄漏的常见原因1.2 避免内存泄漏的方法1.3 内存泄漏检测工具 2. Activity 的配置变更处理2.1 处理配置变更2.2 保存和恢复状态2.3 使用 ViewModel 3. Activity 的测试3.1 单元测试3.2 UI 测试 4…...
go语言切片、数组去重函数SliceUnique 支持所有值是可比较类型的切片或者数组去重
我们在go语言开发的时候经常会需要对切片或者数组进行去重操作, 今天就给大家分享一个切片 或者数组去重的通用函数。 这里提醒大家注意go语言是严格区分数据类型的, 切片slice 和 数组 array是不同的数据类型, 不要混淆!&#x…...

微信小程序实现计算当前位置到目的地的距离
实现方式:使用腾讯位置服务 微信小程序JavaScript SDK | 腾讯位置服务 1.进腾讯位置服务申请key 2.下载sdk 微信小程序JavaScript SDK | 腾讯位置服务 3.微信公众平台添加授权域名 4.代码实现计算 const qqmap require("../../utils/qqmap-wx-jssdk.min.js…...

灵动微单片机洗衣机方案——【软硬件开发支持】
RAMSUN英尚以洗衣机洗涤主驱电机为例,主驱电机和多电机控制首选MM32SPIN0280.灵动微电子能够提供完整的软硬件开发支持,目前方案已经在主流家电厂出货。 洗衣机方案 皮带洗衣机 DD直驱洗衣机 波轮洗衣机 Mini壁挂和桌面洗衣机 洗涤烘干双变频方案 热泵烘…...
EureKa是什么?
Eureka 是一个源于 Netflix 公司的开源项目,主要用于实现服务注册和服务发现的功能。它是构建分布式系统中的微服务架构的一个关键组件。下面是对 Eureka 的解释: 基本概念 Eureka 是基于 REST 的服务,主要用于管理微服务架构中的服务实例的…...

【数据结构】直接选择排序详解!
文章目录 1.直接选择排序 1.直接选择排序 🐧 begin 有可能就是 maxi ,所以交换的时候,要及时更新 maxi 🍎 直接选择排序是不稳定的,例如: 9 [9] 5 [5],排序后,因为直接选择排序是会…...

vue3中的toRaw API
文章目录 什么是toRaw API?为什么需要toRaw?如何使用toRaw?实际应用场景 这两天在写项目的时候,发现了一个之前没用过的api,于是上网查了一下,发现这个api还是挺常用,所以在这记录一下 什么是t…...

接口响应断言-json
json认识JSONPath源码类学习/json串的解析拓展学习 目的:数据返回值校验测试 json认识 json是什么-是一种数据交换格式,举例平时看到的json图2,在使用中查看不方便,会有格式转化的平台,json格式的展示 JSON在线视图…...

全面盘点多模态融合算法及应用场景
关注作者,分享AI全维度知识。作者拥有10年互联网服务架构、AI产品研发经验、团队管理经验,同济本复旦硕博,复旦机器人智能实验室成员,阿里云认证的资深架构师,项目管理专业人士,上亿营收AI产品研发负责人 多…...

超分论文走读
codeFormer 原始动机 高度不确定性,模糊到高清,存在一对多的映射纹理细节丢失人脸身份信息丢失 模型实现 训练VQGAN 从而得到HQ码本空间作为本文的离散人脸先验。为了降低LQ-HQ映射之间的不确定性,我们设计尽量小的码本空间和尽量短的Code…...
Android ViewPager2 + FragmentStateAdapter 的使用以及问题
场景介绍:在Android业务功能开发的过程中,需要使用到嵌套ViewPage2实现页面切换,这种场景在我们的开发过程中并不少见,大致结构为一个activity包含一个viewPage2,这个viewPage2中存在一个fragment A,fragme…...

FPGA中的乒乓操作
为什么不直接选用一个缓存更大的FIFO而选用乒乓操作为什么乒乓操作可以实现低速处理高速数据乒乓操作适用哪些场景 一、乒乓操作结构 首先先介绍一下乒乓操作的原理,其结构如下: 输入选择单元负责将数据送到数据缓冲模块,然后输出选择单元负…...

gnocchi学习小结
背景 总结gnocchi 4.4版本gnocchi-metricd工作流程 入口 gnocchi.cli.metricd metricd stop after processing metric默认为0,调servicemanager run MetricdServiceManager __init__ 服务逻辑封装到MetricdServiceManager初始化中 主要由MetricProcessor, Met…...

【机器学习】Pandas中to_pickle()函数的介绍与机器学习中的应用
【机器学习】Pandas中to_pickle()函数的介绍和机器学习中的应用 🌈 欢迎莅临我的个人主页👈这里是我深耕Python编程、机器学习和自然语言处理(NLP)领域,并乐于分享知识与经验的小天地!🎇 &#…...
lightning的hook顺序
结果 setup: 训练循环开始前设置数据加载器和模型。 configure_optimizers: 设置优化器和学习率调度器。 on_fit_start: 训练过程开始。 on_train_start: 训练开始。 on_train_epoch_start: 每个训练周期开始。 on_train_batch_start: 每个训练批次开始。 on_before_bac…...
[2025CVPR]DeepVideo-R1:基于难度感知回归GRPO的视频强化微调框架详解
突破视频大语言模型推理瓶颈,在多个视频基准上实现SOTA性能 一、核心问题与创新亮点 1.1 GRPO在视频任务中的两大挑战 安全措施依赖问题 GRPO使用min和clip函数限制策略更新幅度,导致: 梯度抑制:当新旧策略差异过大时梯度消失收敛困难:策略无法充分优化# 传统GRPO的梯…...

Unity3D中Gfx.WaitForPresent优化方案
前言 在Unity中,Gfx.WaitForPresent占用CPU过高通常表示主线程在等待GPU完成渲染(即CPU被阻塞),这表明存在GPU瓶颈或垂直同步/帧率设置问题。以下是系统的优化方案: 对惹,这里有一个游戏开发交流小组&…...

中南大学无人机智能体的全面评估!BEDI:用于评估无人机上具身智能体的综合性基准测试
作者:Mingning Guo, Mengwei Wu, Jiarun He, Shaoxian Li, Haifeng Li, Chao Tao单位:中南大学地球科学与信息物理学院论文标题:BEDI: A Comprehensive Benchmark for Evaluating Embodied Agents on UAVs论文链接:https://arxiv.…...
uni-app学习笔记二十二---使用vite.config.js全局导入常用依赖
在前面的练习中,每个页面需要使用ref,onShow等生命周期钩子函数时都需要像下面这样导入 import {onMounted, ref} from "vue" 如果不想每个页面都导入,需要使用node.js命令npm安装unplugin-auto-import npm install unplugin-au…...
基于服务器使用 apt 安装、配置 Nginx
🧾 一、查看可安装的 Nginx 版本 首先,你可以运行以下命令查看可用版本: apt-cache madison nginx-core输出示例: nginx-core | 1.18.0-6ubuntu14.6 | http://archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages ng…...
React Native在HarmonyOS 5.0阅读类应用开发中的实践
一、技术选型背景 随着HarmonyOS 5.0对Web兼容层的增强,React Native作为跨平台框架可通过重新编译ArkTS组件实现85%以上的代码复用率。阅读类应用具有UI复杂度低、数据流清晰的特点。 二、核心实现方案 1. 环境配置 (1)使用React Native…...

Keil 中设置 STM32 Flash 和 RAM 地址详解
文章目录 Keil 中设置 STM32 Flash 和 RAM 地址详解一、Flash 和 RAM 配置界面(Target 选项卡)1. IROM1(用于配置 Flash)2. IRAM1(用于配置 RAM)二、链接器设置界面(Linker 选项卡)1. 勾选“Use Memory Layout from Target Dialog”2. 查看链接器参数(如果没有勾选上面…...
css的定位(position)详解:相对定位 绝对定位 固定定位
在 CSS 中,元素的定位通过 position 属性控制,共有 5 种定位模式:static(静态定位)、relative(相对定位)、absolute(绝对定位)、fixed(固定定位)和…...

多模态大语言模型arxiv论文略读(108)
CROME: Cross-Modal Adapters for Efficient Multimodal LLM ➡️ 论文标题:CROME: Cross-Modal Adapters for Efficient Multimodal LLM ➡️ 论文作者:Sayna Ebrahimi, Sercan O. Arik, Tejas Nama, Tomas Pfister ➡️ 研究机构: Google Cloud AI Re…...

论文笔记——相干体技术在裂缝预测中的应用研究
目录 相关地震知识补充地震数据的认识地震几何属性 相干体算法定义基本原理第一代相干体技术:基于互相关的相干体技术(Correlation)第二代相干体技术:基于相似的相干体技术(Semblance)基于多道相似的相干体…...