Migrated CI environment from TravisCI to Github Actions.
It also supports ubuntu(16.04, 18.04, 20.04), debian(9, 10), CentOS(6, 7, 8) and Fedora(30, 31, 32) operating systems.
Background
Due to the charge for TravisCI, travis-ci.org will be closed and moved to travis-ci.com.
The Free plan imposes restrictions on building AntPiackax products.
Also, with the release of Github Actions, we have decided to move from TravisCI to Github Actions.
This allows users who fork the repository to use CI without restrictions.
Migrating repository settings
Build with Github Actions is available without any restrictions.
If you want to build a package with Github Actions and publish the package, you need to set it.
(The package to be published is assumed to be packagecloud.io.)
If you want to publish a package, you will need a token for packagecloud.io.
In the Secret panel on the repository settings page, set the token in the PACKAGECLOUD_TOKEN variable.
About customizing Github Actions
This repository use Github Actions as CI, but there are cases where I want to change it when I fork.
You can change the behavior by setting the following variables in the Secret panel on the repository settings page.
(In the case of Travis CI, it could be set as Environment, but in Github Actions it is set with Secret.)
These values are all arbitrary variables except that the main repository requires PACKAGECLOUD_TOKEN. (Usually, it is not necessary to set)
OSTYPE_VARS_FILE
You can specify a file(default is ostypevars.sh) that declares and sets variables for each OS.
You can customize it by setting this variable.
The variables specified in the file will be described later.
BUILD_NUMBER
Specify the build number of the package to be created.
Normally, it is set as 1.
DEVELOPER_FULLNAME
Specifies the full name of the developer of the package.
The main repository has a name derived from AntPickax.
DEVELOPER_EMAIL
Specify the email address of the developer of the package.
In the main repository, the email address derived from AntPickax is set.
FORCE_PUBLISH
If you set this value to true, it will force the package to be published when you run Github Actions.
Normally, the package is published only when the Release Tag is created.
If false is set, the package will not be published even if the Release Tag is created.
USE_PACKAGECLOUD_REPO
Before building, you will install the relevant packages, but you can specify whether to use the packagecloud.io repository.
Set the value to true or false. (Default is true)
PACKAGECLOUD_TOKEN
When the package is published, please set the token required to upload to papacgecloud.io.
The main repository is always set because it will be uploaded when the Release Tag is created.
Forked repositories etc. do not normally upload, so you do not need to set this variable.
PACKAGECLOUD_OWNER
Specify the owner name that is part of the path of the papacgecloud.io repository to use.
The default is ʻantpickax`. (Shows a part of the path at https://packagecloud.io/antpickax.)
PACKAGECLOUD_PUBLISH_REPO
When publishing a package, specify the repository name that is part of the path to the pacakgecloud.io repository to upload.
The default is current. (Shows a portion of the path at https://packagecloud.io/antpickax/current.)
PACKAGECLOUD_DOWNLOAD_REPO
Specifies the repository name that is part of the path to the papacgecloud.io repository when installing packages before build.
The default is stable. (Shows a part of the path at https://packagecloud.io/antpickax/stable.)
Environment settings by OS
The build and packaging functions provided by this repository using Github Actions require OS-specific settings.
These settings are described in the .github/workflows/ostypevars.sh file.
The variables used by Github Actions provided by this repository are shown below.
The values of these variables are changed to customize the OS individually.
DIST_TAG
Set the Distro/Version of the package to be created.
INSTALL_PKG_LIST
Contains a list of packages that need to be installed before building.
CONFIGURE_EXT_OPT
In the build, run configure. You can set the arguments to pass to this configure.
INSTALLER_BIN
Since the package management software differs for each OS, set the command name.
(Example: yum/dnf/apt-get)
PKG_TYPE_DEB
Set 1 when creating ubuntu or debian type packages.
PKG_TYPE_RPM
Set 1 when creating a CentOS or Fedora package.
PKG_OUTPUT_DIR
This value depends on the script under buildutils, so basically do not set it.
For ubuntu/debian series, set debian_build, and for CentOS/Fedora series, set ..
PKG_EXT
Specify the extension of the package file to be created.
For ubuntu/debian series, set deb, and for CentOS/Fedora series, set rpm.
Relevant Issue (if applicable)
n/a
Details
Migrated CI environment from TravisCI to Github Actions. It also supports ubuntu(16.04, 18.04, 20.04), debian(9, 10), CentOS(6, 7, 8) and Fedora(30, 31, 32) operating systems.
Background
Due to the charge for TravisCI,
travis-ci.org
will be closed and moved totravis-ci.com
. TheFree plan
imposes restrictions on building AntPiackax products. Also, with the release of Github Actions, we have decided to move from TravisCI to Github Actions. This allows users who fork the repository to use CI without restrictions.Migrating repository settings
Build with Github Actions is available without any restrictions. If you want to build a package with Github Actions and publish the package, you need to set it. (The package to be published is assumed to be packagecloud.io.)
If you want to publish a package, you will need a token for packagecloud.io. In the Secret panel on the repository settings page, set the token in the
PACKAGECLOUD_TOKEN
variable.About customizing Github Actions
This repository use Github Actions as CI, but there are cases where I want to change it when I fork. You can change the behavior by setting the following variables in the Secret panel on the repository settings page. (In the case of Travis CI, it could be set as Environment, but in Github Actions it is set with Secret.) These values are all arbitrary variables except that the main repository requires
PACKAGECLOUD_TOKEN
. (Usually, it is not necessary to set)OSTYPE_VARS_FILE
You can specify a file(default is ostypevars.sh) that declares and sets variables for each OS. You can customize it by setting this variable. The variables specified in the file will be described later.
BUILD_NUMBER
Specify the build number of the package to be created. Normally, it is set as
1
.DEVELOPER_FULLNAME
Specifies the full name of the developer of the package. The main repository has a name derived from AntPickax.
DEVELOPER_EMAIL
Specify the email address of the developer of the package. In the main repository, the email address derived from AntPickax is set.
FORCE_PUBLISH
If you set this value to true, it will force the package to be published when you run Github Actions. Normally, the package is published only when the Release Tag is created. If false is set, the package will not be published even if the Release Tag is created.
USE_PACKAGECLOUD_REPO
Before building, you will install the relevant packages, but you can specify whether to use the packagecloud.io repository. Set the value to true or false. (Default is true)
PACKAGECLOUD_TOKEN
When the package is published, please set the token required to upload to papacgecloud.io. The main repository is always set because it will be uploaded when the Release Tag is created. Forked repositories etc. do not normally upload, so you do not need to set this variable.
PACKAGECLOUD_OWNER
Specify the owner name that is part of the path of the papacgecloud.io repository to use. The default is ʻantpickax`. (Shows a part of the path at https://packagecloud.io/antpickax.)
PACKAGECLOUD_PUBLISH_REPO
When publishing a package, specify the repository name that is part of the path to the pacakgecloud.io repository to upload. The default is
current
. (Shows a portion of the path at https://packagecloud.io/antpickax/current.)PACKAGECLOUD_DOWNLOAD_REPO
Specifies the repository name that is part of the path to the papacgecloud.io repository when installing packages before build. The default is
stable
. (Shows a part of the path at https://packagecloud.io/antpickax/stable.)Environment settings by OS
The build and packaging functions provided by this repository using Github Actions require OS-specific settings. These settings are described in the
.github/workflows/ostypevars.sh
file. The variables used by Github Actions provided by this repository are shown below. The values of these variables are changed to customize the OS individually.DIST_TAG
Set the
Distro/Version
of the package to be created.INSTALL_PKG_LIST
Contains a list of packages that need to be installed before building.
CONFIGURE_EXT_OPT
In the build, run
configure
. You can set the arguments to pass to thisconfigure
.INSTALLER_BIN
Since the package management software differs for each OS, set the command name. (Example: yum/dnf/apt-get)
PKG_TYPE_DEB
Set
1
when creating ubuntu or debian type packages.PKG_TYPE_RPM
Set
1
when creating a CentOS or Fedora package.PKG_OUTPUT_DIR
This value depends on the script under
buildutils
, so basically do not set it. For ubuntu/debian series, setdebian_build
, and for CentOS/Fedora series, set.
.PKG_EXT
Specify the extension of the package file to be created. For ubuntu/debian series, set
deb
, and for CentOS/Fedora series, setrpm
.IS_OS_UBUNTU / IS_OS_DEBIAN / IS_OS_CENTOS / IS_OS_FEDORA
Set
1
to the variable of the matching OS type.