nextrevision / vagrant-rancher

Vagrant plugin to install a Rancher server and agents on all Vagrant guests.
MIT License
4 stars 4 forks source link

Rancher 2.x API error #8

Open feffi opened 6 years ago

feffi commented 6 years ago

Hi, while trying to setup a Rancher 2.x preview, I got the following error on vagrant up:

$ vagrant up
Bringing machine 'rancher-server-01' up with 'virtualbox' provider...
Bringing machine 'k8s-nodes-01' up with 'virtualbox' provider...
Bringing machine 'k8s-nodes-02' up with 'virtualbox' provider...
Bringing machine 'k8s-nodes-03' up with 'virtualbox' provider...
Bringing machine 'k8s-nodes-04' up with 'virtualbox' provider...
==> rancher-server-01: Importing base box 'coreos-alpha'...
==> rancher-server-01: Matching MAC address for NAT networking...
==> rancher-server-01: Checking if box 'coreos-alpha' is up to date...
==> rancher-server-01: Setting the name of the VM: vagrant-rancher-ci_rancher-server-01_1507538246956_46661
==> rancher-server-01: Clearing any previously set network interfaces...
==> rancher-server-01: Preparing network interfaces based on configuration...
    rancher-server-01: Adapter 1: nat
    rancher-server-01: Adapter 2: hostonly
==> rancher-server-01: Forwarding ports...
    rancher-server-01: 22 (guest) => 2222 (host) (adapter 1)
==> rancher-server-01: Running 'pre-boot' VM customizations...
==> rancher-server-01: Booting VM...
==> rancher-server-01: Waiting for machine to boot. This may take a few minutes...
    rancher-server-01: SSH address: 127.0.0.1:2222
    rancher-server-01: SSH username: core
    rancher-server-01: SSH auth method: private key
==> rancher-server-01: Machine booted and ready!
==> rancher-server-01: Setting hostname...
==> rancher-server-01: Configuring and enabling network interfaces...
==> rancher-server-01: Exporting NFS shared folders...
==> rancher-server-01: Preparing to edit /etc/exports. Administrator privileges will be required...
==> rancher-server-01: Mounting NFS shared folders...
==> rancher-server-01: Running provisioner: rancher...
==> rancher-server-01: Pulling Rancher server image: rancher/server:v2.0.0-alpha10...
==> rancher-server-01: Starting server container: rancher/server:v2.0.0-alpha10...
    rancher-server-01: Waiting for server API to become available...
There was an error connecting to the Rancher API endpoint at
http://10.0.0.11:8080

The error returned was

784: unexpected token at '<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta id="viewport" name="viewport" content="width=device-width, initial-scale=1">
    <link rel="icon" href="/assets/images/logos/favicon.ico">
    <title>Loading&hellip;</title>
    <!-- 2.0.11 -->
    <meta name="description" content="">
    <base href="/" />
    <link id = "vendor" rel="stylesheet" href="/assets/vendor.css">
    <link id="theme" rel="stylesheet">

  </head>
  <body>

    <script src="/assets/vendor-c3196d14bd22086a6449ddff4eb53ce6.js"></script>
    <script src="/assets/ui-66d49349f3b9451c253ba33e1e723751.js"></script>

  </body>
</html>
'

The uses Vagrant and config files are here: https://github.com/feffi/vagrant-rancher-ci The version of rancher I tried was: v2.0.0-alpha10

nextrevision commented 6 years ago

Thanks! I'll take a look at making this compatible with 2.x.