หน้านี้ยังไม่พร้อมใช้งานในภาษาท้องถิ่นของคุณ เรากำลังพยายามอย่างหนักเพื่อเพิ่มเวอร์ชันภาษาอื่น ๆ เพิ่มเติม ขอบคุณสำหรับการสนับสนุนเสมอมา

Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive
Help Center/ CodeArts Artifact/ Best Practices/ Uploading/Obtaining a Debian Component Using Linux Commands

Uploading/Obtaining a Debian Component Using Linux Commands

Updated on 2025-02-07 GMT+08:00

This section describes how to use Linux commands to upload a component to a Debian repository and obtain a dependency from the repository.

Prerequisites

  • A Debian component is available.
  • A Linux host that can connect to the public network is available.
  • You have created a Debian repository.
  • You have permissions for the current repository. For details, see Configuring Repository Permissions 2.0

Releasing a Component to a Debian Repository

  1. Log in to CodeArts Artifact and access the Debian repository. Click Tutorial on the right of the page.
  2. In the displayed dialog box, click Download Configuration File.

  3. On the Linux host, run the following command to upload a Debian component:

    curl -u <USERNAME>:<PASSWORD> -X PUT "https:// <repoUrl>/<DEBIAN_PACKAGE_NAME>;deb.distribution=<DISTRIBUTION>;deb.component=<COMPONENT>;deb.architecture=<ARCHITECTURE>" -T <PATH_TO_FILE>

    In this command, USERNAME, PASSWORD, and repoUrl can be obtained from the Debian upload command in the configuration file downloaded in the previous step.

    • USERNAME: username used for uploading files, which can be obtained from the Debian configuration file. For details, see the example figure.
    • PASSWORD: password used for uploading files, which can be obtained from the Debian configuration file. For details, see the example figure.
    • repoUrl: URL used for uploading files, which can be obtained from the Debian configuration file. For details, see the example figure.

      DEBIAN_PACKAGE_NAME, DISTRIBUTION, COMPONENT, and ARCHITECTURE can be obtained from the Debian component.

      The a2jmidid_8_dfsg0-1_amd64.deb component is used as an example.

    • DEBIAN_PACKAGE_NAME: software package name, for example, a2jmidid_8_dfsg0-1_amd64.deb.
    • DISTRIBUTION: release version, for example, trusty.
    • COMPONENT: component name, for example, main.
    • ARCHITECTURE: system architecture, for example, amd64.
    • PATH_TO_FILE: local storage path of the Debian component, for example, /root/a2jmidid_8_dfsg0-1_amd64.deb.

      The following figure shows the complete commands.

  4. After the commands are successfully executed, go to the self-hosted repo and find the uploaded Debian component.

Obtaining a Dependency from a Debian Repository

The following procedure uses the Debian component released in Releasing a Component to a Debian Repository as an example to describe how to obtain a dependency from a Debian repository.

  1. Download the public key file of the Debian repository by referring to Releasing a Component to a Debian Repository.

  2. Import the gpg public key.

    gpg --import <PUBLIC_KEY_PATH>

    PUBLIC_KEY_PATH: local path for storing the Debian public key, for example, artifactory.gpg.public.

  3. Add the public key to the list of keys used by apt to authenticate packages.

    gpg --export --armor <SIG_ID> | apt-key add -

  4. Add the apt repository source.

    Open the configuration file (for details about how to obtain the file, see Releasing a Component to a Debian Repository), replace all DISTRIBUTION fields with the value of COMPONENT (for example, main) used for uploading the Debian file, and add the repository source based on the downloaded configuration file sources.list.

  5. After the repository source is added, run the following command to update the repository source:

    apt-get update

  6. Run the following command to download the Debian package: Replace a2jmidid with the actual value of PACKAGE.

    apt download a2jmidid

    To obtain <PACKAGE>, perform the following steps:

    Download the Packages source data of the Debian component. The following uses the a2jmidid package as an example.

เราใช้คุกกี้เพื่อปรับปรุงไซต์และประสบการณ์การใช้ของคุณ การเรียกดูเว็บไซต์ของเราต่อแสดงว่าคุณยอมรับนโยบายคุกกี้ของเรา เรียนรู้เพิ่มเติม

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback