logo
0
0
WeChat Login
add secret and modify name

Hexo + Rsync to Remote Server

badge badge badge

In this example, you will use Cloud Native Build (CNB) to package the "hexo-rsync-remote" project, build the Hexo static site, and synchronize the generated files to a remote server using Rsync.

Prerequisites

  1. Use Cloud Native Build (CNB) to build your project <<<<<<< HEAD
  2. Environment variables and usage: Environment Variables
  3. Declarative build cache
  4. Plugins and usage: Plugin Market
  5. Use tencentcom/rsync plugin: Allows users to synchronize files to remote servers through simple command-line instructions, similar to scp. =======
  6. Environment variables and usage: Environment Variables
  7. Declarative build cache
  8. Plugins and usage: Plugin Market
  9. Use tencentcom/rsync plugin: Allows users to synchronize files to remote servers through simple command-line instructions, similar to scp.

refs/stashes/1991686256591597568/main/commit

Configuration Secrets

# Secret repository env.yml RSYNC_KEY: | -----BEGIN RSA PRIVATE KEY----- MIIEowIBAAKCAQEAplJz7MtuFLDrrqt7Aq6ZBQsoJbebx0tzqneBW1nNaJ0r73W0 87JoXrRvDSWC+ngHgv7YP7tASfsEd8zPBmXbt4qlBIPygfkVxJHwj6+VaooEvZIV -----END RSA PRIVATE KEY----- RSYNC_USER: xxx

Getting Started

cnb-init-from https://cnb.cool/examples/ecosystem/hexo-rsync-remote.git

Quick Start

Click the Fork button in the upper right corner to fork the project to your own repository. Then click the Cloud Native Development button to start remote development.

  1. Install dependencies
yarn install
  1. Run the project
yarn run server
  1. Preview

img.png