Ubuntu Pastebin

Paste from stokachu at Mon, 23 Jan 2017 17:09:46 +0000

Download as text
  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
status

ubuntu@bobbybooshay:/etc/systemd/system$ sudo systemctl start snap.conjure-up.bridge.service 
Job for snap.conjure-up.bridge.service failed because the control process exited with error code. See "systemctl status snap.conjure-up.bridge.service" and "journalctl -xe" for details.
ubuntu@bobbybooshay:/etc/systemd/system$ systemctl status snap.conjure-up.bridge.service
● snap.conjure-up.bridge.service - Service for snap application conjure-up.bridge
   Loaded: loaded (/etc/systemd/system/snap.conjure-up.bridge.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Mon 2017-01-23 17:07:34 UTC; 10s ago
  Process: 1341 ExecStop=/usr/bin/snap run --command=stop conjure-up.bridge (code=exited, status=0/SUCCESS)
  Process: 1550 ExecStart=/usr/bin/snap run conjure-up.bridge (code=exited, status=2)
 Main PID: 1550 (code=exited, status=2)

Jan 23 17:07:34 bobbybooshay systemd[1]: Starting Service for snap application conjure-up.bridge...
Jan 23 17:07:34 bobbybooshay snap[1550]: RTNETLINK answers: File exists
Jan 23 17:07:34 bobbybooshay systemd[1]: snap.conjure-up.bridge.service: Main process exited, code=exited, status=2
Jan 23 17:07:34 bobbybooshay systemd[1]: Failed to start Service for snap application conjure-up.bridge.
Jan 23 17:07:34 bobbybooshay systemd[1]: snap.conjure-up.bridge.service: Unit entered failed state.
Jan 23 17:07:34 bobbybooshay systemd[1]: snap.conjure-up.bridge.service: Failed with result 'exit-code'.


content:

ubuntu@bobbybooshay:/etc/systemd/system$ cat snap.conjure-up.bridge.service 
[Unit]
# Auto-generated, DO NO EDIT
Description=Service for snap application conjure-up.bridge
Requires=snap-conjure\x2dup-x1.mount
Wants=network-online.target
After=snap-conjure\x2dup-x1.mount network-online.target
X-Snappy=yes

[Service]
ExecStart=/usr/bin/snap run conjure-up.bridge
Restart=no
WorkingDirectory=/var/snap/conjure-up/x1
ExecStop=/usr/bin/snap run --command=stop conjure-up.bridge

TimeoutStopSec=30
Type=oneshot


[Install]
WantedBy=multi-user.target


bridge.start

ubuntu@bobbybooshay:~/conjure-up-snap$ cat snapcraft/wrappers/bridge.start 
#!/bin/sh

set -eu

ip link add dev conjureup0 type bridge
ip addr add 10.99.0.1/24 dev conjureup0
ip link set dev conjureup0 up

echo 1 > /proc/sys/net/ipv4/ip_forward

iptables -I FORWARD -i conjureup0 -j ACCEPT
iptables -I FORWARD -o conjureup0 -j ACCEPT
iptables -t nat -A POSTROUTING -s 10.99.0.1/24 ! -d 10.99.0.1/24 -j MASQUERADE
iptables -I INPUT -i conjureup0 -p tcp -m tcp --dport 53 -j ACCEPT
iptables -I INPUT -i conjureup0 -p udp -m udp --dport 53 -j ACCEPT
iptables -I INPUT -i conjureup0 -p tcp -m tcp --dport 67 -j ACCEPT
iptables -I INPUT -i conjureup0 -p udp -m udp --dport 67 -j ACCEPT


snapcraft.yaml

name: conjure-up
version: 2.1.0
summary: Package runtime for conjure-up spells
description: >
   This package provides conjure-up, an interface to installing spells that
   provide the user with an end to end walkthrough experience for installing and
   using big software.
confinement: classic
grade: stable

apps:
  conjure-up:
    command: wrappers/conjure-up
  juju:
    command: bin/juju
  bridge:
    command: wrappers/bridge.start
    stop-command: wrappers/bridge.stop
    restart-condition: never
    daemon: oneshot

parts:
  conjure-up:
    plugin: python
    source: https://github.com/conjure-up/conjure-up
    source-type: git
    source-branch: master
    requirements: requirements.txt
    stage-packages:
      - bsdtar
      - jq
  configs:
    plugin: dump
    source: https://github.com/conjure-up/conjure-up
    source-type: git
    filesets:
      etc/conjure-up.conf: etc/conjure-up.conf
  wrappers:
    plugin: dump
    source: snapcraft/
  juju:
    plugin: godeps
    go-importpath: github.com/juju/juju
    source: https://github.com/juju/juju.git
    source-type: git
    source-tag: juju-2.1-beta4
    prime:
      - bin/juju
Download as text