Coder Social home page Coder Social logo

git-mirror's Introduction

git-mirror

Mirror git repositories.

Architecture

flowchart LR
  rancher

  git-clone  -. create .-> persistent-volume
  git-porter -. read   .-> persistent-volume
  git-scrub  -. delete .-> persistent-volume
  git-mirror -. update .-> persistent-volume

  rancher -. read .-> git-porter

  subgraph chart
    git-scrub
    git-clone
    git-porter
    git-mirror
    persistent-volume
  end

git-mirror's People

Contributors

cloudnautique avatar drpebcak avatar oxr463 avatar rawmind0 avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

git-mirror's Issues

git-sync pod in crashloop backoff for partner-charts repository

INFO: detected pid 1, running init handler
I0616 18:01:40.203668      12 main.go:473] "level"=0 "msg"="starting up" "pid"=12 "args"=["/git-sync"]
I0616 18:01:40.203713      12 main.go:923] "level"=0 "msg"="cloning repo" "origin"="https://github.com/rancher/partner-charts" "path"="/tmp/git"
E0616 18:01:40.576644      12 main.go:525] "msg"="too many failures, aborting" "error"="Run(git clone -v --no-checkout -b master https://github.com/rancher/partner-charts /tmp/git): exit status 128: { stdout: "", stderr: "Cloning into '/tmp/git'...\nPOST git-upload-pack (353 bytes)\nfatal: Remote branch master not found in upstream origin\n" }" "failCount"=0

Investigate alternatives for running nginx and fcgiwrap with tini for git-porter image

There are two potential solutions to look into:

  • A) Rewriting git-porter to use ingress-nginx FCGI services and annotations
  • B) Decomposing git-porter into separate containers: fcgiwrap, and nginx (using volumes to mount the shared socket, and updating the nginx config to point to the fcgiwrap service via cluster-local DNS)

Reference(s):

fcgiwrap.sock connect() failed no such file or directory for git-porter container

Here is the error from the container log:

2022/06/22 19:22:27 [crit] 12#12: *4 connect() to unix:/var/run/fcgiwrap.socket failed (2: No such file or directory) while connecting to upstream, client: 10.42.0.181, server: git-mirror.ftp.sh, request: "GET /rke2-charts.git/info/refs?service=git-upload-pack HTTP/1.1", upstream: "fastcgi://unix:/var/run/fcgiwrap.socket:", host: "git-mirror.ftp.sh"

Here are the permissions:

cd /var/run
ls -la
total 20
drwxr-xr-x    1 root     root          4096 Jun 22 13:44 .
drwxr-xr-x    1 root     root          4096 Jun 22 13:44 ..
drwxrwsr-x    2 fcgiwrap www-data      4096 Jun 22 13:44 fcgiwrap
-rw-r--r--    1 root     root             3 Jun 22 13:44 nginx.pid
drwxr-xr-x    3 root     root          4096 Jun 22 13:44 secrets

cd /var/run/fcgiwrap
ls -la
total 8
drwxrwsr-x    2 fcgiwrap www-data      4096 Jun 22 13:44 .
drwxr-xr-x    1 root     root          4096 Jun 22 13:44 ..

Reference(s):

Permission denied for '/root/.config/git/attributes'

git clone https://git-mirror.ftp.sh/rke2-charts.git
Cloning into 'rke2-charts'...
remote: warning: unable to access '/root/.config/git/attributes': Permission denied
remote: Enumerating objects: 7363, done.
remote: Counting objects: 100% (7363/7363), done.
remote: Compressing objects: 100% (2679/2679), done.
remote: Total 7363 (delta 4221), reused 7363 (delta 4221), pack-reused 0
Receiving objects: 100% (7363/7363), 6.61 MiB | 2.01 MiB/s, done.
Resolving deltas: 100% (4221/4221), done.

Update NOTES template for helm chart

  • We need to display all of the repository URLs, instead of just the one... which is currently broken.
  • We need to update the URL for the source repository
Release "git-mirror" has been upgraded. Happy Helming!
NAME: git-mirror
LAST DEPLOYED: Thu Jun 16 17:59:25 2022
NAMESPACE: git-mirror-chart-testing
STATUS: deployed
REVISION: 3
TEST SUITE: None
NOTES:
1. Get the application URL by running these commands:
  https://map[host:git.rancher.io]

Source can be found here: https://github.com/rancher/git-mirror-docker

git-sync pod in crashloop backoff for rke2-charts repository

INFO: detected pid 1, running init handler
I0616 18:01:41.176330      13 main.go:473] "level"=0 "msg"="starting up" "pid"=13 "args"=["/git-sync"]
I0616 18:01:41.176372      13 main.go:923] "level"=0 "msg"="cloning repo" "origin"="https://github.com/rancher/rke2-charts" "path"="/tmp/git"
E0616 18:01:41.559356      13 main.go:525] "msg"="too many failures, aborting" "error"="Run(git clone -v --no-checkout -b master https://github.com/rancher/rke2-charts /tmp/git): exit status 128: { stdout: "", stderr: "Cloning into '/tmp/git'...\nPOST git-upload-pack (353 bytes)\nfatal: Remote branch master not found in upstream origin\n" }" "failCount"=0

info/refs no such file or directory

2022/06/28 18:28:40 [error] 12#12: *1 open() "/var/git/rke2-charts/info/refs" failed (2: No such file or directory), client: 10.42.0.181, server: git-mirror.ftp.sh, request: "GET /rke2-charts/info/refs?service=git-upload-pack HTTP/1.1", host: "git-mirror.ftp.sh" 

Originally posted by @oxr463 in #24 (comment)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.