Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
tf_mod_aws_eks_cluster
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
steamhaus
tf_mod_aws_eks_cluster
Commits
7b69a4ee
Commit
7b69a4ee
authored
Jun 22, 2018
by
Chris Merrett
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Commands with slash line seperation not working, one-linered everywhere
parent
b3b1caf8
Pipeline
#4966
passed with stage
in 16 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
16 deletions
+5
-16
userdata.tpl
templates/userdata.tpl
+5
-16
No files found.
templates/userdata.tpl
View file @
7b69a4ee
...
...
@@ -27,30 +27,19 @@ systemctl daemon-reload
systemctl restart kubelet kube-proxy
# Install cron
yum -y install crontabs
&&
\
chkconfig crond on
&&
\
service crond start
yum -y install crontabs
&&
chkconfig crond on
&&
service crond start
# Add Steamhaus user
adduser steamhaus
&&
\
passwd -l steamhaus
&&
\
mkdir -p /home/steamhaus/bin
&&
\
mkdir -p /home/steamhaus/.ssh
&&
\
chmod 700 /home/steamhaus/.ssh
adduser steamhaus
&&
passwd -l steamhaus
&&
mkdir -p /home/steamhaus/bin
&&
mkdir -p /home/steamhaus/.ssh
&&
chmod 700 /home/steamhaus/.ssh
# Ensure Steamhaus user has full passwordless root
echo "steamhaus ALL=(ALL)NOPASSWD:ALL" > /etc/sudoers.d/steamhaus
&&
\
chmod 440 /etc/sudoers.d/steamhaus
echo "steamhaus ALL=(ALL)NOPASSWD:ALL" > /etc/sudoers.d/steamhaus
&&
chmod 440 /etc/sudoers.d/steamhaus
# Create Steamhaus SSH credential update script
wget --no-check-certificate "https://gist.githubusercontent.com/chrisfu/87b642951aadafa62b99/raw/sh_pubkey_update.sh" -O /home/steamhaus/bin/sh_pubkey_update.sh
&&
\
sed -i 's/`whoami`/steamhaus/g' /home/steamhaus/bin/sh_pubkey_update.sh
&&
\
chmod 755 /home/steamhaus/bin/sh_pubkey_update.sh
wget --no-check-certificate "https://gist.githubusercontent.com/chrisfu/87b642951aadafa62b99/raw/sh_pubkey_update.sh" -O /home/steamhaus/bin/sh_pubkey_update.sh
&&
sed -i s,`whoami`,steamhaus,g /home/steamhaus/bin/sh_pubkey_update.sh
&&
chmod 755 /home/steamhaus/bin/sh_pubkey_update.sh
# Perform first-time update of Steamhaus SSH credentials
/home/steamhaus/bin/sh_pubkey_update.sh
&&
\
# Add Steamhaus update script to cron, run 1am every morning, if first run succeeds
echo "0 1 * * * /home/steamhaus/bin/sh_pubkey_update.sh" > /var/spool/cron/steamhaus
/home/steamhaus/bin/sh_pubkey_update.sh
&&
echo "0 1 * * * /home/steamhaus/bin/sh_pubkey_update.sh" > /var/spool/cron/steamhaus
# Ensure everything within Steamhaus home directory is owned by Steamhaus
chown -R steamhaus: /home/steamhaus/
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment