From c03b8698d7ee6ffe40a81dd4492dcd94ebe00cb2 Mon Sep 17 00:00:00 2001 From: mwcm17 <mwcm17@inf.ufpr.br> Date: Wed, 20 Feb 2019 10:23:37 -0300 Subject: [PATCH] api document script --- .gitlab-ci.yml | 28 +++++++++++++++++++++------- docploy.sh | 26 ++++++++++++++++++++++++++ 2 files changed, 47 insertions(+), 7 deletions(-) create mode 100755 docploy.sh diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index cd5ec997e..fc5b65cbe 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -17,6 +17,7 @@ variables: stages: - test + - apidoc - deploy before_script: @@ -43,13 +44,26 @@ test: - elasticsearch - redis -#deploy: -# stage: deploy -# script: -# - mina deploy -# only: -# - master -# tags: +doc: + stage: apidoc + script: + - bundle exec rake db:migrate:reset RAILS_ENV=test + - bundle exec rake docs:generate + - ./docploy.sh + only: + - stable + tags: + - ruby + - postgres + - elasticsearch + - redis +# deploy: +# stage: deploy +# script: +# # - mina deploy +# only: +# - master +# tags: # - ruby # - postgres # - elasticsearch diff --git a/docploy.sh b/docploy.sh new file mode 100755 index 000000000..e07bd6bf0 --- /dev/null +++ b/docploy.sh @@ -0,0 +1,26 @@ +#!/bin/bash + +# Copyright (C) 2015 Centro de Computacao Cientifica e Software Livre +# Departamento de Informatica - Universidade Federal do Parana +# +# This file is part of portalmec. +# +# portalmec is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# portalmec is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with portalmec. If not, see <http://www.gnu.org/licenses/>. + + +eval "$(ssh-agent -s)" +ssh-add <(echo "$SSH_KEY_PROD") + + +scp -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -r /builds/portalmec/portalmec/doc/ $SSH_HOST_PROD:/home/portalmec/ \ No newline at end of file -- GitLab