File: userdata_setup.yaml

package info (click to toggle)
ceph 18.2.7%2Bds-1
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 1,186,140 kB
  • sloc: cpp: 6,278,388; ansic: 3,507,431; python: 372,964; asm: 216,381; java: 133,450; sh: 125,043; xml: 39,398; ruby: 32,026; makefile: 29,004; javascript: 23,994; cs: 18,980; perl: 9,708; sql: 7,833; lisp: 5,920; pascal: 3,109; ada: 1,681; yacc: 478; awk: 188; f90: 55; php: 1
file content (36 lines) | stat: -rw-r--r-- 1,161 bytes parent folder | download | duplicates (3)
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
#cloud-config-archive

- type: text/cloud-config
  content: |
    output:
      all: '| tee -a /var/log/cloud-init-output.log'

# allow passwordless access for debugging
- |
  #!/usr/bin/env bash
  exec passwd -d ubuntu

- |
  #!/usr/bin/env bash

  # mount a NFS share for storing logs
  sed -i 's/archive.ubuntu.com/old-releases.ubuntu.com/' /etc/apt/sources.list
  sed -i 's/security.ubuntu.com/old-releases.ubuntu.com/' /etc/apt/sources.list
  apt-get update

  # DST Root CA X3 certificate expired on Sep 30, 2021.  It was used by
  # Let's Encrypt, which is what git.ceph.com relies on for HTTPS.  Get the
  # new Let's Encrypt root certificate in place and deactivate the old one
  # (lines that begin with "!" are deselected).
  apt-get install --only-upgrade ca-certificates libssl1.0.0
  sed -i 's/mozilla\/DST_Root_CA_X3\.crt/!mozilla\/DST_Root_CA_X3\.crt/' /etc/ca-certificates.conf
  update-ca-certificates

  apt-get -y install nfs-common
  mkdir /mnt/log
  # 10.0.2.2 is the host
  mount -v -t nfs -o proto=tcp 10.0.2.2:{mnt_dir} /mnt/log

  # mount the iso image that has the test script
  mkdir /mnt/cdrom
  mount -t auto /dev/cdrom /mnt/cdrom