mirror of https://github.com/apache/cloudstack.git
Merge branch '2.1.x' of ssh://anthony@git.cloud.com/var/lib/git/cloudstack-oss into 2.1.x
This commit is contained in:
commit
df35aa1d16
|
|
@ -95,6 +95,7 @@ setup_router() {
|
|||
fi
|
||||
sed -i -e "s/^dhcp-range=.*$/dhcp-range=$DHCP_RANGE,static/" /etc/dnsmasq.conf
|
||||
sed -i -e "s/^[#]*listen-address=.*$/listen-address=$ETH0_IP/" /etc/dnsmasq.conf
|
||||
sed -i -e "s/^log-queries.*$/#log-queries/" /etc/dnsmasq.conf
|
||||
sed -i /gateway/d /etc/hosts
|
||||
echo "$ETH0_IP $NAME" >> /etc/hosts
|
||||
[ -f /etc/httpd/conf/httpd.conf ] && sed -i -e "s/^Listen.*$/Listen $ETH0_IP:80/" /etc/httpd/conf/httpd.conf
|
||||
|
|
|
|||
|
|
@ -0,0 +1,13 @@
|
|||
/var/log/dnsmasq.log {
|
||||
daily
|
||||
missingok
|
||||
rotate 5
|
||||
notifempty
|
||||
delaycompress
|
||||
sharedscripts
|
||||
postrotate
|
||||
[ ! -f /var/run/dnsmasq.pid ] || kill -USR2 `cat /var/run/dnsmasq.pid`
|
||||
endscript
|
||||
create 0640 dnsmasq dnsmasq
|
||||
}
|
||||
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
/var/log/haproxy.log {
|
||||
daily
|
||||
rotate 5
|
||||
missingok
|
||||
notifempty
|
||||
size 10M
|
||||
postrotate
|
||||
/bin/kill -HUP `cat /var/run/rsyslog.pid 2> /dev/null` 2> /dev/null || true
|
||||
endscript
|
||||
}
|
||||
|
|
@ -0,0 +1,29 @@
|
|||
# Log all kernel messages to the console.
|
||||
# Logging much else clutters up the screen.
|
||||
#kern.* /dev/console
|
||||
|
||||
# Log anything (except mail) of level info or higher.
|
||||
# Don't log private authentication messages!
|
||||
*.info;mail.none;authpriv.none;cron.none;local0.none /var/log/messages
|
||||
|
||||
# The authpriv file has restricted access.
|
||||
authpriv.* /var/log/secure
|
||||
|
||||
# Log all the mail messages in one place.
|
||||
mail.* -/var/log/maillog
|
||||
|
||||
|
||||
# Log cron stuff
|
||||
cron.* /var/log/cron
|
||||
|
||||
# Everybody gets emergency messages
|
||||
*.emerg *
|
||||
|
||||
# Save news errors of level crit and higher in a special file.
|
||||
uucp,news.crit /var/log/spooler
|
||||
|
||||
# Save boot messages also to boot.log
|
||||
local7.* /var/log/boot.log
|
||||
|
||||
#haproxy
|
||||
local0.* /var/log/haproxy.log
|
||||
|
|
@ -0,0 +1,23 @@
|
|||
*nat
|
||||
:PREROUTING ACCEPT [0:0]
|
||||
:POSTROUTING ACCEPT [0:0]
|
||||
:OUTPUT ACCEPT [0:0]
|
||||
COMMIT
|
||||
*filter
|
||||
:INPUT DROP [0:0]
|
||||
:FORWARD DROP [0:0]
|
||||
:OUTPUT ACCEPT [0:0]
|
||||
-A INPUT -i eth0 -m state --state RELATED,ESTABLISHED -j ACCEPT
|
||||
-A INPUT -i eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
|
||||
-A INPUT -p icmp -j ACCEPT
|
||||
-A INPUT -i lo -j ACCEPT
|
||||
-A INPUT -i eth0 -p udp -m udp --dport 67 -j ACCEPT
|
||||
-A INPUT -i eth0 -p udp -m udp --dport 53 -j ACCEPT
|
||||
-A INPUT -i eth1 -p tcp -m state --state NEW --dport 3922 -j ACCEPT
|
||||
-A INPUT -i eth0 -p tcp -m state --state NEW --dport 8080 -j ACCEPT
|
||||
-A INPUT -i eth0 -p tcp -m state --state NEW --dport 80 -j ACCEPT
|
||||
-A FORWARD -i eth0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
|
||||
-A FORWARD -i eth0 -o eth2 -j ACCEPT
|
||||
-A FORWARD -i eth2 -o eth0 -m state --state RELATED,ESTABLISHED -j ACCEPT
|
||||
COMMIT
|
||||
|
||||
|
|
@ -0,0 +1,23 @@
|
|||
*nat
|
||||
:PREROUTING ACCEPT [0:0]
|
||||
:POSTROUTING ACCEPT [0:0]
|
||||
:OUTPUT ACCEPT [0:0]
|
||||
COMMIT
|
||||
*filter
|
||||
:INPUT DROP [0:0]
|
||||
:FORWARD DROP [0:0]
|
||||
:OUTPUT ACCEPT [0:0]
|
||||
-A INPUT -i eth0 -m state --state RELATED,ESTABLISHED -j ACCEPT
|
||||
-A INPUT -i eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
|
||||
-A INPUT -p icmp -j ACCEPT
|
||||
-A INPUT -i lo -j ACCEPT
|
||||
-A INPUT -i eth0 -p udp -m udp --dport 67 -j ACCEPT
|
||||
-A INPUT -i eth0 -p udp -m udp --dport 53 -j ACCEPT
|
||||
-A INPUT -i eth1 -p tcp -m state --state NEW --dport 3922 -j ACCEPT
|
||||
-A INPUT -i eth0 -p tcp -m state --state NEW --dport 8080 -j ACCEPT
|
||||
-A INPUT -i eth0 -p tcp -m state --state NEW --dport 80 -j ACCEPT
|
||||
-A FORWARD -i eth0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
|
||||
-A FORWARD -i eth0 -o eth2 -j ACCEPT
|
||||
-A FORWARD -i eth2 -o eth0 -m state --state RELATED,ESTABLISHED -j ACCEPT
|
||||
COMMIT
|
||||
|
||||
|
|
@ -286,6 +286,7 @@ public abstract class BaseCmd {
|
|||
START_VLAN("startvlan", BaseCmd.TYPE_LONG, "startvlan"),
|
||||
END_VLAN("endvlan", BaseCmd.TYPE_LONG, "endvlan"),
|
||||
SIZE("size", BaseCmd.TYPE_LONG, "size"),
|
||||
SIZE_NETAPP_VOL("netappvolsize", BaseCmd.TYPE_LONG, "netappvolsize"),
|
||||
STATE("state", BaseCmd.TYPE_STRING, "state"),
|
||||
STORAGE("storage", BaseCmd.TYPE_LONG, "storage"),
|
||||
SUCCESS("success", BaseCmd.TYPE_BOOLEAN, "success"),
|
||||
|
|
|
|||
|
|
@ -1247,8 +1247,13 @@ public class ConsoleProxyManagerImpl implements ConsoleProxyManager,
|
|||
ConsoleAccessAuthenticationCommand cmd) {
|
||||
long vmId = 0;
|
||||
|
||||
String ticket = ConsoleProxyServlet.genAccessTicket(cmd.getHost(), cmd.getPort(), cmd.getSid(), cmd.getVmId());
|
||||
String ticketInUrl = cmd.getTicket();
|
||||
if(ticketInUrl == null) {
|
||||
s_logger.error("No access ticket found, you could be running an old console proxy. vmId: " + cmd.getVmId());
|
||||
return new ConsoleAccessAuthenticationAnswer(cmd, false);
|
||||
}
|
||||
|
||||
String ticket = ConsoleProxyServlet.genAccessTicket(cmd.getHost(), cmd.getPort(), cmd.getSid(), cmd.getVmId());
|
||||
if(!ticket.startsWith(ticketInUrl)) {
|
||||
s_logger.error("Access ticket expired or has been modified. vmId: " + cmd.getVmId());
|
||||
return new ConsoleAccessAuthenticationAnswer(cmd, false);
|
||||
|
|
|
|||
|
|
@ -82,7 +82,7 @@ CREATE TABLE `cloud`.`netapp_storage_pool` (
|
|||
`aggregate_name` varchar(255) NOT NULL COMMENT 'name for the aggregate',
|
||||
`pool_name` varchar(255) NOT NULL COMMENT 'name for the pool/volume',
|
||||
`snapshot_policy` varchar(255) NOT NULL COMMENT 'snapshot policy',
|
||||
`pool_size` bigint unsigned COMMENT 'size of the pool',
|
||||
`pool_size` varchar(15) COMMENT 'size of the pool eg 15g',
|
||||
`round_robin_marker` bigint unsigned COMMENT 'this is set to 1 to indicate the vol/pool to use for allocation',
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||
|
|
|
|||
Loading…
Reference in New Issue