mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-16 16:31:41 +00:00
ci: publicar los assets
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
This commit is contained in:
parent
12a85bc585
commit
723b8e7974
1 changed files with 32 additions and 19 deletions
|
@ -1,23 +1,4 @@
|
|||
pipeline:
|
||||
assets:
|
||||
image: "registry.nulo.in/sutty/panel:3.14.8-2.7.6"
|
||||
commands:
|
||||
- "apk add python2 dotenv"
|
||||
- "yarn"
|
||||
- "cp .env.example .env"
|
||||
- "dotenv bundle install --path=vendor"
|
||||
- "dotenv RAILS_ENV=production bundle exec rails assets:precompile assets:clean"
|
||||
- "git add assets && git commit -m \"[skip ci] JS\" || true"
|
||||
when:
|
||||
branch:
|
||||
- "rails"
|
||||
- "panel.sutty.nl"
|
||||
path:
|
||||
include:
|
||||
- "app/assets/**/*"
|
||||
- "app/javascript/**/*"
|
||||
- "package.json"
|
||||
- "yarn.lock"
|
||||
publish:
|
||||
image: "plugins/docker"
|
||||
settings:
|
||||
|
@ -44,6 +25,38 @@ pipeline:
|
|||
include:
|
||||
- "Dockerfile"
|
||||
- ".dockerignore"
|
||||
assets:
|
||||
image: "registry.nulo.in/sutty/panel:${ALPINE_VERSION}-${RUBY_VERSION}.${RUBY_PATCH}"
|
||||
commands:
|
||||
- "apk add python2 dotenv openssh-client"
|
||||
- "mkdir ~/.ssh/"
|
||||
- "echo \"$${KNOW_HOSTS}\" | base64 -d >> ~/.ssh/known_hosts"
|
||||
- "eval $(ssh-agent -s)"
|
||||
- "echo \"$${SSH_KEY}\" | base64 -d | ssh-add -"
|
||||
- "git config user.name Woodpecker"
|
||||
- "git config user.email ci@sutty.coop.ar"
|
||||
- "git remote add origin ${ORIGIN}"
|
||||
- "git checkout -B ${CI_COMMIT_BRANCH}"
|
||||
- "yarn"
|
||||
- "cp .env.example .env"
|
||||
- "dotenv bundle install --path=vendor"
|
||||
- "dotenv RAILS_ENV=production bundle exec rails assets:precompile assets:clean"
|
||||
- "git add public && git commit -m \"ci: assets [skip ci]\""
|
||||
- "git push origin ${CI_COMMIT_BRANCH}"
|
||||
secrets:
|
||||
- "SSH_KEY"
|
||||
- "KNOWN_HOSTS"
|
||||
- "ORIGIN"
|
||||
when:
|
||||
branch:
|
||||
- "rails"
|
||||
- "panel.sutty.nl"
|
||||
path:
|
||||
include:
|
||||
- "app/assets/**/*"
|
||||
- "app/javascript/**/*"
|
||||
- "package.json"
|
||||
- "yarn.lock"
|
||||
matrix:
|
||||
include:
|
||||
- ALPINE_VERSION: "3.14.8"
|
||||
|
|
Loading…
Reference in a new issue