mirror of
https://github.com/OpenNebula/one.git
synced 2025-01-08 21:17:43 +03:00
M #-: URL changes
* opennebula.org -> opennebula.io * opennebula.systems -> opennebula.io also * removed unused sunstone code and conf * remove trailing whitespaces
This commit is contained in:
parent
944f9ab7cf
commit
466f9b3fb8
12
README.md
12
README.md
@ -8,7 +8,7 @@
|
|||||||
OpenNebula is an open-source project delivering a simple but feature-rich and
|
OpenNebula is an open-source project delivering a simple but feature-rich and
|
||||||
flexible solution to build and manage enterprise clouds and virtualized data centers.
|
flexible solution to build and manage enterprise clouds and virtualized data centers.
|
||||||
|
|
||||||
Complete documentation: https://docs.opennebula.org
|
Complete documentation: https://docs.opennebula.io
|
||||||
|
|
||||||
How to contribute: https://github.com/OpenNebula/one/wiki/How-to-Contribute-to-Development
|
How to contribute: https://github.com/OpenNebula/one/wiki/How-to-Contribute-to-Development
|
||||||
|
|
||||||
@ -44,7 +44,7 @@ include a handy script to install them and the requirements. It is located at
|
|||||||
`share/install_gems/install_gems` and you should use it to install the
|
`share/install_gems/install_gems` and you should use it to install the
|
||||||
required gems. You have more information at:
|
required gems. You have more information at:
|
||||||
|
|
||||||
https://docs.opennebula.org/stable/integration/references/compile.html
|
https://docs.opennebula.io/stable/integration/references/compile.html
|
||||||
|
|
||||||
If you want to install them manually here are the list of required rubygems:
|
If you want to install them manually here are the list of required rubygems:
|
||||||
|
|
||||||
@ -156,20 +156,20 @@ You can find the documentation about OpenNebula architecture, installation,
|
|||||||
configuration and references to configuration files in this documentation
|
configuration and references to configuration files in this documentation
|
||||||
chapter:
|
chapter:
|
||||||
|
|
||||||
https://docs.opennebula.org/stable/deployment/index.html
|
https://docs.opennebula.io/stable/deployment/index.html
|
||||||
|
|
||||||
The reference about the main configuration file is located here:
|
The reference about the main configuration file is located here:
|
||||||
|
|
||||||
https://docs.opennebula.org/stable/deployment/references/oned_conf.html
|
https://docs.opennebula.io/stable/deployment/references/oned_conf.html
|
||||||
|
|
||||||
|
|
||||||
## Contact
|
## Contact
|
||||||
|
|
||||||
OpenNebula web page: https://opennebula.org
|
OpenNebula web page: https://opennebula.io
|
||||||
|
|
||||||
Development and issue tracking: https://github.com/OpenNebula/one/issues
|
Development and issue tracking: https://github.com/OpenNebula/one/issues
|
||||||
|
|
||||||
Support: https://opennebula.org/support
|
Support: https://opennebula.io/support
|
||||||
|
|
||||||
|
|
||||||
## License
|
## License
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
Each project has it's own way of doing things. The following simple rules capture the OpenNebula dev team gitflow. Comments are welcome (contact@opennebula.org)!
|
Each project has it's own way of doing things. The following simple rules capture the OpenNebula dev team gitflow. Comments are welcome (contact@opennebula.io)!
|
||||||
|
|
||||||
OpenNebula branches
|
OpenNebula branches
|
||||||
===================
|
===================
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
opennebula_repository_version: '5.10'
|
opennebula_repository_version: '5.10'
|
||||||
|
|
||||||
# Repository of the OpenNebula packages
|
# Repository of the OpenNebula packages
|
||||||
opennebula_repository_base: 'https://downloads.opennebula.org/repo/{{ opennebula_repository_version }}'
|
opennebula_repository_base: 'https://downloads.opennebula.io/repo/{{ opennebula_repository_version }}'
|
||||||
|
|
||||||
# Enable GPG check for the packages
|
# Enable GPG check for the packages
|
||||||
opennebula_repository_gpgcheck: yes
|
opennebula_repository_gpgcheck: yes
|
||||||
|
@ -19,7 +19,7 @@
|
|||||||
when: ansible_distribution == "RedHat"
|
when: ansible_distribution == "RedHat"
|
||||||
|
|
||||||
- name: Add repository GPG key for RPM
|
- name: Add repository GPG key for RPM
|
||||||
rpm_key: key=https://downloads.opennebula.org/repo/repo.key
|
rpm_key: key=https://downloads.opennebula.io/repo/repo.key
|
||||||
when: opennebula_repository_gpgcheck | bool
|
when: opennebula_repository_gpgcheck | bool
|
||||||
|
|
||||||
- name: Add OpenNebula repository
|
- name: Add OpenNebula repository
|
||||||
@ -27,7 +27,7 @@
|
|||||||
name: opennebula
|
name: opennebula
|
||||||
description: OpenNebula packages
|
description: OpenNebula packages
|
||||||
baseurl: "{{ opennebula_repository_base }}/CentOS/{{ ansible_distribution_major_version }}/{{ ansible_architecture }}"
|
baseurl: "{{ opennebula_repository_base }}/CentOS/{{ ansible_distribution_major_version }}/{{ ansible_architecture }}"
|
||||||
gpgkey: https://downloads.opennebula.org/repo/repo.key
|
gpgkey: https://downloads.opennebula.io/repo/repo.key
|
||||||
gpgcheck: "{{ opennebula_repository_gpgcheck }}"
|
gpgcheck: "{{ opennebula_repository_gpgcheck }}"
|
||||||
repo_gpgcheck: "{{ opennebula_repository_repo_gpgcheck }}"
|
repo_gpgcheck: "{{ opennebula_repository_repo_gpgcheck }}"
|
||||||
notify: "clean repository metadata"
|
notify: "clean repository metadata"
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
|
|
||||||
- name: Add repository key
|
- name: Add repository key
|
||||||
apt_key:
|
apt_key:
|
||||||
url: https://downloads.opennebula.org/repo/repo.key
|
url: https://downloads.opennebula.io/repo/repo.key
|
||||||
validate_certs: no
|
validate_certs: no
|
||||||
state: present
|
state: present
|
||||||
register: apt_result
|
register: apt_result
|
||||||
|
@ -49,12 +49,12 @@ Gem::Specification.new do |s|
|
|||||||
s.summary = "$(SUMMARY)"
|
s.summary = "$(SUMMARY)"
|
||||||
s.description = "$(DESCRIPTION)"
|
s.description = "$(DESCRIPTION)"
|
||||||
s.authors = ["OpenNebula"]
|
s.authors = ["OpenNebula"]
|
||||||
s.email = 'contact@opennebula.org'
|
s.email = 'contact@opennebula.io'
|
||||||
s.license = 'Apache-2.0'
|
s.license = 'Apache-2.0'
|
||||||
s.files = [
|
s.files = [
|
||||||
$(FILES)
|
$(FILES)
|
||||||
]
|
]
|
||||||
s.homepage = 'http://opennebula.org'
|
s.homepage = 'http://opennebula.io'
|
||||||
$(EXECUTABLES)
|
$(EXECUTABLES)
|
||||||
$(DEPENDENCIES)
|
$(DEPENDENCIES)
|
||||||
end
|
end
|
||||||
@ -237,4 +237,3 @@ Dir.chdir(root)
|
|||||||
|
|
||||||
|
|
||||||
GEM_DESCRIPTION.each {|name, gem| generate_gem(gem) }
|
GEM_DESCRIPTION.each {|name, gem| generate_gem(gem) }
|
||||||
|
|
||||||
|
@ -45,7 +45,7 @@ module OpenNebula
|
|||||||
#
|
#
|
||||||
# @param [OpenNebula::Client] client the xml-rpc client
|
# @param [OpenNebula::Client] client the xml-rpc client
|
||||||
# @param [Integer] user_id the filter flag, see
|
# @param [Integer] user_id the filter flag, see
|
||||||
# http://opennebula.org/documentation:rel3.6:api
|
# http://docs.opennebula.io/stable/integration/system_interfaces/api.html
|
||||||
#
|
#
|
||||||
# @return [DocumentPool] the new object
|
# @return [DocumentPool] the new object
|
||||||
def initialize(cloud_auth, client)
|
def initialize(cloud_auth, client)
|
||||||
|
@ -25,7 +25,7 @@ require 'rexml/document'
|
|||||||
# OpenNebula MarketPlace
|
# OpenNebula MarketPlace
|
||||||
class OneMarket
|
class OneMarket
|
||||||
|
|
||||||
ONE_MARKET_URL = 'https://marketplace.opennebula.systems/'
|
ONE_MARKET_URL = 'https://marketplace.opennebula.io/'
|
||||||
AGENT = 'Market Driver'
|
AGENT = 'Market Driver'
|
||||||
VERSION = File.dirname(__FILE__) + '/../../VERSION'
|
VERSION = File.dirname(__FILE__) + '/../../VERSION'
|
||||||
|
|
||||||
|
@ -15,7 +15,7 @@ type NIC struct {
|
|||||||
type NICKeys string
|
type NICKeys string
|
||||||
|
|
||||||
// Some keys are specific to VM some others to VRouter
|
// Some keys are specific to VM some others to VRouter
|
||||||
// For VM values: https://docs.opennebula.org/5.8/operation/references/template.html#network-section
|
// For VM values: https://docs.opennebula.io/5.8/operation/references/template.html#network-section
|
||||||
const (
|
const (
|
||||||
NICVec string = "NIC"
|
NICVec string = "NIC"
|
||||||
NICID NICKeys = "NIC_ID"
|
NICID NICKeys = "NIC_ID"
|
||||||
|
@ -15,7 +15,7 @@
|
|||||||
/*--------------------------------------------------------------------------- */
|
/*--------------------------------------------------------------------------- */
|
||||||
package keys
|
package keys
|
||||||
|
|
||||||
// Available template parts and keys are listed here: https://docs.opennebula.org/5.8/operation/references/template.html
|
// Available template parts and keys are listed here: https://docs.opennebula.io/5.8/operation/references/template.html
|
||||||
// Some specific part are not defined: vCenter, Public Cloud, Hypervisor, User Inputs
|
// Some specific part are not defined: vCenter, Public Cloud, Hypervisor, User Inputs
|
||||||
|
|
||||||
// Template is a type used to enumerate VM generic keys
|
// Template is a type used to enumerate VM generic keys
|
||||||
|
@ -26,7 +26,7 @@ import (
|
|||||||
"github.com/OpenNebula/one/src/oca/go/src/goca/schemas/vm/keys"
|
"github.com/OpenNebula/one/src/oca/go/src/goca/schemas/vm/keys"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Available template parts and keys are listed here: https://docs.opennebula.org/5.8/operation/references/template.html
|
// Available template parts and keys are listed here: https://docs.opennebula.io/5.8/operation/references/template.html
|
||||||
// Some specific part are not defined: vCenter, Public Cloud, Hypervisor, User Inputs
|
// Some specific part are not defined: vCenter, Public Cloud, Hypervisor, User Inputs
|
||||||
|
|
||||||
// Template is a structure allowing to parse VM templates.
|
// Template is a structure allowing to parse VM templates.
|
||||||
|
@ -85,7 +85,7 @@ do_documentation()
|
|||||||
-doctitle 'OpenNebula Cloud API Specification' \
|
-doctitle 'OpenNebula Cloud API Specification' \
|
||||||
-header '<b>OpenNebula</b><br><font size="-1">Cloud API</font>' \
|
-header '<b>OpenNebula</b><br><font size="-1">Cloud API</font>' \
|
||||||
-bottom 'Visit <a
|
-bottom 'Visit <a
|
||||||
href="http://opennebula.org/">OpenNebula.org</a><br>Copyright 2002-2019 ©
|
href="http://opennebula.io/">OpenNebula.io</a><br>Copyright 2002-2019 ©
|
||||||
OpenNebula Project, OpenNebula Systems.'
|
OpenNebula Project, OpenNebula Systems.'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -23,12 +23,12 @@ The jar files you need are xmlrpc-client-*.jar, ws-commons-util-*.jar and xmlrpc
|
|||||||
|
|
||||||
<h2>Related Documentation</h2>
|
<h2>Related Documentation</h2>
|
||||||
<p>
|
<p>
|
||||||
Please visit the <a href="http://opennebula.org">OpenNebula</a> site for general information,
|
Please visit the <a href="http://opennebula.io">OpenNebula</a> site for general information,
|
||||||
and consult the <a href="http://opennebula.org/doku.php?id=documentation">documentation section</a>
|
and consult the <a href="http://docs.opennebula.io">documentation section</a>
|
||||||
to find up to date references, tutorials, and more.
|
to find up to date references, tutorials, and more.
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
You can learn about the OpenNebula XML-RPC API <a href="http://opennebula.org/doku.php?id=documentation:rel1.4:api">here</a>.
|
You can learn about the OpenNebula XML-RPC API <a href="http://docs.opennebula.io/stable/integration/system_interfaces/api.html">here</a>.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<!-- Put @see and @since tags down here. -->
|
<!-- Put @see and @since tags down here. -->
|
||||||
|
@ -47,7 +47,7 @@ setup(
|
|||||||
long_description=long_description,
|
long_description=long_description,
|
||||||
|
|
||||||
# The project's main homepage.
|
# The project's main homepage.
|
||||||
url='http://opennebula.org',
|
url='http://opennebula.io',
|
||||||
|
|
||||||
# Author details
|
# Author details
|
||||||
author='Rafael del Valle',
|
author='Rafael del Valle',
|
||||||
|
@ -52,7 +52,7 @@ module OpenNebula
|
|||||||
#
|
#
|
||||||
# @param [OpenNebula::Client] client the xml-rpc client
|
# @param [OpenNebula::Client] client the xml-rpc client
|
||||||
# @param [Integer] user_id the filter flag, see
|
# @param [Integer] user_id the filter flag, see
|
||||||
# http://opennebula.org/documentation:rel3.6:api
|
# http://docs.opennebula.io/stable/integration/system_interfaces/api.html
|
||||||
#
|
#
|
||||||
# @return [DocumentPool] the new object
|
# @return [DocumentPool] the new object
|
||||||
def initialize(client, user_id=-1)
|
def initialize(client, user_id=-1)
|
||||||
|
@ -97,14 +97,6 @@
|
|||||||
# Two Factor Authentication Issuer Label
|
# Two Factor Authentication Issuer Label
|
||||||
:two_factor_auth_issuer: opennebula
|
:two_factor_auth_issuer: opennebula
|
||||||
|
|
||||||
################################################################################
|
|
||||||
# Check Upgrades
|
|
||||||
################################################################################
|
|
||||||
|
|
||||||
# To check for the latest release. Comment this value if you don't want to check
|
|
||||||
# this.
|
|
||||||
:remote_version: http://downloads.opennebula.org/latest
|
|
||||||
|
|
||||||
################################################################################
|
################################################################################
|
||||||
# UI Settings
|
# UI Settings
|
||||||
################################################################################
|
################################################################################
|
||||||
@ -164,7 +156,7 @@
|
|||||||
# The url should not include the /appliance path since it will be automatically
|
# The url should not include the /appliance path since it will be automatically
|
||||||
# included
|
# included
|
||||||
#
|
#
|
||||||
:marketplace_url: http://marketplace.opennebula.systems/
|
:marketplace_url: http://marketplace.opennebula.io/
|
||||||
|
|
||||||
################################################################################
|
################################################################################
|
||||||
# OneFlow
|
# OneFlow
|
||||||
@ -203,7 +195,7 @@
|
|||||||
|
|
||||||
# this display button and clock icon in table of vm
|
# this display button and clock icon in table of vm
|
||||||
:leases:
|
:leases:
|
||||||
suspense:
|
suspense:
|
||||||
time: "+1209600"
|
time: "+1209600"
|
||||||
color: "#000000"
|
color: "#000000"
|
||||||
warning:
|
warning:
|
||||||
|
@ -36,7 +36,7 @@ define(function(require) {
|
|||||||
SupportUtils.checkLastVersionSupport();
|
SupportUtils.checkLastVersionSupport();
|
||||||
$(".support_not_connected > button").on("click", function(e){
|
$(".support_not_connected > button").on("click", function(e){
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
window.open("http://opennebula.systems/opennebula-support/", "_blank");
|
window.open("http://opennebula.io/support/", "_blank");
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -95,7 +95,7 @@ define(function(require) {
|
|||||||
});
|
});
|
||||||
|
|
||||||
if (message){
|
if (message){
|
||||||
var link = $("<a/>", {href:"https://opennebula.org/software/"}).text(
|
var link = $("<a/>", {href:"https://opennebula.io/use/"}).text(
|
||||||
"(new version available: " + gitVersion + ")"
|
"(new version available: " + gitVersion + ")"
|
||||||
);
|
);
|
||||||
$("#latest_version").show().empty().append(link);
|
$("#latest_version").show().empty().append(link);
|
||||||
|
@ -21,7 +21,7 @@ require 'base64'
|
|||||||
|
|
||||||
UNSUPPORTED_RUBY = !(RUBY_VERSION =~ /^1.8/).nil?
|
UNSUPPORTED_RUBY = !(RUBY_VERSION =~ /^1.8/).nil?
|
||||||
GITHUB_TAGS_URL = 'https://api.github.com/repos/opennebula/one/tags'
|
GITHUB_TAGS_URL = 'https://api.github.com/repos/opennebula/one/tags'
|
||||||
ENTERPRISE_REPO_URL = 'https://downloads.opennebula.systems/repo/'
|
ENTERPRISE_REPO_URL = 'https://downloads.opennebula.io/repo/'
|
||||||
|
|
||||||
begin
|
begin
|
||||||
require 'zendesk_api'
|
require 'zendesk_api'
|
||||||
|
@ -241,17 +241,17 @@ SUPPORT = {
|
|||||||
:custom_field_severity => 391197,
|
:custom_field_severity => 391197,
|
||||||
:author_id => 21231023,
|
:author_id => 21231023,
|
||||||
:author_name => "OpenNebula Support Team",
|
:author_name => "OpenNebula Support Team",
|
||||||
:support_subscription => "http://opennebula.systems/support/",
|
:support_subscription => "https://opennebula.io/support/",
|
||||||
:account => "http://opennebula.systems/buy/",
|
:account => "https://opennebula.io/buy-support",
|
||||||
:docs => "http://docs.opennebula.org/5.11/",
|
:docs => "https://docs.opennebula.io/5.11/",
|
||||||
:community => "http://opennebula.org/support/community/",
|
:community => "https://opennebula.io/usec",
|
||||||
:project => "OpenNebula"
|
:project => "OpenNebula"
|
||||||
}
|
}
|
||||||
|
|
||||||
UPGRADE = {
|
UPGRADE = {
|
||||||
:upgrade => "<span style='color: #0098c3' id='itemUpdate' style='display:none;'>Upgrade Available</span> <span style='color:#DC7D24'><i class='fas fa-exclamation-circle'></i></span>",
|
:upgrade => "<span style='color: #0098c3' id='itemUpdate' style='display:none;'>Upgrade Available</span> <span style='color:#DC7D24'><i class='fas fa-exclamation-circle'></i></span>",
|
||||||
:no_upgrade => "",
|
:no_upgrade => "",
|
||||||
:url => "http://opennebula.org/software/"
|
:url => "https://opennebula.io/use/"
|
||||||
}
|
}
|
||||||
|
|
||||||
##############################################################################
|
##############################################################################
|
||||||
@ -637,16 +637,7 @@ end
|
|||||||
get '/version' do
|
get '/version' do
|
||||||
version = {}
|
version = {}
|
||||||
|
|
||||||
if (remote_version_url = $conf[:remote_version])
|
version["version"] = OpenNebula::VERSION
|
||||||
begin
|
|
||||||
version = JSON.parse(Net::HTTP.get(URI(remote_version_url)))
|
|
||||||
rescue Exception
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
if !version["version"] || version["version"].empty?
|
|
||||||
version["version"] = OpenNebula::VERSION
|
|
||||||
end
|
|
||||||
|
|
||||||
[200, version.to_json]
|
[200, version.to_json]
|
||||||
end
|
end
|
||||||
|
@ -90,7 +90,7 @@
|
|||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<div id="footer" class="text-center large-12 columns">
|
<div id="footer" class="text-center large-12 columns">
|
||||||
<a href="http://opennebula.org" target="_blank">OpenNebula <%= OpenNebula::VERSION %></a>
|
<a href="http://opennebula.io" target="_blank">OpenNebula <%= OpenNebula::VERSION %></a>
|
||||||
<div id="latest_version" style="display:none;"></div>
|
<div id="latest_version" style="display:none;"></div>
|
||||||
<p>by <a href="http://OpenNebula.systems" target="_blank">OpenNebula Systems</a>.</p>
|
<p>by <a href="http://OpenNebula.systems" target="_blank">OpenNebula Systems</a>.</p>
|
||||||
</div>
|
</div>
|
||||||
|
@ -59,9 +59,9 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer" style="overflow:visible;">
|
<div id="footer" style="overflow:visible;">
|
||||||
<a href="http://opennebula.org" target="_blank">OpenNebula <%= OpenNebula::VERSION %></a>
|
<a href="http://opennebula.io" target="_blank">OpenNebula <%= OpenNebula::VERSION %></a>
|
||||||
by
|
by
|
||||||
<a href="http://opennebula.systems" target="_blank">OpenNebula Systems</a>
|
<a href="http://opennebula.io" target="_blank">OpenNebula Systems</a>
|
||||||
.
|
.
|
||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
||||||
|
@ -1,23 +1,23 @@
|
|||||||
/*
|
/*
|
||||||
|
|
||||||
Copyright (C) 2007 Proxmox Server Solutions GmbH
|
Copyright (C) 2007 Proxmox Server Solutions GmbH
|
||||||
|
|
||||||
Copyright: vzdump is under GNU GPL, the GNU General Public License.
|
Copyright: vzdump is under GNU GPL, the GNU General Public License.
|
||||||
|
|
||||||
This program is free software; you can redistribute it and/or modify
|
This program is free software; you can redistribute it and/or modify
|
||||||
it under the terms of the GNU General Public License as published by
|
it under the terms of the GNU General Public License as published by
|
||||||
the Free Software Foundation; version 2 dated June, 1991.
|
the Free Software Foundation; version 2 dated June, 1991.
|
||||||
|
|
||||||
This program is distributed in the hope that it will be useful,
|
This program is distributed in the hope that it will be useful,
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
GNU General Public License for more details.
|
GNU General Public License for more details.
|
||||||
|
|
||||||
You should have received a copy of the GNU General Public License
|
You should have received a copy of the GNU General Public License
|
||||||
along with this program; if not, write to the Free Software
|
along with this program; if not, write to the Free Software
|
||||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
||||||
02111-1307, USA.
|
02111-1307, USA.
|
||||||
|
|
||||||
Author: Dietmar Maurer <dietmar@proxmox.com>
|
Author: Dietmar Maurer <dietmar@proxmox.com>
|
||||||
|
|
||||||
Copyright 2002-2019, OpenNebula Project, OpenNebula Systems
|
Copyright 2002-2019, OpenNebula Project, OpenNebula Systems
|
||||||
@ -26,12 +26,12 @@
|
|||||||
- Added command line options & usage
|
- Added command line options & usage
|
||||||
- Other minor code changes
|
- Other minor code changes
|
||||||
|
|
||||||
contact@opennebula.systems
|
contact@opennebula.io
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <zlib.h>
|
#include <zlib.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <linux/limits.h>
|
#include <linux/limits.h>
|
||||||
#include <getopt.h>
|
#include <getopt.h>
|
||||||
@ -66,7 +66,7 @@ static int vt_font_maxsize = 0; //Max size of fontmap
|
|||||||
#define PSF2_SEPARATOR 0xFF
|
#define PSF2_SEPARATOR 0xFF
|
||||||
#define PSF2_STARTSEQ 0xFE
|
#define PSF2_STARTSEQ 0xFE
|
||||||
|
|
||||||
struct psf2_header
|
struct psf2_header
|
||||||
{
|
{
|
||||||
unsigned char magic[4];
|
unsigned char magic[4];
|
||||||
unsigned int version;
|
unsigned int version;
|
||||||
@ -89,7 +89,7 @@ struct psf2_header
|
|||||||
*/
|
*/
|
||||||
static int font_add_glyph (const char *data, unsigned int gsize)
|
static int font_add_glyph (const char *data, unsigned int gsize)
|
||||||
{
|
{
|
||||||
if (vt_font_size >= vt_font_maxsize)
|
if (vt_font_size >= vt_font_maxsize)
|
||||||
{
|
{
|
||||||
vt_font_maxsize += 256;
|
vt_font_maxsize += 256;
|
||||||
vt_font_data = realloc (vt_font_data, vt_font_maxsize * gsize);
|
vt_font_data = realloc (vt_font_data, vt_font_maxsize * gsize);
|
||||||
@ -158,7 +158,7 @@ static int load_psf_font (const char *filename, int is_default)
|
|||||||
|
|
||||||
gzFile f = gzopen(filename, "rb");
|
gzFile f = gzopen(filename, "rb");
|
||||||
|
|
||||||
if (f == NULL)
|
if (f == NULL)
|
||||||
{
|
{
|
||||||
fprintf (stderr, "unable to read file %s\n", filename);
|
fprintf (stderr, "unable to read file %s\n", filename);
|
||||||
return -1;
|
return -1;
|
||||||
@ -167,7 +167,7 @@ static int load_psf_font (const char *filename, int is_default)
|
|||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
/* Load PSF2 header and check consistency */
|
/* Load PSF2 header and check consistency */
|
||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
if (gzread(f, &psf2hdr, psf2hdr_len) != psf2hdr_len)
|
if (gzread(f, &psf2hdr, psf2hdr_len) != psf2hdr_len)
|
||||||
{
|
{
|
||||||
fprintf(stderr, "Wrong header in psf2 font file (%s)\n", filename);
|
fprintf(stderr, "Wrong header in psf2 font file (%s)\n", filename);
|
||||||
gzclose(f);
|
gzclose(f);
|
||||||
@ -208,7 +208,7 @@ static int load_psf_font (const char *filename, int is_default)
|
|||||||
|
|
||||||
char *chardata = (char *) malloc (font_size);
|
char *chardata = (char *) malloc (font_size);
|
||||||
|
|
||||||
if (gzread(f, chardata, font_size)!= font_size)
|
if (gzread(f, chardata, font_size)!= font_size)
|
||||||
{
|
{
|
||||||
fprintf (stderr, "Cannot read font character data from %s\n", filename);
|
fprintf (stderr, "Cannot read font character data from %s\n", filename);
|
||||||
gzclose (f);
|
gzclose (f);
|
||||||
@ -221,7 +221,7 @@ static int load_psf_font (const char *filename, int is_default)
|
|||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
/* Read the Unicode description of the glyphs */
|
/* Read the Unicode description of the glyphs */
|
||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
for (int glyph = 0 ;glyph < psf2hdr.length ;glyph++)
|
for (int glyph = 0 ;glyph < psf2hdr.length ;glyph++)
|
||||||
{
|
{
|
||||||
int fi = 0;
|
int fi = 0;
|
||||||
char s;
|
char s;
|
||||||
@ -241,9 +241,9 @@ static int load_psf_font (const char *filename, int is_default)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!vt_fontmap[uchar] && uchar != 0)
|
if (!vt_fontmap[uchar] && uchar != 0)
|
||||||
{
|
{
|
||||||
if (!fi)
|
if (!fi)
|
||||||
{
|
{
|
||||||
fi = font_add_glyph(chardata + glyph * gsize, gsize);
|
fi = font_add_glyph(chardata + glyph * gsize, gsize);
|
||||||
}
|
}
|
||||||
@ -251,11 +251,11 @@ static int load_psf_font (const char *filename, int is_default)
|
|||||||
vt_fontmap[uchar] = fi;
|
vt_fontmap[uchar] = fi;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (is_default && fi && glyph < 256)
|
if (is_default && fi && glyph < 256)
|
||||||
{
|
{
|
||||||
vt_fontmap[0xf000 + glyph] = fi;
|
vt_fontmap[0xf000 + glyph] = fi;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
free(chardata);
|
free(chardata);
|
||||||
@ -274,7 +274,7 @@ void print_glyphs ()
|
|||||||
|
|
||||||
printf ("static unsigned char vt_font_data[] = {\n");
|
printf ("static unsigned char vt_font_data[] = {\n");
|
||||||
|
|
||||||
for (int i = 0; i < vt_font_size; i++)
|
for (int i = 0; i < vt_font_size; i++)
|
||||||
{
|
{
|
||||||
printf("\t/* %d 0x%02x */\n", i, i);
|
printf("\t/* %d 0x%02x */\n", i, i);
|
||||||
|
|
||||||
@ -284,10 +284,10 @@ void print_glyphs ()
|
|||||||
|
|
||||||
printf ("\t0x%02X, /* ", d);
|
printf ("\t0x%02X, /* ", d);
|
||||||
|
|
||||||
for (int k = 128; k > 0; k = k>>1)
|
for (int k = 128; k > 0; k = k>>1)
|
||||||
{
|
{
|
||||||
printf ("%c", (d & k) ? '1': '0');
|
printf ("%c", (d & k) ? '1': '0');
|
||||||
}
|
}
|
||||||
|
|
||||||
printf (" */\n");
|
printf (" */\n");
|
||||||
}
|
}
|
||||||
@ -299,7 +299,7 @@ void print_glyphs ()
|
|||||||
|
|
||||||
printf ("static unsigned short vt_fontmap[65536] = {\n");
|
printf ("static unsigned short vt_fontmap[65536] = {\n");
|
||||||
|
|
||||||
for (int i = 0; i < 0x0ffff; i++)
|
for (int i = 0; i < 0x0ffff; i++)
|
||||||
{
|
{
|
||||||
printf ("\t/* 0x%04X => */ %d,\n", i, vt_fontmap[i]);
|
printf ("\t/* 0x%04X => */ %d,\n", i, vt_fontmap[i]);
|
||||||
}
|
}
|
||||||
@ -313,7 +313,7 @@ void print_glyphs ()
|
|||||||
|
|
||||||
static void print_usage()
|
static void print_usage()
|
||||||
{
|
{
|
||||||
fprintf(stderr, "Usage: genfont [-d font_path] [font1 font2...]\n");
|
fprintf(stderr, "Usage: genfont [-d font_path] [font1 font2...]\n");
|
||||||
fprintf(stderr, "Generate Glyph Bitmaps and associated Unicode mapping\n\n");
|
fprintf(stderr, "Generate Glyph Bitmaps and associated Unicode mapping\n\n");
|
||||||
fprintf(stderr, "\tfont1... List of fonts, the first one is the default\n\n");
|
fprintf(stderr, "\tfont1... List of fonts, the first one is the default\n\n");
|
||||||
fprintf(stderr, "\t-d path: Font path defaults to /usr/share/consolefonts\n\n");
|
fprintf(stderr, "\t-d path: Font path defaults to /usr/share/consolefonts\n\n");
|
||||||
@ -370,4 +370,3 @@ int main (int argc, char** argv)
|
|||||||
|
|
||||||
exit (0);
|
exit (0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -31,7 +31,7 @@
|
|||||||
- Simplify timeout managemnt
|
- Simplify timeout managemnt
|
||||||
- Adds some specific options
|
- Adds some specific options
|
||||||
|
|
||||||
contact@opennebula.systems
|
contact@opennebula.io
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@ -106,7 +106,7 @@ ucs2_to_utf8 (unicode c, char *out)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
rfb_draw_char (rfbScreenInfoPtr rfbScreen, int x, int y, unsigned short c,
|
rfb_draw_char (rfbScreenInfoPtr rfbScreen, int x, int y, unsigned short c,
|
||||||
rfbPixel col)
|
rfbPixel col)
|
||||||
{
|
{
|
||||||
if (c > vt_font_size) {
|
if (c > vt_font_size) {
|
||||||
@ -1661,8 +1661,8 @@ new_client (rfbClientPtr client)
|
|||||||
static void
|
static void
|
||||||
rfbVncAuthSendChallenge(rfbClientPtr cl)
|
rfbVncAuthSendChallenge(rfbClientPtr cl)
|
||||||
{
|
{
|
||||||
|
|
||||||
/* 4 byte header is alreay sent. Which is rfbSecTypeVncAuth
|
/* 4 byte header is alreay sent. Which is rfbSecTypeVncAuth
|
||||||
(same as rfbVncAuth). Just send the challenge. */
|
(same as rfbVncAuth). Just send the challenge. */
|
||||||
rfbRandomBytes(cl->authChallenge);
|
rfbRandomBytes(cl->authChallenge);
|
||||||
if (rfbWriteExact(cl, (char *)cl->authChallenge, CHALLENGESIZE) < 0) {
|
if (rfbWriteExact(cl, (char *)cl->authChallenge, CHALLENGESIZE) < 0) {
|
||||||
@ -1670,7 +1670,7 @@ rfbVncAuthSendChallenge(rfbClientPtr cl)
|
|||||||
rfbCloseClient(cl);
|
rfbCloseClient(cl);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Dispatch client input to rfbVncAuthProcessResponse. */
|
/* Dispatch client input to rfbVncAuthProcessResponse. */
|
||||||
cl->state = RFB_AUTHENTICATION;
|
cl->state = RFB_AUTHENTICATION;
|
||||||
}
|
}
|
||||||
@ -1699,8 +1699,8 @@ rfbVncAuthNone(rfbClientPtr cl)
|
|||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Advertise the supported security types (protocol 3.7). Here before sending
|
* Advertise the supported security types (protocol 3.7). Here before sending
|
||||||
* the list of security types to the client one more security type is added
|
* the list of security types to the client one more security type is added
|
||||||
* to the list if primaryType is not set to rfbSecTypeInvalid. This security
|
* to the list if primaryType is not set to rfbSecTypeInvalid. This security
|
||||||
* type is the standard vnc security type which does the vnc authentication
|
* type is the standard vnc security type which does the vnc authentication
|
||||||
* or it will be security type for no authentication.
|
* or it will be security type for no authentication.
|
||||||
@ -1754,7 +1754,7 @@ vncTerm * create_vncterm (int sd, int maxx, int maxy, int *argc, char **argv)
|
|||||||
|
|
||||||
cmap->data.bytes = malloc (16*3);
|
cmap->data.bytes = malloc (16*3);
|
||||||
|
|
||||||
for(int i=0;i<16;i++)
|
for(int i=0;i<16;i++)
|
||||||
{
|
{
|
||||||
cmap->data.bytes[i*3 + 0] = default_red[color_table[i]];
|
cmap->data.bytes[i*3 + 0] = default_red[color_table[i]];
|
||||||
cmap->data.bytes[i*3 + 1] = default_grn[color_table[i]];
|
cmap->data.bytes[i*3 + 1] = default_grn[color_table[i]];
|
||||||
@ -1814,7 +1814,7 @@ vncTerm * create_vncterm (int sd, int maxx, int maxy, int *argc, char **argv)
|
|||||||
|
|
||||||
vt->cells = (TextCell *)calloc(sizeof(TextCell), vt->width*vt->total_height);
|
vt->cells = (TextCell *)calloc(sizeof(TextCell), vt->width*vt->total_height);
|
||||||
|
|
||||||
for (int i = 0; i < vt->width * vt->total_height; i++)
|
for (int i = 0; i < vt->width * vt->total_height; i++)
|
||||||
{
|
{
|
||||||
vt->cells[i].ch = ' ';
|
vt->cells[i].ch = ' ';
|
||||||
vt->cells[i].attrib = vt->default_attrib;
|
vt->cells[i].attrib = vt->default_attrib;
|
||||||
@ -1826,13 +1826,13 @@ vncTerm * create_vncterm (int sd, int maxx, int maxy, int *argc, char **argv)
|
|||||||
|
|
||||||
rfbInitServer(screen);
|
rfbInitServer(screen);
|
||||||
|
|
||||||
if (screen->authPasswdData && strcmp(((char**)screen->authPasswdData)[0],""))
|
if (screen->authPasswdData && strcmp(((char**)screen->authPasswdData)[0],""))
|
||||||
{
|
{
|
||||||
screen->passwordCheck = CheckPasswordByList;
|
screen->passwordCheck = CheckPasswordByList;
|
||||||
|
|
||||||
rfbRegisterSecurityHandler(&VncSecurityHandlerVncAuth);
|
rfbRegisterSecurityHandler(&VncSecurityHandlerVncAuth);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
screen->authPasswdData = NULL;
|
screen->authPasswdData = NULL;
|
||||||
screen->passwordCheck = NULL;
|
screen->passwordCheck = NULL;
|
||||||
@ -2028,7 +2028,7 @@ void cmd_ctrl_pipe(int pipe_fd, struct vncterm_command ** client_fds)
|
|||||||
int i = 0;
|
int i = 0;
|
||||||
int rb;
|
int rb;
|
||||||
|
|
||||||
do
|
do
|
||||||
{
|
{
|
||||||
rb = read(pipe_fd, &c, sizeof(char));
|
rb = read(pipe_fd, &c, sizeof(char));
|
||||||
|
|
||||||
@ -2047,16 +2047,16 @@ void cmd_ctrl_pipe(int pipe_fd, struct vncterm_command ** client_fds)
|
|||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
char * token;
|
char * token;
|
||||||
|
|
||||||
/* FIRST TOKEN: VNC PORT */
|
/* FIRST TOKEN: VNC PORT */
|
||||||
vt_cmd = (struct vncterm_command *) malloc(sizeof(struct vncterm_command));
|
vt_cmd = (struct vncterm_command *) malloc(sizeof(struct vncterm_command));
|
||||||
|
|
||||||
token = strtok(cmd, " ");
|
token = strtok(cmd, " ");
|
||||||
|
|
||||||
vt_cmd->vnc_port = atoi(token);
|
vt_cmd->vnc_port = atoi(token);
|
||||||
|
|
||||||
/* SECOND TOKEN: PASSWD ( - if none ) */
|
/* SECOND TOKEN: PASSWD ( - if none ) */
|
||||||
token = strtok(NULL, " ");
|
token = strtok(NULL, " ");
|
||||||
|
|
||||||
@ -2108,7 +2108,7 @@ void cmd_ctrl_pipe(int pipe_fd, struct vncterm_command ** client_fds)
|
|||||||
|
|
||||||
/* -------------------------------------------------------------------------- */
|
/* -------------------------------------------------------------------------- */
|
||||||
|
|
||||||
int vncterm_cmd(int sd, int timeout, int width, int heigth,
|
int vncterm_cmd(int sd, int timeout, int width, int heigth,
|
||||||
struct vncterm_command * vcmd)
|
struct vncterm_command * vcmd)
|
||||||
{
|
{
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
@ -2427,5 +2427,3 @@ int main (int argc, char** argv)
|
|||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user