Skip to content
Snippets Groups Projects
Commit ae926761 authored by Mika Perälä's avatar Mika Perälä
Browse files

PDK update - switch to letsencrypt - correct PDK errors - dont use runserver

parent b8c5e74c
No related branches found
No related tags found
2 merge requests!21PDK update - switch to letsencrypt - correct PDK errors - dont use runserver,!20PDK update - switch to letsencrypt - correct PDK errors - dont use runserver
Pipeline #74900 passed
...@@ -13,14 +13,18 @@ https://github.com/microsoft/vscode-dev-containers/tree/v0.140.1/containers/pupp ...@@ -13,14 +13,18 @@ https://github.com/microsoft/vscode-dev-containers/tree/v0.140.1/containers/pupp
// Set *default* container specific settings.json values on container create. // Set *default* container specific settings.json values on container create.
"settings": { "settings": {
"terminal.integrated.shell.linux": "/bin/bash" "terminal.integrated.profiles.linux": {
"bash": {
"path": "bash",
}
}
}, },
// Add the IDs of extensions you want installed when the container is created. // Add the IDs of extensions you want installed when the container is created.
"extensions": [ "extensions": [
"puppet.puppet-vscode", "puppet.puppet-vscode",
"rebornix.Ruby" "rebornix.Ruby"
] ],
// Use 'forwardPorts' to make a list of ports inside the container available locally. // Use 'forwardPorts' to make a list of ports inside the container available locally.
"forwardPorts": [], "forwardPorts": [],
......
...@@ -4,7 +4,7 @@ require: ...@@ -4,7 +4,7 @@ require:
- rubocop-rspec - rubocop-rspec
AllCops: AllCops:
DisplayCopNames: true DisplayCopNames: true
TargetRubyVersion: '2.4' TargetRubyVersion: '2.5'
Include: Include:
- "**/*.rb" - "**/*.rb"
Exclude: Exclude:
......
...@@ -24,6 +24,7 @@ group :development do ...@@ -24,6 +24,7 @@ group :development do
gem "puppet-module-posix-dev-r#{minor_version}", '~> 1.0', require: false, platforms: [:ruby] gem "puppet-module-posix-dev-r#{minor_version}", '~> 1.0', require: false, platforms: [:ruby]
gem "puppet-module-win-default-r#{minor_version}", '~> 1.0', require: false, platforms: [:mswin, :mingw, :x64_mingw] gem "puppet-module-win-default-r#{minor_version}", '~> 1.0', require: false, platforms: [:mswin, :mingw, :x64_mingw]
gem "puppet-module-win-dev-r#{minor_version}", '~> 1.0', require: false, platforms: [:mswin, :mingw, :x64_mingw] gem "puppet-module-win-dev-r#{minor_version}", '~> 1.0', require: false, platforms: [:mswin, :mingw, :x64_mingw]
gem "voxpupuli-puppet-lint-plugins", '>= 3.0', require: false
gem "puppet-lint-absolute_classname-check", '3.0.1', require: false gem "puppet-lint-absolute_classname-check", '3.0.1', require: false
gem "puppet-lint-absolute_template_path", '1.0.1', require: false gem "puppet-lint-absolute_template_path", '1.0.1', require: false
gem "puppet-lint-empty_trailing_lines", '0.0.1', require: false gem "puppet-lint-empty_trailing_lines", '0.0.1', require: false
......
...@@ -4,28 +4,31 @@ ...@@ -4,28 +4,31 @@
# #
# @example # @example
# include tracingcarbon # include tracingcarbon
class tracingcarbon { class tracingcarbon (
) {
include profiles::letsencrypt
firewalld_service { 'Allow SSH in the liu zone': firewalld_service { 'Allow SSH in the liu zone':
ensure => present, ensure => present,
zone => 'liu', zone => 'liu',
service => 'ssh', service => 'ssh',
} }
firewalld_service {'Allow http in the liu Zone': firewalld_service { 'Allow http in the liu Zone':
ensure => present, ensure => present,
zone => 'liu', zone => 'liu',
service => 'http', service => 'http',
} }
firewalld_service {'Allow https in the liu Zone': firewalld_service { 'Allow https in the liu Zone':
ensure => present, ensure => present,
zone => 'liu', zone => 'liu',
service => 'https', service => 'https',
} }
firewalld_service {'Allow http in the public Zone': firewalld_service { 'Allow http in the public Zone':
ensure => present, ensure => present,
zone => 'public', zone => 'public',
service => 'http', service => 'http',
} }
firewalld_service {'Allow https in the public Zone': firewalld_service { 'Allow https in the public Zone':
ensure => present, ensure => present,
zone => 'public', zone => 'public',
service => 'https', service => 'https',
...@@ -36,10 +39,7 @@ class tracingcarbon { ...@@ -36,10 +39,7 @@ class tracingcarbon {
sshkey => 'AAAAB3NzaC1yc2EAAAADAQABAAABAQDHsZ1q+e4nD2SAx659Kv1vf3tmhQmQJ/KOe4zOk4FyJt2OUoHsv82RD4rYVXxcnGojwFjTAtYTW2B4q/f334IGY9aezow/b39kkg977bJ7AC/OU1enkWFK3nkDtkP7htVbsSeogvyHf32niyosDvW8VCTNe9DZctyJ5Eu9AB0z/tuAr++/z+9sWYtiG0sGn/rUnrAvOqWHkTR2ShZHZPyXq+UCrJXHfbJ+P9EzzgFjr2uPoFgBiCqd0Ov2/zWP3k+chGcbSSKtJ3I3Ylh49jAxB1/srct4R0o7sNOKQBnrXXTAIkDLma2ilu0dAksPjD22ZYvWgRt03u7qxQR6lOB/', #lint:ignore:140chars sshkey => 'AAAAB3NzaC1yc2EAAAADAQABAAABAQDHsZ1q+e4nD2SAx659Kv1vf3tmhQmQJ/KOe4zOk4FyJt2OUoHsv82RD4rYVXxcnGojwFjTAtYTW2B4q/f334IGY9aezow/b39kkg977bJ7AC/OU1enkWFK3nkDtkP7htVbsSeogvyHf32niyosDvW8VCTNe9DZctyJ5Eu9AB0z/tuAr++/z+9sWYtiG0sGn/rUnrAvOqWHkTR2ShZHZPyXq+UCrJXHfbJ+P9EzzgFjr2uPoFgBiCqd0Ov2/zWP3k+chGcbSSKtJ3I3Ylh49jAxB1/srct4R0o7sNOKQBnrXXTAIkDLma2ilu0dAksPjD22ZYvWgRt03u7qxQR6lOB/', #lint:ignore:140chars
} }
include certdist
include tracingcarbon::python include tracingcarbon::python
# include tracingcarbon::yarn #include tracingcarbon::yarn
#include tracingcarbon::runserver
include tracingcarbon::runserver
} }
# Ensures python is installed # Ensures python is installed
class tracingcarbon::python ( ) { class tracingcarbon::python (
package { 'python39' : ) {
package { 'python39':
ensure => 'installed', ensure => 'installed',
} }
} }
# Starts the django server in a pipenv, if not already running # Starts the django server in a pipenv, if not already running
class tracingcarbon::runserver () { class tracingcarbon::runserver (
exec { 'Run django' : ) {
exec { 'Run django':
command => 'npm run build && pipenv run python3 manage.py migrate && pipenv run python3 manage.py runserver &', command => 'npm run build && pipenv run python3 manage.py migrate && pipenv run python3 manage.py runserver &',
path => [ '/home/mange61/.local/bin', '/usr/bin', '/bin' ], path => ['/home/mange61/.local/bin', '/usr/bin', '/bin'],
cwd => '/home/mange61/tracing-carbon', cwd => '/home/mange61/tracing-carbon',
user => 'mange61', user => 'mange61',
unless => 'nc localhost 8000 -w 1', unless => 'nc localhost 8000 -w 1',
......
# Ensures yarn is installed # Ensures yarn is installed
class tracingcarbon::yarn ( ) { class tracingcarbon::yarn (
) {
package { 'nodejs' : package { 'nodejs' :
ensure => 'installed', ensure => 'installed',
} }
......
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
"version_requirement": ">= 6.21.0 < 8.0.0" "version_requirement": ">= 6.21.0 < 8.0.0"
} }
], ],
"pdk-version": "2.4.0", "pdk-version": "2.5.0",
"template-url": "https://gitlab.it.liu.se/puppet-infra/pdk-templates.git#liu", "template-url": "https://gitlab.it.liu.se/puppet-infra/pdk-templates.git#liu",
"template-ref": "heads/liu-0-g76c91ed" "template-ref": "heads/liu-0-gcb718ad"
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment