Closed Nuyb closed 7 years ago
Those scripts you copied and pasted demonstrate examples of things you can put it. The data you put didn't work because it doesn't make sense. Nobody said that the examples would work right now. They are examples.
libpython2.7
) is no longer available at this version (2.7.3-0ubuntu3.1
). So script is fine but it's impossible to do.foobar
because the group, selinux group, and other things don't exist yetubuntu
because users foo
and bar
don't existYou have to read and understand documentation.
Tested hostname and timezone functionalities in Windows instances but they both failed. Tried digging through the Cloudbase-init log files but couldn't find anything useful. The script that I inputted appears in the log files but there's no indication as to why they failed. I tried Googling both of these issues but couldn't find anything helpful.
Test powershell script.
@DSpeichert tested it and it works
Try
#cloud-config
timezone: Eastern Standard Time
on Windows.
Nobody said timezone names are the same on Windows and Linux.
https://msdn.microsoft.com/en-us/library/ms912391(v=winembedded.11).aspx
didn't work either
Keep trying, or google a working example.
Cent OS
Functionality | Success/Fail | Priority Level | Justification | Use Cases |
---|---|---|---|---|
Yum Repo | Success | Low | Package managment tool meant to be used CentOs to install RedHat package manager | 1. Can be Used on CentOS to install packages |
Yum Repo Script:
#cloud-config
`#cloud-config
yum_repos:
# The name of the repository
epel-testing:
# Any repository configuration options
# See: man yum.conf
#
# This one is required!
baseurl: http://download.fedoraproject.org/pub/epel/testing/5/$basearch
enabled: false
failovermethod: priority
gpgcheck: true
gpgkey: file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL
name: Extra Packages for Enterprise Linux 5 - Testing`
Windows
#cloud-config
set_timezone: America/New_York
Cent OS
Functionality | Success/Fail | Priority Level | Justification | Use Cases |
---|---|---|---|---|
CA-Cert | Failed | Medium | Allows users to add trusted certificates | 1. Can be used for adding organization certificates for possible assignments |
ca-cert Script
#cloud-config
ca-certs:
# If present and set to True, the 'remove-defaults' parameter will remove
# all the default trusted CA certificates that are normally shipped with
# Ubuntu.
# This is mainly for paranoid admins - most users will not need this
# functionality.
remove-defaults: true
# If present, the 'trusted' parameter should contain a certificate (or list
# of certificates) to add to the system as trusted CA certificates.
# Pay close attention to the YAML multiline list syntax. The example shown
# here is for a list of multiline certificates.
trusted:
- |
-----BEGIN CERTIFICATE-----
MIICCTCCAXKgAwIBAgIBATANBgkqhkiG9w0BAQUFADANMQswCQYDVQQDDAJjYTAe
Fw0xMDAyMTUxNzI5MjFaFw0xNTAyMTQxNzI5MjFaMA0xCzAJBgNVBAMMAmNhMIGf
MA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCu7Q40sm47/E1Pf+r8AYb/V/FWGPgc
b014OmNoX7dgCxTDvps/h8Vw555PdAFsW5+QhsGr31IJNI3kSYprFQcYf7A8tNWu
1MASW2CfaEiOEi9F1R3R4Qlz4ix+iNoHiUDTjazw/tZwEdxaQXQVLwgTGRwVa+aA
qbutJKi93MILLwIDAQABo3kwdzA4BglghkgBhvhCAQ0EKxYpUHVwcGV0IFJ1Ynkv
T3BlblNTTCBHZW5lcmF0ZWQgQ2VydGlmaWNhdGUwDwYDVR0TAQH/BAUwAwEB/zAd
BgNVHQ4EFgQUu4+jHB+GYE5Vxo+ol1OAhevspjAwCwYDVR0PBAQDAgEGMA0GCSqG
SIb3DQEBBQUAA4GBAH/rxlUIjwNb3n7TXJcDJ6MMHUlwjr03BDJXKb34Ulndkpaf
+GAlzPXWa7bO908M9I8RnPfvtKnteLbvgTK+h+zX1XCty+S2EQWk29i2AdoqOTxb
hppiGMp0tT5Havu4aceCXiy2crVcudj3NFciy8X66SoECemW9UYDCb9T5D0d
-----END CERTIFICATE-----
- |
Questions for @DSpeichert:
@Nuyb Come up with a proposal that works and open a PR with it. Then I'll tell you if that's viable.
@DSpeichert In terms of a proposal, do you want to specify model data and form entries for each script or actually code it first for your review.
Just do it. Show me code.
Completed according to new (slightly changed) requirements. We're dropping the support for defining extra users/groups.
Related work and other functionality previously unplanned in:
Objectives:
Do NOT edit this comment. Post new comments in this issue.
Linux
Scripts
Install Packages Script:
Users and Groups Script:
User Scripts:
Write Files Script:
Final Message Script:
Timezone Script:
Hostname Script:
Windows
Scripts
PowerShell Script:
Timezone Script:
Hostname Script: