-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
232 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
name: test | ||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
|
||
jobs: | ||
run: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
- name: Set runner IP | ||
id: ip | ||
run: | | ||
iface=$(ls -1 /sys/class/net | sed '/^\(lo\|br-\|veth\|docker\|bond\|dummy\|sit\)/d' | head -n1) | ||
ip=$(ip a show dev ${iface} | sed -n 's|^\s*inet\s\([0-9\.]\+\)/.*|\1|p' | head -n1) | ||
echo ${ip} | ||
echo "::set-output name=ip::${ip}" | ||
sed "s/localhost/${ip}/g" -i $(find test -type f) | ||
- name: Build dummy server | ||
run: cd test && docker-compose build | ||
- name: Start dummy server | ||
run: cd test && docker-compose up -d | ||
|
||
- name: Prpare repos | ||
run: | | ||
mv ${GITHUB_WORKSPACE} /tmp/orig | ||
git clone http://localhost/repos/foo.git ${GITHUB_WORKSPACE} | ||
mv /tmp/orig ${GITHUB_WORKSPACE}/.bloom-release-action | ||
- name: Run bloom-release-action | ||
uses: ./.bloom-release-action | ||
with: | ||
ros_distro: noetic | ||
github_token_bloom: dummy | ||
github_user: dummy | ||
git_email: dummy@dummy | ||
repository: foo | ||
open_pr: true | ||
env: | ||
ROSDISTRO_INDEX_URL: http://${{ steps.ip.outputs.ip }}/raw/rosdistro/index-v4.yaml | ||
|
||
- name: Check release repo | ||
working-directory: /tmp | ||
run: | | ||
git clone http://localhost/repos/foo-release.git | ||
cd foo-release | ||
git show upstream/0.0.1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#!/bin/sh | ||
|
||
addgroup nginx www-data | ||
|
||
su - fcgiwrap -s /bin/sh -c " | ||
umask 002 | ||
fcgiwrap -s unix:/var/run/fcgiwrap/socket | ||
" & |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
FROM nginx:1.21-alpine | ||
|
||
RUN apk add --no-cache \ | ||
fcgiwrap \ | ||
git \ | ||
git-daemon \ | ||
gzip \ | ||
make | ||
|
||
COPY cache /usr/share/nginx/html/cache | ||
RUN make -C /usr/share/nginx/html/cache | ||
COPY repos /usr/share/nginx/html/raw | ||
|
||
COPY 40-start-fastcgi.sh /docker-entrypoint.d | ||
COPY default.conf /etc/nginx/conf.d | ||
|
||
RUN git config --global user.email "[email protected]" \ | ||
&& git config --global user.name "Your Name" | ||
|
||
COPY repos /repos | ||
WORKDIR /repos | ||
|
||
RUN for repo in *; \ | ||
do \ | ||
git -C ${repo} init; \ | ||
git -C ${repo} add .; \ | ||
git -C ${repo} commit -m "Initial"; \ | ||
if [ ${repo} = "foo" ]; \ | ||
then \ | ||
git -C ${repo} tag 0.0.1; \ | ||
git -C ${repo} push origin 0.0.1; \ | ||
fi; \ | ||
git -C ${repo} config core.bare true; \ | ||
git -C ${repo} config http.receivepack true; \ | ||
mv ${repo}/.git ${repo}.git; \ | ||
chown -R fcgiwrap:www-data ${repo}.git; \ | ||
rm -rf ${repo}; \ | ||
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
hoge-cache.yaml.gz: hoge-cache.yaml | ||
cat $< | gzip > $@ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
distribution_file: | ||
- release_platforms: | ||
ubuntu: [xenial] | ||
repositories: | ||
foo: {release: {tags: {release: 'release/noetic/{package}/{version}'}, url: 'http://localhost/repos/foo-release.git', version: 0.0.0-0}, source: {type: git, url: 'http://localhost/repos/foo.git', version: noetic}, status: maintained} | ||
name: noetic | ||
release_package_xmls: | ||
foo: <?xml version="1.0" ?><?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?><package format="3"><name>foo</name><version>0.0.0</version><description>Dummy</description><maintainer email="[email protected]">Dummy</maintainer><license>Dummy</license><buildtool_depend>catkin</buildtool_depend></package> | ||
source_repo_package_xmls: {} | ||
type: cache | ||
version: 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
server { | ||
listen 80; | ||
|
||
root /repos; | ||
|
||
location / { | ||
root /usr/share/nginx/html; | ||
index index.html index.htm; | ||
} | ||
|
||
location ~ /repos(/.*) { | ||
fastcgi_pass unix:/var/run/fcgiwrap/socket; | ||
include fastcgi_params; | ||
fastcgi_param SCRIPT_FILENAME /usr/libexec/git-core/git-http-backend; | ||
fastcgi_param GIT_HTTP_EXPORT_ALL ""; | ||
fastcgi_param GIT_PROJECT_ROOT /repos; | ||
fastcgi_param PATH_INFO $1; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
version: '3.5' | ||
services: | ||
bloom-test: | ||
image: bloom-test | ||
build: . | ||
ports: | ||
- "80:80" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
# Release of foo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
release_repo_url: http://localhost/repos/foo-release.git | ||
tracks: | ||
noetic: | ||
actions: | ||
- bloom-export-upstream :{vcs_local_uri} :{vcs_type} --tag :{release_tag} --display-uri | ||
:{vcs_uri} --name :{name} --output-dir :{archive_dir_path} | ||
- git-bloom-import-upstream :{archive_path} :{patches} --release-version :{version} | ||
--replace | ||
- git-bloom-generate -y rosrelease :{ros_distro} --source upstream -i :{release_inc} | ||
- git-bloom-generate -y rosdebian --prefix release/:{ros_distro} :{ros_distro} | ||
-i :{release_inc} --os-name ubuntu | ||
- git-bloom-generate -y rosdebian --prefix release/:{ros_distro} :{ros_distro} | ||
-i :{release_inc} --os-name debian --os-not-required | ||
- git-bloom-generate -y rosrpm --prefix release/:{ros_distro} :{ros_distro} -i | ||
:{release_inc} --os-name fedora | ||
- git-bloom-generate -y rosrpm --prefix release/:{ros_distro} :{ros_distro} -i | ||
:{release_inc} --os-name rhel | ||
devel_branch: master | ||
last_version: 0.0.0 | ||
name: upstream | ||
patches: null | ||
release_inc: '0' | ||
release_repo_url: http://localhost/repos/foo-release.git | ||
release_tag: :{version} | ||
ros_distro: noetic | ||
vcs_type: git | ||
vcs_uri: http://localhost/repos/foo.git | ||
version: :{auto} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
cmake_minimum_required(VERSION 3.1.3) | ||
project(foo) | ||
|
||
find_package(catkin REQUIRED) | ||
catkin_package() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<?xml version="1.0" ?> | ||
<?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?> | ||
<package format="3"> | ||
<name>foo</name> | ||
<version>0.0.1</version> | ||
<description>Dummy</description> | ||
<maintainer email="[email protected]">Dummy</maintainer> | ||
<license>Dummy</license> | ||
<buildtool_depend>catkin</buildtool_depend> | ||
</package> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
%YAML 1.1 | ||
# ROS index file | ||
# see REP 153: http://ros.org/reps/rep-0153.html | ||
--- | ||
distributions: | ||
noetic: | ||
distribution: [noetic/distribution.yaml] | ||
distribution_cache: http://localhost/cache/noetic-cache.yaml.gz | ||
distribution_status: active | ||
distribution_type: ros1 | ||
python_version: 3 | ||
type: index | ||
version: 4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
%YAML 1.1 | ||
# ROS distribution file | ||
# see REP 143: http://ros.org/reps/rep-0143.html | ||
--- | ||
release_platforms: | ||
ubuntu: | ||
- focal | ||
repositories: | ||
catkin: | ||
doc: | ||
type: git | ||
url: https://github.com/ros/catkin.git | ||
version: noetic-devel | ||
release: | ||
tags: | ||
release: release/noetic/{package}/{version} | ||
url: https://github.com/ros-gbp/catkin-release.git | ||
version: 0.8.10-1 | ||
source: | ||
test_pull_requests: true | ||
type: git | ||
url: https://github.com/ros/catkin.git | ||
version: noetic-devel | ||
status: maintained | ||
foo: | ||
doc: | ||
type: git | ||
url: http://localhost/repos/foo.git | ||
version: master | ||
release: | ||
tags: | ||
release: release/noetic/{package}/{version} | ||
url: http://localhost/repos/foo-release.git | ||
version: 0.0.0-0 | ||
source: | ||
type: git | ||
url: http://localhost/repos/foo.git | ||
version: master | ||
status: maintained | ||
type: distribution | ||
version: 2 |