Updated on 2023-12-21 GMT+08:00

Uploading Files to OBS

For details about the restrictions on using OBS, see Restrictions and Limitations.

Configuration Description

Add Upload Files to OBS, when configuring build actions.

The parameters are described in the following table.

Parameter

Description

Action Name

Name of a build action. It can be customized.

Authorized Account

  • Current: Upload files to an OBS bucket of the current account.
  • Other: Upload files to an OBS bucket of a specific account by using an IAM account.

Build Directory

Directory for storing build results. If no file name is specified for OBS storage, use wildcard characters to upload multiple files. Example: **/target/*.?ar uploads all JAR and WAR packages built with Maven.

Bucket Name

Name of the target OBS bucket. Cross-region upload is not supported.

OBS Directory

Directory for storing build results on OBS (for example, application/version/). You can leave this parameter blank or enter ./ to store build results to the OBS root directory.

File Name

New name (excluding the directory) for the built file after OBS storage. Leave it blank to upload multiple files with their old names, or specify a name to upload a single file, for example, application.jar.

Headers

Add one or more custom response headers during file upload. The headers will be included in the response to download objects or query the object metadata. For example, you can set the key to x-frame-options and value to false to prevent web pages stored in OBS from being embedded into third-party web pages.