5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-11-16 16:21:41 +00:00
panel/app/models/deploy_distributed_press.rb

35 lines
653 B
Ruby
Raw Normal View History

2022-10-05 21:44:23 +00:00
# frozen_string_literal: true
# Soportar Distributed Press APIv0
#
# No se realiza ninguna acción porque el deploy se hace desde el plugin
# local.
class DeployDistributedPress < Deploy
store :values, accessors: %i[api_key hostname], coder: JSON
def deploy; end
def limit; end
def size
deploy_local.size
end
# TODO: Devolver hyper:// y otras
def url
"ipfs://#{hostname}/"
end
# Devuelve variables de entorno para enviarle a DeployLocal
#
# @return [Hash]
def local_env
{
'DISTRIBUTED_PRESS_PROJECT_DOMAIN' => hostname,
'DISTRIBUTED_PRESS_API_KEY' => api_key
}
end
def destination; end
end